netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: guoren@kernel.org
Cc: andriy.shevchenko@linux.intel.com, davem@davemloft.net,
	edumazet@google.com, pabeni@redhat.com, linux@rasmusvillemoes.dk,
	yury.norov@gmail.com, caraitto@google.com, willemb@google.com,
	jonolson@google.com, amritha.nambiar@intel.com,
	linux-kernel@vger.kernel.org, netdev@vger.kernel.org,
	Guo Ren <guoren@linux.alibaba.com>
Subject: Re: [PATCH V2 1/2] net: Fixup netif_attrmask_next_and warning
Date: Thu, 13 Oct 2022 20:35:44 -0700	[thread overview]
Message-ID: <20221013203544.110a143c@kernel.org> (raw)
In-Reply-To: <20221014030459.3272206-2-guoren@kernel.org>

On Thu, 13 Oct 2022 23:04:58 -0400 guoren@kernel.org wrote:
> -	for (j = -1; j = netif_attrmask_next_and(j, online_mask, mask, nr_ids),
> -	     j < nr_ids;) {
> +	for (j = -1; j < nr_ids;
> +	     j = netif_attrmask_next_and(j, online_mask, mask, nr_ids)) {

This does not look equivalent, have you tested it?

nr_ids is unsigned, doesn't it mean we'll never enter the loop?

Can we instead revert 854701ba4c and take the larger rework Yury 
has posted a week ago into net-next?

  reply	other threads:[~2022-10-14  3:35 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-14  3:04 [PATCH V2 0/2] net: Fixup cpu_mask usage guoren
2022-10-14  3:04 ` [PATCH V2 1/2] net: Fixup netif_attrmask_next_and warning guoren
2022-10-14  3:35   ` Jakub Kicinski [this message]
2022-10-14  3:39     ` Jakub Kicinski
2022-10-14  4:42       ` Yury Norov
2022-10-14  6:42         ` Guo Ren
2022-10-14 16:03         ` Jakub Kicinski
2022-10-14 16:16           ` Yury Norov
2022-10-14 18:03             ` Jakub Kicinski
2022-10-15  1:41           ` Guo Ren
2022-10-14  6:38     ` Guo Ren
2022-10-14 15:52       ` Jakub Kicinski
2022-10-15  1:38         ` Guo Ren
2022-10-14 10:00   ` Andy Shevchenko
2022-10-14 10:04     ` Guo Ren
2022-10-14  3:04 ` [PATCH V2 2/2] net: Fixup virtnet_set_affinity() cause cpumask warning guoren
2022-10-14 10:00   ` Andy Shevchenko
2022-10-14 10:04     ` Guo Ren
2022-10-17  1:58   ` Xuan Zhuo
2022-10-17  2:46     ` Guo Ren
2022-10-17  2:58       ` Xuan Zhuo

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=20221013203544.110a143c@kernel.org \
    --to=kuba@kernel.org \
    --cc=amritha.nambiar@intel.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=caraitto@google.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=guoren@kernel.org \
    --cc=guoren@linux.alibaba.com \
    --cc=jonolson@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@rasmusvillemoes.dk \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=willemb@google.com \
    --cc=yury.norov@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).