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: <20170622093957.vlhacauj4vff64bv@e106622-lin>
Date:   Thu, 22 Jun 2017 10:39:57 +0100
From:   Juri Lelli <juri.lelli@....com>
To:     Viresh Kumar <viresh.kumar@...aro.org>
Cc:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        linux-arm-kernel@...ts.infradead.org,
        Catalin Marinas <catalin.marinas@....com>,
        linux@....linux.org.uk, Will Deacon <will.deacon@....com>,
        Vincent Guittot <vincent.guittot@...aro.org>,
        arnd.bergmann@...aro.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH V2 4/5] arch_topology: Return 0 or -ve errors from
 topology_parse_cpu_capacity()

Hi,

On 21/06/17 10:16, Viresh Kumar wrote:
> Use the standard way of returning errors instead of returning 0(failure)
> OR 1(success) and making it hard to read.
> 
> Signed-off-by: Viresh Kumar <viresh.kumar@...aro.org>
> ---
>  arch/arm/kernel/topology.c   | 2 +-
>  drivers/base/arch_topology.c | 8 ++++----
>  2 files changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/arch/arm/kernel/topology.c b/arch/arm/kernel/topology.c
> index bf949a763dbe..a7ef4c35855e 100644
> --- a/arch/arm/kernel/topology.c
> +++ b/arch/arm/kernel/topology.c
> @@ -111,7 +111,7 @@ static void __init parse_dt_topology(void)
>  			continue;
>  		}
>  
> -		if (topology_parse_cpu_capacity(cn, cpu)) {
> +		if (!topology_parse_cpu_capacity(cn, cpu)) {

Not sure why you want to change this.

I currently read it as "if cpu_capacity parsing succedeed" continue with
next CPU, otherwise we set cap_from_dt to false and fall back to using
efficiencies.

Thanks,

- Juri

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ