<div dir="ltr">I believe "<span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:12.800000190734863px">CPU through an interrupt</span>" is correct, dude there is lot material on Google on this topic, just try to search using terms "how kernel detect a hardware" or "kernel plug and play" etc, try to use different queries and you will find lot of stuff.<div>
<br></div><div>Cheers,</div><div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Aug 20, 2013 at 6:46 AM, Tao Jiang (姜涛) <span dir="ltr"><<a href="mailto:jiangtao.jit@gmail.com" target="_blank">jiangtao.jit@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Saqlain:<br>
Thanks for your reply.<br>
The article really opened my eyes.<br>
But in that article wrote as<br>
1. " Linux kernel constantly scans all your computer bus’es for any changes and new hardware. Once any change on any bus is detected magic begins "<br>
And in the comments at the bottom,<br>
2. "a bus controller notifies the CPU through an interrupt which allows the kernel to query the controller back for information"<br>
So my question is which one is right?<br>
And can you show me more details on Linux kernel's implementation about "constantly scans" or "notifies the CPU through an interrupt"?<br>
<br>
------------------<br>
Tao Jiang (姜涛)<br>
2013-08-20<br>
<br>
-------------------------------------------------------------<br>
发件人:Saqlain Abbas <<a href="mailto:saqlain.abbas.7@gmail.com">saqlain.abbas.7@gmail.com</a>><br>
发送日期:2013-08-19 19:53<br>
收件人:Tao Jiang (姜涛)<br>
抄送:kernelnewbies<br>
主题:Re: Need help on understanding hardware detection<br>
<div class="HOEnZb"><div class="h5"><br>
have a look at <a href="http://blogas.sysadmin.lt/?p=141" target="_blank">http://blogas.sysadmin.lt/?p=141</a> will give you a nice idea...<br>
<br>
Cheers,<br>
Saqlain.<br>
<br>
<br>
On Mon, Aug 19, 2013 at 4:47 PM, Tao Jiang (姜涛) <<a href="mailto:jiangtao.jit@gmail.com">jiangtao.jit@gmail.com</a>>wrote:<br>
<br>
> Hi All:<br>
> I did some search on "how does linux kernel detect hardware?" and<br>
> got what udev is.<br>
> I konw Linux kernel will send a netlink message to udevd.<br>
> But I still do not understand how the kernel can decide to send a<br>
> netlink message.<br>
> What happend before the netlink message?<br>
> Take an usb stick for example, what will happen and what the<br>
> kernel do from the very beginning of it been plugged in?<br>
> Thank you for advance. Any references will be appreciated.<br>
><br>
> --------------<br>
> Tao Jiang (姜涛)<br>
> 2013-08-19<br>
> _______________________________________________<br>
> Kernelnewbies mailing list<br>
> <a href="mailto:Kernelnewbies@kernelnewbies.org">Kernelnewbies@kernelnewbies.org</a><br>
> <a href="http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies" target="_blank">http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies</a><br>
><br>
<br>
<br>
<br>
--<br>
Kind Regards,<br>
Saqlain Abbas.<br>
<br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br>Kind Regards,<div>Saqlain Abbas.</div>
</div>