linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff Garzik <jgarzik@pobox.com>
To: Lukasz Kosewski <lkosewsk@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>,
	linux-kernel@vger.kernel.org, linux-ide@vger.kernel.org,
	linux-scsi@vger.kernel.org
Subject: Re: [PATCH 2/3] Add disk hotswap support to libata RESEND #5
Date: Mon, 03 Oct 2005 11:53:26 -0400	[thread overview]
Message-ID: <434153F6.2050405@pobox.com> (raw)
In-Reply-To: <355e5e5e0510030819od4ef8e5l93708588990081da@mail.gmail.com>

Lukasz Kosewski wrote:
> How about this; I want this SATA hotswapping stuff to be tested, so
> I'll commit my patches for 'SATA only' for the time being.  I'll stare
> at them for a while and then see what kind of PATA-specific if
> statements and hooks are necessary in the code?

Ideally we should just create hooks for any SATA-specific behavior, and 
ensure that nothing SATA-specific is written into any of the core paths.

One of the SATA controllers, Intel ICH5 & ICH6, does not have a hotplug 
interrupt, but yet supports "coldplug":

	* user indicates to kernel, to disable the SATA port
	* kernel says "OK, it's disabled"
	* user disconnects hard drive
and
	* SATA port is disabled
	* user connects hard drive
	* user indicates to kernel, to enable SATA port
	* kernel says "OK, I've turned it on" and probes it

This is a real-world, high-volume SATA case, yet it functionally behaves 
like PATA.

So that causes us to consider various entry points:

* {something}, be it a hot-unplug interrupt or user write(2) to sysfs, 
tells us a device is gone
* {something}, be it a hot-plug interrupt or user write(2) to sysfs, 
tells us a new device appeared

So for either SATA or PATA, it should look similar in the core:  we just 
need a "kick", a function call that triggers one of these two actions. 
The handling of those actions [your code] should hopefully be pretty 
generic.  ;-)

Thanks for working on this!

	Jeff



  reply	other threads:[~2005-10-03 15:53 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-09-27  1:01 [PATCH 2/3] Add disk hotswap support to libata RESEND #5 Lukasz Kosewski
     [not found] ` <017101c5c39b$95699900$1b00a8c0@FRSNOTI>
2005-09-27 21:47   ` Lukasz Kosewski
2005-09-28 19:10 ` Jeff Garzik
2005-09-28 23:20   ` Alan Cox
2005-10-03 15:19     ` Lukasz Kosewski
2005-10-03 15:53       ` Jeff Garzik [this message]
2005-10-03 16:09       ` Alan Cox
2005-10-03 14:30   ` Lukasz Kosewski
2005-10-03 15:47     ` Jeff Garzik

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=434153F6.2050405@pobox.com \
    --to=jgarzik@pobox.com \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=lkosewsk@gmail.com \
    /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;
as well as URLs for NNTP newsgroup(s).