linux-security-module.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: KP Singh <kpsingh@chromium.org>,
	linux-kernel@vger.kernel.org, bpf@vger.kernel.org,
	linux-security-module@vger.kernel.org
Cc: kbuild-all@lists.01.org, Alexei Starovoitov <ast@kernel.org>,
	Daniel Borkmann <daniel@iogearbox.net>,
	Martin KaFai Lau <kafai@fb.com>, Paul Turner <pjt@google.com>,
	Jann Horn <jannh@google.com>,
	Florent Revest <revest@chromium.org>
Subject: Re: [PATCH bpf-next v5 5/7] bpf: Implement bpf_local_storage for inodes
Date: Thu, 23 Jul 2020 08:22:43 +0800	[thread overview]
Message-ID: <202007230807.y1gfvekv%lkp@intel.com> (raw)
In-Reply-To: <20200722171409.102949-6-kpsingh@chromium.org>

[-- Attachment #1: Type: text/plain, Size: 2313 bytes --]

Hi KP,

I love your patch! Perhaps something to improve:

[auto build test WARNING on bpf-next/master]

url:    https://github.com/0day-ci/linux/commits/KP-Singh/Generalizing-bpf_local_storage/20200723-011814
base:   https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git master
config: sparc-allmodconfig (attached as .config)
compiler: sparc64-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=sparc 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

   kernel/bpf/bpf_inode_storage.c: In function 'unlink_inode_storage':
>> kernel/bpf/bpf_inode_storage.c:34:32: warning: variable 'smap' set but not used [-Wunused-but-set-variable]
      34 |  struct bpf_local_storage_map *smap;
         |                                ^~~~

vim +/smap +34 kernel/bpf/bpf_inode_storage.c

    29	
    30	static bool unlink_inode_storage(struct bpf_local_storage *local_storage,
    31					 struct bpf_local_storage_elem *selem,
    32					 bool uncharge_omem)
    33	{
  > 34		struct bpf_local_storage_map *smap;
    35		struct bpf_storage_blob *bsb;
    36		bool free_local_storage;
    37		struct inode *inode;
    38	
    39		inode = local_storage->owner;
    40		bsb = bpf_inode(inode);
    41		if (!bsb)
    42			return false;
    43	
    44		smap = rcu_dereference(SDATA(selem)->smap);
    45		/* All uncharging on sk->sk_omem_alloc must be done first.
    46		 * sk may be freed once the last selem is unlinked from sk_storage.
    47		 */
    48	
    49		free_local_storage = hlist_is_singular_node(&selem->snode,
    50							    &local_storage->list);
    51	
    52		if (free_local_storage) {
    53			/* After this RCU_INIT, sk may be freed and cannot be used */
    54			RCU_INIT_POINTER(bsb->storage, NULL);
    55			local_storage->owner = NULL;
    56		}
    57	
    58		return free_local_storage;
    59	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 65959 bytes --]

  reply	other threads:[~2020-07-23  0:26 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-22 17:14 [PATCH bpf-next v5 0/7] Generalizing bpf_local_storage KP Singh
2020-07-22 17:14 ` [PATCH bpf-next v5 1/7] bpf: Renames to prepare for generalizing sk_storage KP Singh
2020-07-22 17:14 ` [PATCH bpf-next v5 2/7] bpf: Generalize caching for sk_storage KP Singh
2020-07-22 17:14 ` [PATCH bpf-next v5 3/7] bpf: Generalize bpf_sk_storage KP Singh
2020-07-22 17:14 ` [PATCH bpf-next v5 4/7] bpf: Split bpf_local_storage to bpf_sk_storage KP Singh
2020-07-22 17:14 ` [PATCH bpf-next v5 5/7] bpf: Implement bpf_local_storage for inodes KP Singh
2020-07-23  0:22   ` kernel test robot [this message]
2020-07-23  5:18     ` Alexei Starovoitov
2020-07-23 11:52       ` KP Singh
2020-07-22 17:14 ` [PATCH bpf-next v5 6/7] bpf: Allow local storage to be used from LSM programs KP Singh
2020-07-22 17:14 ` [PATCH bpf-next v5 7/7] bpf: Add selftests for local_storage KP Singh

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202007230807.y1gfvekv%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=ast@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=jannh@google.com \
    --cc=kafai@fb.com \
    --cc=kbuild-all@lists.01.org \
    --cc=kpsingh@chromium.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-security-module@vger.kernel.org \
    --cc=pjt@google.com \
    --cc=revest@chromium.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).