Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 2710
b: refs/heads/master
c: 68188ba
h: refs/heads/master
v: v3
  • Loading branch information
Jean Delvare authored and Greg Kroah-Hartman committed Jun 22, 2005
1 parent d11a352 commit 6747596
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 15 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ff3240946d6a3d9f2ecf273f7330e09eec5484eb
refs/heads/master: 68188ba7de2db9999ff08a4544a78b2f10eb08bd
4 changes: 1 addition & 3 deletions trunk/drivers/i2c/chips/asb100.c
Original file line number Diff line number Diff line change
Expand Up @@ -169,8 +169,6 @@ static int ASB100_PWM_FROM_REG(u8 reg)
return reg * 16;
}

#define ALARMS_FROM_REG(val) (val)

#define DIV_FROM_REG(val) (1 << (val))

/* FAN DIV: 1, 2, 4, or 8 (defaults to 2)
Expand Down Expand Up @@ -557,7 +555,7 @@ device_create_file(&client->dev, &dev_attr_vrm);
static ssize_t show_alarms(struct device *dev, struct device_attribute *attr, char *buf)
{
struct asb100_data *data = asb100_update_device(dev);
return sprintf(buf, "%d\n", ALARMS_FROM_REG(data->alarms));
return sprintf(buf, "%u\n", data->alarms);
}

static DEVICE_ATTR(alarms, S_IRUGO, show_alarms, NULL);
Expand Down
4 changes: 1 addition & 3 deletions trunk/drivers/i2c/chips/it87.c
Original file line number Diff line number Diff line change
Expand Up @@ -172,8 +172,6 @@ static inline u8 FAN_TO_REG(long rpm, int div)
((val)+500)/1000),-128,127))
#define TEMP_FROM_REG(val) (((val)>0x80?(val)-0x100:(val))*1000)

#define ALARMS_FROM_REG(val) (val)

#define PWM_TO_REG(val) ((val) >> 1)
#define PWM_FROM_REG(val) (((val)&0x7f) << 1)

Expand Down Expand Up @@ -665,7 +663,7 @@ show_pwm_offset(3);
static ssize_t show_alarms(struct device *dev, struct device_attribute *attr, char *buf)
{
struct it87_data *data = it87_update_device(dev);
return sprintf(buf,"%d\n", ALARMS_FROM_REG(data->alarms));
return sprintf(buf, "%u\n", data->alarms);
}
static DEVICE_ATTR(alarms, S_IRUGO, show_alarms, NULL);

Expand Down
4 changes: 1 addition & 3 deletions trunk/drivers/i2c/chips/lm85.c
Original file line number Diff line number Diff line change
Expand Up @@ -284,8 +284,6 @@ static int ZONE_TO_REG( int zone )
/* i2c-vid.h defines vid_from_reg() */
#define VID_FROM_REG(val,vrm) (vid_from_reg((val),(vrm)))

#define ALARMS_FROM_REG(val) (val)

/* Unlike some other drivers we DO NOT set initial limits. Use
* the config file to set limits. Some users have reported
* motherboards shutting down when we set limits in a previous
Expand Down Expand Up @@ -480,7 +478,7 @@ static DEVICE_ATTR(vrm, S_IRUGO | S_IWUSR, show_vrm_reg, store_vrm_reg);
static ssize_t show_alarms_reg(struct device *dev, struct device_attribute *attr, char *buf)
{
struct lm85_data *data = lm85_update_device(dev);
return sprintf(buf, "%ld\n", (long) ALARMS_FROM_REG(data->alarms));
return sprintf(buf, "%u\n", data->alarms);
}

static DEVICE_ATTR(alarms, S_IRUGO, show_alarms_reg, NULL);
Expand Down
4 changes: 1 addition & 3 deletions trunk/drivers/i2c/chips/via686a.c
Original file line number Diff line number Diff line change
Expand Up @@ -292,8 +292,6 @@ static inline long TEMP_FROM_REG10(u16 val)
tempLUT[eightBits + 1] * twoBits) * 25;
}

#define ALARMS_FROM_REG(val) (val)

#define DIV_FROM_REG(val) (1 << (val))
#define DIV_TO_REG(val) ((val)==8?3:(val)==4?2:(val)==1?0:1)

Expand Down Expand Up @@ -570,7 +568,7 @@ show_fan_offset(2);
/* Alarms */
static ssize_t show_alarms(struct device *dev, struct device_attribute *attr, char *buf) {
struct via686a_data *data = via686a_update_device(dev);
return sprintf(buf,"%d\n", ALARMS_FROM_REG(data->alarms));
return sprintf(buf, "%u\n", data->alarms);
}
static DEVICE_ATTR(alarms, S_IRUGO, show_alarms, NULL);

Expand Down
3 changes: 1 addition & 2 deletions trunk/drivers/i2c/chips/w83781d.c
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,6 @@ FAN_TO_REG(long rpm, int div)
: (val)) / 1000, 0, 0xff))
#define TEMP_FROM_REG(val) (((val) & 0x80 ? (val)-0x100 : (val)) * 1000)

#define ALARMS_FROM_REG(val) (val)
#define PWM_FROM_REG(val) (val)
#define PWM_TO_REG(val) (SENSORS_LIMIT((val),0,255))
#define BEEP_MASK_FROM_REG(val,type) ((type) == as99127f ? \
Expand Down Expand Up @@ -523,7 +522,7 @@ static ssize_t
show_alarms_reg(struct device *dev, struct device_attribute *attr, char *buf)
{
struct w83781d_data *data = w83781d_update_device(dev);
return sprintf(buf, "%ld\n", (long) ALARMS_FROM_REG(data->alarms));
return sprintf(buf, "%u\n", data->alarms);
}

static
Expand Down

0 comments on commit 6747596

Please sign in to comment.