linux-next: manual merge of the sysctl tree with the userns tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all,

Today's linux-next merge of the sysctl tree got a conflict in:

  ipc/ipc_sysctl.c

between commit:

  54e1011bd95a ("sysctl: Allow change system v ipc sysctls inside ipc namespace")

from the userns tree and commit:

  a6dd7f5a787b ("sysctl: treewide: constify ctl_table_root::permissions")

from the sysctl tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging.  You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

-- 
Cheers,
Stephen Rothwell

diff --cc ipc/ipc_sysctl.c
index 01c4a50d22b2,d876f96f5992..000000000000
--- a/ipc/ipc_sysctl.c
+++ b/ipc/ipc_sysctl.c
@@@ -14,11 -14,10 +14,11 @@@
  #include <linux/ipc_namespace.h>
  #include <linux/msg.h>
  #include <linux/slab.h>
 +#include <linux/cred.h>
  #include "util.h"
  
- static int proc_ipc_dointvec_minmax_orphans(struct ctl_table *table, int write,
- 		void *buffer, size_t *lenp, loff_t *ppos)
+ static int proc_ipc_dointvec_minmax_orphans(const struct ctl_table *table,
+ 		int write, void *buffer, size_t *lenp, loff_t *ppos)
  {
  	struct ipc_namespace *ns =
  		container_of(table->data, struct ipc_namespace, shm_rmid_forced);
@@@ -191,21 -190,7 +191,21 @@@ static int set_is_seen(struct ctl_table
  	return &current->nsproxy->ipc_ns->ipc_set == set;
  }
  
 +static void ipc_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 =
 +		container_of(head->set, struct ipc_namespace, ipc_set);
 +
 +	kuid_t ns_root_uid = make_kuid(ns->user_ns, 0);
 +	kgid_t ns_root_gid = make_kgid(ns->user_ns, 0);
 +
 +	*uid = uid_valid(ns_root_uid) ? ns_root_uid : GLOBAL_ROOT_UID;
 +	*gid = gid_valid(ns_root_gid) ? ns_root_gid : GLOBAL_ROOT_GID;
 +}
 +
- static int ipc_permissions(struct ctl_table_header *head, struct ctl_table *table)
+ static int ipc_permissions(struct ctl_table_header *head, const struct ctl_table *table)
  {
  	int mode = table->mode;
  

Attachment: pgpYmt2slH3AW.pgp
Description: OpenPGP digital signature


[Index of Archives]     [Linux Kernel]     [Linux USB Development]     [Yosemite News]     [Linux SCSI]

  Powered by Linux