From 9b95794b50f5b848c1c263b2c43e07278522db4c Mon Sep 17 00:00:00 2001 From: Dan Eaton Date: Thu, 19 Oct 2000 17:24:00 +0000 Subject: [PATCH] (dan) Corrected inadvertent overwrite of part of cached data value. git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@912 7894878c-1315-0410-8ee3-d5d059ff63e0 --- kernel/chips/pcf8574.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/kernel/chips/pcf8574.c b/kernel/chips/pcf8574.c index 3de01668..355cabbd 100644 --- a/kernel/chips/pcf8574.c +++ b/kernel/chips/pcf8574.c @@ -313,9 +313,10 @@ void pcf8574_status(struct i2c_client *client, int operation, pcf8574_update_client(client); tmpstatus = data->status; tmpstatus = (tmpstatus & 0xf0) >> 4; - data->status &= 0x0f; results[0] = tmpstatus; - results[1] = data->status; + tmpstatus = data->status; + tmpstatus &= 0x0f; + results[1] = tmpstatus; *nrels_mag = 2; } else if (operation == SENSORS_PROC_REAL_WRITE) { if (*nrels_mag >= 1) {