From: "Владимир Дашевский" <vladimir.dashevsky@gmail.com>
To: Tejun Heo <tj@kernel.org>
Cc: Jeff Garzik <jgarzik@pobox.com>, linux-ide@vger.kernel.org
Subject: Re: hot plug on ICH9 with AHCI on
Date: Tue, 24 Mar 2009 11:26:34 +0300 [thread overview]
Message-ID: <49C8993A.9010206@gmail.com> (raw)
In-Reply-To: <49C77A00.6020204@kernel.org>
[-- Attachment #1: Type: text/plain, Size: 4265 bytes --]
Tejun!
> No it won't show up and I can't really answer all your linux related
> questions. Sorry. :-P
>
Nice system...
>
>>> Yeah, I know it has been in the spec but without hardware to play with
>>> it's difficult to add driver features and lack of general availability
>>> also means lower demand.
>>>
>>>
>> Well, I just cannot imagine how software raid can work without clearly
>> visible state. One drive mixed up in RAID5 and the whole array can get
>> damaged. And it is not so difficult to mix them up because drive names
>> may differ from physical slot numbers.
>>
>
> Yeah, it can be tricky but highend machine usually go with sas and
> consumer grade machines don't really care, so there just aren't too
> many ahci machines with enclosure support. Well, not here anyway.
>
>
As for me, there is a lot of tasks where the main issue is a reliablity
and not nesessary a performance.
SAS cannot be used for RAID anyway, it's closer to RAED. I guess that
software RAID can be the best solution for every case where reliablity
and online scalability is needed.
>>> I think it should be independent from RAID but having general
>>> enclosure support will be nice. Care to post the patches?
>>>
>>>
>>>
>> Well, I can provide you with a code which works on my ICH9 Supermicro
>> platform. I believe it will also work with both ICH8 and ICH10.
>> However, since I could not install this module as traditional pci driver
>> (the kernel decided not to claim my ahci device since the main driver
>> present in the system) I had to rewrite it as a general linux kernel
>> module. It justs scan pci devices for AHCI capable ones and remaps their
>> ABAR to try enclosure management support. For now, only my ICH9 PCI IDs
>> are in my try list. All AHCI EM-capable devices get their associated
>> proc interface - /proc/ahci_emX/leds*. This module actually works in
>> parallel with kernel ahci driver but I think it will be a conflict with
>> it once the kernel driver starts to support em by itself. I guess, the
>> best way would be to document some API for controlling the EM, then to
>> declare some kernel ahci flag that will indicate full EM presence in the
>> kernel. Then I can improve my ahci_em module to skip its installation
>> when similar functions are built into the kernel.
>>
>> My interface is quite simple. You just write a char to leds-controlling
>> proc file to set state of leds, for example:
>> echo r > /proc/ahci_em0/leds0 means you asked for REBUILD state
>> indicated in the bay of port 0.
>> I think that most of users would prefer additional module rather that
>> kernel udgrade, for the first time. Also, I am not very close to linux
>> kernel to provide a kernel patch.
>>
>
> I don't think the design you described would fit into upstream kernel
> too well but if you have it working it's some place to start. Just
> refresh in on top of the current devel kernel and let's see what can
> be done.
>
Sorry, I am not so close to linux kernel to perform a jump from my
current kernel
(2.6.25) to latest one. I am sending you the sources of kernel module
which performs all LEDs EM functions.
The code is simple and relatively small. I have brushed it up to be more
readable.
If you decide it useful and will change user API for this (eg, move proc
interface to sys interface) then let me know.
I would like to design this software so that module could be used with
older kernels and have the same behavior as newer kenels will have. this
will help to spread this technology among machines where kernel cannot
be upgraded for some reasons.
Usage notes:
1. Use 'make' to make driver module.
2. Use 'make reload' to (re)install driver into a system
3. Use 'echo X > /proc/ahci_em0/ledsN' to set state of leds for porn N
(N is 0 to 5 for ICH9).
X is one of the:
'N' - normal state (leds off)
'L' - locate state (4Hz blinking)
'R' - rebuild state (1Hz blinking)
'F' - failure state (solid + beep)
'P' - predicted failure state (two 4Hz blinks in 1 second )
'H' - hot spare ( two 4Hz blinks in 4 seconds).
My enclosure has only one state LED (besides activity LED) so I
developed blink patterns as described here:
http://en.wikipedia.org/wiki/IBPI
Best regards, Vladimir Dashevsky
[-- Attachment #2: ahci_em.tar.gz --]
[-- Type: application/gzip, Size: 4973 bytes --]
prev parent reply other threads:[~2009-03-24 8:28 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-18 22:12 hot plug on ICH9 with AHCI on Владимир Дашевский
2009-03-20 2:04 ` Tejun Heo
2009-03-20 9:55 ` Владимир Дашевский
[not found] ` <49C39933.4020501@kernel.org>
2009-03-20 15:31 ` Владимир Дашевский
2009-03-22 12:51 ` Владимир Дашевский
2009-03-22 15:08 ` Tejun Heo
2009-03-22 16:07 ` Владимир Дашевский
2009-03-22 16:41 ` Tejun Heo
2009-03-22 18:26 ` Владимир Дашевский
2009-03-23 2:04 ` Tejun Heo
2009-03-23 11:38 ` Владимир Дашевский
2009-03-23 12:01 ` Tejun Heo
2009-03-24 8:26 ` Владимир Дашевский [this message]
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=49C8993A.9010206@gmail.com \
--to=vladimir.dashevsky@gmail.com \
--cc=jgarzik@pobox.com \
--cc=linux-ide@vger.kernel.org \
--cc=tj@kernel.org \
/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).