public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
* RE: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
@ 2006-01-26 20:27 Brown, Len
  2006-01-27 11:43 ` Johan Vromans
  0 siblings, 1 reply; 15+ messages in thread
From: Brown, Len @ 2006-01-26 20:27 UTC (permalink / raw)
  To: Marco Giumelli, linux-acpi

>Hi, I'm a linux newbye.
>I installed Ubuntu Linux Breezy(5.10) on my notebook:
>acer travelmate 4000 WLMI.
>Everything run but the battery.
>I can't see the battery status.
>I tryed to patch the kernel (2.6.12) following the wiki instructions:
>https://wiki.ubuntu.com/ACPIBattery

I should state for the record (again) that a Linux distro
is really out on thin ice when they advocate that users
other than hackers modify and run the platform firmware -
as such a configuration is simply not supportable.

To make matters worse, if the modified DSDT works,
then the user doesn't complain about Linux and Linux
doesn't get fixed to work on an unmodified DSDT...

I wish the repository of DSDTs on sourceforge.net
would simply GO AWAY for this reason.  It is a crutch
that makes Linux  WORSE, NOT BETTER.

That said....
If you can boot a recent kernel.org kernel, say 2.6.15
and still have a problem, then please speak up on this
list and/or in bugzilla.kernel.org.  Run only the
DSDT that comes with the BIOS for the machine,
and change it only by updating to a newer BIOS
from the vendor for that machine.

thanks,
-Len

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-01-26 20:27 UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI Brown, Len
@ 2006-01-27 11:43 ` Johan Vromans
  2006-04-19 23:31   ` Was: " Berthold Cogel
  0 siblings, 1 reply; 15+ messages in thread
From: Johan Vromans @ 2006-01-27 11:43 UTC (permalink / raw)
  To: Brown, Len; +Cc: Marco Giumelli, linux-acpi

"Brown, Len" <len.brown@intel.com> writes:

> I wish the repository of DSDTs on sourceforge.net would simply GO
> AWAY for this reason. It is a crutch that makes Linux WORSE, NOT
> BETTER.

I too run Linux (Fedora Core) on a TravelMate 4001WLMi[1]. I needed to
change the DSDT since it returned the wrong values for the processor
speeds (!) which, I have been assured, is not an uncommon problem. No
other changes were necessary. In fact, I could have continued using
the unmodified DSDT except for the frequencey scaling.

For the smart battery, I use the original, EC based implementation by
Rich Townsend, and it works like a charm.

Later (AFAIK) Rich went to a DSDT-based approach of the smart battery
problem. I personally prefer the EC based version.

-- Johan

[1] http://www.squirrel.nl/people/jvromans/articles/TM4001WLMi/index.html

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Was: Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-01-27 11:43 ` Johan Vromans
@ 2006-04-19 23:31   ` Berthold Cogel
  2006-04-20 10:43     ` Johan Vromans
  2006-04-22 18:27     ` Johan Vromans
  0 siblings, 2 replies; 15+ messages in thread
From: Berthold Cogel @ 2006-04-19 23:31 UTC (permalink / raw)
  To: linux-acpi

Johan Vromans wrote:

> I too run Linux (Fedora Core) on a TravelMate 4001WLMi[1]. I needed to
> change the DSDT since it returned the wrong values for the processor
> speeds (!) which, I have been assured, is not an uncommon problem. No
> other changes were necessary. In fact, I could have continued using
> the unmodified DSDT except for the frequencey scaling.
> 
> For the smart battery, I use the original, EC based implementation by
> Rich Townsend, and it works like a charm.
> 
> Later (AFAIK) Rich went to a DSDT-based approach of the smart battery
> problem. I personally prefer the EC based version.
> 

Hello!

The latest patch from the sbs-linux (Rich Townsend) project works only
for kernel versions up to 2.6.15.x for my Acer Extensa 3002 WLMi.

What is the recommended way to solve the problem with the smart battery
for newer kernels?

Regards
Berthold

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Was: Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-04-19 23:31   ` Was: " Berthold Cogel
@ 2006-04-20 10:43     ` Johan Vromans
  2006-04-20 11:32       ` Matthew Garrett
  2006-04-20 22:45       ` Berthold Cogel
  2006-04-22 18:27     ` Johan Vromans
  1 sibling, 2 replies; 15+ messages in thread
From: Johan Vromans @ 2006-04-20 10:43 UTC (permalink / raw)
  To: Berthold Cogel; +Cc: linux-acpi

Berthold Cogel <cogel@rrz.uni-koeln.de> writes:

> What is the recommended way to solve the problem with the smart
> battery for newer kernels?

The right solution is hal, but I don't know whether it has been picked
up yet.

For the time being, I ported Rich' sbs-cm approach[1] to 2.6.16 and it
seems to work okay.

-- Johan

https://sourceforge.net/project/showfiles.php?group_id=129330

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Was: Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-04-20 10:43     ` Johan Vromans
@ 2006-04-20 11:32       ` Matthew Garrett
  2006-04-22 20:53         ` Johan Vromans
  2006-04-20 22:45       ` Berthold Cogel
  1 sibling, 1 reply; 15+ messages in thread
From: Matthew Garrett @ 2006-04-20 11:32 UTC (permalink / raw)
  To: Johan Vromans; +Cc: Berthold Cogel, linux-acpi

On Thu, Apr 20, 2006 at 12:43:16PM +0200, Johan Vromans wrote:
> Berthold Cogel <cogel@rrz.uni-koeln.de> writes:
> 
> > What is the recommended way to solve the problem with the smart
> > battery for newer kernels?
> 
> The right solution is hal, but I don't know whether it has been picked
> up yet.

No. There needs to be a kernel driver, regardless of how it provides 
information. hal can only display what the kernel gives it - it's not a 
set of drivers, and it can't read from a smart battery on its own.

-- 
Matthew Garrett | mjg59@srcf.ucam.org

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Was: Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-04-20 10:43     ` Johan Vromans
  2006-04-20 11:32       ` Matthew Garrett
@ 2006-04-20 22:45       ` Berthold Cogel
  2006-04-21  9:30         ` Johan Vromans
  1 sibling, 1 reply; 15+ messages in thread
From: Berthold Cogel @ 2006-04-20 22:45 UTC (permalink / raw)
  To: Johan Vromans; +Cc: linux-acpi

Johan Vromans wrote:
> Berthold Cogel <cogel@rrz.uni-koeln.de> writes:
> 
>> What is the recommended way to solve the problem with the smart
>> battery for newer kernels?
> 
> The right solution is hal, but I don't know whether it has been picked
> up yet.
> 
> For the time being, I ported Rich' sbs-cm approach[1] to 2.6.16 and it
> seems to work okay.
> 
> -- Johan
> 
> https://sourceforge.net/project/showfiles.php?group_id=129330

Thanks! I've overlooked the patches at Sourceforge.
Is there any chance to get the patch into the kernel somehow?

Berthold



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Was: Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-04-20 22:45       ` Berthold Cogel
@ 2006-04-21  9:30         ` Johan Vromans
  2006-04-22 18:02           ` Berthold Cogel
  0 siblings, 1 reply; 15+ messages in thread
From: Johan Vromans @ 2006-04-21  9:30 UTC (permalink / raw)
  To: Berthold Cogel; +Cc: Johan Vromans, linux-acpi

Berthold Cogel <cogel@rrz.uni-koeln.de> writes:

> Johan Vromans wrote:
>> https://sourceforge.net/project/showfiles.php?group_id=129330
>
> Thanks! I've overlooked the patches at Sourceforge.
> Is there any chance to get the patch into the kernel somehow?

There are two patches required. One patch is to allow a
custom-supplied DSDT in initrd. This is a harmless patch that would be
very nice to have in the kernel, and the feature could even be enabled
by default[1]. Several distro's already do this.

The other patch (I'm replying for Rich now, so don't point _me_ down
on the deeper details) concerns the use of a semaphore instead of spin
lock in ec. This is to overcome loss of interrupts while reading out
the bus. There has been much debate about this patch, and it can be
argued that it implements the right solution. (It does the job,
though.)

But the best solution would be to have a kernel module that deals with
this kind of smart batttery subsystems, and provide the correct
information for userland (hal?) to react upon. This is basically the
original approach taken by Pedro Venda, Bruno Ducrot and completed for
2.6.10 (or so) by Rich Townsend[2]. Unfortunately, recent changes to
the i2c drivers conflict with the changes required for this approach,
and I haven't been able to find out how to modify the patches for the
2.6.16 kernel. (Help appreciated.)

-- Johan

[1] For my Acer Travelmate 4001WLMi I need to supply a custom DSDT
    anyway, since some of the original DSDT data is just wrong...
[2] http://shayol.bartol.udel.edu/~rhdt/download/acpi_sbs-20050120.tar.gz

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Was: Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-04-21  9:30         ` Johan Vromans
@ 2006-04-22 18:02           ` Berthold Cogel
  0 siblings, 0 replies; 15+ messages in thread
From: Berthold Cogel @ 2006-04-22 18:02 UTC (permalink / raw)
  To: linux-acpi; +Cc: Johan Vromans

Johan Vromans wrote:
> Berthold Cogel <cogel@rrz.uni-koeln.de> writes:
> 
>> Johan Vromans wrote:
>>> https://sourceforge.net/project/showfiles.php?group_id=129330
>> Thanks! I've overlooked the patches at Sourceforge.
>> Is there any chance to get the patch into the kernel somehow?
> 
> There are two patches required. One patch is to allow a
> custom-supplied DSDT in initrd. This is a harmless patch that would be
> very nice to have in the kernel, and the feature could even be enabled
> by default[1]. Several distro's already do this.

I would appreciate this. I'm using this patch for my kernels. But there
seems to be a problem with the latest ACPI patches with at least kernel
2.6.16.9, which I tried yesterday.

linux-2.6.16.9
acpi-release-20060310-2.6.16.diff
acpi-dsdt-initrd-v0.8.1-2.6.16.patch


make bzImage

....

  LD      init/built-in.o
  LD      .tmp_vmlinux1
drivers/built-in.o: In function `acpi_find_dsdt_initrd':
(.text+0x2526d): undefined reference to `ACPI_MEM_ALLOCATE'
drivers/built-in.o: In function `acpi_find_dsdt_initrd':
(.text+0x252c8): undefined reference to `ACPI_MEM_FREE'
drivers/built-in.o: In function `acpi_tb_get_table_body':
(.text+0x3772e): undefined reference to `ACPI_MEM_FREE'
make: *** [.tmp_vmlinux1] Fehler 1

Building the kernel with the ACPI patches or with the initrd patch
works. But the combination .....

Seems that something has been changed in the ACPI patches.


> But the best solution would be to have a kernel module that deals with
> this kind of smart batttery subsystems, and provide the correct
> information for userland (hal?) to react upon. This is basically the
> original approach taken by Pedro Venda, Bruno Ducrot and completed for
> 2.6.10 (or so) by Rich Townsend[2]. Unfortunately, recent changes to

This was what I used in the first time with kernel 2.6.11 when I got my
notebook.

> the i2c drivers conflict with the changes required for this approach,
> and I haven't been able to find out how to modify the patches for the
> 2.6.16 kernel. (Help appreciated.)

I haven't been much of a software developer myself and my C is rusty. I
read LKML just out of curiosity. But I'm willing to do the testing part.

Berthold

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Was: Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-04-19 23:31   ` Was: " Berthold Cogel
  2006-04-20 10:43     ` Johan Vromans
@ 2006-04-22 18:27     ` Johan Vromans
  2006-04-23 21:56       ` Berthold Cogel
  1 sibling, 1 reply; 15+ messages in thread
From: Johan Vromans @ 2006-04-22 18:27 UTC (permalink / raw)
  To: Berthold Cogel; +Cc: linux-acpi

Berthold Cogel <cogel@rrz.uni-koeln.de> writes:

> The latest patch from the sbs-linux (Rich Townsend) project works only
> for kernel versions up to 2.6.15.x for my Acer Extensa 3002 WLMi.

I managed to get the latest acpi-sbs (20050120) going on 2.6.16.
I have no idea what the impact of my changes is to the rest of the
kernel, but I got my familiar battery readings back.
Drop me a line if you want to give it a try. At your own risk, of
course...

-- Johan

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Was: Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-04-20 11:32       ` Matthew Garrett
@ 2006-04-22 20:53         ` Johan Vromans
  2006-04-22 21:23           ` Matthew Garrett
  0 siblings, 1 reply; 15+ messages in thread
From: Johan Vromans @ 2006-04-22 20:53 UTC (permalink / raw)
  To: Matthew Garrett; +Cc: linux-acpi

Matthew Garrett <mjg59@srcf.ucam.org> writes:

> On Thu, Apr 20, 2006 at 12:43:16PM +0200, Johan Vromans wrote:
>> Berthold Cogel <cogel@rrz.uni-koeln.de> writes:
>> 
>> > What is the recommended way to solve the problem with the smart
>> > battery for newer kernels?
>> 
>> The right solution is hal, but I don't know whether it has been picked
>> up yet.
>
> No. There needs to be a kernel driver, regardless of how it provides 
> information. 

Isn't that exactly what Rich Townsend's acpi_sbs implements?

-- Johan

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Was: Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-04-22 20:53         ` Johan Vromans
@ 2006-04-22 21:23           ` Matthew Garrett
  0 siblings, 0 replies; 15+ messages in thread
From: Matthew Garrett @ 2006-04-22 21:23 UTC (permalink / raw)
  To: Johan Vromans; +Cc: linux-acpi

On Sat, Apr 22, 2006 at 10:53:02PM +0200, Johan Vromans wrote:
> Matthew Garrett <mjg59@srcf.ucam.org> writes:
> > No. There needs to be a kernel driver, regardless of how it provides 
> > information. 
> 
> Isn't that exactly what Rich Townsend's acpi_sbs implements?

Yes, and it seems to work fairly well. It should really be submitted for 
mainline.

-- 
Matthew Garrett | mjg59@srcf.ucam.org

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Was: Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-04-22 18:27     ` Johan Vromans
@ 2006-04-23 21:56       ` Berthold Cogel
  2006-04-24  9:36         ` Johan Vromans
  0 siblings, 1 reply; 15+ messages in thread
From: Berthold Cogel @ 2006-04-23 21:56 UTC (permalink / raw)
  To: Johan Vromans; +Cc: linux-acpi

Johan Vromans wrote:
 > I managed to get the latest acpi-sbs (20050120) going on 2.6.16.
> I have no idea what the impact of my changes is to the rest of the
> kernel, but I got my familiar battery readings back.
> Drop me a line if you want to give it a try. At your own risk, of
> course...
> 

I don't know why I'm 'playing' this game. But somehow I'm getting used
to it.

No risk, no fun! ;-)

I'm not sure if I can do the test before May, but I try.

Berthold

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Was: Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-04-23 21:56       ` Berthold Cogel
@ 2006-04-24  9:36         ` Johan Vromans
  2006-05-09 23:43           ` Berthold Cogel
  0 siblings, 1 reply; 15+ messages in thread
From: Johan Vromans @ 2006-04-24  9:36 UTC (permalink / raw)
  To: Berthold Cogel; +Cc: Johan Vromans, linux-acpi

Berthold Cogel <cogel@rrz.uni-koeln.de> writes:

> I don't know why I'm 'playing' this game.

To get battery readings ...

> I'm not sure if I can do the test before May, but I try.

Okay, I've packed it up with the rest of Rich' sources in what I've
shamelessly called acpi_sbs-20060422. You can fetch it from
http://www.squirrel.nl/pub/xfer/acpi_sbs-20060422.tar.bz2

Remember -- use at your own risk. I merely removed the code that
didn't compile... But it seems to work for me.

-- Johan

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Was: Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-04-24  9:36         ` Johan Vromans
@ 2006-05-09 23:43           ` Berthold Cogel
  2006-06-01 16:29             ` Johan Vromans
  0 siblings, 1 reply; 15+ messages in thread
From: Berthold Cogel @ 2006-05-09 23:43 UTC (permalink / raw)
  To: Johan Vromans; +Cc: linux-acpi

Johan Vromans wrote:
> 
>> I'm not sure if I can do the test before May, but I try.
> 
> Okay, I've packed it up with the rest of Rich' sources in what I've
> shamelessly called acpi_sbs-20060422. You can fetch it from
> http://www.squirrel.nl/pub/xfer/acpi_sbs-20060422.tar.bz2
> 
> Remember -- use at your own risk. I merely removed the code that
> didn't compile... But it seems to work for me.
> 
> -- Johan

Hello Johan,

the modules work great. Without a patched DSDT. Just out of the box.

But there are still some minor flaws. I got some warnings during compile
with kernel 2.6.16.13:

  CC [M]  /usr/src/acpi_sbs-20060422/i2c-acpi-ec.o
/usr/src/acpi_sbs-20060422/i2c-acpi-ec.c: In function 'acpi_ec_smb_access':
/usr/src/acpi_sbs-20060422/i2c-acpi-ec.c:144: warning: 'len' may be used
uninitialized in this function
/usr/src/acpi_sbs-20060422/i2c-acpi-ec.c:144: warning: 'temp[0]' may be
used uninitialized in this function
/usr/src/acpi_sbs-20060422/i2c-acpi-ec.c:144: warning: 'temp[1]' may be
used uninitialized in this function

And the Makefile installed the modules in the root filesystem. I used a
Makefile from an older version of Rich's package, which did the job.
I've attached the file.


It would be nice to have this in the kernel.

I don't know if it is possible to merge the ac-adapter/battery part of
the modules with the corresponding kernel modules (to provide the legacy
interfaces ?).
The code could then be switched with a configuration option, which also
enables the rest of the code in additional modules (acpi_sbs, i2c_acpi_ec).

This would simplify the configuration and reduces the need to read the
kernel docs. ;-)


Regards,

Berthold

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Was: Re: UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI
  2006-05-09 23:43           ` Berthold Cogel
@ 2006-06-01 16:29             ` Johan Vromans
  0 siblings, 0 replies; 15+ messages in thread
From: Johan Vromans @ 2006-06-01 16:29 UTC (permalink / raw)
  To: linux-acpi

Berthold Cogel <cogel@rrz.uni-koeln.de> writes:

> It would be nice to have this in the kernel.

What steps are needed to get this in the kernel?

-- Johan

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2006-06-01 16:29 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-01-26 20:27 UBUNTU - acpi battery on ACER TRAVELMATE 4000 WLMI Brown, Len
2006-01-27 11:43 ` Johan Vromans
2006-04-19 23:31   ` Was: " Berthold Cogel
2006-04-20 10:43     ` Johan Vromans
2006-04-20 11:32       ` Matthew Garrett
2006-04-22 20:53         ` Johan Vromans
2006-04-22 21:23           ` Matthew Garrett
2006-04-20 22:45       ` Berthold Cogel
2006-04-21  9:30         ` Johan Vromans
2006-04-22 18:02           ` Berthold Cogel
2006-04-22 18:27     ` Johan Vromans
2006-04-23 21:56       ` Berthold Cogel
2006-04-24  9:36         ` Johan Vromans
2006-05-09 23:43           ` Berthold Cogel
2006-06-01 16:29             ` Johan Vromans

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox