Input: omap4-keypad - fix handling of platform_get_irq() error
authorKrzysztof Kozlowski <krzk@kernel.org>
Wed, 16 Sep 2020 00:52:15 +0000 (17:52 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 29 Oct 2020 09:08:09 +0000 (10:08 +0100)
commit86f11d554a8c3362d8e47eb4d6bde6e99b92dbe4
tree49be7920fe5e1c0f1ca04290ee7348186f566223
parentd96fc374d241f51777115af043c35f2727163dd2
Input: omap4-keypad - fix handling of platform_get_irq() error

[ Upstream commit 4738dd1992fa13acfbbd71800c71c612f466fa44 ]

platform_get_irq() returns -ERRNO on error.  In such case comparison
to 0 would pass the check.

Fixes: f3a1ba60dbdb ("Input: omap4-keypad - use platform device helpers")
Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
Link: https://lore.kernel.org/r/20200828145744.3636-2-krzk@kernel.org
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/input/keyboard/omap4-keypad.c