Gentoo Archives: gentoo-ppc-user

From: Marius Berntsberg <marbern@×××××.no>
To: gentoo-ppc-user@g.o
Subject: [gentoo-ppc-user] pmud reporting wrong battery status?
Date: Thu, 24 Jul 2003 00:21:58
Message-Id: 1059006111.6334.12.camel@hal9000
1 Hi list.
2
3 Last night I was playing around with the laptop-mode in
4 2.4.21-ben2.
5
6 While checking what pmud reported i saw that it was reporting "minimum
7 battery" on a fully charged battery. When connecting the psu pmud
8 reported "maximum ac".
9
10 pmud never reports maximum or medium while system is running og battery,
11 while on ac, pmud always reports "maximum", even if battery state is
12 low.
13
14 is this the way it should work?
15
16 anyone able to reproduce?
17 or an error in my conf files?
18
19 Thanx!
20 Marius
21
22
23 With psu connected:
24
25 marius@powerbook ~ $ cat /proc/cpuinfo
26 cpu : 7455, altivec supported
27 clock : 867MHz
28 revision : 3.3 (pvr 8001 0303)
29 bogomips : 844.35
30 machine : PowerBook6,1
31 motherboard : PowerBook6,1 MacRISC3 Power Macintosh
32 board revision : 00000001
33 detected as : 287 (PowerBook G4 12")
34 pmac flags : 0000000a
35 L2 cache : 256K unified
36 memory : 384MB
37 pmac-generation : NewWorld
38
39 marius@powerbook ~ $ cat /proc/pmu/info
40 PMU driver version : 2
41 PMU firmware version : 0c
42 AC Power : 1
43 Battery count : 1
44
45 marius@powerbook ~ $ cat /proc/pmu/battery_0
46
47 flags : 00000011
48 charge : 2926
49 max_charge : 3922
50 current : -1181
51 voltage : 11693
52 time rem. : 8919
53
54
55 powerbook marius # pmud -d -a
56 pmud[6008]: pmud [treshold = 420, margin = powerbook marius # pmud -d -a
57 pmud[6008]: pmud [treshold = 420, margin = 15] started
58 pmud[6008]: opening /dev/adb
59 pmud[6008]: opening /dev/pmu
60 pmud[6008]: pmu_op(0xea, ..., version req)
61 PMU version 12: iBook/G3 Pismo/G4 Titanium
62 pmud[6008]: PMU version 12: iBook/G3 Pismo/G4 Titanium
63 pmud[6008]: starting monitoring loop
64 pmud[6008]: pmu_op(0xdc, ..., switch req)
65 pmud[6008]: pmu_op(0x6f, ..., smart battery req)
66 pmud[6008]: pmu_op(0x6f, ..., smart battery req)
67 pmud[6008]: timeleft = 8549
68 pmud[6008]: running /etc/power/pwrctl maximum ac
69
70 Broadcast message from root (Wed Jul 23 13:02:14 2003):
71
72 maximum ac
73 pmud[6008]: PMU interrupt:
74 pmud[6008]: 40
75 pmud[6008]: 14
76 pmud[6008]: pmu_op(0xdc, ..., switch req)
77 pmud[6008]: pmu_op(0x6f, ..., smart battery req)
78 pmud[6008]: pmu_op(0x6f, ..., smart battery req)
79 pmud[6008]: timeleft = -1
80 pmud[6008]: PMU interrupt:
81 pmud[6008]: 40
82 pmud[6008]: 14
83 pmud[6008]: pmu_op(0xdc, ..., switch req)
84 pmud[6008]: pmu_op(0x6f, ..., smart battery req)
85 pmud[6008]: pmu_op(0x6f, ..., smart battery req)
86 pmud[6008]: timeleft = -1
87 15] started
88 pmud[6008]: opening /dev/adb
89 pmud[6008]: opening /dev/pmu
90 pmud[6008]: pmu_op(0xea, ..., version req)
91 PMU version 12: iBook/G3 Pismo/G4 Titanium
92 pmud[6008]: PMU version 12: iBook/G3 Pismo/G4 Titanium
93 pmud[6008]: starting monitoring loop
94 pmud[6008]: pmu_op(0xdc, ..., switch req)
95 pmud[6008]: pmu_op(0x6f, ..., smart battery req)
96 pmud[6008]: pmu_op(0x6f, ..., smart battery req)
97 pmud[6008]: timeleft = 8549
98 pmud[6008]: running /etc/power/pwrctl maximum ac
99
100 Broadcast message from root (Wed Jul 23 13:02:14 2003):
101
102 maximum ac
103 pmud[6008]: PMU interrupt:
104 pmud[6008]: 40
105 pmud[6008]: 14
106 pmud[6008]: pmu_op(0xdc, ..., switch req)
107 pmud[6008]: pmu_op(0x6f, ..., smart battery req)
108 pmud[6008]: pmu_op(0x6f, ..., smart battery req)
109 pmud[6008]: timeleft = -1
110 pmud[6008]: PMU interrupt:
111 pmud[6008]: 40
112 pmud[6008]: 14
113 pmud[6008]: pmu_op(0xdc, ..., switch req)
114 pmud[6008]: pmu_op(0x6f, ..., smart battery req)
115 pmud[6008]: pmu_op(0x6f, ..., smart battery req)
116 pmud[6008]: timeleft = -1
117
118
119
120 Whitout psu:
121
122 marius@powerbook ~ $ cat /proc/cpuinfo
123 cpu : 7455, altivec supported
124 clock : 533MHz
125 revision : 3.3 (pvr 8001 0303)
126 bogomips : 519.08
127 machine : PowerBook6,1
128 motherboard : PowerBook6,1 MacRISC3 Power Macintosh
129 board revision : 00000001
130 detected as : 287 (PowerBook G4 12")
131 pmac flags : 0000000a
132 L2 cache : 256K unified
133 memory : 384MB
134 pmac-generation : NewWorld
135
136 marius@powerbook ~ $ cat /proc/pmu/info
137 PMU driver version : 2
138 PMU firmware version : 0c
139 AC Power : 0
140 Battery count : 1
141
142 marius@powerbook ~ $ cat /proc/pmu/battery_0
143
144 flags : 00000011
145 charge : 2941
146 max_charge : 3922
147 current : -1167
148 voltage : 11752
149 time rem. : 9072
150
151 powerbook marius # pmud -d -a
152 pmud[5995]: pmud [treshold = 420, margin = 15] started
153 pmud[5995]: opening /dev/adb
154 pmud[5995]: opening /dev/pmu
155 pmud[5995]: pmu_op(0xea, ..., version req)
156 PMU version 12: iBook/G3 Pismo/G4 Titanium
157 pmud[5995]: PMU version 12: iBook/G3 Pismo/G4 Titanium
158 pmud[5995]: starting monitoring loop
159 pmud[5995]: pmu_op(0xdc, ..., switch req)
160 pmud[5995]: pmu_op(0x6f, ..., smart battery req)
161 pmud[5995]: pmu_op(0x6f, ..., smart battery req)
162 pmud[5995]: timeleft = 8294
163 pmud[5995]: running /etc/power/pwrctl minimum battery
164
165 Broadcast message from root (Wed Jul 23 13:01:13 2003):
166
167 minimum battery
168 pmud[5995]: PMU interrupt:
169 pmud[5995]: 40
170 pmud[5995]: 10
171 pmud[5995]: pmu_op(0xdc, ..., switch req)
172 pmud[5995]: pmu_op(0x6f, ..., smart battery req)
173 pmud[5995]: pmu_op(0x6f, ..., smart battery req)
174 pmud[5995]: timeleft = 8294
175 pmud[5995]: PMU interrupt:
176 pmud[5995]: 40
177 pmud[5995]: 10
178 pmud[5995]: pmu_op(0xdc, ..., switch req)
179 pmud[5995]: pmu_op(0x6f, ..., smart battery req)
180 pmud[5995]: pmu_op(0x6f, ..., smart battery req)
181 pmud[5995]: timeleft = 8294
182
183
184
185 --
186 gentoo-ppc-user@g.o mailing list