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>] [day] [month] [year] [list]
Message-ID: <20240117092209.7157a9c2@canb.auug.org.au>
Date: Wed, 17 Jan 2024 09:22:09 +1100
From: Stephen Rothwell <sfr@...b.auug.org.au>
To: Andrew Morton <akpm@...ux-foundation.org>
Cc: Yury Norov <yury.norov@...il.com>, 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 mm-nonmm-unstable
 branch of the mm tree

Hi all,

After merging the mm tree, today's linux-next build (powerpc
ppc64_defconfig) failed like this:

In file included from include/uapi/linux/posix_types.h:5,
                 from include/uapi/linux/types.h:14,
                 from include/linux/types.h:6,
                 from include/linux/kasan-checks.h:5,
                 from include/asm-generic/rwonce.h:26,
                 from ./arch/powerpc/include/generated/asm/rwonce.h:1,
                 from include/linux/compiler.h:251,
                 from include/linux/array_size.h:5,
                 from include/linux/kernel.h:16,
                 from lib/group_cpus.c:6:
lib/group_cpus.c: In function 'group_cpus_evenly':
include/linux/stddef.h:8:14: error: invalid initializer
    8 | #define NULL ((void *)0)
      |              ^
lib/group_cpus.c:356:59: note: in expansion of macro 'NULL'
  356 |         cpumask_var_t npresmsk __free(free_cpumask_var) = NULL;
      |                                                           ^~~~

Caused by commit

  f004021b058f ("lib/group_cpus: fix initialization section in group_cpus_evenly()")

CONFIG_CPUMASK_OFFSTACK is not set for this build (so cpumask_var_t is
an single element array, not a pointer).

I applied this hack for today:

From: Stephen Rothwell <sfr@...b.auug.org.au>
Date: Wed, 17 Jan 2024 09:15:07 +1100
Subject: [PATCH] fix up for "lib/group_cpus: fix initialization section in group_cpus_evenly()"

Signed-off-by: Stephen Rothwell <sfr@...b.auug.org.au>
---
 lib/group_cpus.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/lib/group_cpus.c b/lib/group_cpus.c
index c9c95b21e6c6..2c54b49d4c59 100644
--- a/lib/group_cpus.c
+++ b/lib/group_cpus.c
@@ -353,7 +353,11 @@ struct cpumask *group_cpus_evenly(unsigned int numgrps)
 {
 	cpumask_var_t *node_to_cpumask __free(free_node_to_cpumask) = alloc_node_to_cpumask();
 	struct cpumask *masks __free(kfree) = kcalloc(numgrps, sizeof(*masks), GFP_KERNEL);
+#ifdef CONFIG_CPUMASK_OFFSTACK
 	cpumask_var_t npresmsk __free(free_cpumask_var) = NULL;
+#else
+	cpumask_var_t npresmsk __free(free_cpumask_var);
+#endif
 	int curgrp, nr_present, nr_others;
 
 	if (!masks || !node_to_cpumask || !alloc_cpumask_var(&npresmsk, GFP_KERNEL))
-- 
2.43.0

-- 
Cheers,
Stephen Rothwell

Content of type "application/pgp-signature" skipped

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ