You are not logged in.

#1 2011-03-30 05:07:24

Dj_kourampies
Member
From: Greece
Registered: 2005-11-02
Posts: 32
Website

Esprimo U9200 - Battery status problems - Fix Found, Help needed!

After months with this bug, and unsuccessfully searching for a solution, it seems like I found one in the edubuntu wiki.
But I need help, seems this solution is based on the ubuntu distro tools, and since Im not such an advanced user of (Arch) Linux, therefore I don't know how to adapt this solution to Archlinux.

From the related entry in the edubuntu wiki: https://wiki.edubuntu.org/LaptopTesting … primoU9200

Battery: the BIOS DSDT has a bug, which causes to incorrectly show the Charged and Discharging states. The fix is easy. First we'll get the DSDT table and dissasemble it:
sudo apt-get install iasl
cd
mkdir DSDT
cd DSDT
sudo cat /proc/acpi/dsdt > dsdt.dat
iasl -d dsdt.dat
gedit dsdt.aml
Ok, now you should have your dsdt file open. So let's fix it, look for the following code in Device (BAT0), under the Method (UPBS, 0, NotSerialized) subsection:
     If (LEqual (Local0, 0x02))
     {
         And (Local7, One, Local0)
         If (LEqual (Local0, One))
         {
             And (Local7, 0x80, Local1)
             If (LEqual (Local1, 0x80))
             {
                 Or (Local4, 0x02, Local4)
             }
             Else
             {
                 Or (Local4, One, Local4)
             }
         }
      }
Ok, now let's fix it. Else code is misplaced, it has to be moved out of the If (LEqual (Local0, One)). So, it should be:
     If (LEqual (Local0, 0x02))
     {
         And (Local7, One, Local0)
         If (LEqual (Local0, One))
         {
             And (Local7, 0x80, Local1)
             If (LEqual (Local1, 0x80))
             {
                 Or (Local4, 0x02, Local4)
             }
             //ELSE WAS HERE
         }
         // ELSE CORRECT PLACE
         Else
         {
             Or (Local4, One, Local4)
         }
      }
Now, simply save and close gedit, and let's continue:
cd
cd DSDT
iasl -tc dsdt.dsl
sudo cp dsdt.aml /etc/initramfs-tools/DSDT.aml
sudo update-initramfs -u -k all

So, that's it. What we've done is recompile the DSDT including the fix, moving it into the initramfs and then recompiled the initramfs so that the custom DSDT gets loaded. After rebooting the battery status should be always ok.

I managed to install iaml, disassemble the DSDT from /sys/firmware/acpi/tables/DSDT (and not the pathe the wiki says) and do the changes the wiki says, and recompile it, but Im not really sure of what to do after that.

The commands to make the initramfs and the configuration files I probably need to modify to include my patch are different. Any help on those? I marked the lines I need help with as bold. Thanks.

Last edited by Dj_kourampies (2011-03-30 05:10:30)

Offline

#2 2011-03-30 06:09:21

ngoonee
Forum Fellow
From: Between Thailand and Singapore
Registered: 2009-03-17
Posts: 7,356

Re: Esprimo U9200 - Battery status problems - Fix Found, Help needed!

You'd have the find the appropriate locations in mkinitcpio, which is what Arch uses for the initramfs...


Allan-Volunteer on the (topic being discussed) mailn lists. You never get the people who matters attention on the forums.
jasonwryan-Installing Arch is a measure of your literacy. Maintaining Arch is a measure of your diligence. Contributing to Arch is a measure of your competence.
Griemak-Bleeding edge, not bleeding flat. Edge denotes falls will occur from time to time. Bring your own parachute.

Offline

#3 2011-04-01 12:46:39

Dj_kourampies
Member
From: Greece
Registered: 2005-11-02
Posts: 32
Website

Re: Esprimo U9200 - Battery status problems - Fix Found, Help needed!

I found how to do it with initramfs, but I also discovered that custom DSDTs through initramfs are no longer supported since kernel 2.6.30.

So I had to recompile the kernel, including the custom DSDT in the kernel build. Sadly Im not so good with ABS so I just modded the original kernel26 package. IIt works perfectly. hope that sometime soon I ll manage to make a PKGBUILD for a kernel26-u9200 package.

Offline

Board footer

Powered by FluxBB