]> git.baikalelectronics.ru Git - kernel.git/commit
mfd: fix undefined twl4030-power resconfig value checks
authorAaro Koskinen <aaro.koskinen@nokia.com>
Mon, 19 Oct 2009 19:24:02 +0000 (21:24 +0200)
committerSamuel Ortiz <sameo@linux.intel.com>
Sun, 13 Dec 2009 18:21:25 +0000 (19:21 +0100)
commit3151a4519b356a655edf6ef204e0fb0f1d58b593
treecacc84313e48bb592adb76fe6f28e790e5ab942c
parent5201b67ea2bd1f56f4108d31354c59b53279a904
mfd: fix undefined twl4030-power resconfig value checks

The code tries to skip values initialized with -1, but since the values
are unsigned the comparison is always true.

The patch eliminates the following compiler warnings:

drivers/mfd/twl4030-power.c: In function 'twl4030_configure_resource':
drivers/mfd/twl4030-power.c:338: warning: comparison is always true due to
limited range of data type
drivers/mfd/twl4030-power.c:358: warning: comparison is always true due to
limited range of data type
drivers/mfd/twl4030-power.c:363: warning: comparison is always true due to
limited range of data type

Signed-off-by: Aaro Koskinen <aaro.koskinen@nokia.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
drivers/mfd/twl4030-power.c
include/linux/i2c/twl4030.h