test-runner: Add basic trusty_set_boot_params test

Adds very basic validation of the keymaster bootloader interface.
TODO: Call in full boot path instead and test more typical boot flow.

Bug: 175896427
Change-Id: I55784541c8f93e64b25ac553de2aefacc21134e8
diff --git a/test-runner/test-runner-sysdeps.c b/test-runner/test-runner-sysdeps.c
index 68965e1..d99c5da 100644
--- a/test-runner/test-runner-sysdeps.c
+++ b/test-runner/test-runner-sysdeps.c
@@ -26,7 +26,7 @@
 #include <trusty/sysdeps.h>
 
 /* Size limits for bump allocators (trusty_calloc and trusty_alloc_pages) */
-#define HEAP_SIZE (56)
+#define HEAP_SIZE (56 + 6 * 4)
 #define PAGE_COUNT (3)
 
 static uint8_t heap[HEAP_SIZE];
@@ -132,11 +132,6 @@
 }
 
 void trusty_free(void* addr) {
-    /*
-     * We don't have a real allocator. Make sure we don't trigger any
-     * code-paths that need dynamic memory.
-     */
-    trusty_abort();
 }
 
 void* trusty_alloc_pages(unsigned count) {
diff --git a/test-runner/test-runner.c b/test-runner/test-runner.c
index e9f0631..793103b 100644
--- a/test-runner/test-runner.c
+++ b/test-runner/test-runner.c
@@ -143,6 +143,12 @@
         log_msg("km_tipc_init failed\n");
         return;
     }
+    ret = trusty_set_boot_params(0, 0, KM_VERIFIED_BOOT_UNVERIFIED, false, NULL,
+                                 0, NULL, 0);
+    if (ret != 0) {
+        log_msg("trusty_set_boot_params failed\n");
+        return;
+    }
     km_tipc_shutdown(ipc_dev);
 
     ret = arch_start_secondary_cpus();