From: Stephen Boyd Date: Mon, 19 Jan 2015 10:17:45 +0000 (+0100) Subject: pinctrl: qcom: Don't iterate past end of function array X-Git-Tag: omap-for-v4.1/prcm-dts-mfd-syscon-fix~254^2~1 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bcd53f858d87f52843cc87764b283999126a50d6;p=pandora-kernel.git pinctrl: qcom: Don't iterate past end of function array Timur reports that this code crashes if nfunctions is 0. Fix the loop iteration to only consider valid elements of the functions array. Reported-by: Timur Tabi Cc: Pramod Gurav Cc: Bjorn Andersson Cc: Ivan T. Ivanov Cc: Andy Gross Fixes: 327455817a92 "pinctrl: qcom: Add support for reset for apq8064" Signed-off-by: Stephen Boyd Signed-off-by: Linus Walleij --- Reading git-diff-tree failed