[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Hard Drive light

According to Benjamin Herrenschmidt, on Sun, 19 Dec 2004 15:48:07 +0100, 
>> I attach a very small patch doing that. This a patch only for drivers/ide/ppc/pmac.c
>file,> with respect to a pure kernel 2.6.9 from kernel.org
>> It adds an entry in /sys/devices/ide-pmac/blinking_led
>> echo 1 > /sys/devices/ide-pmac/blinking_led
>> activates the led
>> echo 0 > /sys/devices/ide-pmac/blinking_led
>> disactivates it
>> It starts disactivated.
>BTW.. looked at the patch a bit more, why do you create a platform
>device just for that ? The mac-io IDE already has it's own sysfs entry

You mean in /sys/bus/macio/drivers/ide-pmac ?
The main reason is that I could not find how to add my sysfs in this directory since it is
not created in the ide-pmac.c file (still a lot to learn :)). So I convinced myself that a
platform device was not so irrelevant. 
Just give me an hint or an example and I'll change that.

Other thing strange to me is that I have to use the saved command line to know if there
is a boot time argument. According to the comments around MODULE_PARM, a module parameter
should be enough. I tried that, but the boot parameter never had any influence on the 

Thanks for your remark.

Cedric Pradalier

Reply to: