Re: [PATCH net-next v2 1/2] net: macb: implement ethtool_ops.get|set_channels()
From: Jakub Kicinski <kuba@kernel.org>
Date: 2026-03-16 23:20:15
Also in:
lkml
From: Jakub Kicinski <kuba@kernel.org>
Date: 2026-03-16 23:20:15
Also in:
lkml
On Mon, 16 Mar 2026 17:24:28 +0100 Théo Lebrun wrote:
quoted
Sorry for the delay. This code can only be reached from the IOCTL path. The Netlink path will check that params haven't changed in ethnl_set_channels() (look at the @mod variable) and return 0 directly. So you're basically adding a discrepancy between ioctl and Netlink. Not a huge deal but I don't envy any user having to debug this..Actually, the IOCTL path also does the check (see below). So the `count == old_count` check shall be dropped from the driver .set_channels() callback because it is redundant. Agreed?
Oh, even better! Some of the ioctl paths don't validate the equivalence of the config but clearly I don't remember which.