summaryrefslogtreecommitdiff
path: root/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDriver.c
diff options
context:
space:
mode:
Diffstat (limited to 'MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDriver.c')
-rw-r--r--MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDriver.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDriver.c b/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDriver.c
index 05bdb5e..503c7cb 100644
--- a/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDriver.c
+++ b/MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDriver.c
@@ -257,17 +257,9 @@ Ip4ConfigDriverBindingStart (
Instance->NicIndex = Index;
if (Instance->NicAddr.Type == NET_IFTYPE_ETHERNET) {
- Instance->NicName[0] = 'e';
- Instance->NicName[1] = 't';
- Instance->NicName[2] = 'h';
- Instance->NicName[3] = (UINT16) ('0' + Index);
- Instance->NicName[4] = 0;
+ UnicodeSPrint (Instance->NicName, (UINTN) IP4_NIC_NAME_LENGTH, L"eth%d", Index);
} else {
- Instance->NicName[0] = 'u';
- Instance->NicName[1] = 'n';
- Instance->NicName[2] = 'k';
- Instance->NicName[3] = (UINT16) ('0' + Index);
- Instance->NicName[4] = 0;
+ UnicodeSPrint (Instance->NicName, (UINTN) IP4_NIC_NAME_LENGTH, L"unk%d", Index);
}
break;