linux/include/uapi/linux/apm_bios.h

/* SPDX-License-Identifier: GPL-2.0+ WITH Linux-syscall-note */
/*
 * Include file for the interface to an APM BIOS
 * Copyright 1994-2001 Stephen Rothwell ([email protected])
 *
 * This program is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License as published by the
 * Free Software Foundation; either version 2, or (at your option) any
 * later version.
 *
 * This program is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * General Public License for more details.
 */
#ifndef _UAPI_LINUX_APM_H
#define _UAPI_LINUX_APM_H


#include <linux/types.h>

apm_event_t;
apm_eventinfo_t;

struct apm_bios_info {};


/*
 * Power states
 */
#define APM_STATE_READY
#define APM_STATE_STANDBY
#define APM_STATE_SUSPEND
#define APM_STATE_OFF
#define APM_STATE_BUSY
#define APM_STATE_REJECT
#define APM_STATE_OEM_SYS
#define APM_STATE_OEM_DEV

#define APM_STATE_DISABLE
#define APM_STATE_ENABLE

#define APM_STATE_DISENGAGE
#define APM_STATE_ENGAGE

/*
 * Events (results of Get PM Event)
 */
#define APM_SYS_STANDBY
#define APM_SYS_SUSPEND
#define APM_NORMAL_RESUME
#define APM_CRITICAL_RESUME
#define APM_LOW_BATTERY
#define APM_POWER_STATUS_CHANGE
#define APM_UPDATE_TIME
#define APM_CRITICAL_SUSPEND
#define APM_USER_STANDBY
#define APM_USER_SUSPEND
#define APM_STANDBY_RESUME
#define APM_CAPABILITY_CHANGE
#define APM_USER_HIBERNATION
#define APM_HIBERNATION_RESUME

/*
 * Error codes
 */
#define APM_SUCCESS
#define APM_DISABLED
#define APM_CONNECTED
#define APM_NOT_CONNECTED
#define APM_16_CONNECTED
#define APM_16_UNSUPPORTED
#define APM_32_CONNECTED
#define APM_32_UNSUPPORTED
#define APM_BAD_DEVICE
#define APM_BAD_PARAM
#define APM_NOT_ENGAGED
#define APM_BAD_FUNCTION
#define APM_RESUME_DISABLED
#define APM_NO_ERROR
#define APM_BAD_STATE
#define APM_NO_EVENTS
#define APM_NOT_PRESENT

/*
 * APM Device IDs
 */
#define APM_DEVICE_BIOS
#define APM_DEVICE_ALL
#define APM_DEVICE_DISPLAY
#define APM_DEVICE_STORAGE
#define APM_DEVICE_PARALLEL
#define APM_DEVICE_SERIAL
#define APM_DEVICE_NETWORK
#define APM_DEVICE_PCMCIA
#define APM_DEVICE_BATTERY
#define APM_DEVICE_OEM
#define APM_DEVICE_OLD_ALL
#define APM_DEVICE_CLASS
#define APM_DEVICE_MASK


/*
 * Battery status
 */
#define APM_MAX_BATTERIES

/*
 * APM defined capability bit flags
 */
#define APM_CAP_GLOBAL_STANDBY
#define APM_CAP_GLOBAL_SUSPEND
#define APM_CAP_RESUME_STANDBY_TIMER
#define APM_CAP_RESUME_SUSPEND_TIMER
#define APM_CAP_RESUME_STANDBY_RING
#define APM_CAP_RESUME_SUSPEND_RING
#define APM_CAP_RESUME_STANDBY_PCMCIA
#define APM_CAP_RESUME_SUSPEND_PCMCIA

/*
 * ioctl operations
 */
#include <linux/ioctl.h>

#define APM_IOC_STANDBY
#define APM_IOC_SUSPEND

#endif /* _UAPI_LINUX_APM_H */