Deleted Added
full compact
pmuvar.h (228270) pmuvar.h (259284)
1/*-
2 * Copyright (c) 2006 Michael Lorenz
3 * Copyright (c) 2008 Nathan Whitehorn
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 10 unchanged lines hidden (view full) ---

19 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
20 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
21 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
22 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
23 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
24 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
25 * POSSIBILITY OF SUCH DAMAGE.
26 *
1/*-
2 * Copyright (c) 2006 Michael Lorenz
3 * Copyright (c) 2008 Nathan Whitehorn
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 10 unchanged lines hidden (view full) ---

19 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
20 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
21 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
22 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
23 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
24 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
25 * POSSIBILITY OF SUCH DAMAGE.
26 *
27 * $FreeBSD: head/sys/powerpc/powermac/pmuvar.h 228270 2011-12-05 00:12:10Z jhibbits $
27 * $FreeBSD: head/sys/powerpc/powermac/pmuvar.h 259284 2013-12-13 02:37:35Z jhibbits $
28 *
29 */
30
31#ifndef PMUVAR_H
32#define PMUVAR_H
33
34/* PMU commands */
35#define PMU_POWER_CTRL0 0x10 /* control power of some devices */

--- 119 unchanged lines hidden (view full) ---

155 struct resource *sc_irq;
156 void *sc_ih;
157
158 struct mtx sc_mutex;
159 device_t adb_bus;
160 volatile int sc_autopoll;
161 int sc_batteries;
162 struct cdev *sc_leddev;
28 *
29 */
30
31#ifndef PMUVAR_H
32#define PMUVAR_H
33
34/* PMU commands */
35#define PMU_POWER_CTRL0 0x10 /* control power of some devices */

--- 119 unchanged lines hidden (view full) ---

155 struct resource *sc_irq;
156 void *sc_ih;
157
158 struct mtx sc_mutex;
159 device_t adb_bus;
160 volatile int sc_autopoll;
161 int sc_batteries;
162 struct cdev *sc_leddev;
163 int lid_closed;
163 int lid_closed;
164 uint8_t saved_regs[9];
164};
165
166struct pmu_battstate {
167 int state;
168
169 int charge;
170 int maxcharge;
171 int current;
172 int voltage;
173};
174
165};
166
167struct pmu_battstate {
168 int state;
169
170 int charge;
171 int maxcharge;
172 int current;
173 int voltage;
174};
175
176int pmu_set_speed(int low_speed);
177
175#endif /* PMUVAR_H */
178#endif /* PMUVAR_H */