Search Linux Wireless

Re: [PATCH 0/4] ath10k: fix/cleanup fw stats

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

 



On Fri, 2014-09-26 at 13:14 +0200, Michal Kazior wrote:
> On 26 September 2014 13:06, Kalle Valo <kvalo@xxxxxxxxxxxxxxxx> wrote:
> > drivers/net/wireless/ath/ath10k/wmi.c:1513: WARNING: else is not generally useful after a break or return
> I'm aware of this one but the code looks nicer with the `else` to me though.

Yay Michal.

Always use your taste over any mindless style tool.

Ignore any checkpatch complaint you want.

btw: checkpatch shouldn't warn about this as of:

commit adefeef310ee8bd3923d41b67bc53c398bc53621
Author: Joe Perches <joe@xxxxxxxxxxx>
Date:   Fri Sep 26 10:19:29 2014 +1000

    checkpatch: add exception to return then else test
    
    Add an exception to the return before else warning
    when the line following it is also a return like:
    
        if (foo)
                return bar;
        else
                return baz;
    
    This form of a test then return is at least as readable as
    
        if (foo)
                return bar;
        return baz;
    
    so don't emit a warning on the first form.
    
    Signed-off-by: Joe Perches <joe@xxxxxxxxxxx>
    Reported-by: Al Viro <viro@xxxxxxxxxxxxxxxxxx>
    Cc: Elshad Mustafayev <elshadimo@xxxxxxxxx>
    Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>


--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux