how kernel detect device and make proble() called?

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

 



List,

Example is PCI ethernet card. how kernel knows NIC is inserted to PCI bus and call .probe?

static struct pci_driver e1000_driver = {

	.name     = e1000_driver_name,

	.id_table = e1000_pci_tbl,

	.probe    = e1000_probe,

	.remove   = __devexit_p(e1000_remove),

#ifdef CONFIG_PM

	/* Power Management Hooks */

	.suspend  = e1000_suspend,

	.resume   = e1000_resume,

#endif

#ifndef USE_REBOOT_NOTIFIER

	.shutdown = e1000_shutdown,

#endif

#ifdef HAVE_PCI_ERS

	.err_handler = &e1000_err_handler

#endif

};


--- On Thu, 11/13/08, Greg KH <greg at kroah.com> wrote:

> From: Greg KH <greg at kroah.com>
> Subject: Re: how kernel detect device and make proble() called?
> To: "hong zhang" <henryzhang62 at yahoo.com>
> Cc: devel at linuxdriverproject.org
> Date: Thursday, November 13, 2008, 10:30 AM
> On Thu, Nov 13, 2008 at 08:10:11AM -0800, Greg KH wrote:
> > On Thu, Nov 13, 2008 at 07:34:58AM -0800, hong zhang
> wrote:
> > > List,
> > > 
> > > Does anyone know how kernel detects a device and
> make probe() called for its driver?
> > 
> > Yes.
> 
> (hint, you are going to have to be a lot more specific
> about your
> question in order to get a good answer...)


      


[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux