Re: [PATCH] Driver Core patches for 2.6.7

From: Greg KH
Date: Tue Jun 22 2004 - 13:02:58 EST


ChangeSet 1.1722.111.27, 2004/06/14 10:50:59-07:00, mhoffman@xxxxxxxxxxxxx

[PATCH] I2C: add alternate VCORE calculations for w83627thf and w83637hf

Pick a VRM (for VID interpretation) based on the VRM & OVT config,
if available. Props to Jean Delvare <khali@xxxxxxxxxxxx> for the
idea & code fragment.

Signed-off-by: Greg Kroah-Hartman <greg@xxxxxxxxx>


drivers/i2c/chips/w83627hf.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)


diff -Nru a/drivers/i2c/chips/w83627hf.c b/drivers/i2c/chips/w83627hf.c
--- a/drivers/i2c/chips/w83627hf.c Tue Jun 22 09:46:43 2004
+++ b/drivers/i2c/chips/w83627hf.c Tue Jun 22 09:46:43 2004
@@ -1275,12 +1275,15 @@
}

/* Read VRM & OVT Config only once */
- if (w83627thf == data->type || w83637hf == data->type)
+ if (w83627thf == data->type || w83637hf == data->type) {
data->vrm_ovt =
w83627hf_read_value(client, W83627THF_REG_VRM_OVT_CFG);
+ data->vrm = (data->vrm_ovt & 0x01) ? 90 : 82;
+ } else {
+ /* Convert VID to voltage based on default VRM */
+ data->vrm = DEFAULT_VRM;
+ }

- /* Convert VID to voltage based on default VRM */
- data->vrm = DEFAULT_VRM;
if (type != w83697hf)
vid = vid_from_reg(vid, data->vrm);


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/