1.\"- 2.\" Copyright (c) 2008 Nathan Whitehorn <nwhitehorn@FreeBSD.org> 3.\" All rights reserved. 4.\" 5.\" Redistribution and use in source and binary forms, with or without 6.\" modification, are permitted provided that the following conditions 7.\" are met: 8.\" 1. Redistributions of source code must retain the above copyright 9.\" notice, this list of conditions and the following disclaimer. 10.\" 2. Redistributions in binary form must reproduce the above copyright 11.\" notice, this list of conditions and the following disclaimer in the 12.\" documentation and/or other materials provided with the distribution. 13.\" 14.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 15.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 16.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 17.\" DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, 18.\" INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 19.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 20.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 22.\" STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 23.\" ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 24.\" POSSIBILITY OF SUCH DAMAGE. 25.\" 26.Dd December 6, 2008 27.Dt PMU 4 28.Os 29.Sh NAME 30.Nm pmu 31.Nd Apple PMU99 Power Management Driver 32.Sh SYNOPSIS 33To compile this driver into the kernel, 34place the following lines in your 35kernel configuration file: 36.Bd -ragged -offset indent 37.Cd "device adb" 38.Cd "device pmu" 39.Ed 40.Sh DESCRIPTION 41The 42.Nm 43driver provides support for the Power Management Unit (PMU) found in Apple 44Core99 hardware. 45This includes late G3 laptops, all G4 machines, early G5 46desktops and all G5 XServes. 47.Pp 48The Apple PMU controller is a multi-purpose ASIC that provides power 49management and thermal control, as well as an ADB bus for the internal 50keyboard and mouse on laptops. 51.Sh HARDWARE 52Chips supported by the 53.Nm 54driver include: 55.Pp 56.Bl -bullet -compact 57.It 58Apple KeyLargo PMU 59.It 60Apple K2-KeyLargo PMU 61.El 62.Sh SYSCTL VARIABLES 63The 64.Nm 65driver provides power management services in addition to an 66.Xr adb 4 67interface. 68The following sysctls can be used to control the 69power management behavior and to examine current system power and 70thermal conditions. 71.Bl -tag -width indent 72.It Va dev.pmu.%d.server_mode 73Restart after power failure behavior (1 causes system to reboot after power 74cut, 0 causes system to remain off). 75.It Va dev.pmu.%d.batteries.%d.present 76Indicates whether the relevant battery is inserted. 77.It Va dev.pmu.%d.batteries.%d.charging 78Indicates whether the battery is currently charging. 79.It Va dev.pmu.%d.batteries.%d.charge 80The current battery charge, in milliamp hours. 81.It Va dev.pmu.%d.batteries.%d.maxcharge 82The battery's self-reported maximum charge, in milliamp hours. 83.It Va dev.pmu.%d.batteries.%d.rate 84The current into the battery, in milliamps. 85While the battery is discharging, 86this will be negative. 87.It Va dev.pmu.%d.batteries.%d.voltage 88Battery voltage, in millivolts. 89.It Va dev.pmu.%d.batteries.%d.time 90Estimated time until full battery charge (or discharge), in minutes. 91.It Va dev.pmu.%d.batteries.%d.life 92Current fraction of the battery's maximum charge, in percent. 93.El 94.Sh SEE ALSO 95.Xr acpi 4 , 96.Xr adb 4 , 97.Xr led 4 98.Sh HISTORY 99The 100.Nm 101device driver appeared in 102.Nx 4.0 , 103and then in 104.Fx 8.0 . 105.Sh AUTHORS 106.An -nosplit 107The 108.Nm 109driver was written by 110.An Michael Lorenz Aq Mt macallan@NetBSD.org 111and ported to 112.Fx 113by 114.An Nathan Whitehorn Aq Mt nwhitehorn@FreeBSD.org . 115