Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 12 Aug 2002 16:35:23 +0800
From:      "ouyang kai" <oykai@msn.com>
To:        <freebsd-hackers@FreeBSD.ORG>
Subject:   Hi, how the kernel add the devices
Message-ID:  <OE60x6F7tagsyN1lcdk0001e877@hotmail.com>

next in thread | raw e-mail | index | archive | help

[-- Attachment #1 --]
Hi Everybody,
  I am a jackaroo to FreeBSD kernel. I have a question about how the kernel add all devices.   
  For example, in NetBSD, I can find the code in /sys/kern/init_main.c:
 /* Attach pseudo-devices. */
for (pdev = pdevinit; pdev->pdev_attach != NULL; pdev++)
              (*pdev->pdev_attach)(pdev->pdev_count);
I know the NetBSD kernel add devices(such as storage device and network device) by them.
But in FreeBSD, I can not locate the place.
which part code should I read?
Thank you.
   
Best Regards
  Ouyang KaiGet more from the Web.  FREE MSN Explorer download : http://explorer.msn.com

[-- Attachment #2 --]
<HTML><BODY STYLE="font:10pt verdana; border:none;"><DIV>Hi Everybody,<BR>&nbsp; I am a jackaroo to FreeBSD kernel. I have a question about how the kernel add all devices.&nbsp; <BR>&nbsp; For example, in NetBSD, I can find the code in /sys/kern/init_main.c:<BR>&nbsp;/* Attach pseudo-devices. */<BR>for (pdev = pdevinit; pdev-&gt;pdev_attach != NULL; pdev++)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (*pdev-&gt;pdev_attach)(pdev-&gt;pdev_count);<BR>I know the NetBSD kernel add devices(such as storage device and network device) by them.<BR>But in FreeBSD, I can not locate the place.<BR>which part code should I read?<BR>Thank you.<BR>&nbsp; <BR>Best Regards<BR>&nbsp; Ouyang Kai</DIV> <DIV>&nbsp;</DIV> <DIV>&nbsp;</DIV></BODY></HTML><br clear=all><hr>Get more from the Web.  FREE MSN Explorer download : <a href='http://explorer.msn.com'>http://explorer.msn.com</a><br></p>;

Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?OE60x6F7tagsyN1lcdk0001e877>