linux-next: build warning after merge of the akpm-current tree
Subsystems (2)
Hi all,
After merging the akpm-current tree, today's linux-next build (x86_64 allmodconfig) produced this warning:
In file included from arch/x86/include/asm/percpu.h:45,
from arch/x86/include/asm/current.h:6,
from include/linux/sched.h:12,
from include/linux/uaccess.h:5,
from fs/proc/base.c:51:
fs/proc/base.c: In function 'proc_smack_attr_dir_lookup':
include/linux/kernel.h:73:25: warning: passing argument 4 of 'proc_pident_lookup' makes pointer from integer without a cast [-Wint-conversion]
#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]) + __must_be_array(arr))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
fs/proc/base.c:2602:7: note: in expansion of macro 'ARRAY_SIZE'
ARRAY_SIZE(LSM##_attr_dir_stuff)); \
^~~~~~~~~~fs/proc/base.c:2615:1: note: in expansion of macro 'LSM_DIR_OPS'
LSM_DIR_OPS(smack);
^~~~~~~~~~~fs/proc/base.c:2454:31: note: expected 'const struct pid_entry *' but argument is of type 'long unsigned int'
const struct pid_entry *end)
~~~~~~~~~~~~~~~~~~~~~~~~^~~
Introduced by commit
f6e3521a4c5b ("proc: calculate end pointer for /proc/*/* lookup at compile time")
interacting with commit
6d9c939dbe4d ("procfs: add smack subdir to attrs")
from the security tree.
I have applied the following merge fix patch
From: Stephen Rothwell <[email protected]>
Date: Thu, 31 Jan 2019 15:56:56 +1100
Subject: [PATCH] proc: merge fix for proc_pident_lookup() API change
--- fs/proc/base.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/proc/base.c +1 -1
@@ -2599,7 +2599,7 @@ static struct dentry *proc_##LSM##_attr_dir_lookup(struct inode *dir, \ { \return proc_pident_lookup (dir, dentry, \ LSM##_attr_dir_stuff, \ - ARRAY_SIZE(LSM##_attr_dir_stuff)); \ + LSM##_attr_dir_stuff + ARRAY_SIZE(LSM##_attr_dir_stuff)); \ } \ \ static const struct inode_operations proc_##LSM##_attr_dir_inode_ops = { \
Signature · 5 lines
2.20.1 --- Cheers, Stephen Rothwell