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>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20141128100045.GC4860@mwanda>
Date:	Fri, 28 Nov 2014 13:00:45 +0300
From:	Dan Carpenter <dan.carpenter@...cle.com>
To:	Loïc Pefferkorn <loic@...cp.eu>
Cc:	Greg KH <gregkh@...uxfoundation.org>, keith.mannthey@...el.com,
	devel@...verdev.osuosl.org, andreas.dilger@...el.com,
	linux-kernel@...r.kernel.org, oleg.drokin@...el.com,
	gdonald@...il.com, HPDD-discuss@...1.01.org, john.hammond@...el.com
Subject: Re: [PATCH] staging: lustre: fix sparse warnings related to lock
 context imbalance

On Thu, Nov 27, 2014 at 07:34:10PM +0100, Loïc Pefferkorn wrote:
> 1827         if (valid != 0) {
> 1828             cl_object_attr_lock(obj);
> 1829             cl_object_attr_set(env, obj, attr, valid);
> 1830             cl_object_attr_unlock(obj);
> 
> after:
> 
> 1827         if (valid != 0) {
> 1828             spin_lock(cl_object_attr_guard(obj));
> 1829             cl_object_attr_set(env, obj, attr, valid);
> 1830             spin_unlock(cl_object_attr_guard(obj));

The word "_object" doesn't add any new information to the name.  If you
remove it then the code is improved.

		spin_lock(cl_attr_guard(obj));
		cl_attr_set(env, obj, attr, valid);
		spin_unlock(cl_attr_guard(obj));


regards,
dan carpenter

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ