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-next>] [day] [month] [year] [list]
Message-ID: <20221024132319.4b3910ad@canb.auug.org.au>
Date:   Mon, 24 Oct 2022 13:23:19 +1100
From:   Stephen Rothwell <sfr@...b.auug.org.au>
To:     Theodore Ts'o <tytso@....edu>,
        "Jason A. Donenfeld" <Jason@...c4.com>,
        Thomas Gleixner <tglx@...utronix.de>,
        Ingo Molnar <mingo@...hat.com>,
        "H. Peter Anvin" <hpa@...or.com>,
        Peter Zijlstra <peterz@...radead.org>
Cc:     Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Linux Next Mailing List <linux-next@...r.kernel.org>
Subject: linux-next: build failure after merge of the random tree

Hi all,

After merging the random tree, today's linux-next build (x86_64
allmodconfig) failed like this:

arch/x86/mm/cpu_entry_area.c: In function 'init_cea_offsets':
arch/x86/mm/cpu_entry_area.c:38:23: error: implicit declaration of function 'prandom_u32_max'; did you mean 'prandom_u32_state'? [-Werror=implicit-function-declaration]
   38 |                 cea = prandom_u32_max(max_cea);
      |                       ^~~~~~~~~~~~~~~
      |                       prandom_u32_state
cc1: all warnings being treated as errors

Caused by commit

  921b09c09fe7 ("prandom: remove prandom_u32_max()")

interacting with commit

  1248fb6a8201 ("x86/mm: Randomize per-cpu entry area")

from the tip tree.

I have applied the following fix up patch for today.

From: Stephen Rothwell <sfr@...b.auug.org.au>
Date: Mon, 24 Oct 2022 12:37:28 +1100
Subject: [PATCH] fix up for "prandom: remove prandom_u32_max()"

Signed-off-by: Stephen Rothwell <sfr@...b.auug.org.au>
---
 arch/x86/mm/cpu_entry_area.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/mm/cpu_entry_area.c b/arch/x86/mm/cpu_entry_area.c
index ad1f750517a1..7a1b63fb80d3 100644
--- a/arch/x86/mm/cpu_entry_area.c
+++ b/arch/x86/mm/cpu_entry_area.c
@@ -35,7 +35,7 @@ static __init void init_cea_offsets(void)
 		unsigned int cea;
 
 again:
-		cea = prandom_u32_max(max_cea);
+		cea = get_random_u32_below(max_cea);
 
 		/* Make sure that no previous CPU shares the offset: */
 		for_each_possible_cpu(j) {
-- 
2.34.1

-- 
Cheers,
Stephen Rothwell

Content of type "application/pgp-signature" skipped

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ