[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170815224250.GA28337@fury>
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