linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Andrey Konovalov <andreyknvl@google.com>
Cc: kbuild-all@lists.01.org,
	Linux Memory Management List <linux-mm@kvack.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	Marco Elver <elver@google.com>
Subject: [linux-next:master 5995/6188] mm/kasan/kasan_test_module.c:90:26: sparse: sparse: incompatible types in comparison expression (different address spaces):
Date: Thu, 8 Sep 2022 22:03:21 +0800	[thread overview]
Message-ID: <202209082120.MTrpG6Be-lkp@intel.com> (raw)

Hi Andrey,

First bad commit (maybe != root cause):

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   47c191411b68a771261be3dc0bd6f68394cef358
commit: 5de20e0f195f50622c10ea2fd0fc6c43b49988cc [5995/6188] kasan: move tests to mm/kasan/
config: s390-randconfig-s041-20220907 (https://download.01.org/0day-ci/archive/20220908/202209082120.MTrpG6Be-lkp@intel.com/config)
compiler: s390-linux-gcc (GCC) 12.1.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # apt-get install sparse
        # sparse version: v0.6.4-39-gce1a6720-dirty
        # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=5de20e0f195f50622c10ea2fd0fc6c43b49988cc
        git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
        git fetch --no-tags linux-next master
        git checkout 5de20e0f195f50622c10ea2fd0fc6c43b49988cc
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=s390 SHELL=/bin/bash

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

sparse warnings: (new ones prefixed by >>)
>> mm/kasan/kasan_test_module.c:90:26: sparse: sparse: incompatible types in comparison expression (different address spaces):
>> mm/kasan/kasan_test_module.c:90:26: sparse:    struct kasan_rcu_info [noderef] __rcu *
>> mm/kasan/kasan_test_module.c:90:26: sparse:    struct kasan_rcu_info *

vim +90 mm/kasan/kasan_test_module.c

73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  78  
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  79  static noinline void __init kasan_rcu_uaf(void)
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  80  {
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  81  	struct kasan_rcu_info *ptr;
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  82  
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  83  	pr_info("use-after-free in kasan_rcu_reclaim\n");
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  84  	ptr = kmalloc(sizeof(struct kasan_rcu_info), GFP_KERNEL);
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  85  	if (!ptr) {
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  86  		pr_err("Allocation failed\n");
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  87  		return;
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  88  	}
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  89  
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13 @90  	global_rcu_ptr = rcu_dereference_protected(ptr, NULL);
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  91  	call_rcu(&global_rcu_ptr->rcu, kasan_rcu_reclaim);
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  92  }
73228c7ecc5e40 lib/test_kasan_module.c Patricia Alfonso 2020-10-13  93  

:::::: The code at line 90 was first introduced by commit
:::::: 73228c7ecc5e40c0851c4703c5ec6ed38123e989 KASAN: port KASAN Tests to KUnit

:::::: TO: Patricia Alfonso <trishalfonso@google.com>
:::::: CC: Linus Torvalds <torvalds@linux-foundation.org>

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp


                 reply	other threads:[~2022-09-08 14:04 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=202209082120.MTrpG6Be-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=akpm@linux-foundation.org \
    --cc=andreyknvl@google.com \
    --cc=elver@google.com \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-mm@kvack.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