Re: Is it possible to undo the ixgbe device name change?
From: Andrew Lunn
Date: Thu Apr 24 2025 - 17:32:32 EST
On Thu, Apr 24, 2025 at 07:06:56PM +0100, David Howells wrote:
> [resent with mailing list addresses fixes]
>
> Hi,
>
> With commit:
>
> a0285236ab93fdfdd1008afaa04561d142d6c276
> ixgbe: add initial devlink support
>
> the name of the device that I see on my 10G ethernet card changes from enp1s0
> to enp1s0np0.
Are you sure this patch is directly responsible? Looking at the patch
i see:
@@ -11617,6 +11626,11 @@ static int ixgbe_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
}
strcpy(netdev->name, "eth%d");
pci_set_drvdata(pdev, adapter);
+
+ devl_lock(adapter->devlink);
+ ixgbe_devlink_register_port(adapter);
+ SET_NETDEV_DEVLINK_PORT(adapter->netdev, &adapter->devlink_port);
+
Notice the context, not the change. The interface is being called
eth%d, which is normal. The kernel will replace the %d with a unique
number. So the kernel will call it eth42 or something. You should see
this in dmesg.
It is systemd which later renames it to enp1s0 or enp1s0np0. If you
ask me, you are talking to the wrong people.
Andrew