HP accelerometer driver: testers wanted
HP accelerometer driver: testers wanted
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
It is in latest -mm. Enable CONFIG_SENSORS_LIS3LV02D, recompile/reboot. Documentation is in Documentation/hwmon/lis3lv02d and Documentation/hwmon/hpfall.c is standalone binary that should park your disk (and light a led) as soon as freefall is detected.
For standalone patch, see
http://www.livejournal.com/~pavelmachek
Pavel
Signature · 1 line
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
Hi Pavel,
Quoted 4 lines · Pavel Machek
It is in latest -mm. Enable
CONFIG_SENSORS_LIS3LV02D, recompile/reboot. Documentation is inDocumentation/hwmon/lis3lv02dandDocumentation/hwmon/hpfall.cis standalone binary that should park your disk (and light a led) as soon as freefall is detected.
My HP 2510p notebook has the device. By chance I activated the driver with my last few builds and at least the input device works perfectly with the -rc2 kernel (tested with jstest and Tux Racer).
What are the differences relative to -rc2? Looks like it adds the freefall device?
Could you please give some additional info what exactly you want tested, how to test it, and how safe it is to do the test?
I'd be willing to test, but not if to do so I'd have to throw the notebook out of the window... Or even if there is the slightest risk of somehow damaging the hard disk.
Cheers,
FJP
Quoted 8 lines · Frans Pop
Hi Pavel,
Quoted 4 lines · Pavel Machek
It is in latest -mm. Enable
CONFIG_SENSORS_LIS3LV02D, recompile/reboot. Documentation is inDocumentation/hwmon/lis3lv02dandDocumentation/hwmon/hpfall.cis standalone binary that should park your disk (and light a led) as soon as freefall is detected.
Quoted 6 lines
My HP 2510p notebook has the device. By chance I activated the driver with my last few builds and at least the input device works perfectly with the -rc2 kernel (tested with jstest and Tux Racer).
What are the differences relative to -rc2? Looks like it adds the freefall device?
Yes.
Quoted 2 lines
Could you please give some additional info what exactly you want tested, how to test it, and how safe it is to do the test?
Run hpfall, and see if LED lights and disk parks if you "drop" a computer. (*)
Quoted 3 lines
I'd be willing to test, but not if to do so I'd have to throw the notebook out of the window... Or even if there is the slightest risk of somehow damaging the hard disk.
(*) drop: just move it quickly downwards for 5-10cm. Even walking with the computer usually triggers it for me.
Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
Minor issue in the patch: hpfall.c should not be executable:
-rwxr-xr-x 1 fjp fjp 1759 2009-01-22 23:31 hpfall.c
With patch applied:
$ ls -l /dev/freefall crw-rw---- 1 root root 10, 59 2009-01-22 23:44 /dev/freefall
$ gcc -o hpfall -Os hpfall.c hpfall.c: In function ‘main’: hpfall.c:73: warning: passing argument 2 of ‘signal’ from incompatible pointer type
Quoted 2 lines
Run hpfall, and see if LED lights and disk parks if you "drop" a computer. (*)
$ sudo ./hpfall &
The LED lights up yellow, but I have problems telling if the disk gets parked or not. One time I got a green led and seemingly a fair amount of activity immediately after getting the yellow led.
After looking at hpfall.c, I checked /sys/block/sda/device/unload_heads after a drop:
$ cat /sys/block/sda/device/unload_heads 19616 $ cat /sys/block/sda/device/unload_heads 0
The last was at most 2 seconds after the first, certainly not 20...
Wouldn't it be good to have locks/unlocks registered in the logs when /sys/block/sda/device/unload_heads changes (assuming the actual write will get delayed until the head is unparked)?
Cheers,
FJP
Quoted 4 lines · Frans Pop
The LED lights up yellow, but I have problems telling if the disk gets parked or not. One time I got a green led and seemingly a fair amount of activity immediately after getting the yellow led.
Quoted 8 lines
After looking at
hpfall.c, I checked/sys/block/sda/device/unload_headsafter a drop:$ cat /sys/block/sda/device/unload_heads 19616 $ cat /sys/block/sda/device/unload_heads 0The last was at most 2 seconds after the first, certainly not 20...
I've just looked at hpcall.c a bit closer and I guess that's because of the alarm(2) call? I must admit having some problems reading that code.
Quoted 12 lines · Frans Pop
Quoted 11 lines · Frans Pop
The LED lights up yellow, but I have problems telling if the disk gets parked or not. One time I got a green led and seemingly a fair amount of activity immediately after getting the yellow led.
After looking at
hpfall.c, I checked/sys/block/sda/device/unload_headsafter a drop:$ cat /sys/block/sda/device/unload_heads 19616 $ cat /sys/block/sda/device/unload_heads 0
Quoted 5 lines
Quoted 1 line
The last was at most 2 seconds after the first, certainly not 20...
I've just looked at
hpcall.ca bit closer and I guess that's because of the alarm(2) call? I must admit having some problems reading that code.
Yes, it works as designed. Change if (1 || into if (0) and you'll get 20 second timeouts.
(It initially asks for 20 seconds to give itself time for those other calculations.)
Pavel
Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
Hi!
Quoted 2 lines
Minor issue in the patch:
hpfall.cshould not be executable:
-rwxr-xr-x 1 fjp fjp 1759 2009-01-22 23:31hpfall.c
Hmm, fixed in my local tree, but will have to think about how to make it into patch.
Quoted 9 lines
Quoted 2 lines
Run hpfall, and see if LED lights and disk parks if you "drop" a computer. (*)
$ sudo ./hpfall &The LED lights up yellow, but I have problems telling if the disk gets parked or not. One time I got a green led and seemingly a fair amount of activity immediately after getting the yellow led.
Quoted 6 lines
After looking at
hpfall.c, I checked/sys/block/sda/device/unload_headsafter a drop:$ cat /sys/block/sda/device/unload_heads 19616 $ cat /sys/block/sda/device/unload_heads 0
Ok, so drop detection works for you; good. I could see disk activity stopping during find / ...
Quoted 3 lines
Wouldn't it be good to have locks/unlocks registered in the logs when
/sys/block/sda/device/unload_headschanges (assuming the actual write will get delayed until the head is unparked)?
That would fill the logs rather quickly, right?
Pavel
Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
Quoted 11 lines
HP accelerometer driver: testers wanted
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~It is in latest -mm. Enable
CONFIG_SENSORS_LIS3LV02D, recompile/reboot. Documentation is inDocumentation/hwmon/lis3lv02dandDocumentation/hwmon/hpfall.cis standalone binary that should park your disk (and light a led) as soon as freefall is detected.For standalone patch, see
Then lets add kernel-testers@ to CC.
Mariusz