On 7/7/2025 1:58 AM, Jedrzej Jagielski wrote:
> Users of the ixgbe driver report that after adding devlink
> support by the commit a0285236ab93 ("ixgbe: add initial devlink support")
> their configs got broken due to unwanted changes of interfaces names.
> It's caused by changing names by devlink port initialization flow.
>
> To prevent from that set skip_phys_port_name_get flag for ixgbe
> devlink ports.
> I thought this had been discussed on other devices, and the consensus had been that this is not the kernel fault. > Reported-by: David Howells <[email protected]> > Closes: https://lkml.org/lkml/2025/4/24/2052 > Reported-by: David Kaplan <[email protected]> > Closes: https://www.spinics.net/lists/netdev/msg1099410.html > Suggested-by: Jakub Kicinski <[email protected]> > Acked-by: Przemek Kitszel <[email protected]> > Fixes: a0285236ab93 ("ixgbe: add initial devlink support") > Signed-off-by: Jedrzej Jagielski <[email protected]> > --- > v2: use new flag instead of creating blank implementation of > ndo_get_phys_port_name() > --- > drivers/net/ethernet/intel/ixgbe/devlink/devlink.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/net/ethernet/intel/ixgbe/devlink/devlink.c > b/drivers/net/ethernet/intel/ixgbe/devlink/devlink.c > index 54f1b83dfe42..47fae5035b9f 100644 > --- a/drivers/net/ethernet/intel/ixgbe/devlink/devlink.c > +++ b/drivers/net/ethernet/intel/ixgbe/devlink/devlink.c > @@ -543,6 +543,7 @@ int ixgbe_devlink_register_port(struct ixgbe_adapter > *adapter) > > attrs.flavour = DEVLINK_PORT_FLAVOUR_PHYSICAL; > attrs.phys.port_number = adapter->hw.bus.func; > + attrs.skip_phys_port_name_get = 1; The use of an attribute here is a lot nicer than filling in a custom ndo_get_phys_port_name() option, I agree. Reviewed-by: Jacob Keller <[email protected]> > ixgbe_devlink_set_switch_id(adapter, &attrs.switch_id); > > devlink_port_attrs_set(devlink_port, &attrs);
OpenPGP_signature.asc
Description: OpenPGP digital signature
