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] [thread-next>] [day] [month] [year] [list]
Message-Id: <9651D503-F2D9-4FE0-9593-8D204360C258@linux.dev>
Date: Wed, 10 Dec 2025 16:48:08 +0100
From: Thorsten Blum <thorsten.blum@...ux.dev>
To: Jarkko Sakkinen <jarkko@...nel.org>
Cc: Dave Hansen <dave.hansen@...ux.intel.com>,
 Thomas Gleixner <tglx@...utronix.de>,
 Ingo Molnar <mingo@...hat.com>,
 Borislav Petkov <bp@...en8.de>,
 x86@...nel.org,
 "H. Peter Anvin" <hpa@...or.com>,
 linux-sgx@...r.kernel.org,
 linux-kernel@...r.kernel.org
Subject: Re: [PATCH] x86/sgx: Use goto to remove redundant if check in
 sgx_encl_init

On 10. Dec 2025, at 16:32, Jarkko Sakkinen wrote:
> On Wed, Dec 10, 2025 at 02:00:35PM +0100, Thorsten Blum wrote:
>> Immediately break out of both loops when 'ret != SGX_UNMASKED_EVENT'
>> instead of checking for the same condition again in the outer loop.
>> 
>> Signed-off-by: Thorsten Blum <thorsten.blum@...ux.dev>
>> ---
>> [...]
> 
> I don't think moving code around is very useful.

The patch doesn't actually move any code around, but it removes up to 50
(SGX_EINIT_SLEEP_COUNT) duplicate and therefore unnecessary if checks in
the outer for loop.

Thanks,
Thorsten


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ