mfd: WM835x GPIO direction register is not locked
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Thu, 7 Jan 2010 16:16:14 +0000 (16:16 +0000)
committerSamuel Ortiz <sameo@linux.intel.com>
Mon, 18 Jan 2010 11:30:28 +0000 (12:30 +0100)
No need to set the security key when writing to it.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
drivers/mfd/wm8350-core.c

index 8485a70..9a970bd 100644 (file)
@@ -134,8 +134,7 @@ static inline int is_reg_locked(struct wm8350 *wm8350, u8 reg)
            wm8350->reg_cache[WM8350_SECURITY] == WM8350_UNLOCK_KEY)
                return 0;
 
-       if ((reg == WM8350_GPIO_CONFIGURATION_I_O) ||
-           (reg >= WM8350_GPIO_FUNCTION_SELECT_1 &&
+       if ((reg >= WM8350_GPIO_FUNCTION_SELECT_1 &&
             reg <= WM8350_GPIO_FUNCTION_SELECT_4) ||
            (reg >= WM8350_BATTERY_CHARGER_CONTROL_1 &&
             reg <= WM8350_BATTERY_CHARGER_CONTROL_3))