fdtdec: support multiple phandles in memory carveout
[oweals/u-boot.git] / lib / efi_selftest / efi_selftest_block_device.c
index 1cdd8307f4f1d0073409cea821a54b33fd46c551..d98a854e6d1a81d97762ce6d2f9e8508a291c8ec 100644 (file)
@@ -24,8 +24,8 @@
 
 static struct efi_boot_services *boottime;
 
-static const efi_guid_t block_io_protocol_guid = BLOCK_IO_GUID;
-static const efi_guid_t guid_device_path = DEVICE_PATH_GUID;
+static const efi_guid_t block_io_protocol_guid = EFI_BLOCK_IO_PROTOCOL_GUID;
+static const efi_guid_t guid_device_path = EFI_DEVICE_PATH_PROTOCOL_GUID;
 static const efi_guid_t guid_simple_file_system_protocol =
                                        EFI_SIMPLE_FILE_SYSTEM_PROTOCOL_GUID;
 static const efi_guid_t guid_file_system_info = EFI_FILE_SYSTEM_INFO_GUID;
@@ -257,14 +257,14 @@ static int teardown(void)
                                disk_handle, &block_io_protocol_guid,
                                &block_io);
                if (r != EFI_SUCCESS) {
-                       efi_st_todo(
+                       efi_st_error(
                                "Failed to uninstall block I/O protocol\n");
-                       return EFI_ST_SUCCESS;
+                       return EFI_ST_FAILURE;
                }
        }
 
        if (image) {
-               r = efi_free_pool(image);
+               r = boottime->free_pool(image);
                if (r != EFI_SUCCESS) {
                        efi_st_error("Failed to free image\n");
                        return EFI_ST_FAILURE;
@@ -337,7 +337,7 @@ static int execute(void)
                }
                if (len >= dp_size(dp_partition))
                        continue;
-               if (efi_st_memcmp(dp, dp_partition, len))
+               if (memcmp(dp, dp_partition, len))
                        continue;
                handle_partition = handles[i];
                break;
@@ -409,7 +409,7 @@ static int execute(void)
                             (unsigned int)buf_size);
                return EFI_ST_FAILURE;
        }
-       if (efi_st_memcmp(buf, "ello world!", 11)) {
+       if (memcmp(buf, "ello world!", 11)) {
                efi_st_error("Unexpected file content\n");
                return EFI_ST_FAILURE;
        }
@@ -480,7 +480,7 @@ static int execute(void)
                             (unsigned int)buf_size);
                return EFI_ST_FAILURE;
        }
-       if (efi_st_memcmp(buf, "U-Boot", 7)) {
+       if (memcmp(buf, "U-Boot", 7)) {
                efi_st_error("Unexpected file content %s\n", buf);
                return EFI_ST_FAILURE;
        }