Distribution: Mandrake Hardware Environment: Dell Inspiron 5150 Software Environment: Problem Description: Battery Removal Undetected Steps to reproduce: Remove battery; cat /proc/acpi/battery/BAT0/state This produces the following output, which is identical to that when the battery was present: present: yes capacity state: ok charging state: unknown present rate: unknown remaining capacity: 6450 mAh present voltage: 16462 mV
Created attachment 2287 [details] ACPI dump from my laptop
did you notice if interrupt is generated when you remove battery? eg. compare 'cat /proc/interrupts' before remove and after before
I can't really tell with the output. Maybe you can, but I don't think there's enough information here to tell for sure. Here's the diff before and after: < 0: 12235163 IO-APIC-edge timer < 1: 48857 IO-APIC-edge i8042 --- > 0: 12241609 IO-APIC-edge timer > 1: 48881 IO-APIC-edge i8042 9c9 < 15: 83025 IO-APIC-edge ide1 --- > 15: 83034 IO-APIC-edge ide1 11c11 < 17: 596990 IO-APIC-level Intel 82801DB-ICH4, eth0 --- > 17: 597280 IO-APIC-level Intel 82801DB-ICH4, eth0 14c14 < 20: 755733 IO-APIC-level nvidia --- > 20: 756123 IO-APIC-level nvidia 17c17 < LOC: 12231507 --- > LOC: 12237953 I'll try to put a printk in the ISR and see what happens.
ok, according to your diff file, no interrupt when you remove battery. please check if press power button can generate interrupt? eg.check if the value of acpi in 'cat /proc/interrupts' changed
No, the power button does not generate an interrupt. Nor does the suspend button or closing the lid. The ACPI interrupt count is, in fact, at zero.
ok, it likes an interrupt issue instead of a battery issue. please attach the dmesg and cat /proc/interrupts. thanks -- shaohua
Created attachment 2329 [details] dmesg file
Created attachment 2330 [details] /proc/interrupts
FYI: in light of this information, bug 1752 may be related to this.
yes, it's the same issue. *** This bug has been marked as a duplicate of 1752 ***