From 79c3fb7b88eb1c608c902ccb8d4e68c674e39797 Mon Sep 17 00:00:00 2001 From: Courtney Darville Date: Mon, 23 Sep 2024 17:41:41 +1000 Subject: [PATCH] Add multicore configuration of IMX and odroidc4 Signed-off-by: Courtney Darville --- benchmark/benchmark.c | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/benchmark/benchmark.c b/benchmark/benchmark.c index abd4ac5d5..16e730c03 100644 --- a/benchmark/benchmark.c +++ b/benchmark/benchmark.c @@ -93,7 +93,8 @@ static void benchmark_print_IPC_data(uint64_t *buffer, uint32_t id) number_schedules = buffer[BENCHMARK_TCB_NUMBER_SCHEDULES]; kernel = buffer[BENCHMARK_TCB_KERNEL_UTILISATION]; entries = buffer[BENCHMARK_TCB_NUMBER_KERNEL_ENTRIES]; - sddf_printf("Utilisation details for PD: %s (%x)\n", pd_id_to_name(id), id); + sddf_printf("Utilisation details for PD: %s (%x)\n", + pd_id_to_name(id), id); } sddf_printf("{\nKernelUtilisation: %lx\nKernelEntries: " "%lx\nNumberSchedules: %lx\nTotalUtilisation: %lx\n}\n", @@ -105,7 +106,6 @@ static void benchmark_stop_core() seL4_BenchmarkFinalizeLog(); seL4_BenchmarkGetThreadUtilisation(TCB_CAP); benchmark_print_IPC_data((uint64_t *)&seL4_GetIPCBuffer()->msg[0], TOTAL_ID); - for (uint32_t id = 1; id < core_config.max_core_id + 1; id++) { if (core_config.core_bitmap & (1 << id)) { seL4_BenchmarkGetThreadUtilisation(BASE_TCB_CAP + id); @@ -219,7 +219,8 @@ void notified(microkit_channel ch) void init(void) { - serial_cli_queue_init_sys(microkit_name, NULL, NULL, NULL, &serial_tx_queue_handle, serial_tx_queue, + serial_cli_queue_init_sys(microkit_name, NULL, NULL, NULL, + &serial_tx_queue_handle, serial_tx_queue, serial_tx_data); serial_putchar_init(SERIAL_TX_CH, &serial_tx_queue_handle); @@ -262,18 +263,20 @@ seL4_Bool fault(microkit_child id, microkit_msginfo msginfo, microkit_msginfo *r sddf_printf("BENCH|LOG: Faulting PD %s (%x)\n", pd_id_to_name(id), id); seL4_UserContext regs; - seL4_TCB_ReadRegisters(BASE_TCB_CAP + id, false, 0, sizeof(seL4_UserContext) / sizeof(seL4_Word), ®s); + seL4_TCB_ReadRegisters(BASE_TCB_CAP + id, false, 0, + sizeof(seL4_UserContext) / sizeof(seL4_Word), ®s); sddf_printf("Registers: \npc : %lx\nspsr : %lx\nx0 : %lx\nx1 : %lx\n" "x2 : %lx\nx3 : %lx\nx4 : %lx\nx5 : %lx\nx6 : %lx\nx7 : %lx\n", - regs.pc, regs.spsr, regs.x0, regs.x1, regs.x2, regs.x3, regs.x4, regs.x5, regs.x6, regs.x7); + regs.pc, regs.spsr, regs.x0, regs.x1, regs.x2, regs.x3, + regs.x4, regs.x5, regs.x6, regs.x7); switch (microkit_msginfo_get_label(msginfo)) { case seL4_Fault_CapFault: { uint64_t ip = seL4_GetMR(seL4_CapFault_IP); uint64_t fault_addr = seL4_GetMR(seL4_CapFault_Addr); uint64_t in_recv_phase = seL4_GetMR(seL4_CapFault_InRecvPhase); - sddf_printf("CapFault: ip=%lx fault_addr=%lx in_recv_phase=%s\n", ip, fault_addr, - (in_recv_phase == 0 ? "false" : "true")); + sddf_printf("CapFault: ip=%lx fault_addr=%lx in_recv_phase=%s\n", + ip, fault_addr, (in_recv_phase == 0 ? "false" : "true")); break; } case seL4_Fault_UserException: { @@ -285,7 +288,8 @@ seL4_Bool fault(microkit_child id, microkit_msginfo msginfo, microkit_msginfo *r uint64_t fault_addr = seL4_GetMR(seL4_VMFault_Addr); uint64_t is_instruction = seL4_GetMR(seL4_VMFault_PrefetchFault); uint64_t fsr = seL4_GetMR(seL4_VMFault_FSR); - sddf_printf("VMFault: ip=%lx fault_addr=%lx fsr=%lx %s\n", ip, fault_addr, fsr, + sddf_printf("VMFault: ip=%lx fault_addr=%lx fsr=%lx %s\n", + ip, fault_addr, fsr, (is_instruction ? "(instruction fault)" : "(data fault)")); break; }