lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 17 Aug 2012 13:17:12 -0300
From:	Herton Ronaldo Krzesinski <herton.krzesinski@...onical.com>
To:	Paul Gortmaker <paul.gortmaker@...driver.com>
Cc:	stable@...r.kernel.org, linux-kernel@...r.kernel.org,
	John Stultz <john.stultz@...aro.org>,
	Sasha Levin <levinsasha928@...il.com>,
	Thomas Gleixner <tglx@...utronix.de>,
	Prarit Bhargava <prarit@...hat.com>, Willy Tarreau <w@....eu>,
	Richard Cochran <richardcochran@...il.com>,
	Peter Zijlstra <a.p.zijlstra@...llo.nl>,
	Ingo Molnar <mingo@...nel.org>,
	Ben Hutchings <ben@...adent.org.uk>
Subject: Re: [v2.6.34-stable 109/165] ntp: Fix leap-second hrtimer livelock

On Wed, Aug 15, 2012 at 03:47:33PM -0400, Paul Gortmaker wrote:
> From: John Stultz <john.stultz@...aro.org>
> 
>                    -------------------
>     This is a commit scheduled for the next v2.6.34 longterm release.
>     http://git.kernel.org/?p=linux/kernel/git/paulg/longterm-queue-2.6.34.git
>     If you see a problem with using this for longterm, please comment.
>                    -------------------
> 
> commit 6b43ae8a619d17c4935c3320d2ef9e92bdeed05d upstream.
> 
> This should have been backported when it was commited, but I
> mistook the problem as requiring the ntp_lock changes
> that landed in 3.4 in order for it to occur.
> 
> Unfortunately the same issue can happen (with only one cpu)
> as follows:
> do_adjtimex()
>  write_seqlock_irq(&xtime_lock);
>   process_adjtimex_modes()
>    process_adj_status()
>     ntp_start_leap_timer()
>      hrtimer_start()
>       hrtimer_reprogram()
>        tick_program_event()
>         clockevents_program_event()
>          ktime_get()
>           seq = req_seqbegin(xtime_lock); [DEADLOCK]
> 
> This deadlock will no always occur, as it requires the
> leap_timer to force a hrtimer_reprogram which only happens
> if its set and there's no sooner timer to expire.
[...]

I remember this came through the leapsecond deadlock & hrtimer/futex
issue fixes. But I noted now commit 6b1859dba01c7d512b72d77e3fd7da8354235189
("ntp: Fix STA_INS/DEL clearing bug") was not included, and its changelog
says it fixes a problem introduced with this. Wouldn't it be worth/right to
also include it in 2.6.34? I didn't test etc., just detected through the
changelog/description but would expect it would be affected too. I also
noted it is missing from 3.2.y and 2.6.32.y stables, and perhaps should be
scheduled for inclusion in their cases too.

-- 
[]'s
Herton
--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ