Re: sim710_device_remove seems buggy

2007-07-17 Thread Matthew Wilcox
On Tue, Jul 17, 2007 at 01:57:48PM -0500, James Bottomley wrote: > That's certainly the way lasi700 does it ... so it makes sense that this > driver should as well. OK. Here's a patch to fix all the other drivers that had copied this one: Fix drivers misusing dev_to_shost Some drivers were usin

Re: sim710_device_remove seems buggy

2007-07-17 Thread James Bottomley
On Tue, 2007-07-17 at 12:52 -0600, Matthew Wilcox wrote: > On Tue, Jul 17, 2007 at 10:55:21AM -0600, Matthew Wilcox wrote: > > Unfortunately, I don't have a good idea about how to solve this. The > > least lame perhaps is to have separate routines for EISA and MCA > > devices, each of which passes

Re: sim710_device_remove seems buggy

2007-07-17 Thread Matthew Wilcox
On Tue, Jul 17, 2007 at 10:55:21AM -0600, Matthew Wilcox wrote: > Unfortunately, I don't have a good idea about how to solve this. The > least lame perhaps is to have separate routines for EISA and MCA > devices, each of which passes the shost to this routine. I had an idea. How does this look?

sim710_device_remove seems buggy

2007-07-17 Thread Matthew Wilcox
Hi Richard, I was looking for inspiration in sim710 when I found what appears to me to be a bug. Your implementation of sim710_device_remove does: sim710_device_remove(struct device *dev) { struct Scsi_Host *host = dev_to_shost(dev); Now, this is going to be called with the struct devi