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

------=_NextPart_001_0001_01C2421E.413F6140
Content-Type: text/plain; charset="gb2312"
Content-Transfer-Encoding: quoted-printable

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

------=_NextPart_001_0001_01C2421E.413F6140
Content-Type: text/html; charset="gb2312"
Content-Transfer-Encoding: quoted-printable

<HTML><BODY STYLE=3D"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 ca=
n find the code in /sys/kern/init_main.c:<BR>&nbsp;/* Attach pseudo-devic=
es. */<BR>for (pdev =3D pdevinit; pdev-&gt;pdev_attach !=3D NULL; pdev++)=
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;&nbsp; (*pdev-&gt;pdev_attach)(pdev-&gt;pdev_count);<BR>I know the Net=
BSD 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 shoul=
d 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=3Dall><hr=
>Get more from the Web.  FREE MSN Explorer download : <a href=3D'http://e=
xplorer.msn.com'>http://explorer.msn.com</a><br></p>;

------=_NextPart_001_0001_01C2421E.413F6140--

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




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