# \[PATCH v3 4/4\] pinctrl: qcom: Add support for reset for apq8064

- From: Linus Walleij \<hidden\>
- Date: 2015-01-19 10:18:33 
- List: linux-arm-kernel
- Page: https://ratatoskr.run/linux-arm-kernel/2015/01/4412508
- Thread: https://ratatoskr.run/linux-arm-msm/2014/08/4323435/t.md

```text
On Thu, Jan 15, 2015 at 1:23 AM, Stephen Boyd [ref] wrote:
> On 01/14/2015 03:54 PM, Timur Tabi wrote:
>> On Wed, Jan 14, 2015 at 5:44 PM, Stephen Boyd [ref] wrote:
>>> I think so. Can you send a patch? Plus it would be nice to move i = 0 in
>>> the for loop at the same time.
>> Sadly, Qualcomm policy makes that very cumbersome for me.  I won't be
>> able to send a patch any time soon.
>>
>
> Hm... we'll have to figure out that part. Anyway here's the patch.
>
> ---8<----
> From: Stephen Boyd <redacted>
> Subject: [PATCH] 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 <redacted>
> Cc: Pramod Gurav <redacted>
> Cc: Bjorn Andersson <redacted>
> Cc: Ivan T. Ivanov <redacted>
> Cc: Andy Gross <redacted>
> Fixes: 327455817a92 "pinctrl: qcom: Add support for reset for apq8064"
> Signed-off-by: Stephen Boyd <redacted>

This patch applied for fixes.

Yours,
Linus Walleij
```
