[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20231206141941.3ed51cb1@canb.auug.org.au>
Date: Wed, 6 Dec 2023 14:19:41 +1100
From: Stephen Rothwell <sfr@...b.auug.org.au>
To: Luis Chamberlain <mcgrof@...nel.org>,
"Eric W. Biederman" <ebiederm@...ssion.com>
Cc: Thomas Weißschuh <linux@...ssschuh.net>,
Alexey Gladkov <legion@...nel.org>,
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 sysctl tree
Hi all,
After merging the sysctl tree, today's linux-next build (powerpc
ppc64_defconfig) failed like this:
ipc/mq_sysctl.c:115:24: error: initialization of 'int (*)(struct ctl_table_header *, const struct ctl_table *)' from incompatible pointer type 'int (*)(struct ctl_table_header *, struct ctl_table *)' [-Werror=incompatible-pointer-types]
115 | .permissions = mq_permissions,
| ^~~~~~~~~~~~~~
ipc/mq_sysctl.c:115:24: note: (near initialization for 'set_root.permissions')
ipc/mq_sysctl.c:116:26: error: initialization of 'void (*)(struct ctl_table_header *, const struct ctl_table *, kuid_t *, kgid_t *)' from incompatible pointer type 'void (*)(struct ctl_table_header *, struct ctl_table *, kuid_t *, kgid_t *)' [-Werror=incompatible-pointer-types]
116 | .set_ownership = mq_set_ownership,
| ^~~~~~~~~~~~~~~~
ipc/mq_sysctl.c:116:26: note: (near initialization for 'set_root.set_ownership')
Caused by commits
a6dd7f5a787b ("sysctl: treewide: constify ctl_table_root::permissions")
a56545552ecf ("sysctl: treewide: constify ctl_table_root::set_ownership")
interacting with commit
7608b6a72ed0 ("sysctl: Allow to change limits for posix messages queues")
from the userns tree.
I have applied the following merge resolution patch.
From: Stephen Rothwell <sfr@...b.auug.org.au>
Date: Wed, 6 Dec 2023 14:12:02 +1100
Subject: [PATCH] fixup for "sysctl: treewide: constify
ctl_table_root::permissions"
and "sysctl: treewide: constify ctl_table_root::set_ownership" interacting
with "sysctl: Allow to change limits for posix messages queues".
Signed-off-by: Stephen Rothwell <sfr@...b.auug.org.au>
---
ipc/mq_sysctl.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/ipc/mq_sysctl.c b/ipc/mq_sysctl.c
index 69c709262f5a..850dfc83af23 100644
--- a/ipc/mq_sysctl.c
+++ b/ipc/mq_sysctl.c
@@ -78,7 +78,7 @@ static int set_is_seen(struct ctl_table_set *set)
}
static void mq_set_ownership(struct ctl_table_header *head,
- struct ctl_table *table,
+ const struct ctl_table *table,
kuid_t *uid, kgid_t *gid)
{
struct ipc_namespace *ns =
@@ -91,7 +91,7 @@ static void mq_set_ownership(struct ctl_table_header *head,
*gid = gid_valid(ns_root_gid) ? ns_root_gid : GLOBAL_ROOT_GID;
}
-static int mq_permissions(struct ctl_table_header *head, struct ctl_table *table)
+static int mq_permissions(struct ctl_table_header *head, const struct ctl_table *table)
{
int mode = table->mode;
kuid_t ns_root_uid;
--
2.40.1
--
Cheers,
Stephen Rothwell
Content of type "application/pgp-signature" skipped
Powered by blists - more mailing lists