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]
Date:   Tue, 15 Aug 2017 15:42:50 -0700
From:   Darren Hart <dvhart@...radead.org>
To:     Andy Shevchenko <andy.shevchenko@...il.com>
Cc:     Hao Wei Tee <angelsl@...4.sg>,
        Platform Driver <platform-driver-x86@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        Andy Shevchenko <andy@...radead.org>,
        Ike Panhc <ike.pan@...onical.com>
Subject: Re: [PATCH v2] platform/x86: ideapad-laptop: Expose conservation
 mode switch

On Mon, Aug 14, 2017 at 06:32:48PM +0300, Andy Shevchenko wrote:
> On Mon, Aug 14, 2017 at 5:17 PM, Hao Wei Tee <angelsl@...4.sg> wrote:
> > +static int method_gbmd(acpi_handle handle, unsigned long *ret)
> > +{
> > +       int val;
> > +       int result = read_method_int(handle, "GBMD", &val);
> 
> Reversed X-mas tree order in new code, please.

Generally yes, but of here they are using &val in the second initializer.

So either as is or:

int result;
int val;

result = read_method_int(handle, "GBMD", &val)

I tend to accept it as is when there is a declaration order dependency like
this.

-- 
Darren Hart
VMware Open Source Technology Center

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ