From: Thomas Gleixner <tglx@linutronix.de>
To: Borislav Petkov <bp@alien8.de>
Cc: vitalif@yourcmc.ru, Ben Hutchings <ben@decadent.org.uk>,
"Venkatesh Pallipadi (Venki)" <venki@google.com>,
700333@bugs.debian.org, LKML <linux-kernel@vger.kernel.org>,
Clemens Ladisch <clemens@ladisch.de>
Subject: Re: Bug#700333: Stack trace
Date: Mon, 22 Apr 2013 14:15:34 +0200 (CEST) [thread overview]
Message-ID: <alpine.LFD.2.02.1304221409420.21884@ionos> (raw)
In-Reply-To: <20130420225516.GB4649@pd.tnic>
On Sun, 21 Apr 2013, Borislav Petkov wrote:
> + tglx.
>
> On Sun, Apr 21, 2013 at 01:38:33AM +0400, vitalif@yourcmc.ru wrote:
> > >>Stack trace picture is here:
> > >>http://vmx.yourcmc.ru/var/pics/IMG_20130306_141045.jpg
> > >
> > >Vitaliy reported that his system crashes when suspending to disk.
> > >This
> > >was a regression from 3.2 to 3.7, and remains in 3.8. Some
> > >details of
> > >this system are in the bug log at <http://bugs.debian.org/700333>.
> > >
> > >The photo shows a BUG in hrtimer_interrupt() after making the
> > >hibernation image and while resuming the non-boot CPUs. The HPET
> > >interrupt handler was called immediately after it was registered
> > >for CPU
> > >2 (?), before the corresponding clock_event_device was registered.
> > >
> > >Seems like an obvious race condition, but then shouldn't the HPET
> > >have
> > >been stopped while the CPU was previously offlined? And it's strange
> > >that this system apparently hits the race quite reliably.
> >
> > Anyone?
So what happens is, that the HPET seems to have an interrupt pending
and this gets immediately fired, when the handler is installed. The
core code does not remove the hpet->event_handler, so it calls into
the hrtimer_interrupt where it hits the BUG and dies.
With the patch below, the box should survive and we should see a
"Spurious HPET timer interrupt on HPET timer..." entry in dmesg.
That's a first workaround to confirm my theory. I'll look into the
HPET code how we can avoid that at all.
Thanks,
tglx
diff --git a/kernel/time/tick-common.c b/kernel/time/tick-common.c
index b1600a6..0f0ce6e 100644
--- a/kernel/time/tick-common.c
+++ b/kernel/time/tick-common.c
@@ -323,6 +323,7 @@ static void tick_shutdown(unsigned int *cpup)
*/
dev->mode = CLOCK_EVT_MODE_UNUSED;
clockevents_exchange_device(dev, NULL);
+ dev->event_handler = NULL;
td->evtdev = NULL;
}
raw_spin_unlock_irqrestore(&tick_device_lock, flags);
next prev parent reply other threads:[~2013-04-22 12:15 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <4bded8a24b0719d575f6ffa6b38aebb6@yourcmc.ru>
[not found] ` <1362490501.3768.409.camel@deadeye.wl.decadent.org.uk>
[not found] ` <1b81bc6219ee47a5b8e53d03e9944939@yourcmc.ru>
[not found] ` <20130305203952.GZ9079@decadent.org.uk>
[not found] ` <4e8c511dcfd811c0f2ab822adaf52e50@yourcmc.ru>
[not found] ` <1362536476.3768.416.camel@deadeye.wl.decadent.org.uk>
[not found] ` <15ec7b46ebd929a67caea0d80b324af9@yourcmc.ru>
2013-03-11 3:10 ` Bug#700333: Stack trace Ben Hutchings
2013-04-20 21:38 ` vitalif
2013-04-20 22:55 ` Borislav Petkov
2013-04-22 12:15 ` Thomas Gleixner [this message]
2013-04-25 9:41 ` Thomas Gleixner
2013-04-27 15:08 ` vitalif
2013-04-27 15:49 ` Borislav Petkov
2013-04-28 13:26 ` vitalif
2013-04-28 19:05 ` Borislav Petkov
2013-04-28 19:53 ` Thomas Gleixner
2013-04-30 21:04 ` vitalif
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=alpine.LFD.2.02.1304221409420.21884@ionos \
--to=tglx@linutronix.de \
--cc=700333@bugs.debian.org \
--cc=ben@decadent.org.uk \
--cc=bp@alien8.de \
--cc=clemens@ladisch.de \
--cc=linux-kernel@vger.kernel.org \
--cc=venki@google.com \
--cc=vitalif@yourcmc.ru \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox