public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Oliver Neukum <oliver@neukum.name>
To: Mike Anderson <andmike@us.ibm.com>
Cc: James Bottomley <James.Bottomley@SteelEye.com>,
	SCSI Mailing List <linux-scsi@vger.kernel.org>,
	Matthew Dharm <mdharm-scsi@one-eyed-alien.net>
Subject: Re: [PATCH / RFC] scsi_set_host_offline
Date: Thu, 6 Mar 2003 15:33:39 +0100	[thread overview]
Message-ID: <200303061533.39375.oliver@neukum.name> (raw)
In-Reply-To: <20030305223504.GB4014@beaverton.ibm.com>

> > What exactly is a refcount supposed to do? It doesn't help the main
> > problem. You must prevent new references arising. This requires locking
> > and flags.
>
> Refcounting is need for proper freeing so it needs to be part of the
> solution. We need to have the refcounting implementation prevent gets
> post "offline"
>
> Yes, currently the kobject_get does not contain any support for
> preventing the incrementing of the ref count. This needs to be wrapped
> by the implementor (I believe as I do not see the object state support
> being implemented in the core code).

True but it misses an important part of the problem. It mixes references
through IO in progress with devices attached to a host. These are independent
issues.

> It is not required, but lack of any online state in a driver will
> possibly cause extended time to cancel the IO. We would not want
> excessive checking in the main IO path so there will be code that races
> with "offline" and makes it to queuecommand.

The main IO path is independent of the problems arising from offlining a
host. This issue must be dealt with in connection with offlining a _device_.

However offlining a host causes additional problems because devices
can be added and taken away from a host.
It takes a flag to make sure that no further devices can be added to the
host. This does not influence the main IO path, only device detection
and removal, which are not critical to performance.

	Regards
		Oliver


  reply	other threads:[~2003-03-06 14:33 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-03-03 22:15 [PATCH / RFC] scsi_set_host_offline Mike Anderson
2003-03-04  0:03 ` Oliver Neukum
2003-03-04 20:36   ` Matthew Dharm
2003-03-04 20:57     ` Oliver Neukum
2003-03-04 22:29     ` Mike Anderson
2003-03-04 23:12       ` Oliver Neukum
2003-03-05 16:52         ` James Bottomley
2003-03-05 19:49           ` Oliver Neukum
2003-03-05 22:35             ` Mike Anderson
2003-03-06 14:33               ` Oliver Neukum [this message]
2003-03-04  0:08 ` Patrick Mansfield
2003-03-22 21:24 ` Matthew Dharm
2003-03-25  9:46   ` Mike Anderson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200303061533.39375.oliver@neukum.name \
    --to=oliver@neukum.name \
    --cc=James.Bottomley@SteelEye.com \
    --cc=andmike@us.ibm.com \
    --cc=linux-scsi@vger.kernel.org \
    --cc=mdharm-scsi@one-eyed-alien.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox