1*d2ec54f7Sphitran /* 2*d2ec54f7Sphitran * CDDL HEADER START 3*d2ec54f7Sphitran * 4*d2ec54f7Sphitran * The contents of this file are subject to the terms of the 5*d2ec54f7Sphitran * Common Development and Distribution License (the "License"). 6*d2ec54f7Sphitran * You may not use this file except in compliance with the License. 7*d2ec54f7Sphitran * 8*d2ec54f7Sphitran * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9*d2ec54f7Sphitran * or http://www.opensolaris.org/os/licensing. 10*d2ec54f7Sphitran * See the License for the specific language governing permissions 11*d2ec54f7Sphitran * and limitations under the License. 12*d2ec54f7Sphitran * 13*d2ec54f7Sphitran * When distributing Covered Code, include this CDDL HEADER in each 14*d2ec54f7Sphitran * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15*d2ec54f7Sphitran * If applicable, add the following below this CDDL HEADER, with the 16*d2ec54f7Sphitran * fields enclosed by brackets "[]" replaced with your own identifying 17*d2ec54f7Sphitran * information: Portions Copyright [yyyy] [name of copyright owner] 18*d2ec54f7Sphitran * 19*d2ec54f7Sphitran * CDDL HEADER END 20*d2ec54f7Sphitran */ 21*d2ec54f7Sphitran /* 22*d2ec54f7Sphitran * Copyright 2008 Sun Microsystems, Inc. All rights reserved. 23*d2ec54f7Sphitran * Use is subject to license terms. 24*d2ec54f7Sphitran */ 25*d2ec54f7Sphitran 26*d2ec54f7Sphitran #ifndef _SYS_SYSEVENT_PWRCTL_H 27*d2ec54f7Sphitran #define _SYS_SYSEVENT_PWRCTL_H 28*d2ec54f7Sphitran 29*d2ec54f7Sphitran #pragma ident "%Z%%M% %I% %E% SMI" 30*d2ec54f7Sphitran 31*d2ec54f7Sphitran #ifdef __cplusplus 32*d2ec54f7Sphitran extern "C" { 33*d2ec54f7Sphitran #endif 34*d2ec54f7Sphitran 35*d2ec54f7Sphitran /* 36*d2ec54f7Sphitran * Event type schema for EC_PWRCTL: 37*d2ec54f7Sphitran * Event Class - EC_PWRCTL 38*d2ec54f7Sphitran * Event Sub-Class - ESC_PWRCTL_ADD | 39*d2ec54f7Sphitran * ESC_PWRCTL_REMOVE | 40*d2ec54f7Sphitran * ESC_PWRCTL_WARN | 41*d2ec54f7Sphitran * ESC_PWRCTL_LOW | 42*d2ec54f7Sphitran * ESC_PWRCTL_STATE_CHANGE | 43*d2ec54f7Sphitran * ESC_PWRCTL_POWER_BUTTON | 44*d2ec54f7Sphitran * ESC_PWRCTL_BRIGHTNESS_UP | 45*d2ec54f7Sphitran * ESC_PWRCTL_BRIGHTNESS_DOWN 46*d2ec54f7Sphitran * Event Publisher - SUNW:kern:[environmental monitor name] 47*d2ec54f7Sphitran * Attribute Name - PWRCTL_VERSION 48*d2ec54f7Sphitran * Attribute Type - SE_DATA_TYPE_UINT32 49*d2ec54f7Sphitran * Attribute Value - [version of the schema] 50*d2ec54f7Sphitran * Attribute Name - PWRCTL_DEV_HID 51*d2ec54f7Sphitran * Attribute Type - SE_DATA_TYPE_STRING 52*d2ec54f7Sphitran * Attribute Value - [Label identifying the ACPI hardware] 53*d2ec54f7Sphitran * Attribute Name - PWRCTL_DEV_UID 54*d2ec54f7Sphitran * Attribute Type - SE_DATA_TYPE_STRING 55*d2ec54f7Sphitran * Attribute Value - [Both the _HID and _UID values can be of either type 56*d2ec54f7Sphitran * STRING or NUMBER in the ACPI tables. In order to 57*d2ec54f7Sphitran * provide a consistent data type in the external 58*d2ec54f7Sphitran * interface, these values are always returned as NULL 59*d2ec54f7Sphitran * terminated strings, regardless of the original data 60*d2ec54f7Sphitran * type in the source ACPI table.] 61*d2ec54f7Sphitran * Attribute Name - PWRCTL_DEV_INDEX 62*d2ec54f7Sphitran * Attribute Type - SE_DATA_TYPE_UINT32 63*d2ec54f7Sphitran * Attribute Value - [Device index] 64*d2ec54f7Sphitran * 65*d2ec54f7Sphitran * ESC_PWRCTL_WARN, ESC_PWRCTL_LOW only field: 66*d2ec54f7Sphitran * Attribute Name - PWRCTL_CHARGE_LEVEL 67*d2ec54f7Sphitran * Attribute Type - SE_DATA_TYPE_UINT32 68*d2ec54f7Sphitran * Attribute Value - [charge level] 69*d2ec54f7Sphitran */ 70*d2ec54f7Sphitran 71*d2ec54f7Sphitran #define PWRCTL_VERSION "pwrctl_version" /* Version of the schema */ 72*d2ec54f7Sphitran #define PWRCTL_DEV_PHYS_PATH "pwrctl_dev_phys_path" /* Physical Path */ 73*d2ec54f7Sphitran #define PWRCTL_DEV_HID "pwrctl_dev_hid" /* ACPI device Hardware Id */ 74*d2ec54f7Sphitran #define PWRCTL_DEV_UID "pwrctl_dev_uid" /* ACPI device Unique Id */ 75*d2ec54f7Sphitran #define PWRCTL_DEV_INDEX "pwrctl_dev_index" /* Device index */ 76*d2ec54f7Sphitran #define PWRCTL_CHARGE_LEVEL "pwrctl_charge_level" /* Event related state */ 77*d2ec54f7Sphitran #define PWRCTL_BRIGHTNESS_LEVEL "pwrctl_brightness_level" 78*d2ec54f7Sphitran 79*d2ec54f7Sphitran #ifdef __cplusplus 80*d2ec54f7Sphitran } 81*d2ec54f7Sphitran #endif 82*d2ec54f7Sphitran 83*d2ec54f7Sphitran #endif /* _SYS_SYSEVENT_PWRCTL_H */ 84