From: John Crispin Date: Mon, 23 Apr 2012 17:01:58 +0000 (+0200) Subject: pinctrl: fix signed vs unsigned conditionals inside pinmux_map_to_setting X-Git-Tag: v3.5-rc1~176^2~21 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=15f70e1b9a1a6351c252cb8892272cc4601818c7;p=pandora-kernel.git pinctrl: fix signed vs unsigned conditionals inside pinmux_map_to_setting pinmux_map_to_setting() uses setting->data.mux.func/group to store the return code of pinmux_func_name_to_selector/pinctrl_get_group_selector(). However, struct pinctrl_setting_mux defines these elements as unsigned, resulting in all error codes getting lost. The conditionals following the assignments will always evaluate to false thus breaking the error paths. This bug can be triggered by loading a pinmux group map from the devicetree with an invalid function/group string. Signed-off-by: John Crispin Acked-by: Stephen Warren Acked-by: Dong Aisheng Signed-off-by: Linus Walleij --- Reading git-diff-tree failed