hdaps (accelerator) driver for thinkpads

From: Tobias Kirschstein <lev_at_nupfel.de>
Date: Tue, 25 Mar 2008 23:35:39 +0100
hi there,

i have an ibm x60t thinkpad and want to have this nice feature of
(mostly all) thinkpads: the hdaps acceleration support. i found only an
old implementaton of 2005 and decided to update the driver. as this is
the first time i put my fingers on kernel drivers please be kind :)

here is what i got at the moment:

http://www.nupfel.de/data/accel-0.6.tar.gz

i took the original driver from the old linux hdaps project:

http://hdaps.sourceforge.net/index.php?page=3

added support for my x60t and fixed some kthread -> kproc renaming
issues since 8-CURRENT.

the driver compiles and loads fine on my system (8-CURRENT, also tested
on 7-RELEASE), but if i try to get some values through the sysctl
"hw.accel" or one of the /dev/accel* device nodes my machine (amd64)
completely freezes and rebootes after some seconds. bulding and loading
the module with DEBUG defined it dumps the raw values of the io ports
correctly to the kernel message buffer.

---------------------------------------------
accel0: Found Accelerometer, type 0x5, starting init.. (max. 10 seconds)
accel0: Init finished successful
accel0: Time needed: 2 s 25142 ns
accel0: <Accelerometer> at port 0x1600-0x162f on isa0
accel0: calibration: xzero: 508 yzero: 510
accel0: initstate: 0x5
ppc0: cannot reserve I/O port range
---------------------------------------------

---------------------------------------------
-> entering _accel_getdata
-> entering _accel_request_refresh
io port dump:
0x1600: 14 ff ff ff 00 ff ff ff ff ff ff ff ff ff ff ff  ................
0x1610: 11 02 9c 01 03 02 3d 9b 01 03 02 3d 02 80 00 00  ......=....=....
0x1620: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff  ................
<- exiting _accel_request_refresh value 0x1 (refresh success) wait: 0x1
io port dump:
0x1600: 14 ff ff ff 50 ff ff ff ff ff ff ff ff ff ff ff  ....P...........
0x1610: 11 02 9b 01 04 02 3d 9b 01 04 02 3d 04 a0 00 00  ......=....=....
0x1620: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff  ................
<- exiting _accel_getdata value 0x1
io port dump:
0x1600: 14 ff ff ff 00 ff ff ff ff ff ff ff ff ff ff ff  ................
0x1610: 11 02 9b 01 04 02 3d 9b 01 04 02 3d 04 a0 00 00  ......=....=....
0x1620: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff  ................
-> entering _accel_request_refresh
io port dump:
0x1600: 14 ff ff ff 00 ff ff ff ff ff ff ff ff ff ff ff  ................
0x1610: 11 02 9b 01 04 02 3d 9b 01 04 02 3d 04 a0 00 00  ......=....=....
0x1620: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff  ................
<- exiting _accel_request_refresh value 0x1
(refresh success) wait: 0x0
---------------------------------------------

unloading the module also works find and frees all ressources unless
you don't try to use the devices...

---------------------------------------------
accel0: waiting for kthread to teminate..
accel0: Done.
sysctlfree retval: 0
accel0: detached
---------------------------------------------

the full dmesg: http://www.nupfel.de/data/dmesg.txt

it would be great if some thinkpad users could try the code and help me
debugging the problem :)


-- 
ciao,
lev

Received on Tue Mar 25 2008 - 22:07:47 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:29 UTC