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: <30356.1274269677@redhat.com>
Date:	Wed, 19 May 2010 12:47:57 +0100
From:	David Howells <dhowells@...hat.com>
To:	Michel Lespinasse <walken@...gle.com>
Cc:	dhowells@...hat.com,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	Ingo Molnar <mingo@...e.hu>,
	Thomas Gleixner <tglx@...utronix.de>,
	LKML <linux-kernel@...r.kernel.org>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Mike Waychison <mikew@...gle.com>,
	Suleiman Souhlal <suleiman@...gle.com>,
	Ying Han <yinghan@...gle.com>
Subject: Re: [PATCH 01/10] x86 rwsem: minor cleanups

Michel Lespinasse <walken@...gle.com> wrote:

> The only functional change here is that __up_write won't call
> call_rwsem_wake anymore if the new rwsem value is >0. This makes
> no real difference since call_rwsem_wake would have noticed the
> active count being nonzero and done nothing anyway.

Given that you describe this first, this would suggest that the subject of the
patch should be this.  I'm not sure I'd count this as a minor cleanup.  I think
I'd split it into its own patch.

> Besides that, I clarified a few comments.

Mostly okay, except where you said "expects old value in %edx" - that's only
true on i386, not x86_64.  On the latter it would be %rdi.  However, I can live
with that: it's true enough.

> -	rwsem_count_t tmp;
> +	rwsem_count_t tmp = -RWSEM_ACTIVE_WRITE_BIAS;
> ...
>  		     : "+m" (sem->count), "=d" (tmp)
> -		     : "a" (sem), "1" (-RWSEM_ACTIVE_WRITE_BIAS)
> +		     : "a" (sem), "1" (tmp)

If you're going to put the initialisation of EDX/RDI on tmp (which isn't really
necessary), rather than directly on the asm statement, you could change the
'"=d" (tmp)' output constraint to be '"+d" (tmp)' and drop the '"1" (tmp)'
constraint entirely.

However, apart from that, feel free to add my Acked-by to this patch or its
split resultant patches.

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