Re: about probing a device

2007-10-11 Thread wit
thanks all.. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/

Re: about probing a device

2007-10-10 Thread Cornelia Huck
On Wed, 10 Oct 2007 23:50:01 +0800, wit <[EMAIL PROTECTED]> wrote: > > The first one which matches and successfully attaches "wins". > > Seems that calling the bind routine can bind a driver to a device. Is > there any bad side effect of doing such thing? If the device is already bound to anothe

Re: about probing a device

2007-10-10 Thread Greg KH
On Wed, Oct 10, 2007 at 11:41:47PM +0800, wit wrote: > Thanks very much > > > Why, is there some use for multiple drivers to devices that you want to > > use? > > > > I'm just trying to figure out the difference between 2.4 & 2.6 device > drivers. And this is just an issue that came up to my mind

Re: about probing a device

2007-10-10 Thread wit
Thanks very much. > The first one which matches and successfully attaches "wins". Seems that calling the bind routine can bind a driver to a device. Is there any bad side effect of doing such thing? - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message

Re: about probing a device

2007-10-10 Thread Alan Cox
On Wed, 10 Oct 2007 09:39:44 +0800 wit <[EMAIL PROTECTED]> wrote: > Hi, > I found these routines in the kernel, does this means only one driver > can be matched to a device? What if two drivers both can drive the > device, like sd & sg in scsi subsystem? The first one which matches and successful

Re: about probing a device

2007-10-09 Thread Greg KH
On Wed, Oct 10, 2007 at 09:39:44AM +0800, wit wrote: > Hi, > I found these routines in the kernel, does this means only one driver > can be matched to a device? Yes, you are correct, that is how the driver model currently works. > What if two drivers both can drive the device, like sd & sg in scs

about probing a device

2007-10-09 Thread wit
Hi, I found these routines in the kernel, does this means only one driver can be matched to a device? What if two drivers both can drive the device, like sd & sg in scsi subsystem? static int device_attach(struct device * dev) { struct bus_type * bus = dev->bus; struct list_head *