lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202512181104.Dj73SWGl-lkp@intel.com>
Date: Thu, 18 Dec 2025 12:09:12 +0800
From: kernel test robot <lkp@...el.com>
To: Christian Brauner <brauner@...nel.org>
Cc: oe-kbuild-all@...ts.linux.dev, linux-kernel@...r.kernel.org,
	Amir Goldstein <amir73il@...il.com>
Subject: fs/overlayfs/dir.c:588:13: sparse: sparse: incompatible types in
 comparison expression (different address spaces):

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   ea1013c1539270e372fc99854bc6e4d94eaeff66
commit: f37b334728814b14745e15d46f9eab73750b67ec ovl: add ovl_override_creator_creds cred guard
date:   4 weeks ago
config: x86_64-randconfig-121-20251218 (https://download.01.org/0day-ci/archive/20251218/202512181104.Dj73SWGl-lkp@intel.com/config)
compiler: clang version 20.1.8 (https://github.com/llvm/llvm-project 87f0227cb60147a26a1eeb4fb06e3b505e9c7261)
rustc: rustc 1.88.0 (6b00bc388 2025-06-23)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251218/202512181104.Dj73SWGl-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202512181104.Dj73SWGl-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
>> fs/overlayfs/dir.c:588:13: sparse: sparse: incompatible types in comparison expression (different address spaces):
   fs/overlayfs/dir.c:588:13: sparse:    struct cred const [noderef] __rcu *
   fs/overlayfs/dir.c:588:13: sparse:    struct cred const *

vim +588 fs/overlayfs/dir.c

   583	
   584	static const struct cred *ovl_override_creator_creds(struct dentry *dentry, struct inode *inode, umode_t mode)
   585	{
   586		int err;
   587	
 > 588		if (WARN_ON_ONCE(current->cred != ovl_creds(dentry->d_sb)))
   589			return ERR_PTR(-EINVAL);
   590	
   591		CLASS(prepare_creds, override_cred)();
   592		if (!override_cred)
   593			return ERR_PTR(-ENOMEM);
   594	
   595		override_cred->fsuid = inode->i_uid;
   596		override_cred->fsgid = inode->i_gid;
   597	
   598		err = security_dentry_create_files_as(dentry, mode, &dentry->d_name,
   599						      current->cred, override_cred);
   600		if (err)
   601			return ERR_PTR(err);
   602	
   603		return override_creds(no_free_ptr(override_cred));
   604	}
   605	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ