All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@wwwdotorg.org>
To: Mark Rutland <mark.rutland@arm.com>
Cc: linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org, tglx@linutronix.de,
	nico@linaro.org, Will.Deacon@arm.com, Marc.Zyngier@arm.com,
	john.stultz@linaro.org
Subject: Re: [PATCHv3 4/4] arm: Add generic timer broadcast support
Date: Wed, 06 Feb 2013 13:51:43 -0700	[thread overview]
Message-ID: <5112C25F.6000508@wwwdotorg.org> (raw)
In-Reply-To: <1358183124-28461-5-git-send-email-mark.rutland@arm.com>

On 01/14/2013 10:05 AM, Mark Rutland wrote:
> Implement timer_broadcast for the arm architecture, allowing for the use
> of clock_event_device_drivers decoupled from the timer tick broadcast
> mechanism.

Mark, this patch is now in next-20130206 and causes a crash during boot
on Tegra. The reason appears to be because of:

> diff --git a/arch/arm/kernel/smp.c b/arch/arm/kernel/smp.c

> @@ -524,7 +524,6 @@ static void __cpuinit percpu_timer_setup(void)
>  	struct clock_event_device *evt = &per_cpu(percpu_clockevent, cpu);
>  
>  	evt->cpumask = cpumask_of(cpu);
> -	evt->broadcast = smp_timer_broadcast;

After that change, evt->broadcast is never assigned, and hence is NULL.
Yet elsewhere in kernel/time/tick-broadcast.c it's used unconditionally:

static void tick_do_broadcast(struct cpumask *mask)
...
	if (!cpumask_empty(mask)) {
...
		td = &per_cpu(tick_cpu_device, cpumask_first(mask));
		td->evtdev->broadcast(mask);

Now perhaps the Tegra timer driver simply isn't being set up correctly,
so the bug is there... But the only other place I can find where
->broadcast is assigned is in tick_device_uses_broadcast() which only
does it for "non-functional" timers, which doesn't apply to Tegra's timer.

WARNING: multiple messages have this Message-ID (diff)
From: swarren@wwwdotorg.org (Stephen Warren)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCHv3 4/4] arm: Add generic timer broadcast support
Date: Wed, 06 Feb 2013 13:51:43 -0700	[thread overview]
Message-ID: <5112C25F.6000508@wwwdotorg.org> (raw)
In-Reply-To: <1358183124-28461-5-git-send-email-mark.rutland@arm.com>

On 01/14/2013 10:05 AM, Mark Rutland wrote:
> Implement timer_broadcast for the arm architecture, allowing for the use
> of clock_event_device_drivers decoupled from the timer tick broadcast
> mechanism.

Mark, this patch is now in next-20130206 and causes a crash during boot
on Tegra. The reason appears to be because of:

> diff --git a/arch/arm/kernel/smp.c b/arch/arm/kernel/smp.c

> @@ -524,7 +524,6 @@ static void __cpuinit percpu_timer_setup(void)
>  	struct clock_event_device *evt = &per_cpu(percpu_clockevent, cpu);
>  
>  	evt->cpumask = cpumask_of(cpu);
> -	evt->broadcast = smp_timer_broadcast;

After that change, evt->broadcast is never assigned, and hence is NULL.
Yet elsewhere in kernel/time/tick-broadcast.c it's used unconditionally:

static void tick_do_broadcast(struct cpumask *mask)
...
	if (!cpumask_empty(mask)) {
...
		td = &per_cpu(tick_cpu_device, cpumask_first(mask));
		td->evtdev->broadcast(mask);

Now perhaps the Tegra timer driver simply isn't being set up correctly,
so the bug is there... But the only other place I can find where
->broadcast is assigned is in tick_device_uses_broadcast() which only
does it for "non-functional" timers, which doesn't apply to Tegra's timer.

  reply	other threads:[~2013-02-06 20:51 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-14 17:05 [PATCHv3 0/4] clockevents: decouple broadcast mechanism from drivers Mark Rutland
2013-01-14 17:05 ` Mark Rutland
2013-01-14 17:05 ` [PATCHv3 1/4] clockevents: Add generic timer broadcast receiver Mark Rutland
2013-01-14 17:05   ` Mark Rutland
2013-02-04 10:30   ` [tip:timers/core] " tip-bot for Mark Rutland
2013-01-14 17:05 ` [PATCHv3 2/4] clockevents: Add generic timer broadcast function Mark Rutland
2013-01-14 17:05   ` Mark Rutland
2013-02-04 10:31   ` [tip:timers/core] " tip-bot for Mark Rutland
2013-01-14 17:05 ` [PATCHv3 3/4] arm: Use generic timer broadcast receiver Mark Rutland
2013-01-14 17:05   ` Mark Rutland
2013-01-14 17:05 ` [PATCHv3 4/4] arm: Add generic timer broadcast support Mark Rutland
2013-01-14 17:05   ` Mark Rutland
2013-02-06 20:51   ` Stephen Warren [this message]
2013-02-06 20:51     ` Stephen Warren
2013-02-07 10:04     ` Mark Rutland
2013-02-07 10:04       ` Mark Rutland
2013-02-07 11:40       ` Santosh Shilimkar
2013-02-07 11:40         ` Santosh Shilimkar
2013-02-07 16:51         ` Stephen Warren
2013-02-07 16:51           ` Stephen Warren
2013-02-08  6:48           ` Santosh Shilimkar
2013-02-08  6:48             ` Santosh Shilimkar
2013-02-07 17:17         ` Mark Rutland
2013-02-07 17:17           ` Mark Rutland
2013-02-08  6:52           ` Santosh Shilimkar
2013-02-08  6:52             ` Santosh Shilimkar
2013-02-07 16:49       ` Stephen Warren
2013-02-07 16:49         ` Stephen Warren
2013-02-07 17:25         ` Mark Rutland
2013-02-07 17:25           ` Mark Rutland

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5112C25F.6000508@wwwdotorg.org \
    --to=swarren@wwwdotorg.org \
    --cc=Marc.Zyngier@arm.com \
    --cc=Will.Deacon@arm.com \
    --cc=john.stultz@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=nico@linaro.org \
    --cc=tglx@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.