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
| ||
|
Date: Mon, 10 Oct 2022 12:32:34 -0600 From: "Jason A. Donenfeld" <Jason@...c4.com> To: Linus Torvalds <torvalds@...ux-foundation.org> Cc: linux-kernel@...r.kernel.org, sultan@...neltoast.com Subject: Re: [GIT PULL] random number generator updates for 6.1-rc1 Hey Linus, On Mon, Oct 10, 2022 at 10:48:42AM -0700, Linus Torvalds wrote: > On Mon, Oct 3, 2022 at 10:45 AM Jason A. Donenfeld <Jason@...c4.com> wrote: > > > > - The original jitter algorithm intended (I believe) to schedule the timer for > > the next jiffy, not the next-next jiffy, yet it used mod_timer(jiffies + 1), > > which will fire on the next-next jiffy, instead of what I believe was > > intended, mod_timer(jiffies), which will fire on the next jiffy. So fix > > that. (If you did actually intend the next-next jiffy for this voodoo, let > > me know and I'll happily send you a new pull.) > > Just as long as you verified that yes, it will actually do the next timer. > > At some point we had timer logic that went "trigger timer callback > immediately if it was in the past". I didn't want to have to worry > about that, this the "jiffies + 1". > > I suspect we long ago got rid of that "trigger immediately" because of > deadlocks, and that I was just being a worry-wart about behavior that > we haven't had for decades, so your patch looks fine. But you might > want to make sure. I checked this and it works. Sultan and I jumped pretty far down the timers rabbit hole in the process of investigating 748bc4dd9e66 ("random: use expired timer rather than wq for mixing fast pool"). If you grep the kernel, expiring at "jiffies" is a fairly common pattern too. Jason
Powered by blists - more mailing lists