lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5518ba7f-80b4-43f1-a5c1-eb8298170e9a@nvidia.com>
Date: Thu, 25 Sep 2025 16:13:42 -0500
From: Dan Jurgens <danielj@...dia.com>
To: "Michael S. Tsirkin" <mst@...hat.com>
Cc: netdev@...r.kernel.org, jasowang@...hat.com, alex.williamson@...hat.com,
 pabeni@...hat.com, virtualization@...ts.linux.dev, parav@...dia.com,
 shshitrit@...dia.com, yohadt@...dia.com, xuanzhuo@...ux.alibaba.com,
 eperezma@...hat.com, shameerali.kolothum.thodi@...wei.com, jgg@...pe.ca,
 kevin.tian@...el.com, kuba@...nel.org, andrew+netdev@...n.ch,
 edumazet@...gle.com
Subject: Re: [PATCH net-next v3 08/11] virtio_net: Implement IPv4 ethtool flow
 rules

On 9/25/25 3:53 PM, Michael S. Tsirkin wrote:
> On Tue, Sep 23, 2025 at 09:19:17AM -0500, Daniel Jurgens wrote:
>> Add support for IP_USER type rules from ethtool.
>>
>> +static
>> +struct virtio_net_ff_selector *next_selector(struct virtio_net_ff_selector *sel)
>> +{
>> +	void *nextsel;
>> +
>> +	nextsel = (u8 *)sel + sizeof(struct virtio_net_ff_selector) +
>> +		  sel->length;
> 
> you do not need this variable. and cast to void* looks cleaner imho.

It's cast to u8* so we do pointer arithmetic in bytes, which is not
standard C on void*. GCC doesn't mind, but I thing Clang does.

I saw you had a similar comment on a subsequent too.>
>> +
>> +	return nextsel;
>> +}
>> +



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ