Re: [PATCH v10 3/4] ipc: Make the new sequence number generation mode available to all

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

 



Hi Waiman,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on linus/master]
[also build test WARNING on v4.20-rc1]
[cannot apply to next-20181105]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Waiman-Long/ipc-Increase-IPCMNI-limit-IPC-id-generation-modes/20181106-044522
reproduce: make htmldocs

All warnings (new ones prefixed by >>):

   WARNING: convert(1) not found, for SVG to PDF conversion install ImageMagick (https://www.imagemagick.org)
>> ipc/util.c:262: warning: Function parameter or member 'idmode' not described in 'ipc_addid'
   kernel/resource.c:337: warning: Function parameter or member 'start' not described in 'find_next_iomem_res'
   kernel/resource.c:337: warning: Function parameter or member 'end' not described in 'find_next_iomem_res'
   kernel/resource.c:337: warning: Function parameter or member 'flags' not described in 'find_next_iomem_res'
   kernel/resource.c:337: warning: Function parameter or member 'desc' not described in 'find_next_iomem_res'
   kernel/resource.c:337: warning: Function parameter or member 'first_lvl' not described in 'find_next_iomem_res'
   kernel/resource.c:337: warning: Function parameter or member 'res' not described in 'find_next_iomem_res'
   kernel/resource.c:409: warning: Function parameter or member 'arg' not described in 'walk_iomem_res_desc'
   kernel/resource.c:409: warning: Function parameter or member 'func' not described in 'walk_iomem_res_desc'
   kernel/resource.c:409: warning: Function parameter or member 'arg' not described in 'walk_iomem_res_desc'
   kernel/resource.c:409: warning: Function parameter or member 'func' not described in 'walk_iomem_res_desc'
   include/linux/rcutree.h:1: warning: no structured comments found
   kernel/rcu/tree.c:684: warning: Excess function parameter 'irq' description in 'rcu_nmi_exit'
   include/linux/srcu.h:175: warning: Function parameter or member 'p' not described in 'srcu_dereference_notrace'
   include/linux/srcu.h:175: warning: Function parameter or member 'sp' not described in 'srcu_dereference_notrace'
   include/linux/gfp.h:1: warning: no structured comments found
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:4439: warning: Function parameter or member 'wext.ibss' not described in 'wireless_dev'
   include/net/cfg80211.h:4439: warning: Function parameter or member 'wext.connect' not described in 'wireless_dev'
   include/net/cfg80211.h:4439: warning: Function parameter or member 'wext.keys' not described in 'wireless_dev'
   include/net/cfg80211.h:4439: warning: Function parameter or member 'wext.ie' not described in 'wireless_dev'
   include/net/cfg80211.h:4439: warning: Function parameter or member 'wext.ie_len' not described in 'wireless_dev'
   include/net/cfg80211.h:4439: warning: Function parameter or member 'wext.bssid' not described in 'wireless_dev'
   include/net/cfg80211.h:4439: warning: Function parameter or member 'wext.ssid' not described in 'wireless_dev'
   include/net/cfg80211.h:4439: warning: Function parameter or member 'wext.default_key' not described in 'wireless_dev'
   include/net/cfg80211.h:4439: warning: Function parameter or member 'wext.default_mgmt_key' not described in 'wireless_dev'
   include/net/cfg80211.h:4439: warning: Function parameter or member 'wext.prev_bssid_valid' not described in 'wireless_dev'
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '
   include/net/cfg80211.h:2838: warning: cannot understand function prototype: 'struct cfg80211_ftm_responder_stats '

vim +262 ipc/util.c

b8fd998384 Davidlohr Bueso   2017-11-17  243  
^1da177e4c Linus Torvalds    2005-04-16  244  /**
8001c85810 Davidlohr Bueso   2014-01-27  245   * ipc_addid - add an ipc identifier
8001c85810 Davidlohr Bueso   2014-01-27  246   * @ids: ipc identifier set
8001c85810 Davidlohr Bueso   2014-01-27  247   * @new: new ipc permission set
ebf66799ac Davidlohr Bueso   2017-11-17  248   * @limit: limit for the number of used ids
^1da177e4c Linus Torvalds    2005-04-16  249   *
8001c85810 Davidlohr Bueso   2014-01-27  250   * Add an entry 'new' to the ipc ids idr. The permissions object is
27c331a174 Manfred Spraul    2018-08-21  251   * initialised and the first free entry is set up and the index assigned
f4566f0485 Nadia Derbey      2007-10-18  252   * is returned. The 'new' entry is returned in a locked state on success.
39cfffd774 Manfred Spraul    2018-08-21  253   *
283bb7fada Pierre Peiffer    2007-10-18  254   * On failure the entry is not locked and a negative err-code is returned.
39cfffd774 Manfred Spraul    2018-08-21  255   * The caller must use ipc_rcu_putref() to free the identifier.
^1da177e4c Linus Torvalds    2005-04-16  256   *
d9a605e40b Davidlohr Bueso   2013-09-11  257   * Called with writer ipc_ids.rwsem held.
^1da177e4c Linus Torvalds    2005-04-16  258   */
4073296664 Waiman Long       2018-11-05  259  int ipc_addid(struct ipc_ids *ids, struct kern_ipc_perm *new, int limit,
4073296664 Waiman Long       2018-11-05  260  	      int idmode)
^1da177e4c Linus Torvalds    2005-04-16  261  {
1efdb69b0b Eric W. Biederman 2012-02-07 @262  	kuid_t euid;
1efdb69b0b Eric W. Biederman 2012-02-07  263  	kgid_t egid;
e2652ae6bd Manfred Spraul    2018-08-21  264  	int idx, err;
^1da177e4c Linus Torvalds    2005-04-16  265  
39cfffd774 Manfred Spraul    2018-08-21  266  	/* 1) Initialize the refcount so that ipc_rcu_putref works */
39cfffd774 Manfred Spraul    2018-08-21  267  	refcount_set(&new->refcount, 1);
39cfffd774 Manfred Spraul    2018-08-21  268  
fa04270b8b Waiman Long       2018-11-05  269  	if (limit > ipc_mni)
fa04270b8b Waiman Long       2018-11-05  270  		limit = ipc_mni;
7ca7e564e0 Nadia Derbey      2007-10-18  271  
dc2c8c84de Davidlohr Bueso   2018-08-21  272  	if (ids->in_use >= limit)
283bb7fada Pierre Peiffer    2007-10-18  273  		return -ENOSPC;
7ca7e564e0 Nadia Derbey      2007-10-18  274  
54924ea33f Tejun Heo         2013-02-27  275  	idr_preload(GFP_KERNEL);
54924ea33f Tejun Heo         2013-02-27  276  
e00b4ff7eb Nadia Derbey      2008-11-19  277  	spin_lock_init(&new->lock);
e00b4ff7eb Nadia Derbey      2008-11-19  278  	rcu_read_lock();
e00b4ff7eb Nadia Derbey      2008-11-19  279  	spin_lock(&new->lock);
e00b4ff7eb Nadia Derbey      2008-11-19  280  
b9a5322779 Linus Torvalds    2015-09-30  281  	current_euid_egid(&euid, &egid);
b9a5322779 Linus Torvalds    2015-09-30  282  	new->cuid = new->uid = euid;
b9a5322779 Linus Torvalds    2015-09-30  283  	new->gid = new->cgid = egid;
b9a5322779 Linus Torvalds    2015-09-30  284  
39cfffd774 Manfred Spraul    2018-08-21  285  	new->deleted = false;
39cfffd774 Manfred Spraul    2018-08-21  286  
4073296664 Waiman Long       2018-11-05  287  	idx = ipc_idr_alloc(ids, new, idmode);
54924ea33f Tejun Heo         2013-02-27  288  	idr_preload_end();
0cfb6aee70 Guillaume Knispel 2017-09-08  289  
e2652ae6bd Manfred Spraul    2018-08-21  290  	if (idx >= 0 && new->key != IPC_PRIVATE) {
0cfb6aee70 Guillaume Knispel 2017-09-08  291  		err = rhashtable_insert_fast(&ids->key_ht, &new->khtnode,
0cfb6aee70 Guillaume Knispel 2017-09-08  292  					     ipc_kht_params);
0cfb6aee70 Guillaume Knispel 2017-09-08  293  		if (err < 0) {
e2652ae6bd Manfred Spraul    2018-08-21  294  			idr_remove(&ids->ipcs_idr, idx);
e2652ae6bd Manfred Spraul    2018-08-21  295  			idx = err;
0cfb6aee70 Guillaume Knispel 2017-09-08  296  		}
0cfb6aee70 Guillaume Knispel 2017-09-08  297  	}
e2652ae6bd Manfred Spraul    2018-08-21  298  	if (idx < 0) {
39cfffd774 Manfred Spraul    2018-08-21  299  		new->deleted = true;
e00b4ff7eb Nadia Derbey      2008-11-19  300  		spin_unlock(&new->lock);
e00b4ff7eb Nadia Derbey      2008-11-19  301  		rcu_read_unlock();
e2652ae6bd Manfred Spraul    2018-08-21  302  		return idx;
e00b4ff7eb Nadia Derbey      2008-11-19  303  	}
7ca7e564e0 Nadia Derbey      2007-10-18  304  
^1da177e4c Linus Torvalds    2005-04-16  305  	ids->in_use++;
27c331a174 Manfred Spraul    2018-08-21  306  	if (idx > ids->max_idx)
27c331a174 Manfred Spraul    2018-08-21  307  		ids->max_idx = idx;
e2652ae6bd Manfred Spraul    2018-08-21  308  	return idx;
^1da177e4c Linus Torvalds    2005-04-16  309  }
^1da177e4c Linus Torvalds    2005-04-16  310  

:::::: The code at line 262 was first introduced by commit
:::::: 1efdb69b0bb41dec8ee3e2cac0a0f167837d0919 userns: Convert ipc to use kuid and kgid where appropriate

:::::: TO: Eric W. Biederman <ebiederm@xxxxxxxxxxxx>
:::::: CC: Eric W. Biederman <ebiederm@xxxxxxxxxxxx>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux