]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
efi: selftest: APPEND_WRITE is not supported
authorAKASHI Takahiro <takahiro.akashi@linaro.org>
Fri, 24 May 2019 06:59:01 +0000 (15:59 +0900)
committerHeinrich Schuchardt <xypron.glpk@gmx.de>
Fri, 24 May 2019 16:58:14 +0000 (18:58 +0200)
The error here should be marked *todo*.

Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
lib/efi_selftest/efi_selftest_variables.c

index b028c64bbc858bc12b39850e5c3664f1b6f20ce8..06c1a032dd04a5621a1b40673d2de81558737b9e 100644 (file)
@@ -116,21 +116,21 @@ static int execute(void)
                                    EFI_VARIABLE_APPEND_WRITE,
                                    7, v + 8);
        if (ret != EFI_SUCCESS) {
-               efi_st_error("SetVariable failed\n");
-               return EFI_ST_FAILURE;
-       }
-       len = EFI_ST_MAX_DATA_SIZE;
-       ret = runtime->get_variable(L"efi_st_var1", &guid_vendor1,
-                                   &attr, &len, data);
-       if (ret != EFI_SUCCESS) {
-               efi_st_error("GetVariable failed\n");
-               return EFI_ST_FAILURE;
+               efi_st_todo("SetVariable(APPEND_WRITE) failed\n");
+       } else {
+               len = EFI_ST_MAX_DATA_SIZE;
+               ret = runtime->get_variable(L"efi_st_var1", &guid_vendor1,
+                                           &attr, &len, data);
+               if (ret != EFI_SUCCESS) {
+                       efi_st_error("GetVariable failed\n");
+                       return EFI_ST_FAILURE;
+               }
+               if (len != 15)
+                       efi_st_todo("GetVariable returned wrong length %u\n",
+                                   (unsigned int)len);
+               if (memcmp(data, v, len))
+                       efi_st_todo("GetVariable returned wrong value\n");
        }
-       if (len != 15)
-               efi_st_todo("GetVariable returned wrong length %u\n",
-                           (unsigned int)len);
-       if (memcmp(data, v, len))
-               efi_st_todo("GetVariable returned wrong value\n");
        /* Enumerate variables */
        boottime->set_mem(&guid, 16, 0);
        *varname = 0;