git: 8278071ae179 - main - libefivar: Correct the string order of ACPI Expanded Device Path
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 27 Feb 2022 16:47:46 UTC
The branch main has been updated by imp:
URL: https://cgit.FreeBSD.org/src/commit/?id=8278071ae17976490f08e8154f226178abf319ea
commit 8278071ae17976490f08e8154f226178abf319ea
Author: Jose Luis Duran <jlduran@gmail.com>
AuthorDate: 2022-02-23 16:45:14 +0000
Commit: Warner Losh <imp@FreeBSD.org>
CommitDate: 2022-02-27 16:13:00 +0000
libefivar: Correct the string order of ACPI Expanded Device Path
According to UEFI Spec, ACPI Expanded Device Path can be display
AcpiEx(HID|HIDSTR,(CID|CIDSTR,UID|UIDSTR)), but current code display
UID|UIDSTR before CID|CIDSTR.
This patch is to fix this issue.
Upstream Bug: https://bugzilla.tianocore.org/show_bug.cgi?id=1227
Obtained from: https://github.com/tianocore/edk2/commit/05fe7525896cee197cfed98154955dbaa60d6357
Pull Request: https://github.com/freebsd/freebsd-src/pull/581
---
lib/libefivar/efivar-dp-format.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/lib/libefivar/efivar-dp-format.c b/lib/libefivar/efivar-dp-format.c
index 2256a2013ad4..7abbce033f1d 100644
--- a/lib/libefivar/efivar-dp-format.c
+++ b/lib/libefivar/efivar-dp-format.c
@@ -536,16 +536,16 @@ DevPathToTextAcpiEx (
UefiDevicePathLibCatPrint (Str, "AcpiEx(%s,", HIDText);
}
- if (AcpiEx->UID == 0) {
- UefiDevicePathLibCatPrint (Str, "%s,", UIDStr);
+ if (AcpiEx->CID == 0) {
+ UefiDevicePathLibCatPrint (Str, "%s,", CIDStr);
} else {
- UefiDevicePathLibCatPrint (Str, "0x%x,", AcpiEx->UID);
+ UefiDevicePathLibCatPrint (Str, "%s,", CIDText);
}
- if (AcpiEx->CID == 0) {
- UefiDevicePathLibCatPrint (Str, "%s)", CIDStr);
+ if (AcpiEx->UID == 0) {
+ UefiDevicePathLibCatPrint (Str, "%s)", UIDStr);
} else {
- UefiDevicePathLibCatPrint (Str, "%s)", CIDText);
+ UefiDevicePathLibCatPrint (Str, "0x%x)", AcpiEx->UID);
}
} else {
UefiDevicePathLibCatPrint (