[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <201307060059.06053.heiko@sntech.de>
Date: Sat, 6 Jul 2013 00:59:05 +0200
From: Heiko Stübner <heiko@...ech.de>
To: John Stultz <john.stultz@...aro.org>
Cc: Thomas Gleixner <tglx@...utronix.de>,
Jamie Iles <jamie@...ieiles.com>,
Dinh Nguyen <dinguyen@...era.com>,
Grant Likely <grant.likely@...aro.org>,
linux-arm-kernel@...ts.infradead.org,
Rob Herring <rob.herring@...xeda.com>,
devicetree-discuss@...ts.ozlabs.org, linux-kernel@...r.kernel.org,
Arnd Bergmann <arnd@...db.de>, Olof Johansson <olof@...om.net>,
Ulrich Prinz <ulrich.prinz@...glemail.com>
Subject: Re: [PATCH 4/9] clocksource: dw_apb_timer: use the eoi callback to clear pending interrupts
this patch should have had a
From: Ulrich Prinz <ulrich.prinz@...glemail.com>
sorry for the mistake
Am Samstag, 6. Juli 2013, 00:53:36 schrieb Heiko Stübner:
> Some timer variants have different mechanisms to clear a pending timer
> interrupt. Therefore don't hardcode the reading of the eoi register to
> clear them, but instead use the already existing eoi callback for this.
>
> Signed-off-by: Ulrich Prinz <ulrich.prinz@...glemail.com>
> ---
> drivers/clocksource/dw_apb_timer.c | 11 +++++++----
> 1 file changed, 7 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/clocksource/dw_apb_timer.c
> b/drivers/clocksource/dw_apb_timer.c index bd45351..5f80a30 100644
> --- a/drivers/clocksource/dw_apb_timer.c
> +++ b/drivers/clocksource/dw_apb_timer.c
> @@ -121,11 +121,14 @@ static irqreturn_t dw_apb_clockevent_irq(int irq,
> void *data) return IRQ_HANDLED;
> }
>
> -static void apbt_enable_int(struct dw_apb_timer *timer)
> +static void apbt_enable_int(struct dw_apb_clock_event_device *dw_ced)
> {
> + struct dw_apb_timer *timer = &dw_ced->timer;
> unsigned long ctrl = apbt_readl(timer, timer->reg_control);
> +
> /* clear pending intr */
> - apbt_readl(timer, timer->reg_eoi);
> + if (dw_ced->eoi)
> + dw_ced->eoi(timer);
> ctrl &= ~APBTMR_CONTROL_INT;
> apbt_writel(timer, ctrl, timer->reg_control);
> }
> @@ -200,7 +203,7 @@ static void apbt_set_mode(enum clock_event_mode mode,
> break;
>
> case CLOCK_EVT_MODE_RESUME:
> - apbt_enable_int(timer);
> + apbt_enable_int(dw_ced);
> break;
> }
> }
> @@ -325,7 +328,7 @@ void dw_apb_clockevent_register(struct
> dw_apb_clock_event_device *dw_ced)
>
> apbt_writel(timer, 0, timer->reg_control);
> clockevents_register_device(&dw_ced->ced);
> - apbt_enable_int(timer);
> + apbt_enable_int(dw_ced);
> }
>
> /**
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists