gpio: Fix range check in of_gpio_simple_xlate()
of_gpio_simple_xlate() has an off-by-one bug where it checks to see if args[0] is > ngpio instead of >=. args[0] must always be less than ngpio because it is a zero-based enumeration. Signed-off-by: NRoland Stigge <stigge@antcom.de> [grant.likely: beef up commit text] Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
Showing
想要评论请 注册 或 登录