linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tejun Heo <htejun@gmail.com>
To: Roger Oberholtzer <roger@opq.se>
Cc: linux-ide@vger.kernel.org
Subject: Re: libata question
Date: Wed, 02 Aug 2006 16:20:14 +0900	[thread overview]
Message-ID: <44D0522E.6030905@gmail.com> (raw)
In-Reply-To: <1154502301.5691.23.camel@acme>

Roger Oberholtzer wrote:
> On Wed, 2006-08-02 at 04:06 +0900, Tejun Heo wrote: 
>> Roger Oberholtzer wrote:
>>> On Wed, 2006-08-02 at 03:45 +0900, Tejun Heo wrote:
>>>> Roger Oberholtzer wrote:
>>>>> On Wed, 2006-08-02 at 00:33 +0900, Tejun Heo wrote:
>>>>>> Roger Oberholtzer wrote:
>>>>>>> Should hotplug work with Intel Corporation 82801GB/GR/GH (ICH7
>>>>>>> Family) chipset? I am trying kernel 2.6.17.7
>>>> Ah.. I should have spotted this earlier.  2.6.17.7 doesn't contain 
>>>> updated EH and doesn't support any of new features including 
>>>> hot/warmplug.  Please try 2.6.18-rc3.
>>> OK. But I think there are issues with 2.6.18 generally. But I can try it
>>> to see if this makes this better.
>> If you're uncomfortable with -rcX, you can try libata-tj-stable patch. 
>> It contains most of new stuff.
>>
>> http://home-tj.org/files/libata-tj-stable/libata-tj-2.6.17.4-20060710.tar.bz2
> 
> Thanks for that. But it had no noticeable difference.

Hmmm... That's weird. 'echo - - - > /sys/class/scsi_host/xxx.../scan' 
didn't do the right thing?  Care to post dmesg?

> I looked in the bios on my system to see if I could set the SATA disks
> to AHCI mode. I did not see anything like that. I could select to do a
> manual config, in which case I could set things like LBA mode, 32-bit
> I/O (which defaults to off). So if hots wap require AHCI mode, I seem to
> be screwed. It is a phoenix bios for the supermicro computer.

The chipset might not support ahci mode.

> Maybe I can try a different SATA card instead of the stuff on the
> motherboard. What do you think is the best one re hots waping? Either
> PCI or PCI-X.

I primarily use sil3112/4, sil3124/32 and ahci for development.  So 
those tend to have better support for EH/hotplug stuff.

>>>>> I bet the driver does the right thing. The trick is knowing what that is
>>>>> supposed to be. And how to use the various commands on files in /sys at
>>>>> the correct time and in the correct order.
>>>> Really, it's not that complicated.
>>> Once you know what it is you need to do.
>> I tried hard to make things just work.  If you find things unnecessarily 
>> complicated, please let me know.
> 
> I have a system with an IDE disk with the OS that is fixed. I also have
> 4 hot swappable SATA disk bays. My use will involve changing the SATA
> disks to do an analysis of the data they contain. There will be 4 disks
> in an analysis set. I need to make it easy for the user to insert and
> remove disks. Rebooting each time is a bad alternative. So, if hot swap
> does not work, I will have to get warm swap working. I think part of the
> confusion I have is how to deal with disks that are mounted. So I need
> to get the steps well defined and make those that require user
> interaction as few as possible.

As far as libata is concerned, for warmplug, all you need to use are

   echo 1 > /sys/class/scsi_device/xxxx/device/delete

for removal, and for plugging

   echo - - - > /sys/class/scsi_host/xxxxx/scan

If you remove device before unmounting, the mounted fs will suffer from 
io errors and probably spit quite some error messages, so unmounting 
before is a good idea.

In general, ata_piix doesn't respond very well to runtime device 
addition mainly due to problems with port enable.  So, if you boot with 
empty slot and put new device in there and issue scan, it might or might 
not work, but ports which had a device attached on boot seem to always work.

On any 2.6.17 kernel, without new EH, none of hot/warm plugging works. 
Please double check you have the correct kernel.  Kernel messages are 
very different.

-- 
tejun

  reply	other threads:[~2006-08-02  7:20 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-08-01 15:18 libata question Roger Oberholtzer
2006-08-01 15:33 ` Tejun Heo
2006-08-01 18:39   ` Roger Oberholtzer
2006-08-01 18:45     ` Tejun Heo
2006-08-01 19:03       ` Roger Oberholtzer
2006-08-01 19:06         ` Tejun Heo
2006-08-02  7:05           ` Roger Oberholtzer
2006-08-02  7:20             ` Tejun Heo [this message]
2006-08-02  8:06               ` Roger Oberholtzer
2006-08-02 14:35               ` Roger Oberholtzer
2006-08-02 15:02                 ` Tejun Heo
2006-08-03  7:26                   ` Roger Oberholtzer
2006-08-03  7:58                     ` Tejun Heo
2006-08-03  8:49                       ` Roger Oberholtzer
2006-08-03 20:08                         ` Stefan Smietanowski
2006-08-02  1:22 ` 31244 PCI Card sam song

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=44D0522E.6030905@gmail.com \
    --to=htejun@gmail.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=roger@opq.se \
    /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).