Re: Plug and play

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jun 29, 2007 at 05:48:01PM -0700, Kamal gupta wrote:
>  hi
>  I am looking in to the kernel code.. I can understand from the code how. if
>  a new driver is added to the system will get configured to the devices.. but
>  I dont understand how the linux do PnP when new device is attached. From
>  some where device_register must be called with the device structure but what
>  I dont understand is who calls this (I can see for some of the devices it is
>  called when machine is started) but not for all devices like for USB
>  devices. Can somebody please guide me ?

Sure, what specific type of device are you wanting to look at here?
PCI?  USB?  PCMCIA?  ExpressCard?  Something else?  They all do this
differently in their bus specific code and then call the driver core to
register the new device which kicks off the binding of a driver to the
device.

I think a good example of this can be found in the book, Linux Device
Drivers, third edition, free online, that shows the chain of calls from
the PCI core, into the driver core, out of the driver core into the PCI
core, into a driver, and then back into the driver core.

If, after reading that you still have specific questions, please let us
know.

hope this helps,

greg k-h

--
To unsubscribe from this list: send an email with
"unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx
Please read the FAQ at http://kernelnewbies.org/FAQ


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux