diff mbox

mfd: pm8921: fixup probe() error path when irq invalid

Message ID 1394048065-14200-1-git-send-email-joshc@codeaurora.org (mailing list archive)
State Accepted, archived
Headers show

Commit Message

Josh Cartwright March 5, 2014, 7:34 p.m. UTC
platform_get_irq() returns a negative error code when an IRQ is invalid
or unspecified.  Make 'irq' signed to properly handle this.

Cc: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: Josh Cartwright <joshc@codeaurora.org>
---
 drivers/mfd/pm8921-core.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

Comments

Stephen Boyd March 5, 2014, 7:46 p.m. UTC | #1
On 03/05/14 11:34, Josh Cartwright wrote:
> platform_get_irq() returns a negative error code when an IRQ is invalid
> or unspecified.  Make 'irq' signed to properly handle this.
>

Reviewed-by: Stephen Boyd <sboyd@codeaurora.org>

Thanks
Lee Jones March 6, 2014, 9:20 a.m. UTC | #2
> platform_get_irq() returns a negative error code when an IRQ is invalid
> or unspecified.  Make 'irq' signed to properly handle this.
> 
> Cc: Stephen Boyd <sboyd@codeaurora.org>
> Signed-off-by: Josh Cartwright <joshc@codeaurora.org>
> ---
>  drivers/mfd/pm8921-core.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)

Applied thanks.
diff mbox

Patch

diff --git a/drivers/mfd/pm8921-core.c b/drivers/mfd/pm8921-core.c
index 3aab6ac..d48452d 100644
--- a/drivers/mfd/pm8921-core.c
+++ b/drivers/mfd/pm8921-core.c
@@ -403,9 +403,8 @@  static int pm8921_probe(struct platform_device *pdev)
 {
 	struct pm8921 *pmic;
 	struct regmap *regmap;
-	int rc;
+	int irq, rc;
 	unsigned int val;
-	unsigned int irq;
 	u32 rev;
 	struct pm_irq_chip *chip;
 	unsigned int nirqs = PM8921_NR_IRQS;