* [PATCH 4/4] rtc: 88pm80x: update irq base
@ 2012-12-03 5:43 Qing Xu
2012-12-12 6:27 ` Qing Xu
0 siblings, 1 reply; 2+ messages in thread
From: Qing Xu @ 2012-12-03 5:43 UTC (permalink / raw)
To: a.zummo, qingx, zhouqiao, sameo, cxie4, linux-kernel, rtc-linux
From: Qing Xu <qingx@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 <zhouqiao@marvell.com>
Signed-off-by: Qing Xu <qingx@marvell.com>
---
drivers/rtc/rtc-88pm80x.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/rtc/rtc-88pm80x.c b/drivers/rtc/rtc-88pm80x.c
index 6367984..7c3a264 100644
--- a/drivers/rtc/rtc-88pm80x.c
+++ b/drivers/rtc/rtc-88pm80x.c
@@ -256,7 +256,7 @@ static int __devinit pm80x_rtc_probe(struct platform_device *pdev)
struct pm80x_rtc_info *info;
struct rtc_time tm;
unsigned long ticks = 0;
- int ret;
+ int irq, ret;
pdata = pdev->dev.platform_data;
if (pdata == NULL)
@@ -266,12 +266,13 @@ static int __devinit pm80x_rtc_probe(struct platform_device *pdev)
devm_kzalloc(&pdev->dev, sizeof(struct pm80x_rtc_info), GFP_KERNEL);
if (!info)
return -ENOMEM;
- 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");
ret = -EINVAL;
goto out;
}
+ info->irq = irq + chip->irq_base;
info->chip = chip;
info->map = chip->regmap;
--
1.7.0.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 4/4] rtc: 88pm80x: update irq base
2012-12-03 5:43 [PATCH 4/4] rtc: 88pm80x: update irq base Qing Xu
@ 2012-12-12 6:27 ` Qing Xu
0 siblings, 0 replies; 2+ messages in thread
From: Qing Xu @ 2012-12-12 6:27 UTC (permalink / raw)
To: Qing Xu
Cc: a.zummo@towertech.it, Qiao Zhou, sameo@linux.intel.com, Chao Xie,
linux-kernel@vger.kernel.org, rtc-linux@googlegroups.com
On 12/03/2012 01:43 PM, Qing Xu wrote:
> From: Qing Xu <qingx@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 <zhouqiao@marvell.com>
> Signed-off-by: Qing Xu <qingx@marvell.com>
> ---
> drivers/rtc/rtc-88pm80x.c | 7 ++++---
> 1 files changed, 4 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/rtc/rtc-88pm80x.c b/drivers/rtc/rtc-88pm80x.c
> index 6367984..7c3a264 100644
> --- a/drivers/rtc/rtc-88pm80x.c
> +++ b/drivers/rtc/rtc-88pm80x.c
> @@ -256,7 +256,7 @@ static int __devinit pm80x_rtc_probe(struct platform_device *pdev)
> struct pm80x_rtc_info *info;
> struct rtc_time tm;
> unsigned long ticks = 0;
> - int ret;
> + int irq, ret;
>
> pdata = pdev->dev.platform_data;
> if (pdata == NULL)
> @@ -266,12 +266,13 @@ static int __devinit pm80x_rtc_probe(struct platform_device *pdev)
> devm_kzalloc(&pdev->dev, sizeof(struct pm80x_rtc_info), GFP_KERNEL);
> if (!info)
> return -ENOMEM;
> - 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");
> ret = -EINVAL;
> goto out;
> }
> + info->irq = irq + chip->irq_base;
>
> info->chip = chip;
> info->map = chip->regmap;
Samuel,
Could you help to review my patch? Thanks a lot!
Qing
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2012-12-12 6:27 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-12-03 5:43 [PATCH 4/4] rtc: 88pm80x: update irq base Qing Xu
2012-12-12 6:27 ` Qing Xu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox