public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
* qla2300 & mptscsih refcount, or lack thereof
@ 2005-12-30 23:50 Joel Becker
  2006-01-03 19:17 ` Patrick Mansfield
  0 siblings, 1 reply; 4+ messages in thread
From: Joel Becker @ 2005-12-30 23:50 UTC (permalink / raw)
  To: andrew.vasquez, Eric.Moore, linux-scsi, James Bottomley

Folks,
	I've run into an interesting problem.  The qla2300 and
mptspi drivers don't get refcounted for active users, but they are
absolutely required.  Thus, you can do, eg, "rmmod qla2300" with mounted
filesystems, and your system happily removes all child devices.
Hello, EIO!
	Now, I know we're well into "Doctor, it hurts when I do this,"
territory here.  But we generally try not to allow this sort of mistake.
You can't remove a network card while the interface is up, you can't
remove sd_mod while a disk is in use, etc.
	Has this been seen before?  Is there any plan to make qla2300
and mptspi respect the use count of the objects they present to the
system?  Thoughts?

Joel

-- 

Life's Little Instruction Book #222

	"Think twice before burdening a friend with a secret."

Joel Becker
Principal Software Developer
Oracle
E-mail: joel.becker@oracle.com
Phone: (650) 506-8127

^ permalink raw reply	[flat|nested] 4+ messages in thread
* RE: qla2300 & mptscsih refcount, or lack thereof
@ 2006-01-03 22:03 Moore, Eric
  0 siblings, 0 replies; 4+ messages in thread
From: Moore, Eric @ 2006-01-03 22:03 UTC (permalink / raw)
  To: Patrick Mansfield, andrew.vasquez, linux-scsi, James Bottomley

On Tuesday, January 03, 2006 12:18 PM, Patrick Mansfield wrote: 

> snip....

> We probably need to duplicate the .module in struct scsi_host, set it
> appropriately (by default copy struct scsi_host_template 
> value), and then
> use it in scsi_device_get().
> 
> I haven't looked at mptspi drivers.
> 
> -- Patrick Mansfield
> 

There is a patch I posted about a month ago having .module=THIS_MODULE,
in the mptspi.c source.   James Bottomley posted earlier today in
my "Eric Moore" section regarding this.  I believe that is all that is
required
for reference counting, right?  If not, pls let me know.

JB - URL:
http://marc.theaimsgroup.com/?l=linux-scsi&m=113630625920693&w=2

Eric Moore

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2006-01-03 22:03 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-12-30 23:50 qla2300 & mptscsih refcount, or lack thereof Joel Becker
2006-01-03 19:17 ` Patrick Mansfield
2006-01-03 19:28   ` Andrew Vasquez
  -- strict thread matches above, loose matches on Subject: below --
2006-01-03 22:03 Moore, Eric

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox