mfd: Handle tps65910 clear-mask correctly
authorMarcus Folkesson <marcus.folkesson@gmail.com>
Tue, 22 Nov 2011 13:39:51 +0000 (14:39 +0100)
committerSamuel Ortiz <sameo@linux.intel.com>
Tue, 20 Dec 2011 17:53:25 +0000 (18:53 +0100)
The function is not actually cleaing the bitmask.

Signed-off-by: Marcus Folkesson <marcus.folkesson@gmail.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
drivers/mfd/tps65910.c

index 6f5b8cf2f652b8edf6accf9db107d8f63ea72c23..c1da84bc1573f563c4b698f0bc786068e7f911bc 100644 (file)
@@ -120,7 +120,7 @@ int tps65910_clear_bits(struct tps65910 *tps65910, u8 reg, u8 mask)
                goto out;
        }
 
-       data &= mask;
+       data &= ~mask;
        err = tps65910_i2c_write(tps65910, reg, 1, &data);
        if (err)
                dev_err(tps65910->dev, "write to reg %x failed\n", reg);