Quoting Alexander Duyck (2021-02-08 22:43:39) > On Mon, Feb 8, 2021 at 9:19 AM Antoine Tenart <aten...@kernel.org> wrote: > > > > -static void clean_xps_maps(struct net_device *dev, const unsigned long > > *mask, > > +static void clean_xps_maps(struct net_device *dev, > > struct xps_dev_maps *dev_maps, u16 offset, u16 > > count, > > bool is_rxqs_map) > > { > > - unsigned int nr_ids = dev_maps->nr_ids; > > bool active = false; > > int i, j; > > > > - for (j = -1; j = netif_attrmask_next(j, mask, nr_ids), j < nr_ids;) > > - active |= remove_xps_queue_cpu(dev, dev_maps, j, offset, > > - count); > > + for (j = 0; j < dev_maps->nr_ids; j++) > > + active |= remove_xps_queue_cpu(dev, dev_maps, j, offset, > > count); > > if (!active) > > reset_xps_maps(dev, dev_maps, is_rxqs_map); > > > > - if (!is_rxqs_map) { > > - for (i = offset + (count - 1); count--; i--) { > > + if (!is_rxqs_map) > > + for (i = offset + (count - 1); count--; i--) > > netdev_queue_numa_node_write( > > - netdev_get_tx_queue(dev, i), > > - NUMA_NO_NODE); > > - } > > - } > > + netdev_get_tx_queue(dev, i), NUMA_NO_NODE); > > } > > This violates the coding-style guide for the kernel. The if statement > should still have braces as the for loop and > netdev_queue_numa_node_write are more than a single statement. I'd be > curious to see if checkpatch also complains about this because it > probably should.
You're right, I'll remove that change to comply with the coding style. I reran checkpatch, even with --strict, and it did not complain. Maybe because it's a rework, not strictly new code. Thanks, Antoine