Lines Matching +full:vendor +full:- +full:extension
1 /*-
40 #include "efi-osdep.h"
41 #include "efivar-dp.h"
43 #include "uefi-dplib.h"
45 /* XXX STUBS -- this stuff doesn't work yet */
64 Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
65 SPDX-License-Identifier: BSD-2-Clause-Patent
161 Gets current sub-string from a string list, before return
162 the list header is moved to next sub-string. The sub-string is separated
169 @return A pointer to the current sub-string
202 // Find a sub-string, terminate it in SplitStr()
209 // Move to next sub-string in SplitStr()
221 @return A pointer to the current sub-string
290 ParenthesesStack--; in GetNextDeviceNodeStr()
532 Pci->Function = (UINT8)Strtoi (FunctionStr); in DevPathFromTextPci()
533 Pci->Device = (UINT8)Strtoi (DeviceStr); in DevPathFromTextPci()
562 Pccard->FunctionNumber = (UINT8)Strtoi (FunctionNumberStr); in DevPathFromTextPcCard()
595 MemMap->MemoryType = (UINT32)Strtoi (MemoryTypeStr); in DevPathFromTextMemoryMapped()
596 Strtoi64 (StartingAddressStr, &MemMap->StartingAddress); in DevPathFromTextMemoryMapped()
597 Strtoi64 (EndingAddressStr, &MemMap->EndingAddress); in DevPathFromTextMemoryMapped()
603 Converts a text device path node to Vendor device path structure based on the input Type
610 @return A pointer to the newly-created Vendor device path structure.
624 VENDOR_DEVICE_PATH *Vendor; in ConvertFromTextVendor() local
635 Vendor = (VENDOR_DEVICE_PATH *)CreateDeviceNode ( in ConvertFromTextVendor()
641 StrToGuid (GuidStr, &Vendor->Guid); in ConvertFromTextVendor()
642 StrHexToBytes (DataStr, Length * 2, (UINT8 *)(Vendor + 1), Length); in ConvertFromTextVendor()
644 return (EFI_DEVICE_PATH_PROTOCOL *)Vendor; in ConvertFromTextVendor()
648 Converts a text device path node to Vendor Hardware device path structure.
652 @return A pointer to the newly-created Vendor Hardware device path structure.
673 @return A pointer to the newly-created Hardware Controller device path structure.
691 Controller->ControllerNumber = (UINT32)Strtoi (ControllerStr); in DevPathFromTextCtrl()
701 @return A pointer to the newly-created BMC device path structure.
722 BmcDp->InterfaceType = (UINT8)Strtoi (InterfaceTypeStr); in DevPathFromTextBmc()
724 (UINT64 *)(&BmcDp->BaseAddress), in DevPathFromTextBmc()
761 return (((Text[0] - 'A' + 1) & 0x1f) << 10) in EisaIdFromText()
762 + (((Text[1] - 'A' + 1) & 0x1f) << 5) in EisaIdFromText()
763 + (((Text[2] - 'A' + 1) & 0x1f) << 0) in EisaIdFromText()
773 @return A pointer to the newly-created ACPI HID device path structure.
794 Acpi->HID = EisaIdFromText (HIDStr); in DevPathFromTextAcpi()
795 Acpi->UID = (UINT32)Strtoi (UIDStr); in DevPathFromTextAcpi()
806 @return A pointer to the newly-created ACPI HID device path structure.
826 Acpi->HID = EFI_PNP_ID (PnPId); in ConvertFromTextAcpi()
827 Acpi->UID = (UINT32)Strtoi (UIDStr); in ConvertFromTextAcpi()
837 @return A pointer to the newly-created PCI root device path structure.
854 @return A pointer to the newly-created PCIE root device path structure.
871 @return A pointer to the newly-created Floppy device path structure.
888 @return A pointer to the newly-created Keyboard device path structure.
905 @return A pointer to the newly-created Serial device path structure.
922 @return A pointer to the newly-created Parallel Port device path structure.
935 Converts a text device path node to ACPI extension device path structure.
939 @return A pointer to the newly-created ACPI extension device path structure.
974 AcpiEx->HID = EisaIdFromText (HIDStr); in DevPathFromTextAcpiEx()
975 AcpiEx->CID = EisaIdFromText (CIDStr); in DevPathFromTextAcpiEx()
976 AcpiEx->UID = (UINT32)Strtoi (UIDStr); in DevPathFromTextAcpiEx()
987 Converts a text device path node to ACPI extension device path structure.
991 @return A pointer to the newly-created ACPI extension device path structure.
1017 AcpiEx->HID = EisaIdFromText (HIDStr); in DevPathFromTextAcpiExp()
1021 // Set the CID to 0 in the ACPI extension device path structure. in DevPathFromTextAcpiExp()
1024 AcpiEx->CID = 0; in DevPathFromTextAcpiExp()
1026 AcpiEx->CID = EisaIdFromText (CIDStr); in DevPathFromTextAcpiExp()
1029 AcpiEx->UID = 0; in DevPathFromTextAcpiExp()
1054 @return A pointer to the newly-created ACPI _ADR device path structure.
1092 (&AcpiAdr->ADR)[Index] = (UINT32)Strtoi (DisplayDeviceStr); in DevPathFromTextAcpiAdr()
1120 @return A pointer to the newly-created Parallel Port device path structure.
1145 Atapi->PrimarySecondary = 0; in DevPathFromTextAta()
1147 Atapi->PrimarySecondary = 1; in DevPathFromTextAta()
1149 Atapi->PrimarySecondary = (UINT8)Strtoi (PrimarySecondaryStr); in DevPathFromTextAta()
1153 Atapi->SlaveMaster = 0; in DevPathFromTextAta()
1155 Atapi->SlaveMaster = 1; in DevPathFromTextAta()
1157 Atapi->SlaveMaster = (UINT8)Strtoi (SlaveMasterStr); in DevPathFromTextAta()
1160 Atapi->Lun = (UINT16)Strtoi (LunStr); in DevPathFromTextAta()
1170 @return A pointer to the newly-created SCSI device path structure.
1191 Scsi->Pun = (UINT16)Strtoi (PunStr); in DevPathFromTextScsi()
1192 Scsi->Lun = (UINT16)Strtoi (LunStr); in DevPathFromTextScsi()
1202 @return A pointer to the newly-created Fibre device path structure.
1223 Fibre->Reserved = 0; in DevPathFromTextFibre()
1224 Strtoi64 (WWNStr, &Fibre->WWN); in DevPathFromTextFibre()
1225 Strtoi64 (LunStr, &Fibre->Lun); in DevPathFromTextFibre()
1235 @return A pointer to the newly-created FibreEx device path structure.
1256 FibreEx->Reserved = 0; in DevPathFromTextFibreEx()
1257 Strtoi64 (WWNStr, (UINT64 *)(&FibreEx->WWN)); in DevPathFromTextFibreEx()
1258 Strtoi64 (LunStr, (UINT64 *)(&FibreEx->Lun)); in DevPathFromTextFibreEx()
1260 *(UINT64 *)(&FibreEx->WWN) = SwapBytes64 (*(UINT64 *)(&FibreEx->WWN)); in DevPathFromTextFibreEx()
1261 *(UINT64 *)(&FibreEx->Lun) = SwapBytes64 (*(UINT64 *)(&FibreEx->Lun)); in DevPathFromTextFibreEx()
1271 @return A pointer to the newly-created 1394 device path structure.
1290 F1394DevPath->Reserved = 0; in DevPathFromText1394()
1291 F1394DevPath->Guid = StrHexToUint64 (GuidStr); in DevPathFromText1394()
1301 @return A pointer to the newly-created USB device path structure.
1322 Usb->ParentPortNumber = (UINT8)Strtoi (PortStr); in DevPathFromTextUsb()
1323 Usb->InterfaceNumber = (UINT8)Strtoi (InterfaceStr); in DevPathFromTextUsb()
1333 @return A pointer to the newly-created I20 device path structure.
1352 I2ODevPath->Tid = (UINT32)Strtoi (TIDStr); in DevPathFromTextI2O()
1362 @return A pointer to the newly-created Infini Band device path structure.
1389 InfiniBand->ResourceFlags = (UINT32)Strtoi (FlagsStr); in DevPathFromTextInfiniband()
1390 StrToGuid (GuidStr, (EFI_GUID *)InfiniBand->PortGid); in DevPathFromTextInfiniband()
1391 Strtoi64 (SidStr, &InfiniBand->ServiceId); in DevPathFromTextInfiniband()
1392 Strtoi64 (TidStr, &InfiniBand->TargetPortId); in DevPathFromTextInfiniband()
1393 Strtoi64 (DidStr, &InfiniBand->DeviceId); in DevPathFromTextInfiniband()
1399 Converts a text device path node to Vendor-Defined Messaging device path structure.
1403 @return A pointer to the newly-created Vendor-Defined Messaging device path structure.
1420 Converts a text device path node to Vendor defined PC-ANSI device path structure.
1424 @return A pointer to the newly-created Vendor defined PC-ANSI device path structure.
1433 VENDOR_DEVICE_PATH *Vendor; in DevPathFromTextVenPcAnsi() local
1435 Vendor = (VENDOR_DEVICE_PATH *)CreateDeviceNode ( in DevPathFromTextVenPcAnsi()
1440 CopyGuid (&Vendor->Guid, &gEfiPcAnsiGuid); in DevPathFromTextVenPcAnsi()
1442 return (EFI_DEVICE_PATH_PROTOCOL *)Vendor; in DevPathFromTextVenPcAnsi()
1446 Converts a text device path node to Vendor defined VT100 device path structure.
1450 @return A pointer to the newly-created Vendor defined VT100 device path structure.
1459 VENDOR_DEVICE_PATH *Vendor; in DevPathFromTextVenVt100() local
1461 Vendor = (VENDOR_DEVICE_PATH *)CreateDeviceNode ( in DevPathFromTextVenVt100()
1466 CopyGuid (&Vendor->Guid, &gEfiVT100Guid); in DevPathFromTextVenVt100()
1468 return (EFI_DEVICE_PATH_PROTOCOL *)Vendor; in DevPathFromTextVenVt100()
1472 Converts a text device path node to Vendor defined VT100 Plus device path structure.
1476 @return A pointer to the newly-created Vendor defined VT100 Plus device path structure.
1485 VENDOR_DEVICE_PATH *Vendor; in DevPathFromTextVenVt100Plus() local
1487 Vendor = (VENDOR_DEVICE_PATH *)CreateDeviceNode ( in DevPathFromTextVenVt100Plus()
1492 CopyGuid (&Vendor->Guid, &gEfiVT100PlusGuid); in DevPathFromTextVenVt100Plus()
1494 return (EFI_DEVICE_PATH_PROTOCOL *)Vendor; in DevPathFromTextVenVt100Plus()
1498 Converts a text device path node to Vendor defined UTF8 device path structure.
1502 @return A pointer to the newly-created Vendor defined UTF8 device path structure.
1511 VENDOR_DEVICE_PATH *Vendor; in DevPathFromTextVenUtf8() local
1513 Vendor = (VENDOR_DEVICE_PATH *)CreateDeviceNode ( in DevPathFromTextVenUtf8()
1518 CopyGuid (&Vendor->Guid, &gEfiVTUTF8Guid); in DevPathFromTextVenUtf8()
1520 return (EFI_DEVICE_PATH_PROTOCOL *)Vendor; in DevPathFromTextVenUtf8()
1528 @return A pointer to the newly-created UART Flow Control device path structure.
1547 CopyGuid (&UartFlowControl->Guid, &gEfiUartDevicePathGuid); in DevPathFromTextUartFlowCtrl()
1549 UartFlowControl->FlowControlMap = 2; in DevPathFromTextUartFlowCtrl()
1551 UartFlowControl->FlowControlMap = 1; in DevPathFromTextUartFlowCtrl()
1553 UartFlowControl->FlowControlMap = 0; in DevPathFromTextUartFlowCtrl()
1564 @return A pointer to the newly-created Serial Attached SCSI device path structure.
1599 CopyGuid (&Sas->Guid, &gEfiSasDevicePathGuid); in DevPathFromTextSAS()
1600 Strtoi64 (AddressStr, &Sas->SasAddress); in DevPathFromTextSAS()
1601 Strtoi64 (LunStr, &Sas->Lun); in DevPathFromTextSAS()
1602 Sas->RelativeTargetPort = (UINT16)Strtoi (RTPStr); in DevPathFromTextSAS()
1611 Info = (UINT16)(0x2 | ((Uint16 - 1) << 8)); in DevPathFromTextSAS()
1649 Sas->DeviceTopology = Info; in DevPathFromTextSAS()
1650 Sas->Reserved = (UINT32)Strtoi (ReservedStr); in DevPathFromTextSAS()
1660 @return A pointer to the newly-created Serial Attached SCSI Ex device path structure.
1697 WriteUnaligned64 ((UINT64 *)&SasEx->SasAddress, SwapBytes64 (SasAddress)); in DevPathFromTextSasEx()
1698 WriteUnaligned64 ((UINT64 *)&SasEx->Lun, SwapBytes64 (Lun)); in DevPathFromTextSasEx()
1699 SasEx->RelativeTargetPort = (UINT16)Strtoi (RTPStr); in DevPathFromTextSasEx()
1708 Info = (UINT16)(0x2 | ((Uint16 - 1) << 8)); in DevPathFromTextSasEx()
1746 SasEx->DeviceTopology = Info; in DevPathFromTextSasEx()
1756 @return A pointer to the newly-created NVM Express Namespace device path structure.
1779 Nvme->NamespaceId = (UINT32)Strtoi (NamespaceIdStr); in DevPathFromTextNVMe()
1780 Uuid = (UINT8 *)&Nvme->NamespaceUuid; in DevPathFromTextNVMe()
1782 Index = sizeof (Nvme->NamespaceUuid) / sizeof (UINT8); in DevPathFromTextNVMe()
1783 while (Index-- != 0) { in DevPathFromTextNVMe()
1784 Uuid[Index] = (UINT8)StrHexToUintn (SplitStr (&NamespaceUuidStr, '-')); in DevPathFromTextNVMe()
1795 @return A pointer to the newly-created UFS device path structure.
1816 Ufs->Pun = (UINT8)Strtoi (PunStr); in DevPathFromTextUfs()
1817 Ufs->Lun = (UINT8)Strtoi (LunStr); in DevPathFromTextUfs()
1827 @return A pointer to the newly-created SD device path structure.
1846 Sd->SlotNumber = (UINT8)Strtoi (SlotNumberStr); in DevPathFromTextSd()
1856 @return A pointer to the newly-created EMMC device path structure.
1875 Emmc->SlotNumber = (UINT8)Strtoi (SlotNumberStr); in DevPathFromTextEmmc()
1885 @return A pointer to the newly-created Debug Port device path structure.
1902 CopyGuid (&Vend->Guid, &gEfiDebugPortProtocolGuid); in DevPathFromTextDebugPort()
1912 @return A pointer to the newly-created MAC device path structure.
1934 MACDevPath->IfType = (UINT8)Strtoi (IfTypeStr); in DevPathFromTextMAC()
1937 if ((MACDevPath->IfType == 0x01) || (MACDevPath->IfType == 0x00)) { in DevPathFromTextMAC()
1941 StrHexToBytes (AddressStr, Length * 2, MACDevPath->MacAddress.Addr, Length); in DevPathFromTextMAC()
1976 @return A pointer to the newly-created IPV4 device path structure.
2005 StrToIpv4Address (RemoteIPStr, NULL, &IPv4->RemoteIpAddress, NULL); in DevPathFromTextIPv4()
2006 IPv4->Protocol = (UINT16)NetworkProtocolFromText (ProtocolStr); in DevPathFromTextIPv4()
2008 IPv4->StaticIpAddress = TRUE; in DevPathFromTextIPv4()
2010 IPv4->StaticIpAddress = FALSE; in DevPathFromTextIPv4()
2013 StrToIpv4Address (LocalIPStr, NULL, &IPv4->LocalIpAddress, NULL); in DevPathFromTextIPv4()
2015 StrToIpv4Address (GatewayIPStr, NULL, &IPv4->GatewayIpAddress, NULL); in DevPathFromTextIPv4()
2016 StrToIpv4Address (SubnetMaskStr, NULL, &IPv4->SubnetMask, NULL); in DevPathFromTextIPv4()
2018 ZeroMem (&IPv4->GatewayIpAddress, sizeof (IPv4->GatewayIpAddress)); in DevPathFromTextIPv4()
2019 ZeroMem (&IPv4->SubnetMask, sizeof (IPv4->SubnetMask)); in DevPathFromTextIPv4()
2022 IPv4->LocalPort = 0; in DevPathFromTextIPv4()
2023 IPv4->RemotePort = 0; in DevPathFromTextIPv4()
2033 @return A pointer to the newly-created IPV6 device path structure.
2062 StrToIpv6Address (RemoteIPStr, NULL, &IPv6->RemoteIpAddress, NULL); in DevPathFromTextIPv6()
2063 IPv6->Protocol = (UINT16)NetworkProtocolFromText (ProtocolStr); in DevPathFromTextIPv6()
2065 IPv6->IpAddressOrigin = 0; in DevPathFromTextIPv6()
2067 IPv6->IpAddressOrigin = 1; in DevPathFromTextIPv6()
2069 IPv6->IpAddressOrigin = 2; in DevPathFromTextIPv6()
2072 StrToIpv6Address (LocalIPStr, NULL, &IPv6->LocalIpAddress, NULL); in DevPathFromTextIPv6()
2074 StrToIpv6Address (GatewayIPStr, NULL, &IPv6->GatewayIpAddress, NULL); in DevPathFromTextIPv6()
2075 IPv6->PrefixLength = (UINT8)Strtoi (PrefixLengthStr); in DevPathFromTextIPv6()
2077 ZeroMem (&IPv6->GatewayIpAddress, sizeof (IPv6->GatewayIpAddress)); in DevPathFromTextIPv6()
2078 IPv6->PrefixLength = 0; in DevPathFromTextIPv6()
2081 IPv6->LocalPort = 0; in DevPathFromTextIPv6()
2082 IPv6->RemotePort = 0; in DevPathFromTextIPv6()
2092 @return A pointer to the newly-created UART device path structure.
2118 Uart->BaudRate = 115200; in DevPathFromTextUart()
2120 Strtoi64 (BaudStr, &Uart->BaudRate); in DevPathFromTextUart()
2123 Uart->DataBits = (UINT8)((StrCmp (DataBitsStr, "DEFAULT") == 0) ? 8 : Strtoi (DataBitsStr)); in DevPathFromTextUart()
2126 Uart->Parity = 0; in DevPathFromTextUart()
2130 Uart->Parity = 1; in DevPathFromTextUart()
2134 Uart->Parity = 2; in DevPathFromTextUart()
2138 Uart->Parity = 3; in DevPathFromTextUart()
2142 Uart->Parity = 4; in DevPathFromTextUart()
2146 Uart->Parity = 5; in DevPathFromTextUart()
2150 Uart->Parity = (UINT8)Strtoi (ParityStr); in DevPathFromTextUart()
2155 Uart->StopBits = (UINT8)0; in DevPathFromTextUart()
2157 Uart->StopBits = (UINT8)1; in DevPathFromTextUart()
2159 Uart->StopBits = (UINT8)2; in DevPathFromTextUart()
2161 Uart->StopBits = (UINT8)3; in DevPathFromTextUart()
2163 Uart->StopBits = (UINT8)Strtoi (StopBitsStr); in DevPathFromTextUart()
2175 @return A pointer to the newly-created USB class device path structure.
2200 if (UsbClassText->ClassExist) { in ConvertFromTextUsbClass()
2203 UsbClass->DeviceClass = 0xFF; in ConvertFromTextUsbClass()
2205 UsbClass->DeviceClass = (UINT8)Strtoi (ClassStr); in ConvertFromTextUsbClass()
2208 UsbClass->DeviceClass = UsbClassText->Class; in ConvertFromTextUsbClass()
2211 if (UsbClassText->SubClassExist) { in ConvertFromTextUsbClass()
2214 UsbClass->DeviceSubClass = 0xFF; in ConvertFromTextUsbClass()
2216 UsbClass->DeviceSubClass = (UINT8)Strtoi (SubClassStr); in ConvertFromTextUsbClass()
2219 UsbClass->DeviceSubClass = UsbClassText->SubClass; in ConvertFromTextUsbClass()
2225 UsbClass->VendorId = 0xFFFF; in ConvertFromTextUsbClass()
2227 UsbClass->VendorId = (UINT16)Strtoi (VIDStr); in ConvertFromTextUsbClass()
2231 UsbClass->ProductId = 0xFFFF; in ConvertFromTextUsbClass()
2233 UsbClass->ProductId = (UINT16)Strtoi (PIDStr); in ConvertFromTextUsbClass()
2237 UsbClass->DeviceProtocol = 0xFF; in ConvertFromTextUsbClass()
2239 UsbClass->DeviceProtocol = (UINT8)Strtoi (ProtocolStr); in ConvertFromTextUsbClass()
2250 @return A pointer to the newly-created USB class device path structure.
2272 @return A pointer to the newly-created USB audio device path structure.
2295 @return A pointer to the newly-created USB CDC Control device path structure.
2318 @return A pointer to the newly-created USB HID device path structure.
2341 @return A pointer to the newly-created USB Image device path structure.
2364 @return A pointer to the newly-created USB Print device path structure.
2387 @return A pointer to the newly-created USB mass storage device path structure.
2410 @return A pointer to the newly-created USB HUB device path structure.
2433 @return A pointer to the newly-created USB CDC data device path structure.
2456 @return A pointer to the newly-created USB smart card device path structure.
2479 @return A pointer to the newly-created USB video device path structure.
2502 @return A pointer to the newly-created USB diagnostic device path structure.
2525 @return A pointer to the newly-created USB wireless device path structure.
2548 @return A pointer to the newly-created USB device firmware update device path structure.
2572 @return A pointer to the newly-created USB IRDA bridge device path structure.
2596 @return A pointer to the newly-created USB text and measurement device path structure.
2620 @return A pointer to the newly-created USB WWID device path structure.
2643 (SerialNumberStr[SerialNumberStrLen - 1] == '\"') in DevPathFromTextUsbWwid()
2646 SerialNumberStr[SerialNumberStrLen - 1] = '\0'; in DevPathFromTextUsbWwid()
2648 SerialNumberStrLen -= 2; in DevPathFromTextUsbWwid()
2656 UsbWwid->VendorId = (UINT16)Strtoi (VIDStr); in DevPathFromTextUsbWwid()
2657 UsbWwid->ProductId = (UINT16)Strtoi (PIDStr); in DevPathFromTextUsbWwid()
2658 UsbWwid->InterfaceNumber = (UINT16)Strtoi (InterfaceNumStr); in DevPathFromTextUsbWwid()
2678 @return A pointer to the newly-created Logic Unit device path structure.
2697 LogicalUnit->Lun = (UINT8)Strtoi (LunStr); in DevPathFromTextUnit()
2707 @return A pointer to the newly-created iSCSI device path structure.
2741 AsciiStr = ISCSIDevPath->TargetName; in DevPathFromTextiSCSI()
2744 ISCSIDevPath->TargetPortalGroupTag = (UINT16)Strtoi (PortalGroupStr); in DevPathFromTextiSCSI()
2746 WriteUnaligned64 ((UINT64 *)&ISCSIDevPath->Lun, SwapBytes64 (Lun)); in DevPathFromTextiSCSI()
2765 ISCSIDevPath->LoginOption = (UINT16)Options; in DevPathFromTextiSCSI()
2768 ISCSIDevPath->NetworkProtocol = 0; in DevPathFromTextiSCSI()
2773 ISCSIDevPath->NetworkProtocol = 1; in DevPathFromTextiSCSI()
2784 @return A pointer to the newly-created VLAN device path structure.
2803 Vlan->VlanId = (UINT16)Strtoi (VlanStr); in DevPathFromTextVlan()
2813 @return A pointer to the newly-created Bluetooth device path structure.
2834 BluetoothDp->BD_ADDR.Address, in DevPathFromTextBluetooth()
2841 Converts a text device path node to Wi-Fi device path structure.
2845 @return A pointer to the newly-created Wi-Fi device path structure.
2874 CopyMem (WiFiDp->SSId, AsciiStr, DataLen); in DevPathFromTextWiFi()
2885 @return A pointer to the newly-created Bluetooth LE device path structure.
2906 BluetoothLeDp->Address.Type = (UINT8)Strtoi (BluetoothLeAddrTypeStr); in DevPathFromTextBluetoothLE()
2909 sizeof (BluetoothLeDp->Address.Address) * 2, in DevPathFromTextBluetoothLE()
2910 BluetoothLeDp->Address.Address, in DevPathFromTextBluetoothLE()
2911 sizeof (BluetoothLeDp->Address.Address) in DevPathFromTextBluetoothLE()
2921 @return A pointer to the newly-created DNS device path structure.
2984 DnsDeviceNode->IsIPv6 = 0x00; in DevPathFromTextDns()
2989 DnsDeviceNode->IsIPv6 = 0x01; in DevPathFromTextDns()
2998 if (DnsDeviceNode->IsIPv6 == 0x00) { in DevPathFromTextDns()
2999 … StrToIpv4Address (DnsServerIp, NULL, &(DnsDeviceNode->DnsServerIp[DnsServerIpIndex].v4), NULL); in DevPathFromTextDns()
3001 … StrToIpv6Address (DnsServerIp, NULL, &(DnsDeviceNode->DnsServerIp[DnsServerIpIndex].v6), NULL); in DevPathFromTextDns()
3013 @return A pointer to the newly-created URI device path structure.
3027 UriLength = StrnLenS (UriStr, MAX_UINT16 - sizeof (URI_DEVICE_PATH)); in DevPathFromTextUri()
3034 while (UriLength-- != 0) { in DevPathFromTextUri()
3035 Uri->Uri[UriLength] = (CHAR8)UriStr[UriLength]; in DevPathFromTextUri()
3063 @return A pointer to the newly-created HD device path structure.
3091 Hd->PartitionNumber = (UINT32)Strtoi (PartitionStr); in DevPathFromTextHD()
3093 ZeroMem (Hd->Signature, 16); in DevPathFromTextHD()
3094 Hd->MBRType = (UINT8)0; in DevPathFromTextHD()
3097 Hd->SignatureType = SIGNATURE_TYPE_MBR; in DevPathFromTextHD()
3098 Hd->MBRType = 0x01; in DevPathFromTextHD()
3101 CopyMem (Hd->Signature, &Signature32, sizeof (UINT32)); in DevPathFromTextHD()
3103 Hd->SignatureType = SIGNATURE_TYPE_GUID; in DevPathFromTextHD()
3104 Hd->MBRType = 0x02; in DevPathFromTextHD()
3106 StrToGuid (SignatureStr, (EFI_GUID *)Hd->Signature); in DevPathFromTextHD()
3108 Hd->SignatureType = (UINT8)Strtoi (TypeStr); in DevPathFromTextHD()
3111 Strtoi64 (StartStr, &Hd->PartitionStart); in DevPathFromTextHD()
3112 Strtoi64 (SizeStr, &Hd->PartitionSize); in DevPathFromTextHD()
3122 @return A pointer to the newly-created CDROM device path structure.
3145 CDROMDevPath->BootEntry = (UINT32)Strtoi (EntryStr); in DevPathFromTextCDROM()
3146 Strtoi64 (StartStr, &CDROMDevPath->PartitionStart); in DevPathFromTextCDROM()
3147 Strtoi64 (SizeStr, &CDROMDevPath->PartitionSize); in DevPathFromTextCDROM()
3153 Converts a text device path node to Vendor-defined media device path structure.
3157 @return A pointer to the newly-created Vendor-defined media device path structure.
3178 @return A pointer to the newly-created File device path structure.
3196 StrCpyS (File->PathName, StrLen (TextDeviceNode) + 1, TextDeviceNode); in DevPathFromTextFilePath()
3205 v = File->PathName; in DevPathFromTextFilePath()
3217 @return A pointer to the newly-created Media protocol device path structure.
3236 StrToGuid (GuidStr, &Media->Protocol); in DevPathFromTextMedia()
3246 @return A pointer to the newly-created firmware volume device path structure.
3265 StrToGuid (GuidStr, &Fv->FvName); in DevPathFromTextFv()
3275 @return A pointer to the newly-created firmware file device path structure.
3294 StrToGuid (GuidStr, &FvFile->FvFileName); in DevPathFromTextFvFile()
3304 @return A pointer to the newly-created Text device path structure.
3325 Strtoi64 (StartingOffsetStr, &Offset->StartingOffset); in DevPathFromTextRelativeOffsetRange()
3326 Strtoi64 (EndingOffsetStr, &Offset->EndingOffset); in DevPathFromTextRelativeOffsetRange()
3336 @return A pointer to the newly-created Text device path structure.
3364 WriteUnaligned64 ((UINT64 *)&(RamDisk->StartingAddr[0]), StartingAddr); in DevPathFromTextRamDisk()
3366 WriteUnaligned64 ((UINT64 *)&(RamDisk->EndingAddr[0]), EndingAddr); in DevPathFromTextRamDisk()
3367 RamDisk->Instance = (UINT16)Strtoi (InstanceStr); in DevPathFromTextRamDisk()
3368 StrToGuid (TypeGuidStr, &RamDisk->TypeGuid); in DevPathFromTextRamDisk()
3378 @return A pointer to the newly-created Text device path structure.
3405 WriteUnaligned64 ((UINT64 *)&(RamDisk->StartingAddr[0]), StartingAddr); in DevPathFromTextVirtualDisk()
3407 WriteUnaligned64 ((UINT64 *)&(RamDisk->EndingAddr[0]), EndingAddr); in DevPathFromTextVirtualDisk()
3408 RamDisk->Instance = (UINT16)Strtoi (InstanceStr); in DevPathFromTextVirtualDisk()
3409 CopyGuid (&RamDisk->TypeGuid, &gEfiVirtualDiskGuid); in DevPathFromTextVirtualDisk()
3419 @return A pointer to the newly-created Text device path structure.
3446 WriteUnaligned64 ((UINT64 *)&(RamDisk->StartingAddr[0]), StartingAddr); in DevPathFromTextVirtualCd()
3448 WriteUnaligned64 ((UINT64 *)&(RamDisk->EndingAddr[0]), EndingAddr); in DevPathFromTextVirtualCd()
3449 RamDisk->Instance = (UINT16)Strtoi (InstanceStr); in DevPathFromTextVirtualCd()
3450 CopyGuid (&RamDisk->TypeGuid, &gEfiVirtualCdGuid); in DevPathFromTextVirtualCd()
3460 @return A pointer to the newly-created Text device path structure.
3487 WriteUnaligned64 ((UINT64 *)&(RamDisk->StartingAddr[0]), StartingAddr); in DevPathFromTextPersistentVirtualDisk()
3489 WriteUnaligned64 ((UINT64 *)&(RamDisk->EndingAddr[0]), EndingAddr); in DevPathFromTextPersistentVirtualDisk()
3490 RamDisk->Instance = (UINT16)Strtoi (InstanceStr); in DevPathFromTextPersistentVirtualDisk()
3491 CopyGuid (&RamDisk->TypeGuid, &gEfiPersistentVirtualDiskGuid); in DevPathFromTextPersistentVirtualDisk()
3501 @return A pointer to the newly-created Text device path structure.
3528 WriteUnaligned64 ((UINT64 *)&(RamDisk->StartingAddr[0]), StartingAddr); in DevPathFromTextPersistentVirtualCd()
3530 WriteUnaligned64 ((UINT64 *)&(RamDisk->EndingAddr[0]), EndingAddr); in DevPathFromTextPersistentVirtualCd()
3531 RamDisk->Instance = (UINT16)Strtoi (InstanceStr); in DevPathFromTextPersistentVirtualCd()
3532 CopyGuid (&RamDisk->TypeGuid, &gEfiPersistentVirtualCdGuid); in DevPathFromTextPersistentVirtualCd()
3559 @return A pointer to the newly-created BIOS Boot Specification device path structure.
3584 Bbs->DeviceType = BBS_TYPE_FLOPPY; in DevPathFromTextBBS()
3586 Bbs->DeviceType = BBS_TYPE_HARDDRIVE; in DevPathFromTextBBS()
3588 Bbs->DeviceType = BBS_TYPE_CDROM; in DevPathFromTextBBS()
3590 Bbs->DeviceType = BBS_TYPE_PCMCIA; in DevPathFromTextBBS()
3592 Bbs->DeviceType = BBS_TYPE_USB; in DevPathFromTextBBS()
3594 Bbs->DeviceType = BBS_TYPE_EMBEDDED_NETWORK; in DevPathFromTextBBS()
3596 Bbs->DeviceType = (UINT16)Strtoi (TypeStr); in DevPathFromTextBBS()
3599 AsciiStr = Bbs->String; in DevPathFromTextBBS()
3602 Bbs->StatusFlag = (UINT16)Strtoi (FlagsStr); in DevPathFromTextBBS()
3612 @return A pointer to the newly-created SATA device path structure.
3635 Sata->HBAPortNumber = (UINT16)Strtoi (Param1); in DevPathFromTextSata()
3641 Sata->PortMultiplierPortNumber = 0xFFFF; in DevPathFromTextSata()
3643 Sata->PortMultiplierPortNumber = (UINT16)Strtoi (Param2); in DevPathFromTextSata()
3646 Sata->Lun = (UINT16)Strtoi (Param3); in DevPathFromTextSata()
3723 { "Wi-Fi", DevPathFromTextWiFi },
3751 until the first non-device node character.
3809 until the first non-device node character.
3853 DeviceNode->SubType = END_INSTANCE_DEVICE_PATH_SUBTYPE; in UefiDevicePathLibConvertTextToDevicePath()
3874 return -1; in efidp_parse_device_path()
3878 return -1; in efidp_parse_device_path()