pinctrl: mediatek: mtk-common: initialize unmask
authorColin Ian King <colin.king@canonical.com>
Mon, 20 Apr 2015 15:59:17 +0000 (10:59 -0500)
committerLinus Walleij <linus.walleij@linaro.org>
Mon, 4 May 2015 13:20:22 +0000 (15:20 +0200)
commit74d77e50f23123938fbb7987eba71310864e6a7c
treee6fedf5ff64a30738f5b6daf008ec2bf451e29ef
parent4e637ac212b63f4b5dd1da626aca34ffcbfd5daa
pinctrl: mediatek: mtk-common: initialize unmask

cppcheck detected an uninitialized variable:

[drivers/pinctrl/mediatek/pinctrl-mtk-common.c:897]:
  (error) Uninitialized variable: unmask

unmask should be initialized to zero to ensure unmasking
only occurs if a previous mask occurred. The current situation
is that the unmask variable could contain any random garbage
causing random unexpected unmasking.

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/pinctrl/mediatek/pinctrl-mtk-common.c