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: <202401050409.VH31aFND-lkp@intel.com>
Date: Fri, 5 Jan 2024 04:25:25 +0800
From: kernel test robot <lkp@...el.com>
To: Kent Overstreet <kent.overstreet@...ux.dev>
Cc: oe-kbuild-all@...ts.linux.dev, linux-kernel@...r.kernel.org
Subject: fs/bcachefs/alloc_background.c:200:5-8: Unneeded variable: "ret".
 Return "  0" on line 208

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   ac865f00af293d081356bec56eea90815094a60e
commit: b65db750e2bb9252321fd54c284edd73c1595a09 bcachefs: Enumerate fsck errors
date:   9 weeks ago
config: x86_64-randconfig-r064-20231231 (https://download.01.org/0day-ci/archive/20240105/202401050409.VH31aFND-lkp@intel.com/config)
compiler: gcc-7 (Ubuntu 7.5.0-6ubuntu2) 7.5.0

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/202401050409.VH31aFND-lkp@intel.com/

cocci warnings: (new ones prefixed by >>)
>> fs/bcachefs/alloc_background.c:200:5-8: Unneeded variable: "ret". Return "  0" on line 208
   fs/bcachefs/alloc_background.c:216:5-8: Unneeded variable: "ret". Return "  0" on line 222
   fs/bcachefs/alloc_background.c:230:5-8: Unneeded variable: "ret". Return "  0" on line 236
   fs/bcachefs/alloc_background.c:243:5-8: Unneeded variable: "ret". Return "  0" on line 297
   fs/bcachefs/alloc_background.c:523:5-8: Unneeded variable: "ret". Return "  0" on line 530
--
>> fs/bcachefs/lru.c:17:5-8: Unneeded variable: "ret". Return "  0" on line 23
--
>> fs/bcachefs/quota.c:66:5-8: Unneeded variable: "ret". Return "  0" on line 73
--
>> fs/bcachefs/subvolume.c:104:5-8: Unneeded variable: "ret". Return "  0" on line 111

vim +200 fs/bcachefs/alloc_background.c

   194	
   195	int bch2_alloc_v1_invalid(struct bch_fs *c, struct bkey_s_c k,
   196				  enum bkey_invalid_flags flags,
   197				  struct printbuf *err)
   198	{
   199		struct bkey_s_c_alloc a = bkey_s_c_to_alloc(k);
 > 200		int ret = 0;
   201	
   202		/* allow for unknown fields */
   203		bkey_fsck_err_on(bkey_val_u64s(a.k) < bch_alloc_v1_val_u64s(a.v), c, err,
   204				 alloc_v1_val_size_bad,
   205				 "incorrect value size (%zu < %u)",
   206				 bkey_val_u64s(a.k), bch_alloc_v1_val_u64s(a.v));
   207	fsck_err:
 > 208		return ret;
   209	}
   210	

-- 
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