[tlinux-users:07301] Re: ACPI problems with a Sattelite L10
Fred Thiele <[email protected]>
| Newsgroups | gmane.linux.hardware.toshiba |
|---|---|
| Message-ID | <[email protected]> |
> Well, I already know the gentoo doc and the ACPI linux
> ACPI project, but the problem is elsewhere. The DSDT
> itself is uncomplete, not buggy but uncomplete. The
> Toshiba Windows XP provides 2 drivers for the battery
> management.
Hello,
I am not that deeply involved in acpi hacking, but i managed to get sbs
working in GNU/Linux using an older patch than the one presented under
https://sourceforge.net/projects/sbs-linux/
The above didn't work for may L10. I attached two files to this mail. Do
the following to get it working within your linux.
* acpi_sbs-20050120.tar.gz
* acpi_sbs-20050120-Toshiba-L10-Patch.diff
The second one is a div/0-bug patch written by myself, you have to apply
it the the sources in the tar.gz: (do a
patch -p1 < /path/to/acpi_sbs-2005-0120-Toshiba-L10-Patch.diff
in the extracted tar.gz. Hope you can make use of it ;-)
Here I am again. I recently installed a new Gentoo-Linux on my L10 and
again ran into the smart-battery-system issue within it. What to do:
0) Unpack and apply the patch i have attached to this email
- unpack it into a temporary folder ~/tmp/ or so
1) Get a new Kernel
- as i dont know what system you run i can't tell you what to take
- just have a look for a kernel 2.6.XX, where XX is 10 and above (as
for me i have a 2.6.12 running) -- you need the SOURCES!
2) Patch the Kernel with the patch above
- run: cd /usr/src/linux
- then: patch -p1 < ~/tmp/acpi_sbs-20050120/acpi-ec-2.6.10.diff
- this does some changes in the kernels acpi-stuff concerning the
smart battery systems
3) Configure necessary kernel options
- run: cd /usr/src/linux ; make menuconfig
- de-select "AC Adapter" and "Battery" in ACPI_SUPPORT=20
- we apply our own acpi drivers with that patch above, so the
kernel ones have to be excluded
- in "Device Driver"/"I2C-Support" select:
- I2C-suppor
- I2C-device interface
4) Now compile your kernel, i hope you have some experiences with it--
as i dont know what system you are running i cannot provide you help on
what special things you need to include in the kernel.
- run: make && make modules_install
- then mount your /boot partition (if you have a separate /boot)
with: mount /boot
and do an: make install
- or you can do the install stuff by hand: just copy over the
System.map and arch/i386/boot/bzImage over to your /boot and ajust
your grub.conf ore lilo.conf to point to the new kernel-image
At this point you should check if your kernel does really work. Reboot.
5) If everything went well you should now compile the sbs-drivers:
- cd ~/tmp/acpi_sbs-20050120/
- make && make install
- this will build the modules and install them to your
/lib/modules/ directory, where all the kernel-modules reside
6) Now you should be able to get acpi information on your smart
batteries:
- do a: modprobe i2c-acpi-ec
- and a: modprobe acpi_sbs
- check your proc for battery and ac-adapter status:
- cat /proc/acpi/sbs/SBS0/SB0/state=20
- cat /proc/acpi/ac_adapter/AC0/state
--
Best regards,
Fred Thiele GnuPG-Key: 0x4F6BE238 <[email protected]>
Airplanes are interesting toys but of no military value. -- Marechal
Ferdinand Foch, Professor of Strategy, Ecole Superieure de Guerre
acpi_sbs-20050120.tar.gz
(application/x-tar-gz, 21 KB) - not displayed
acpi_sbs-20050120-Toshiba-L10-Patch.diff
(text/plain, 617 B)
diff -Naur acpi_sbs-20050120/acpi-sbs.c acpi_sbs-20050120-TL10Patch/acpi-sbs.c
--- acpi_sbs-20050120/acpi-sbs.c 2005-01-20 02:50:37.000000000 +0000
+++ acpi_sbs-20050120-TL10Patch/acpi-sbs.c 2005-09-06 08:17:42.000000000 +0000
@@ -1594,7 +1594,7 @@
seq_printf(seq, "charging state: charging\n");
seq_printf(seq, "present rate: %d%s\n",
(sb->info.full_charge_capacity - sb->state.remaining_capacity)*cscale*60/
- sb->state.average_time_to_full,
+ (sb->state.average_time_to_full==0?1:sb->state.average_time_to_full),
sb->info.capacity_mode?"0 mW":" mA");
}
else {
signature.asc
(application/pgp-signature, 189 B)
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (GNU/Linux) iD8DBQFDO9TVEBTrFk9r4jgRAp7AAJ4jodSrFBv9Y99m7LqRIMQF3D+2QgCeJZY+ QJ7IXDpMMmOxmgl2HUo+Jxk= =0C6e -----END PGP SIGNATURE-----