Re: [PATCH] platform/x86: intel-hid: Power button suspend on Dell Latitude 7275

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Sep 25, 2017 at 01:57:48PM +0300, Andy Shevchenko wrote:
> On Sat, Sep 23, 2017 at 2:45 AM, Darren Hart <dvhart@xxxxxxxxxxxxx> wrote:
> > On Mon, Sep 18, 2017 at 12:57:12AM +0200, Jérôme de Bretagne wrote:
> 
> >> +             if (event == 0xce) {
> >> +                     input_report_key(priv->input_dev, KEY_POWER, 1);
> >> +                     input_sync(priv->input_dev);
> >> +                     return;
> >> +             } else if (event == 0xcf)
> >> +                     return;
> >
> > Minor CodingStyle nit. If the if block uses parens, so does the else block. In
> > this case, since the if returns, just skip the else entirely.
> >
> > See Documentation/process/coding-style.rst
> > The example immediatley *before* 3.1) Spaces.
> >
> > I've made this change and queued for testing.
> >
> >> +     }
> 
> Actually in this case even 'else' is redundant.

Yes, this is what I meant above by "skip the else entirely", and is the
change I made prior to committing. I was just pointing out the coding
style at the same time :-)

-- 
Darren Hart
VMware Open Source Technology Center
--
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux