/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License, Version 1.0 only
* (the "License"). You may not use this file except in compliance
* with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright 2000-2002 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _ENVD_H
#define _ENVD_H
#pragma ident "%Z%%M% %I% %E% SMI"
#include <libintl.h>
#ifdef __cplusplus
extern "C" {
#endif
/*
*/
#define ENV_CPU_FAN_DEVFS \
"/pci@1f,0/pmu@3/fan-control@0,c8:cpu_fan"
#define ENV_SYSTEM_FAN_DEVFS \
"/pci@1f,0/pmu@3/fan-control@0,c8:sys_fan"
#define SYSTEM_FAN_SPEED_MIN 0
/*
* devfs-path for various temperature sensors and CPU platform path
*/
#define CPU_DIE_SENSOR_DEVFS \
"/pci@1f,0/pmu@3/i2c@0,0/temperature@30:die_temp"
#define CPU_AMB_SENSOR_DEVFS \
"/pci@1f,0/pmu@3/i2c@0,0/temperature@30:amb_temp"
/*
* Temperature thresholds structure
*/
typedef struct {
/*
* CPU "die" temperature thresholds
*/
#define CPU_DIE_LOW_WARNING 0
/*
* CPU ambient temperature thresholds
*/
#define CPU_AMB_LOW_WARNING 0
/*
* Fan names
*/
/*
* Sensor names
*/
/*
* Temperature sensor related data structure
*/
typedef struct env_sensor {
} env_sensor_t;
/*
* Fan information data structure
*/
typedef struct env_fan {
} env_fan_t;
extern int env_debug;
/*
* Various messages
*/
#define ENVD_PLUGIN_INIT_FAILED \
gettext("SUNW_piclenvd: initialization failed!\n")
#define ENVD_PICL_SETUP_FAILED \
gettext("SUNW_piclenvd: PICL setup failed!\n")
#define PM_THREAD_CREATE_FAILED \
gettext("SUNW_piclenvd: pmthr thread creation failed!\n")
#define PM_THREAD_EXITING \
gettext("SUNW_piclenvd: pmthr exiting! errno:%d %s\n")
#define ENV_THREAD_CREATE_FAILED \
gettext("SUNW_piclenvd: envthr thread creation failed!\n")
#define ENV_SHUTDOWN_MSG \
gettext("SUNW_piclenvd: '%s' sensor temperature %d outside safe " \
"limits (%d...%d). Shutting down the system.\n")
#define ENV_WARNING_MSG \
gettext("SUNW_piclenvd: '%s' sensor temperature %d outside safe " \
"operating limits (%d...%d).\n")
#define ENV_FAN_OPEN_FAIL \
gettext("SUNW_piclenvd: can't open '%s' fan path:%s errno:%d %s\n")
#define ENV_SENSOR_OPEN_FAIL \
gettext("SUNW_piclenvd: can't open '%s' sensor path:%s errno:%d %s\n")
#define ENV_SENSOR_ACCESS_FAIL \
gettext("SUNW_piclenvd: can't access '%s' sensor errno:%d %s\n")
#define ENV_SENSOR_ACCESS_OK \
gettext("SUNW_piclenvd: '%s' sensor is accessible now.\n")
#define ENV_CONF_INT_EXPECTED \
gettext("SUNW_piclenvd: file:%s line:%d Invalid syntax or integer " \
"value outside range for keyword '%s'.\n")
#define ENV_CONF_STRING_EXPECTED \
gettext("SUNW_piclenvd: file:%s line:%d Invalid syntax for keyword " \
"'%s'. Expecting string in double quotes (length < %d).\n")
#define ENV_CONF_UNSUPPORTED_TYPE \
gettext("SUNW_piclenvd: file:%s line:%d Unsupported type:%d for " \
"keyword '%s'.\n")
#define ENV_CONF_UNSUPPORTED_KEYWORD \
gettext("SUNW_piclenvd: file:%s line:%d Unsupported keyword '%s'.\n")
#ifdef __cplusplus
}
#endif
#endif /* _ENVD_H */