All of lore.kernel.org
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Hongbo Li <lihongbo22@huawei.com>,
	davem@davemloft.net, edumazet@google.com,  kuba@kernel.org,
	pabeni@redhat.com, kvalo@kernel.org
Cc: linux-wireless@vger.kernel.org, netdev@vger.kernel.org
Subject: Re: [PATCH -next v2] wifi: mac80211: use max to simplify the code
Date: Tue, 27 Aug 2024 09:25:06 +0200	[thread overview]
Message-ID: <d5f495b67fe6bf128e7a51b9fcfe11f70c9b66ae.camel@sipsolutions.net> (raw)
In-Reply-To: <20240827030302.1006179-1-lihongbo22@huawei.com>

On Tue, 2024-08-27 at 11:03 +0800, Hongbo Li wrote:
> The following Coccinelle/coccicheck warning reported by
> minmax.cocci:
>     WARNING opportunity for max()

Yeah well, maybe sometimes we shouldn't blindly follow tools ...

> Let's use max() to simplify the code and fix the warning.

You should explain why.

I think only one out of four changes in this patch is correct,
semantically.

johannes

  reply	other threads:[~2024-08-27  7:25 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-27  3:03 [PATCH -next v2] wifi: mac80211: use max to simplify the code Hongbo Li
2024-08-27  7:25 ` Johannes Berg [this message]
2024-08-27  7:29   ` Hongbo Li
2024-08-27  7:39     ` Johannes Berg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d5f495b67fe6bf128e7a51b9fcfe11f70c9b66ae.camel@sipsolutions.net \
    --to=johannes@sipsolutions.net \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kuba@kernel.org \
    --cc=kvalo@kernel.org \
    --cc=lihongbo22@huawei.com \
    --cc=linux-wireless@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.