Re: [PATCH 3/4] onkey: 88pm80x: update irq base
On 12/03/2012 01:42 PM, Qing Xu wrote: From: Qing Xu irq base is stored in 88pm80x's drv data, we need to add irq base to get the correct irq num Signed-off-by: Qiao Zhou Signed-off-by: Qing Xu --- drivers/input/misc/88pm80x_onkey.c |7 --- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/input/misc/88pm80x_onkey.c b/drivers/input/misc/88pm80x_onkey.c index 7f26e7b..cc352f9 100644 --- a/drivers/input/misc/88pm80x_onkey.c +++ b/drivers/input/misc/88pm80x_onkey.c @@ -67,7 +67,7 @@ static int __devinit pm80x_onkey_probe(struct platform_device *pdev) struct pm80x_chip *chip = dev_get_drvdata(pdev->dev.parent); struct pm80x_onkey_info *info; - int err; + int irq, err; info = kzalloc(sizeof(struct pm80x_onkey_info), GFP_KERNEL); if (!info) @@ -75,13 +75,14 @@ static int __devinit pm80x_onkey_probe(struct platform_device *pdev) info->pm80x = chip; - info->irq = platform_get_irq(pdev, 0); - if (info->irq < 0) { + irq = platform_get_irq(pdev, 0); + if (irq < 0) { dev_err(>dev, "No IRQ resource!\n"); err = -EINVAL; goto out; } + info->irq = irq + chip->irq_base; info->map = info->pm80x->regmap; if (!info->map) { dev_err(>dev, "no regmap!\n"); Samuel, Could you help to review my patch? Thanks a lot! Qing -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH 3/4] onkey: 88pm80x: update irq base
On 12/03/2012 01:42 PM, Qing Xu wrote: From: Qing Xu qi...@marvell.com irq base is stored in 88pm80x's drv data, we need to add irq base to get the correct irq num Signed-off-by: Qiao Zhou zhouq...@marvell.com Signed-off-by: Qing Xu qi...@marvell.com --- drivers/input/misc/88pm80x_onkey.c |7 --- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/input/misc/88pm80x_onkey.c b/drivers/input/misc/88pm80x_onkey.c index 7f26e7b..cc352f9 100644 --- a/drivers/input/misc/88pm80x_onkey.c +++ b/drivers/input/misc/88pm80x_onkey.c @@ -67,7 +67,7 @@ static int __devinit pm80x_onkey_probe(struct platform_device *pdev) struct pm80x_chip *chip = dev_get_drvdata(pdev-dev.parent); struct pm80x_onkey_info *info; - int err; + int irq, err; info = kzalloc(sizeof(struct pm80x_onkey_info), GFP_KERNEL); if (!info) @@ -75,13 +75,14 @@ static int __devinit pm80x_onkey_probe(struct platform_device *pdev) info-pm80x = chip; - info-irq = platform_get_irq(pdev, 0); - if (info-irq 0) { + irq = platform_get_irq(pdev, 0); + if (irq 0) { dev_err(pdev-dev, No IRQ resource!\n); err = -EINVAL; goto out; } + info-irq = irq + chip-irq_base; info-map = info-pm80x-regmap; if (!info-map) { dev_err(pdev-dev, no regmap!\n); Samuel, Could you help to review my patch? Thanks a lot! Qing -- To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[PATCH 3/4] onkey: 88pm80x: update irq base
From: Qing Xu irq base is stored in 88pm80x's drv data, we need to add irq base to get the correct irq num Signed-off-by: Qiao Zhou Signed-off-by: Qing Xu --- drivers/input/misc/88pm80x_onkey.c |7 --- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/input/misc/88pm80x_onkey.c b/drivers/input/misc/88pm80x_onkey.c index 7f26e7b..cc352f9 100644 --- a/drivers/input/misc/88pm80x_onkey.c +++ b/drivers/input/misc/88pm80x_onkey.c @@ -67,7 +67,7 @@ static int __devinit pm80x_onkey_probe(struct platform_device *pdev) struct pm80x_chip *chip = dev_get_drvdata(pdev->dev.parent); struct pm80x_onkey_info *info; - int err; + int irq, err; info = kzalloc(sizeof(struct pm80x_onkey_info), GFP_KERNEL); if (!info) @@ -75,13 +75,14 @@ static int __devinit pm80x_onkey_probe(struct platform_device *pdev) info->pm80x = chip; - info->irq = platform_get_irq(pdev, 0); - if (info->irq < 0) { + irq = platform_get_irq(pdev, 0); + if (irq < 0) { dev_err(>dev, "No IRQ resource!\n"); err = -EINVAL; goto out; } + info->irq = irq + chip->irq_base; info->map = info->pm80x->regmap; if (!info->map) { dev_err(>dev, "no regmap!\n"); -- 1.7.0.4 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[PATCH 3/4] onkey: 88pm80x: update irq base
From: Qing Xu qi...@marvell.com irq base is stored in 88pm80x's drv data, we need to add irq base to get the correct irq num Signed-off-by: Qiao Zhou zhouq...@marvell.com Signed-off-by: Qing Xu qi...@marvell.com --- drivers/input/misc/88pm80x_onkey.c |7 --- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/input/misc/88pm80x_onkey.c b/drivers/input/misc/88pm80x_onkey.c index 7f26e7b..cc352f9 100644 --- a/drivers/input/misc/88pm80x_onkey.c +++ b/drivers/input/misc/88pm80x_onkey.c @@ -67,7 +67,7 @@ static int __devinit pm80x_onkey_probe(struct platform_device *pdev) struct pm80x_chip *chip = dev_get_drvdata(pdev-dev.parent); struct pm80x_onkey_info *info; - int err; + int irq, err; info = kzalloc(sizeof(struct pm80x_onkey_info), GFP_KERNEL); if (!info) @@ -75,13 +75,14 @@ static int __devinit pm80x_onkey_probe(struct platform_device *pdev) info-pm80x = chip; - info-irq = platform_get_irq(pdev, 0); - if (info-irq 0) { + irq = platform_get_irq(pdev, 0); + if (irq 0) { dev_err(pdev-dev, No IRQ resource!\n); err = -EINVAL; goto out; } + info-irq = irq + chip-irq_base; info-map = info-pm80x-regmap; if (!info-map) { dev_err(pdev-dev, no regmap!\n); -- 1.7.0.4 -- To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/