Home | History | Annotate | Download | only in UefiDevicePathLib

Lines Matching refs:DevicePath

38   If DevicePath is NULL, then ASSERT().

40 @param DevicePath A pointer to a device path data structure.
43 @retval TRUE DevicePath is valid.
44 @retval FALSE The length of any node node in the DevicePath is less
46 @retval FALSE If MaxSize is not zero, the size of the DevicePath
49 count of the DevicePath exceeds PcdMaximumDevicePathNodeCount.
54 IN CONST EFI_DEVICE_PATH_PROTOCOL *DevicePath,
62 ASSERT (DevicePath != NULL);
75 for (Count = 0, Size = 0; !IsDevicePathEnd (DevicePath); DevicePath = NextDevicePathNode (DevicePath)) {
76 NodeLength = DevicePathNodeLength (DevicePath);
104 return (BOOLEAN) (DevicePathNodeLength (DevicePath) == END_DEVICE_PATH_LENGTH);
345 specified by DevicePath including the end of device path node.
346 If DevicePath is NULL or invalid, then 0 is returned.
348 @param DevicePath A pointer to a device path data structure.
350 @retval 0 If DevicePath is NULL or invalid.
357 IN CONST EFI_DEVICE_PATH_PROTOCOL *DevicePath
362 if (DevicePath == NULL) {
366 if (!IsDevicePathValid (DevicePath, 0)) {
373 Start = DevicePath;
374 while (!IsDevicePathEnd (DevicePath)) {
375 DevicePath = NextDevicePathNode (DevicePath);
381 return ((UINTN) DevicePath - (UINTN) Start) + DevicePathNodeLength (DevicePath);
387 This function allocates space for a new copy of the device path specified by DevicePath.
388 If DevicePath is NULL, then NULL is returned. If the memory is successfully
389 allocated, then the contents of DevicePath are copied to the newly allocated
394 @param DevicePath A pointer to a device path data structure.
396 @retval NULL DevicePath is NULL or invalid.
403 IN CONST EFI_DEVICE_PATH_PROTOCOL *DevicePath
411 Size = GetDevicePathSize (DevicePath);
420 return AllocateCopyPool (Size, DevicePath);
502 specified by DevicePathNode to a copy of the device path specified by DevicePath
505 If DevicePathNode is NULL then a copy of DevicePath is returned.
506 If DevicePath is NULL then a copy of DevicePathNode, followed by an end-of-device
508 If both DevicePathNode and DevicePath are NULL then a copy of an end-of-device-path
515 @param DevicePath A pointer to a device path data structure.
529 IN CONST EFI_DEVICE_PATH_PROTOCOL *DevicePath, OPTIONAL
539 return DuplicateDevicePath ((DevicePath != NULL) ? DevicePath : &mUefiDevicePathLibEndDevicePath);
559 NewDevicePath = AppendDevicePath (DevicePath, TempDevicePath);
572 by DevicePath in a allocated buffer.
575 If DevicePath is NULL, then a copy if DevicePathInstance is returned.
577 If DevicePath or DevicePathInstance is invalid, then NULL is returned.
583 @param DevicePath A pointer to a device path data structure.
592 IN CONST EFI_DEVICE_PATH_PROTOCOL *DevicePath, OPTIONAL
601 if (DevicePath == NULL) {
609 if (!IsDevicePathValid (DevicePath, 0) || !IsDevicePathValid (DevicePathInstance, 0)) {
613 SrcSize = GetDevicePathSize (DevicePath);
619 TempDevicePath = CopyMem (NewDevicePath, DevicePath, SrcSize);;
638 DevicePath to point to the next device path instance in the device path (or NULL
640 If DevicePath is NULL, then NULL is returned.
641 If DevicePath points to a invalid device path, then NULL is returned.
648 @param DevicePath On input, this holds the pointer to the current
655 path instance, in bytes or zero, if DevicePath
664 IN OUT EFI_DEVICE_PATH_PROTOCOL **DevicePath,
674 if (DevicePath == NULL || *DevicePath == NULL) {
679 if (!IsDevicePathValid (*DevicePath, 0)) {
686 DevPath = *DevicePath;
694 *Size = ((UINTN) DevPath - (UINTN) (*DevicePath)) + sizeof (EFI_DEVICE_PATH_PROTOCOL);
701 ReturnValue = DuplicateDevicePath (*DevicePath);
706 // does not follow, so *DevicePath is set to NULL.
709 *DevicePath = NULL;
711 *DevicePath = NextDevicePathNode (DevPath);
744 EFI_DEVICE_PATH_PROTOCOL *DevicePath;
753 DevicePath = AllocateZeroPool (NodeLength);
754 if (DevicePath != NULL) {
755 DevicePath->Type = NodeType;
756 DevicePath->SubType = NodeSubType;
757 SetDevicePathNodeLength (DevicePath, NodeLength);
760 return DevicePath;
766 This function returns TRUE if the device path specified by DevicePath is
769 If DevicePath is NULL or invalid, then FALSE is returned.
771 @param DevicePath A pointer to a device path data structure.
773 @retval TRUE DevicePath is multi-instance.
774 @retval FALSE DevicePath is not multi-instance, or DevicePath
781 IN CONST EFI_DEVICE_PATH_PROTOCOL *DevicePath
786 if (DevicePath == NULL) {
790 if (!IsDevicePathValid (DevicePath, 0)) {
794 Node = DevicePath;
826 EFI_DEVICE_PATH_PROTOCOL *DevicePath;
832 (VOID *) &DevicePath
835 DevicePath = NULL;
837 return DevicePath;
870 EFI_DEVICE_PATH_PROTOCOL *DevicePath;
873 DevicePath = NULL;
886 DevicePath = DevicePathFromHandle (Device);
889 DevicePath = AppendDevicePath (DevicePath, FileDevicePath);
893 return DevicePath;