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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <7c706521-1e20-44da-91a7-e71f238a235e@paulmck-laptop>
Date:   Thu, 31 Aug 2023 09:22:17 -0700
From:   "Paul E. McKenney" <paulmck@...nel.org>
To:     Julia Lawall <julia.lawall@...ia.fr>
Cc:     linux-kernel@...r.kernel.org, oe-kbuild-all@...ts.linux.dev
Subject: Re: [paulmck-rcu:dev.2023.08.22a 63/69]
 kernel/locking/locktorture.c:294:20-23: ERROR: t is NULL but dereferenced.
 (fwd)

On Thu, Aug 31, 2023 at 11:01:02AM +0200, Julia Lawall wrote:
> Maybe a ! has been forgotton on line 290?

Right you are, and thank you!

I will go get my brown paper bag.  ;-)

							Thanx, Paul

> julia
> 
> ---------- Forwarded message ----------
> Date: Thu, 31 Aug 2023 10:46:56 +0800
> From: kernel test robot <lkp@...el.com>
> To: oe-kbuild@...ts.linux.dev
> Cc: lkp@...el.com, Julia Lawall <julia.lawall@...ia.fr>
> Subject: [paulmck-rcu:dev.2023.08.22a 63/69]
>     kernel/locking/locktorture.c:294:20-23: ERROR: t is NULL but dereferenced.
> 
> BCC: lkp@...el.com
> CC: oe-kbuild-all@...ts.linux.dev
> CC: linux-kernel@...r.kernel.org
> TO: "Paul E. McKenney" <paulmck@...nel.org>
> 
> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu.git dev.2023.08.22a
> head:   354957ec11dc80eac68c4b1e10c237d69adc1833
> commit: 758918804e0d5216981df3cef99ffd7ba0842192 [63/69] locktorture: Add indication of task write-holding lock
> :::::: branch date: 6 days ago
> :::::: commit date: 7 days ago
> config: i386-randconfig-053-20230831 (https://download.01.org/0day-ci/archive/20230831/202308311022.j7jKnIdL-lkp@intel.com/config)
> compiler: gcc-7 (Ubuntu 7.5.0-6ubuntu2) 7.5.0
> reproduce: (https://download.01.org/0day-ci/archive/20230831/202308311022.j7jKnIdL-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>
> | Reported-by: Julia Lawall <julia.lawall@...ia.fr>
> | Closes: https://lore.kernel.org/r/202308311022.j7jKnIdL-lkp@intel.com/
> 
> cocci warnings: (new ones prefixed by >>)
> >> kernel/locking/locktorture.c:294:20-23: ERROR: t is NULL but dereferenced.
>    kernel/locking/locktorture.c:294:43-47: ERROR: t is NULL but dereferenced.
> 
> vim +294 kernel/locking/locktorture.c
> 
> bdd8d60bd4047a Paul E. McKenney 2023-08-23  284
> 94a8fb5e4673d7 Paul E. McKenney 2023-08-22  285  static int torture_spin_lock_dump(struct notifier_block *nb, unsigned long v, void *ptr)
> 94a8fb5e4673d7 Paul E. McKenney 2023-08-22  286  {
> 758918804e0d52 Paul E. McKenney 2023-08-23  287  	struct task_struct *t = READ_ONCE(lock_is_write_held);
> 758918804e0d52 Paul E. McKenney 2023-08-23  288
> 94a8fb5e4673d7 Paul E. McKenney 2023-08-22  289  	pr_alert("%s invoked: v=%lu, duration=%lu.\n", __func__, v, (unsigned long)ptr);
> 758918804e0d52 Paul E. McKenney 2023-08-23  290  	if (t) {
> 758918804e0d52 Paul E. McKenney 2023-08-23  291  		pr_alert("%s No task holding lock.\n", __func__);
> 758918804e0d52 Paul E. McKenney 2023-08-23  292  	} else {
> 758918804e0d52 Paul E. McKenney 2023-08-23  293  		pr_alert("%s Lock held by task %ps %d %*s\n",
> 758918804e0d52 Paul E. McKenney 2023-08-23 @294  			 __func__, t, t->pid, TASK_COMM_LEN, t->comm);
> 758918804e0d52 Paul E. McKenney 2023-08-23  295  		sched_show_task(t);
> 758918804e0d52 Paul E. McKenney 2023-08-23  296  	}
> bdd8d60bd4047a Paul E. McKenney 2023-08-23  297  	spinlock_dump(&torture_spinlock, true);
> 94a8fb5e4673d7 Paul E. McKenney 2023-08-22  298  	return NOTIFY_OK;
> 94a8fb5e4673d7 Paul E. McKenney 2023-08-22  299  }
> 94a8fb5e4673d7 Paul E. McKenney 2023-08-22  300
> 
> -- 
> 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