mirror of
https://github.com/lm-sensors/lm-sensors.git
synced 2026-10-26 12:24:33 +00:00
(Phil) Added adm9240 and adm1021 entries into the lib and added VID
output to ADM9240. Status/alarms values need to be implemented instead of a raw output, but I'll do that too. git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@173 7894878c-1315-0410-8ee3-d5d059ff63e0
This commit is contained in:
1 parent
c55834ae8e
commit
bf7943bb69
6 files changed
+214
-2
No files matched your search
+26
-1
@@ -132,6 +132,9 @@
|
||||
#define DIV_FROM_REG(val) (1 << val)
|
||||
#define DIV_TO_REG(val) (val==1?0:(val==2?1:(val==4?2:3)))
|
||||
|
||||
#define VID_FROM_REG(val) ((val)==0x1f?0:(val)>=0x10?510-(val)*10:\
|
||||
(val)>=0x06?0:205-(val)*5)
|
||||
|
||||
/* Initial limits */
|
||||
#define ADM9240_INIT_IN_0 190
|
||||
#define ADM9240_INIT_IN_1 190
|
||||
@@ -201,7 +204,8 @@ struct adm9240_data {
|
||||
u8 temp_os_max; /* Register value */
|
||||
u8 temp_os_hyst; /* Register value */
|
||||
u16 alarms; /* Register encoding, combined */
|
||||
u8 analog_out; /* Register value */
|
||||
u8 analog_out; /* Register value */
|
||||
u8 vid; /* Register value combined */
|
||||
};
|
||||
|
||||
|
||||
@@ -238,6 +242,8 @@ static void adm9240_fan_div(struct i2c_client *client, int operation, int ctl_na
|
||||
int *nrels_mag, long *results);
|
||||
static void adm9240_analog_out(struct i2c_client *client, int operation, int ctl_name,
|
||||
int *nrels_mag, long *results);
|
||||
static void adm9240_vid(struct i2c_client *client, int operation, int ctl_name,
|
||||
int *nrels_mag, long *results);
|
||||
|
||||
/* I choose here for semi-static ADM9240 allocation. Complete dynamic
|
||||
allocation could also be used; the code needed for this would probably
|
||||
@@ -292,6 +298,8 @@ static ctl_table adm9240_dir_table_template[] = {
|
||||
&sensors_sysctl_real, NULL, &adm9240_alarms },
|
||||
{ ADM9240_SYSCTL_ANALOG_OUT, "analog_out", NULL, 0, 0644, NULL, &sensors_proc_real,
|
||||
&sensors_sysctl_real, NULL, &adm9240_analog_out },
|
||||
{ ADM9240_SYSCTL_VID, "vid", NULL, 0, 0644, NULL, &sensors_proc_real,
|
||||
&sensors_sysctl_real, NULL, &adm9240_vid },
|
||||
{ 0 }
|
||||
};
|
||||
|
||||
@@ -523,6 +531,9 @@ void adm9240_update_client(struct i2c_client *client)
|
||||
i = adm9240_read_value(client,ADM9240_REG_VID_FAN_DIV);
|
||||
data->fan_div[0] = (i >> 4) & 0x03;
|
||||
data->fan_div[1] = (i >> 6) & 0x03;
|
||||
data->vid = i & 0x0f;
|
||||
data->vid |= (adm9240_read_value(client,ADM9240_REG_VID4) & 0x01) << 4;
|
||||
|
||||
data->alarms = adm9240_read_value(client,ADM9240_REG_INT1_STAT) +
|
||||
(adm9240_read_value(client,ADM9240_REG_INT2_STAT) << 8);
|
||||
data->analog_out = adm9240_read_value(client,ADM9240_REG_ANALOG_OUT);
|
||||
@@ -682,6 +693,20 @@ void adm9240_analog_out(struct i2c_client *client, int operation, int ctl_name,
|
||||
}
|
||||
}
|
||||
|
||||
void adm9240_vid(struct i2c_client *client, int operation, int ctl_name,
|
||||
int *nrels_mag, long *results)
|
||||
{
|
||||
struct adm9240_data *data = client->data;
|
||||
|
||||
if (operation == SENSORS_PROC_REAL_INFO)
|
||||
*nrels_mag = 2;
|
||||
else if (operation == SENSORS_PROC_REAL_READ) {
|
||||
adm9240_update_client(client);
|
||||
results[0] = VID_FROM_REG(data->vid);
|
||||
*nrels_mag = 1;
|
||||
}
|
||||
}
|
||||
|
||||
int adm9240_init(void)
|
||||
{
|
||||
int res;
|
||||
|
||||
@@ -231,6 +231,7 @@ struct sensors_chips_data {
|
||||
#define ADM9240_SYSCTL_FAN_DIV 2000 /* 1, 2, 4 or 8 */
|
||||
#define ADM9240_SYSCTL_ALARMS 2001 /* bitvector */
|
||||
#define ADM9240_SYSCTL_ANALOG_OUT 2002
|
||||
#define ADM9240_SYSCTL_VID 2003
|
||||
|
||||
#define LTC1710_SYSCTL_SWITCH_1 1000
|
||||
#define LTC1710_SYSCTL_SWITCH_2 1001
|
||||
|
||||
+112
@@ -295,6 +295,31 @@ static sensors_chip_feature lm75_features[] =
|
||||
{ 0 }
|
||||
};
|
||||
|
||||
|
||||
static sensors_chip_feature adm1021_features[] =
|
||||
{
|
||||
{ SENSORS_ADM1021_TEMP, "temp", SENSORS_NO_MAPPING, SENSORS_NO_MAPPING,
|
||||
SENSORS_MODE_R, ADM1021_SYSCTL_TEMP, VALUE(3), 0 },
|
||||
{ SENSORS_ADM1021_TEMP_HYST, "temp_low", SENSORS_ADM1021_TEMP,
|
||||
SENSORS_ADM1021_TEMP, SENSORS_MODE_RW,
|
||||
ADM1021_SYSCTL_TEMP, VALUE(2), 0 },
|
||||
{ SENSORS_ADM1021_TEMP_OVER, "temp_over", SENSORS_ADM1021_TEMP,
|
||||
SENSORS_ADM1021_TEMP, SENSORS_MODE_RW,
|
||||
ADM1021_SYSCTL_TEMP, VALUE(1), 0 },
|
||||
{ SENSORS_ADM1021_REMOTE_TEMP, "remote_temp", SENSORS_NO_MAPPING, SENSORS_NO_MAPPING,
|
||||
SENSORS_MODE_R, ADM1021_SYSCTL_REMOTE_TEMP, VALUE(3), 0 },
|
||||
{ SENSORS_ADM1021_REMOTE_TEMP_HYST, "remote_temp_low", SENSORS_ADM1021_REMOTE_TEMP,
|
||||
SENSORS_ADM1021_REMOTE_TEMP, SENSORS_MODE_RW,
|
||||
ADM1021_SYSCTL_REMOTE_TEMP, VALUE(2), 0 },
|
||||
{ SENSORS_ADM1021_REMOTE_TEMP_OVER, "remote_temp_over", SENSORS_ADM1021_REMOTE_TEMP,
|
||||
SENSORS_ADM1021_REMOTE_TEMP, SENSORS_MODE_RW,
|
||||
ADM1021_SYSCTL_REMOTE_TEMP, VALUE(1), 0 },
|
||||
{ SENSORS_ADM1021_STATUS, "status", SENSORS_NO_MAPPING,
|
||||
SENSORS_NO_MAPPING, SENSORS_MODE_R,
|
||||
ADM1021_SYSCTL_STATUS, VALUE(1), 0 },
|
||||
{ 0 }
|
||||
};
|
||||
|
||||
static sensors_chip_feature gl518r00_features[] =
|
||||
{
|
||||
{ SENSORS_GL518R00_VDD, "vdd", SENSORS_NO_MAPPING,SENSORS_NO_MAPPING,
|
||||
@@ -641,6 +666,91 @@ static sensors_chip_feature w83781d_features[] =
|
||||
W83781D_SYSCTL_BEEP, VALUE(2), 0 },
|
||||
{ 0 }
|
||||
};
|
||||
|
||||
static sensors_chip_feature adm9240_features[] =
|
||||
{
|
||||
{ SENSORS_ADM9240_IN0, "2.5V", SENSORS_NO_MAPPING, SENSORS_NO_MAPPING,
|
||||
SENSORS_MODE_R, ADM9240_SYSCTL_IN0, VALUE(3), 2 },
|
||||
{ SENSORS_ADM9240_IN1, "Vccp1", SENSORS_NO_MAPPING, SENSORS_NO_MAPPING,
|
||||
SENSORS_MODE_R, ADM9240_SYSCTL_IN1, VALUE(3), 2 },
|
||||
{ SENSORS_ADM9240_IN2, "3.3V", SENSORS_NO_MAPPING, SENSORS_NO_MAPPING,
|
||||
SENSORS_MODE_R, ADM9240_SYSCTL_IN2, VALUE(3), 2 },
|
||||
{ SENSORS_ADM9240_IN3, "5V", SENSORS_NO_MAPPING, SENSORS_NO_MAPPING,
|
||||
SENSORS_MODE_R, ADM9240_SYSCTL_IN3, VALUE(3), 2 },
|
||||
{ SENSORS_ADM9240_IN4, "12V", SENSORS_NO_MAPPING, SENSORS_NO_MAPPING,
|
||||
SENSORS_MODE_R, ADM9240_SYSCTL_IN4, VALUE(3), 2 },
|
||||
{ SENSORS_ADM9240_IN5, "Vccp2", SENSORS_NO_MAPPING, SENSORS_NO_MAPPING,
|
||||
SENSORS_MODE_R, ADM9240_SYSCTL_IN5, VALUE(3), 2 },
|
||||
{ SENSORS_ADM9240_IN0_MIN, "2.5V_min", SENSORS_ADM9240_IN0,
|
||||
SENSORS_ADM9240_IN0, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_IN0, VALUE(1), 2 },
|
||||
{ SENSORS_ADM9240_IN1_MIN, "Vccp1_min", SENSORS_ADM9240_IN1,
|
||||
SENSORS_ADM9240_IN1, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_IN1, VALUE(1), 2 },
|
||||
{ SENSORS_ADM9240_IN2_MIN, "3.3V_min", SENSORS_ADM9240_IN2,
|
||||
SENSORS_ADM9240_IN2, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_IN2, VALUE(1), 2 },
|
||||
{ SENSORS_ADM9240_IN3_MIN, "5V_min", SENSORS_ADM9240_IN3,
|
||||
SENSORS_ADM9240_IN3, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_IN3, VALUE(1), 2 },
|
||||
{ SENSORS_ADM9240_IN4_MIN, "12V_min", SENSORS_ADM9240_IN4,
|
||||
SENSORS_ADM9240_IN4, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_IN4, VALUE(1), 2 },
|
||||
{ SENSORS_ADM9240_IN5_MIN, "Vccp2_min", SENSORS_ADM9240_IN5,
|
||||
SENSORS_ADM9240_IN5, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_IN5, VALUE(1), 2 },
|
||||
{ SENSORS_ADM9240_IN0_MAX, "2.5V_max", SENSORS_ADM9240_IN0,
|
||||
SENSORS_ADM9240_IN0, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_IN0, VALUE(2), 2 },
|
||||
{ SENSORS_ADM9240_IN1_MAX, "Vccp1_max", SENSORS_ADM9240_IN1,
|
||||
SENSORS_ADM9240_IN1, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_IN1, VALUE(2), 2 },
|
||||
{ SENSORS_ADM9240_IN2_MAX, "3.3V_max", SENSORS_ADM9240_IN2,
|
||||
SENSORS_ADM9240_IN2, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_IN2, VALUE(2), 2 },
|
||||
{ SENSORS_ADM9240_IN3_MAX, "5V_max", SENSORS_ADM9240_IN3,
|
||||
SENSORS_ADM9240_IN3, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_IN3, VALUE(2), 2 },
|
||||
{ SENSORS_ADM9240_IN4_MAX, "12V_max", SENSORS_ADM9240_IN4,
|
||||
SENSORS_ADM9240_IN4, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_IN4, VALUE(2), 2 },
|
||||
{ SENSORS_ADM9240_IN5_MAX, "Vccp2_max", SENSORS_ADM9240_IN5,
|
||||
SENSORS_ADM9240_IN5, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_IN5, VALUE(2), 2 },
|
||||
{ SENSORS_ADM9240_FAN1, "fan1", SENSORS_NO_MAPPING, SENSORS_NO_MAPPING,
|
||||
SENSORS_MODE_R, ADM9240_SYSCTL_FAN1, VALUE(2), 0 },
|
||||
{ SENSORS_ADM9240_FAN2, "fan2", SENSORS_NO_MAPPING, SENSORS_NO_MAPPING,
|
||||
SENSORS_MODE_R, ADM9240_SYSCTL_FAN2, VALUE(2), 0 },
|
||||
{ SENSORS_ADM9240_FAN1_MIN, "fan1_min", SENSORS_ADM9240_FAN1,
|
||||
SENSORS_NO_MAPPING, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_FAN1, VALUE(1), 0 },
|
||||
{ SENSORS_ADM9240_FAN2_MIN, "fan2_min", SENSORS_ADM9240_FAN2,
|
||||
SENSORS_NO_MAPPING, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_FAN2, VALUE(1), 0 },
|
||||
{ SENSORS_ADM9240_TEMP, "temp", SENSORS_NO_MAPPING, SENSORS_NO_MAPPING,
|
||||
SENSORS_MODE_R, ADM9240_SYSCTL_TEMP, VALUE(3), 1 },
|
||||
{ SENSORS_ADM9240_TEMP_HYST, "temp_hyst", SENSORS_ADM9240_TEMP,
|
||||
SENSORS_ADM9240_TEMP, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_TEMP, VALUE(2), 1 },
|
||||
{ SENSORS_ADM9240_TEMP_OVER, "temp_over", SENSORS_ADM9240_TEMP,
|
||||
SENSORS_ADM9240_TEMP, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_TEMP, VALUE(1), 1 },
|
||||
|
||||
{ SENSORS_ADM9240_VID, "vid", SENSORS_NO_MAPPING, SENSORS_NO_MAPPING,
|
||||
SENSORS_MODE_R, ADM9240_SYSCTL_VID, VALUE(1), 2 },
|
||||
{ SENSORS_ADM9240_FAN1_DIV, "fan1_div", SENSORS_ADM9240_FAN1,
|
||||
SENSORS_NO_MAPPING, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_FAN_DIV, VALUE(1), 0 },
|
||||
{ SENSORS_ADM9240_FAN2_DIV, "fan2_div", SENSORS_ADM9240_FAN2,
|
||||
SENSORS_NO_MAPPING, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_FAN_DIV, VALUE(2), 0 },
|
||||
{ SENSORS_ADM9240_ALARMS, "alarms", SENSORS_NO_MAPPING, SENSORS_NO_MAPPING,
|
||||
SENSORS_MODE_R, ADM9240_SYSCTL_ALARMS, VALUE(1), 0 },
|
||||
{ SENSORS_ADM9240_ANALOG_OUT, "analog_out", SENSORS_NO_MAPPING,
|
||||
SENSORS_NO_MAPPING, SENSORS_MODE_RW,
|
||||
ADM9240_SYSCTL_ANALOG_OUT, VALUE(1), 0 },
|
||||
{ 0 }
|
||||
};
|
||||
|
||||
sensors_chip_features sensors_chip_features_list[] =
|
||||
{
|
||||
@@ -652,6 +762,8 @@ sensors_chip_features sensors_chip_features_list[] =
|
||||
{ SENSORS_GL518R80_PREFIX, gl518r80_features },
|
||||
{ SENSORS_LM80_PREFIX, lm80_features },
|
||||
{ SENSORS_W83781D_PREFIX, w83781d_features },
|
||||
{ SENSORS_ADM9240_PREFIX, adm9240_features },
|
||||
{ SENSORS_ADM1021_PREFIX, adm1021_features },
|
||||
{ 0 }
|
||||
};
|
||||
|
||||
+48
@@ -166,6 +166,17 @@
|
||||
#define SENSORS_LM75_TEMP_HYST 52 /* RW */
|
||||
#define SENSORS_LM75_TEMP_OVER 53 /* RW */
|
||||
|
||||
/* ADM1021 chips. */
|
||||
|
||||
#define SENSORS_ADM1021_PREFIX "adm1021"
|
||||
|
||||
#define SENSORS_ADM1021_TEMP 51 /* R */
|
||||
#define SENSORS_ADM1021_TEMP_HYST 52 /* RW */
|
||||
#define SENSORS_ADM1021_TEMP_OVER 53 /* RW */
|
||||
#define SENSORS_ADM1021_REMOTE_TEMP 54 /* R */
|
||||
#define SENSORS_ADM1021_REMOTE_TEMP_HYST 55 /* RW */
|
||||
#define SENSORS_ADM1021_REMOTE_TEMP_OVER 56 /* RW */
|
||||
#define SENSORS_ADM1021_STATUS 81 /* R */
|
||||
|
||||
/* GL518SM revision 0x00 chips. You may also use the revision 0x80 defines,
|
||||
but note that some features are unaccessible in revision 0x00. */
|
||||
@@ -318,4 +329,41 @@
|
||||
#define SENSORS_W83781D_BEEP_ENABLE 82 /* RW */
|
||||
#define SENSORS_W83781D_BEEPS 83 /* RW */
|
||||
|
||||
|
||||
/* Analog Devices ADM9240 chips */
|
||||
|
||||
#define SENSORS_ADM9240_PREFIX "adm9240"
|
||||
|
||||
#define SENSORS_ADM9240_IN0 1 /* R */
|
||||
#define SENSORS_ADM9240_IN1 2 /* R */
|
||||
#define SENSORS_ADM9240_IN2 3 /* R */
|
||||
#define SENSORS_ADM9240_IN3 4 /* R */
|
||||
#define SENSORS_ADM9240_IN4 5 /* R */
|
||||
#define SENSORS_ADM9240_IN5 6 /* R */
|
||||
#define SENSORS_ADM9240_IN0_MIN 11 /* RW */
|
||||
#define SENSORS_ADM9240_IN1_MIN 12 /* RW */
|
||||
#define SENSORS_ADM9240_IN2_MIN 13 /* RW */
|
||||
#define SENSORS_ADM9240_IN3_MIN 14 /* RW */
|
||||
#define SENSORS_ADM9240_IN4_MIN 15 /* RW */
|
||||
#define SENSORS_ADM9240_IN5_MIN 16 /* RW */
|
||||
#define SENSORS_ADM9240_IN0_MAX 21 /* RW */
|
||||
#define SENSORS_ADM9240_IN1_MAX 22 /* RW */
|
||||
#define SENSORS_ADM9240_IN2_MAX 23 /* RW */
|
||||
#define SENSORS_ADM9240_IN3_MAX 24 /* RW */
|
||||
#define SENSORS_ADM9240_IN4_MAX 25 /* RW */
|
||||
#define SENSORS_ADM9240_IN5_MAX 26 /* RW */
|
||||
#define SENSORS_ADM9240_FAN1 31 /* R */
|
||||
#define SENSORS_ADM9240_FAN2 32 /* R */
|
||||
#define SENSORS_ADM9240_FAN1_MIN 41 /* RW */
|
||||
#define SENSORS_ADM9240_FAN2_MIN 42 /* RW */
|
||||
#define SENSORS_ADM9240_TEMP 51 /* R */
|
||||
#define SENSORS_ADM9240_TEMP_HYST 52 /* RW */
|
||||
#define SENSORS_ADM9240_TEMP_OVER 53 /* RW */
|
||||
#define SENSORS_ADM9240_VID 61 /* R */
|
||||
#define SENSORS_ADM9240_FAN1_DIV 71 /* RW */
|
||||
#define SENSORS_ADM9240_FAN2_DIV 72 /* RW */
|
||||
#define SENSORS_ADM9240_ALARMS 81 /* R */
|
||||
#define SENSORS_ADM9240_ANALOG_OUT 82 /* RW */
|
||||
|
||||
|
||||
#endif /* def LIB_SENSORS_CHIPS_H */
|
||||
+26
-1
@@ -132,6 +132,9 @@
|
||||
#define DIV_FROM_REG(val) (1 << val)
|
||||
#define DIV_TO_REG(val) (val==1?0:(val==2?1:(val==4?2:3)))
|
||||
|
||||
#define VID_FROM_REG(val) ((val)==0x1f?0:(val)>=0x10?510-(val)*10:\
|
||||
(val)>=0x06?0:205-(val)*5)
|
||||
|
||||
/* Initial limits */
|
||||
#define ADM9240_INIT_IN_0 190
|
||||
#define ADM9240_INIT_IN_1 190
|
||||
@@ -201,7 +204,8 @@ struct adm9240_data {
|
||||
u8 temp_os_max; /* Register value */
|
||||
u8 temp_os_hyst; /* Register value */
|
||||
u16 alarms; /* Register encoding, combined */
|
||||
u8 analog_out; /* Register value */
|
||||
u8 analog_out; /* Register value */
|
||||
u8 vid; /* Register value combined */
|
||||
};
|
||||
|
||||
|
||||
@@ -238,6 +242,8 @@ static void adm9240_fan_div(struct i2c_client *client, int operation, int ctl_na
|
||||
int *nrels_mag, long *results);
|
||||
static void adm9240_analog_out(struct i2c_client *client, int operation, int ctl_name,
|
||||
int *nrels_mag, long *results);
|
||||
static void adm9240_vid(struct i2c_client *client, int operation, int ctl_name,
|
||||
int *nrels_mag, long *results);
|
||||
|
||||
/* I choose here for semi-static ADM9240 allocation. Complete dynamic
|
||||
allocation could also be used; the code needed for this would probably
|
||||
@@ -292,6 +298,8 @@ static ctl_table adm9240_dir_table_template[] = {
|
||||
&sensors_sysctl_real, NULL, &adm9240_alarms },
|
||||
{ ADM9240_SYSCTL_ANALOG_OUT, "analog_out", NULL, 0, 0644, NULL, &sensors_proc_real,
|
||||
&sensors_sysctl_real, NULL, &adm9240_analog_out },
|
||||
{ ADM9240_SYSCTL_VID, "vid", NULL, 0, 0644, NULL, &sensors_proc_real,
|
||||
&sensors_sysctl_real, NULL, &adm9240_vid },
|
||||
{ 0 }
|
||||
};
|
||||
|
||||
@@ -523,6 +531,9 @@ void adm9240_update_client(struct i2c_client *client)
|
||||
i = adm9240_read_value(client,ADM9240_REG_VID_FAN_DIV);
|
||||
data->fan_div[0] = (i >> 4) & 0x03;
|
||||
data->fan_div[1] = (i >> 6) & 0x03;
|
||||
data->vid = i & 0x0f;
|
||||
data->vid |= (adm9240_read_value(client,ADM9240_REG_VID4) & 0x01) << 4;
|
||||
|
||||
data->alarms = adm9240_read_value(client,ADM9240_REG_INT1_STAT) +
|
||||
(adm9240_read_value(client,ADM9240_REG_INT2_STAT) << 8);
|
||||
data->analog_out = adm9240_read_value(client,ADM9240_REG_ANALOG_OUT);
|
||||
@@ -682,6 +693,20 @@ void adm9240_analog_out(struct i2c_client *client, int operation, int ctl_name,
|
||||
}
|
||||
}
|
||||
|
||||
void adm9240_vid(struct i2c_client *client, int operation, int ctl_name,
|
||||
int *nrels_mag, long *results)
|
||||
{
|
||||
struct adm9240_data *data = client->data;
|
||||
|
||||
if (operation == SENSORS_PROC_REAL_INFO)
|
||||
*nrels_mag = 2;
|
||||
else if (operation == SENSORS_PROC_REAL_READ) {
|
||||
adm9240_update_client(client);
|
||||
results[0] = VID_FROM_REG(data->vid);
|
||||
*nrels_mag = 1;
|
||||
}
|
||||
}
|
||||
|
||||
int adm9240_init(void)
|
||||
{
|
||||
int res;
|
||||
|
||||
@@ -231,6 +231,7 @@ struct sensors_chips_data {
|
||||
#define ADM9240_SYSCTL_FAN_DIV 2000 /* 1, 2, 4 or 8 */
|
||||
#define ADM9240_SYSCTL_ALARMS 2001 /* bitvector */
|
||||
#define ADM9240_SYSCTL_ANALOG_OUT 2002
|
||||
#define ADM9240_SYSCTL_VID 2003
|
||||
|
||||
#define LTC1710_SYSCTL_SWITCH_1 1000
|
||||
#define LTC1710_SYSCTL_SWITCH_2 1001
|
||||
|
||||
Reference in new issue
Block a user