1*9e70a116SBin Meng/*
2*9e70a116SBin Meng * Copyright (C) 2008 Advanced Micro Devices, Inc.
3*9e70a116SBin Meng * Copyright (C) 2016 Bin Meng <bmeng.cn@gmail.com>
4*9e70a116SBin Meng *
5*9e70a116SBin Meng * Modified from coreboot src/arch/x86/acpi/statdef.asl
6*9e70a116SBin Meng *
7*9e70a116SBin Meng * SPDX-License-Identifier:	GPL-2.0+
8*9e70a116SBin Meng */
9*9e70a116SBin Meng
10*9e70a116SBin Meng/* Status and notification definitions */
11*9e70a116SBin Meng
12*9e70a116SBin Meng#define STA_MISSING		0x00
13*9e70a116SBin Meng#define STA_PRESENT		0x01
14*9e70a116SBin Meng#define STA_ENABLED		0x03
15*9e70a116SBin Meng#define STA_DISABLED		0x09
16*9e70a116SBin Meng#define STA_INVISIBLE		0x0b
17*9e70a116SBin Meng#define STA_UNAVAILABLE		0x0d
18*9e70a116SBin Meng#define STA_VISIBLE		0x0f
19*9e70a116SBin Meng
20*9e70a116SBin Meng/* SMBus status codes */
21*9e70a116SBin Meng#define SMB_OK			0x00
22*9e70a116SBin Meng#define SMB_UNKNOWN_FAIL	0x07
23*9e70a116SBin Meng#define SMB_DEV_ADDR_NAK	0x10
24*9e70a116SBin Meng#define SMB_DEVICE_ERROR	0x11
25*9e70a116SBin Meng#define SMB_DEV_CMD_DENIED	0x12
26*9e70a116SBin Meng#define SMB_UNKNOWN_ERR		0x13
27*9e70a116SBin Meng#define SMB_DEV_ACC_DENIED	0x17
28*9e70a116SBin Meng#define SMB_TIMEOUT		0x18
29*9e70a116SBin Meng#define SMB_HST_UNSUPP_PROTOCOL	0x19
30*9e70a116SBin Meng#define SMB_BUSY		0x1a
31*9e70a116SBin Meng#define SMB_PKT_CHK_ERROR	0x1f
32*9e70a116SBin Meng
33*9e70a116SBin Meng/* Device Object Notification Values */
34*9e70a116SBin Meng#define NOTIFY_BUS_CHECK	0x00
35*9e70a116SBin Meng#define NOTIFY_DEVICE_CHECK	0x01
36*9e70a116SBin Meng#define NOTIFY_DEVICE_WAKE	0x02
37*9e70a116SBin Meng#define NOTIFY_EJECT_REQUEST	0x03
38*9e70a116SBin Meng#define NOTIFY_DEVICE_CHECK_JR	0x04
39*9e70a116SBin Meng#define NOTIFY_FREQUENCY_ERROR	0x05
40*9e70a116SBin Meng#define NOTIFY_BUS_MODE		0x06
41*9e70a116SBin Meng#define NOTIFY_POWER_FAULT	0x07
42*9e70a116SBin Meng#define NOTIFY_CAPABILITIES	0x08
43*9e70a116SBin Meng#define NOTIFY_PLD_CHECK	0x09
44*9e70a116SBin Meng#define NOTIFY_SLIT_UPDATE	0x0b
45*9e70a116SBin Meng#define NOTIFY_SRA_UPDATE	0x0d
46*9e70a116SBin Meng
47*9e70a116SBin Meng/* Battery Device Notification Values */
48*9e70a116SBin Meng#define NOTIFY_BAT_STATUSCHG	0x80
49*9e70a116SBin Meng#define NOTIFY_BAT_INFOCHG	0x81
50*9e70a116SBin Meng#define NOTIFY_BAT_MAINTDATA	0x82
51*9e70a116SBin Meng
52*9e70a116SBin Meng/* Power Source Object Notification Values */
53*9e70a116SBin Meng#define NOTIFY_PWR_STATUSCHG	0x80
54*9e70a116SBin Meng#define NOTIFY_PWR_INFOCHG	0x81
55*9e70a116SBin Meng
56*9e70a116SBin Meng/* Thermal Zone Object Notification Values */
57*9e70a116SBin Meng#define NOTIFY_TZ_STATUSCHG	0x80
58*9e70a116SBin Meng#define NOTIFY_TZ_TRIPPTCHG	0x81
59*9e70a116SBin Meng#define NOTIFY_TZ_DEVLISTCHG	0x82
60*9e70a116SBin Meng#define NOTIFY_TZ_RELTBLCHG	0x83
61*9e70a116SBin Meng
62*9e70a116SBin Meng/* Power Button Notification Values */
63*9e70a116SBin Meng#define NOTIFY_POWER_BUTTON	0x80
64*9e70a116SBin Meng
65*9e70a116SBin Meng/* Sleep Button Notification Values */
66*9e70a116SBin Meng#define NOTIFY_SLEEP_BUTTON	0x80
67*9e70a116SBin Meng
68*9e70a116SBin Meng/* Lid Notification Values */
69*9e70a116SBin Meng#define NOTIFY_LID_STATUSCHG	0x80
70*9e70a116SBin Meng
71*9e70a116SBin Meng/* Processor Device Notification Values */
72*9e70a116SBin Meng#define NOTIFY_CPU_PPCCHG	0x80
73*9e70a116SBin Meng#define NOTIFY_CPU_CSTATECHG	0x81
74*9e70a116SBin Meng#define NOTIFY_CPU_THROTLCHG	0x82
75*9e70a116SBin Meng
76*9e70a116SBin Meng/* User Presence Device Notification Values */
77*9e70a116SBin Meng#define NOTIFY_USR_PRESNCECHG	0x80
78*9e70a116SBin Meng
79*9e70a116SBin Meng/* Ambient Light Sensor Notification Values */
80*9e70a116SBin Meng#define NOTIFY_ALS_ILLUMCHG	0x80
81*9e70a116SBin Meng#define NOTIFY_ALS_COLORTMPCHG	0x81
82*9e70a116SBin Meng#define NOTIFY_ALS_RESPCHG	0x82
83