From 18c6f4922c334531ed049a7e59febb48c9d7a7cb Mon Sep 17 00:00:00 2001 From: Ivan Baravy Date: Tue, 2 Nov 2021 12:46:36 +0300 Subject: [PATCH] Add new shell commands: dump_win_map and set (variable). --- makefile | 2 +- shell.c | 125 ++++++- ...#xfs_#s05k_ls_all_dir_types_ftype1.ref.log | 1 + ...f70s1_#xfs_#s05k_ls_all_dir_types_ftype1.t | 1 + ...#xfs_#s05k_ls_all_dir_types_ftype0.ref.log | 1 + ...f70s1_#xfs_#s05k_ls_all_dir_types_ftype0.t | 1 + ...70s0_#xfs_#s05k_read_without_holes.ref.log | 1 + ...f70_#f70s0_#xfs_#s05k_read_without_holes.t | 1 + test/004_#f70_#f70s5_#xfs_stat.ref.log | 1 + test/004_#f70_#f70s5_#xfs_stat.t | 1 + test/005_#f30_#xfs_cur_dir.ref.log | 1 + test/005_#f30_#xfs_cur_dir.t | 1 + ..._#f70s0_#xfs_#s05k_read_with_holes.ref.log | 1 + ...6_#f70_#f70s0_#xfs_#s05k_read_with_holes.t | 1 + test/007_#f70_#xfs_#lookup_all.ref.log | 1 + test/007_#f70_#xfs_#lookup_all.t | 1 + ..._#xfs_#s4k_ls_all_dir_types_ftype0.ref.log | 1 + ...#f70s1_#xfs_#s4k_ls_all_dir_types_ftype0.t | 1 + ...70_#f70s0_#f70s1_#xfs_#s05k_#xattr.ref.log | 1 + ...009_#f70_#f70s0_#f70s1_#xfs_#s05k_#xattr.t | 1 + test/010_#f70_#xfs_#lookup_#xattr_all.ref.log | 1 + test/010_#f70_#xfs_#lookup_#xattr_all.t | 1 + ...0_#f70s1_#xfs_#lookup_#unicode_all.ref.log | 1 + ...11_#f70_#f70s1_#xfs_#lookup_#unicode_all.t | 1 + ..._#v5_#s05k_ls_all_dir_types_ftype1.ref.log | 1 + ...1_#xfs_#v5_#s05k_ls_all_dir_types_ftype1.t | 1 + test/013_#f70_#xfs_#v5_#lookup_all.ref.log | 1 + test/013_#f70_#xfs_#v5_#lookup_all.t | 1 + ...0s0_#xfs_#v5_#s05k_read_with_holes.ref.log | 1 + ...70_#f70s0_#xfs_#v5_#s05k_read_with_holes.t | 1 + ..._#xfs_#v5_#s05k_read_without_holes.ref.log | 1 + ...#f70s0_#xfs_#v5_#s05k_read_without_holes.t | 1 + test/016_#f01_#draw_all.ref.log | 1 + test/016_#f01_#draw_all.t | 1 + ..._#f70s0_#xfs_#s05k_read_above_4GiB.ref.log | 1 + ...7_#f70_#f70s0_#xfs_#s05k_read_above_4GiB.t | 1 + test/018_#xfs_#coverage_all.ref.log | 1 + test/018_#xfs_#coverage_all.t | 1 + test/019_#xfs_deep_btree.ref.log | 1 + test/019_#xfs_deep_btree.t | 1 + test/021_#i40_all.ref.log | 1 + test/021_#i40_all.t | 1 + test/026_#acpi_m000.ref.log | 1 + test/026_#acpi_m000.t | 1 + test/027_#acpi_m001.ref.log | 1 + test/027_#acpi_m001.t | 1 + test/028_#acpi_m002.ref.log | 1 + test/028_#acpi_m002.t | 1 + test/029_#acpi_m003.ref.log | 1 + test/029_#acpi_m003.t | 1 + test/030_#acpi_m004.ref.log | 1 + test/030_#acpi_m004.t | 1 + test/031_#acpi_#unit_scope.ref.log | 1 + test/031_#acpi_#unit_scope.t | 1 + test/032_#acpi_m005.ref.log | 1 + test/032_#acpi_m005.t | 1 + test/033_#acpi_debug_object.ref.log | 1 + test/033_#acpi_debug_object.t | 1 + test/034_#acpi_#unit_fieldio.ref.log | 1 + test/034_#acpi_#unit_fieldio.t | 1 + test/035_#acpi_m006.ref.log | 1 + test/035_#acpi_m006.t | 1 + test/036_#acpi_m007.ref.log | 1 + test/036_#acpi_m007.t | 1 + test/038_#acpi_m008.ref.log | 1 + test/038_#acpi_m008.t | 1 + test/040_#acpi_m010.ref.log | 1 + test/040_#acpi_m010.t | 1 + test/041_#acpi_alloc_free.ref.log | 350 ++++++++++++++++-- test/042_#acpi_m011.ref.log | 1 + test/042_#acpi_m011.t | 1 + test/044_#f01_#draw_winmap.ref.log | 166 +++++++++ test/044_#f01_#draw_winmap.ref.png | Bin 0 -> 159 bytes test/044_#f01_#draw_winmap.t | 31 ++ umka.asm | 27 +- umka.h | 131 ++++++- umka_shell.c | 72 ++-- 77 files changed, 900 insertions(+), 72 deletions(-) create mode 100644 test/044_#f01_#draw_winmap.ref.log create mode 100644 test/044_#f01_#draw_winmap.ref.png create mode 100644 test/044_#f01_#draw_winmap.t diff --git a/makefile b/makefile index 927f167..5115c48 100644 --- a/makefile +++ b/makefile @@ -29,7 +29,7 @@ umka_os: umka_os.o umka.o shell.o lodepng.o vdisk.o vnet.o trace.o trace_lbr.o \ $(CC) $(LDFLAGS_32) $^ -o $@ -static -T umka.ld umka.o umka.fas: umka.asm - INCLUDE="$(KOLIBRIOS)/kernel/trunk;$(KOLIBRIOS)/programs/develop/libraries/libcrash/trunk" \ + INCLUDE="$(KOLIBRIOS)/kernel/trunk;$(KOLIBRIOS)/programs/develop/libraries/libcrash/hash" \ $(FASM) $< umka.o -s umka.fas -m 1234567 shell.o: shell.c diff --git a/shell.c b/shell.c index 3567ce3..3060c02 100644 --- a/shell.c +++ b/shell.c @@ -193,9 +193,11 @@ get_last_dir(const char *path) { static void prompt() { if (cur_dir_changed) { - COVERAGE_ON(); - umka_sys_get_cwd(cur_dir, PATH_MAX); - COVERAGE_OFF(); + if (umka_initialized) { + COVERAGE_ON(); + umka_sys_get_cwd(cur_dir, PATH_MAX); + COVERAGE_OFF(); + } last_dir = get_last_dir(cur_dir); cur_dir_changed = false; } @@ -236,6 +238,51 @@ split_args(char *s, char **argv) { return argc; } +static void +shell_umka_init(int argc, char **argv) { + const char *usage = \ + "usage: umka_init"; + (void)argv; + if (argc < 0) { + fputs(usage, fout); + return; + } + COVERAGE_ON(); + umka_init(); + COVERAGE_OFF(); +} + +static void +shell_umka_set_boot_params(int argc, char **argv) { + const char *usage = \ + "usage: umka_set_boot_params [--x_res ] [--y_res ]\n" + " --x_res screen width\n" + " --y_res screen height"; + + argc -= 1; + argv += 1; + + while (argc) { + if (!strcmp(argv[0], "--x_res") && argc > 1) { + kos_boot.x_res = strtoul(argv[1], NULL, 0); + kos_boot.pitch = kos_boot.x_res * 4; // assume 32bpp + argc -= 2; + argv += 2; + continue; + } else if (!strcmp(argv[0], "--y_res") && argc > 1) { + kos_boot.y_res = strtoul(argv[1], NULL, 0); + argc -= 2; + argv += 2; + continue; + } else { + printf("bad option: %s\n", argv[0]); + puts(usage); + exit(1); + } + } + +} + static void shell_i40(int argc, char **argv) { const char *usage = \ @@ -497,6 +544,23 @@ shell_dump_win_pos(int argc, char **argv) { } } +static void +shell_dump_win_map(int argc, char **argv) { + const char *usage = \ + "usage: dump_win_map"; + (void)argv; + if (argc < 0) { + fputs(usage, fout); + return; + } + for (size_t y = 0; y < kos_display.height; y++) { + for (size_t x = 0; x < kos_display.width; x++) { + fputc(kos_display.win_map[y * kos_display.width + x] + '0', fout); + } + fputc('\n', fout); + } +} + static void shell_dump_appdata(int argc, char **argv) { const char *usage = \ @@ -577,6 +641,55 @@ shell_dump_taskdata(int argc, char **argv) { fprintf(fout, "cpu_usage: %" PRIu32 "\n", t->cpu_usage); } +static void +shell_switch_to_thread(int argc, char **argv) { + const char *usage = \ + "usage: switch_to_thread \n" + " thread id to switch to"; + if (argc != 2) { + fputs(usage, fout); + return; + } + uint8_t tid = strtoul(argv[1], NULL, 0); + kos_current_slot_idx = tid; + kos_task_base = kos_task_table + tid; + kos_current_slot = kos_slot_base + tid; +} + +static void +shell_set(int argc, char **argv) { + const char *usage = \ + "usage: set \n" + " variable to set\n" + " decimal or hex value"; + if (argc != 3) { + fputs(usage, fout); + return; + } + const char *var = argv[1]; + size_t value = strtoul(argv[2], NULL, 0); + if (!strcmp(var, "redraw_background")) { + kos_redraw_background = value; + } else { + printf("bad option: %s\n", argv[0]); + puts(usage); + exit(1); + } +} + +static void +shell_new_sys_thread(int argc, char **argv) { + const char *usage = \ + "usage: new_sys_thread"; + if (!argc) { + fputs(usage, fout); + return; + } + (void)argv; + size_t tid = umka_new_sys_threads(0, NULL, NULL); + fprintf(fout, "tid: %u\n", tid); +} + static void shell_mouse_move(int argc, char **argv) { const char *usage = \ @@ -2580,6 +2693,8 @@ shell_bg_unmap(int argc, char **argv) { static void shell_help(int argc, char **argv); func_table_t shell_cmds[] = { + { "umka_init", shell_umka_init }, + { "umka_set_boot_params", shell_umka_set_boot_params }, { "acpi_call", shell_acpi_call }, { "acpi_enable", shell_acpi_enable }, { "acpi_get_usage", shell_acpi_get_usage }, @@ -2598,6 +2713,7 @@ func_table_t shell_cmds[] = { { "blit_bitmap", shell_blit_bitmap }, { "button", shell_button }, { "cd", shell_cd }, + { "set", shell_set }, { "disk_add", shell_disk_add }, { "disk_del", shell_disk_del }, { "display_number", shell_display_number }, @@ -2608,6 +2724,7 @@ func_table_t shell_cmds[] = { { "dump_taskdata", shell_dump_taskdata }, { "dump_win_pos", shell_dump_win_pos }, { "dump_win_stack", shell_dump_win_stack }, + { "dump_win_map", shell_dump_win_map }, { "exec", shell_exec }, { "get_font_size", shell_get_font_size }, { "get_font_smoothing", shell_get_font_smoothing }, @@ -2677,6 +2794,8 @@ func_table_t shell_cmds[] = { { "stat80", shell_stat80 }, { "window_redraw", shell_window_redraw }, { "write_text", shell_write_text }, + { "switch_to_thread", shell_switch_to_thread }, + { "new_sys_thread", shell_new_sys_thread }, }; static void diff --git a/test/001_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype1.ref.log b/test/001_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype1.ref.log index 69be377..5a6099a 100644 --- a/test/001_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype1.ref.log +++ b/test/001_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype1.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v4_ftype1_s05k_b2k_n8k.img hd0 -c 0 /hd0/1: xfs /> disk_add ../img/xfs_short_dir_i8.img hd1 -c 0 diff --git a/test/001_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype1.t b/test/001_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype1.t index 8f2543a..344fbfe 100644 --- a/test/001_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype1.t +++ b/test/001_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype1.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v4_ftype1_s05k_b2k_n8k.img hd0 -c 0 disk_add ../img/xfs_short_dir_i8.img hd1 -c 0 diff --git a/test/002_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype0.ref.log b/test/002_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype0.ref.log index e3b7ae8..2b535eb 100644 --- a/test/002_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype0.ref.log +++ b/test/002_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype0.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v4_ftype0_s05k_b2k_n8k.img hd0 -c 0 /hd0/1: xfs /> ls70 /hd0/1/sf_empty diff --git a/test/002_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype0.t b/test/002_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype0.t index 1a3b452..031fb8b 100644 --- a/test/002_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype0.t +++ b/test/002_#f70_#f70s1_#xfs_#s05k_ls_all_dir_types_ftype0.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v4_ftype0_s05k_b2k_n8k.img hd0 -c 0 ls70 /hd0/1/sf_empty ls70 /hd0/1/sf diff --git a/test/003_#f70_#f70s0_#xfs_#s05k_read_without_holes.ref.log b/test/003_#f70_#f70s0_#xfs_#s05k_read_without_holes.ref.log index cdbd5d4..c58fded 100644 --- a/test/003_#f70_#f70s0_#xfs_#s05k_read_without_holes.ref.log +++ b/test/003_#f70_#f70s0_#xfs_#s05k_read_without_holes.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v4_files_s05k_b4k_n8k.img hd0 -c 0 /hd0/1: xfs # zero length diff --git a/test/003_#f70_#f70s0_#xfs_#s05k_read_without_holes.t b/test/003_#f70_#f70s0_#xfs_#s05k_read_without_holes.t index d84b43a..35a98ab 100644 --- a/test/003_#f70_#f70s0_#xfs_#s05k_read_without_holes.t +++ b/test/003_#f70_#f70s0_#xfs_#s05k_read_without_holes.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v4_files_s05k_b4k_n8k.img hd0 -c 0 # zero length read70 /hd0/1/no_hole 0 0 -b diff --git a/test/004_#f70_#f70s5_#xfs_stat.ref.log b/test/004_#f70_#f70s5_#xfs_stat.ref.log index 02ea508..ee1e4a6 100644 --- a/test/004_#f70_#f70s5_#xfs_stat.ref.log +++ b/test/004_#f70_#f70s5_#xfs_stat.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v4_files_s05k_b4k_n8k.img hd0 -c 0 /hd0/1: xfs /> stat70 /hd0/1/ diff --git a/test/004_#f70_#f70s5_#xfs_stat.t b/test/004_#f70_#f70s5_#xfs_stat.t index 735d9fc..3112aff 100644 --- a/test/004_#f70_#f70s5_#xfs_stat.t +++ b/test/004_#f70_#f70s5_#xfs_stat.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v4_files_s05k_b4k_n8k.img hd0 -c 0 stat70 /hd0/1/ stat70 /hd0/1/hole_begin diff --git a/test/005_#f30_#xfs_cur_dir.ref.log b/test/005_#f30_#xfs_cur_dir.ref.log index 2050223..478d29c 100644 --- a/test/005_#f30_#xfs_cur_dir.ref.log +++ b/test/005_#f30_#xfs_cur_dir.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v4_files_s05k_b4k_n8k.img hd0 -c 0 /hd0/1: xfs /> pwd diff --git a/test/005_#f30_#xfs_cur_dir.t b/test/005_#f30_#xfs_cur_dir.t index 3f8d762..64155b6 100644 --- a/test/005_#f30_#xfs_cur_dir.t +++ b/test/005_#f30_#xfs_cur_dir.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v4_files_s05k_b4k_n8k.img hd0 -c 0 pwd cd /hd0 diff --git a/test/006_#f70_#f70s0_#xfs_#s05k_read_with_holes.ref.log b/test/006_#f70_#f70s0_#xfs_#s05k_read_with_holes.ref.log index 0d685fe..c24e1a2 100644 --- a/test/006_#f70_#f70s0_#xfs_#s05k_read_with_holes.ref.log +++ b/test/006_#f70_#f70s0_#xfs_#s05k_read_with_holes.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v4_files_s05k_b4k_n8k.img hd0 -c 0 /hd0/1: xfs # hole begin diff --git a/test/006_#f70_#f70s0_#xfs_#s05k_read_with_holes.t b/test/006_#f70_#f70s0_#xfs_#s05k_read_with_holes.t index e4de391..02b711f 100644 --- a/test/006_#f70_#f70s0_#xfs_#s05k_read_with_holes.t +++ b/test/006_#f70_#f70s0_#xfs_#s05k_read_with_holes.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v4_files_s05k_b4k_n8k.img hd0 -c 0 # hole begin # zero length diff --git a/test/007_#f70_#xfs_#lookup_all.ref.log b/test/007_#f70_#xfs_#lookup_all.ref.log index b1354a3..250ece8 100644 --- a/test/007_#f70_#xfs_#lookup_all.ref.log +++ b/test/007_#f70_#xfs_#lookup_all.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v4_ftype1_s05k_b2k_n8k.img hd0 -c 0 /hd0/1: xfs /> stat70 /hd0/1/sf_empty diff --git a/test/007_#f70_#xfs_#lookup_all.t b/test/007_#f70_#xfs_#lookup_all.t index 77baafd..8409514 100644 --- a/test/007_#f70_#xfs_#lookup_all.t +++ b/test/007_#f70_#xfs_#lookup_all.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v4_ftype1_s05k_b2k_n8k.img hd0 -c 0 stat70 /hd0/1/sf_empty stat70 /hd0/1/sf_empty/. diff --git a/test/008_#f70_#f70s1_#xfs_#s4k_ls_all_dir_types_ftype0.ref.log b/test/008_#f70_#f70s1_#xfs_#s4k_ls_all_dir_types_ftype0.ref.log index 7d9d2a4..bafc6f5 100644 --- a/test/008_#f70_#f70s1_#xfs_#s4k_ls_all_dir_types_ftype0.ref.log +++ b/test/008_#f70_#f70s1_#xfs_#s4k_ls_all_dir_types_ftype0.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v4_ftype0_s4k_b4k_n8k.img hd0 -c 0 /hd0/1: xfs /> ls70 /hd0/1/sf diff --git a/test/008_#f70_#f70s1_#xfs_#s4k_ls_all_dir_types_ftype0.t b/test/008_#f70_#f70s1_#xfs_#s4k_ls_all_dir_types_ftype0.t index a2bc1b8..91680c3 100644 --- a/test/008_#f70_#f70s1_#xfs_#s4k_ls_all_dir_types_ftype0.t +++ b/test/008_#f70_#f70s1_#xfs_#s4k_ls_all_dir_types_ftype0.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v4_ftype0_s4k_b4k_n8k.img hd0 -c 0 ls70 /hd0/1/sf ls70 /hd0/1/block diff --git a/test/009_#f70_#f70s0_#f70s1_#xfs_#s05k_#xattr.ref.log b/test/009_#f70_#f70s0_#f70s1_#xfs_#s05k_#xattr.ref.log index 682338e..7d25594 100644 --- a/test/009_#f70_#f70s0_#f70s1_#xfs_#s05k_#xattr.ref.log +++ b/test/009_#f70_#f70s0_#f70s1_#xfs_#s05k_#xattr.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v4_ftype0_s05k_b2k_n8k_xattr.img hd0 -c 0 /hd0/1: xfs /> ls70 /hd0/1/sf_empty diff --git a/test/009_#f70_#f70s0_#f70s1_#xfs_#s05k_#xattr.t b/test/009_#f70_#f70s0_#f70s1_#xfs_#s05k_#xattr.t index 4795eca..5589ca1 100644 --- a/test/009_#f70_#f70s0_#f70s1_#xfs_#s05k_#xattr.t +++ b/test/009_#f70_#f70s0_#f70s1_#xfs_#s05k_#xattr.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v4_ftype0_s05k_b2k_n8k_xattr.img hd0 -c 0 ls70 /hd0/1/sf_empty ls70 /hd0/1/sf diff --git a/test/010_#f70_#xfs_#lookup_#xattr_all.ref.log b/test/010_#f70_#xfs_#lookup_#xattr_all.ref.log index e1d703f..a00c2ec 100644 --- a/test/010_#f70_#xfs_#lookup_#xattr_all.ref.log +++ b/test/010_#f70_#xfs_#lookup_#xattr_all.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v4_ftype0_s05k_b2k_n8k_xattr.img hd0 -c 0 /hd0/1: xfs /> stat70 /hd0/1/sf_empty diff --git a/test/010_#f70_#xfs_#lookup_#xattr_all.t b/test/010_#f70_#xfs_#lookup_#xattr_all.t index d519852..3b4ba99 100644 --- a/test/010_#f70_#xfs_#lookup_#xattr_all.t +++ b/test/010_#f70_#xfs_#lookup_#xattr_all.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v4_ftype0_s05k_b2k_n8k_xattr.img hd0 -c 0 stat70 /hd0/1/sf_empty stat70 /hd0/1/sf_empty/. diff --git a/test/011_#f70_#f70s1_#xfs_#lookup_#unicode_all.ref.log b/test/011_#f70_#f70s1_#xfs_#lookup_#unicode_all.ref.log index 1a69684..1b5580f 100644 --- a/test/011_#f70_#f70s1_#xfs_#lookup_#unicode_all.ref.log +++ b/test/011_#f70_#f70s1_#xfs_#lookup_#unicode_all.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v4_unicode.img hd0 -c 0 /hd0/1: xfs diff --git a/test/011_#f70_#f70s1_#xfs_#lookup_#unicode_all.t b/test/011_#f70_#f70s1_#xfs_#lookup_#unicode_all.t index 1ee64c4..bdd579f 100644 --- a/test/011_#f70_#f70s1_#xfs_#lookup_#unicode_all.t +++ b/test/011_#f70_#f70s1_#xfs_#lookup_#unicode_all.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v4_unicode.img hd0 -c 0 stat80 /hd0/1/dir0 diff --git a/test/012_#f70_#f70s1_#xfs_#v5_#s05k_ls_all_dir_types_ftype1.ref.log b/test/012_#f70_#f70s1_#xfs_#v5_#s05k_ls_all_dir_types_ftype1.ref.log index 43de5b2..9b11b0e 100644 --- a/test/012_#f70_#f70s1_#xfs_#v5_#s05k_ls_all_dir_types_ftype1.ref.log +++ b/test/012_#f70_#f70s1_#xfs_#v5_#s05k_ls_all_dir_types_ftype1.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v5_ftype1_s05k_b2k_n8k.img hd0 -c 0 /hd0/1: xfs /> ls70 /hd0/1/sf_empty diff --git a/test/012_#f70_#f70s1_#xfs_#v5_#s05k_ls_all_dir_types_ftype1.t b/test/012_#f70_#f70s1_#xfs_#v5_#s05k_ls_all_dir_types_ftype1.t index 3fac9b1..20d45dd 100644 --- a/test/012_#f70_#f70s1_#xfs_#v5_#s05k_ls_all_dir_types_ftype1.t +++ b/test/012_#f70_#f70s1_#xfs_#v5_#s05k_ls_all_dir_types_ftype1.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v5_ftype1_s05k_b2k_n8k.img hd0 -c 0 ls70 /hd0/1/sf_empty ls70 /hd0/1/sf diff --git a/test/013_#f70_#xfs_#v5_#lookup_all.ref.log b/test/013_#f70_#xfs_#v5_#lookup_all.ref.log index f1a3ae9..2ff3acd 100644 --- a/test/013_#f70_#xfs_#v5_#lookup_all.ref.log +++ b/test/013_#f70_#xfs_#v5_#lookup_all.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v5_ftype1_s05k_b2k_n8k.img hd0 -c 0 /hd0/1: xfs /> stat70 /hd0/1/sf_empty diff --git a/test/013_#f70_#xfs_#v5_#lookup_all.t b/test/013_#f70_#xfs_#v5_#lookup_all.t index 0169677..9a041ab 100644 --- a/test/013_#f70_#xfs_#v5_#lookup_all.t +++ b/test/013_#f70_#xfs_#v5_#lookup_all.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v5_ftype1_s05k_b2k_n8k.img hd0 -c 0 stat70 /hd0/1/sf_empty stat70 /hd0/1/sf_empty/. diff --git a/test/014_#f70_#f70s0_#xfs_#v5_#s05k_read_with_holes.ref.log b/test/014_#f70_#f70s0_#xfs_#v5_#s05k_read_with_holes.ref.log index 635ccec..19369c2 100644 --- a/test/014_#f70_#f70s0_#xfs_#v5_#s05k_read_with_holes.ref.log +++ b/test/014_#f70_#f70s0_#xfs_#v5_#s05k_read_with_holes.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v5_files_s05k_b4k_n8k.img hd0 -c 0 /hd0/1: xfs # hole begin diff --git a/test/014_#f70_#f70s0_#xfs_#v5_#s05k_read_with_holes.t b/test/014_#f70_#f70s0_#xfs_#v5_#s05k_read_with_holes.t index 630c998..f892fac 100644 --- a/test/014_#f70_#f70s0_#xfs_#v5_#s05k_read_with_holes.t +++ b/test/014_#f70_#f70s0_#xfs_#v5_#s05k_read_with_holes.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v5_files_s05k_b4k_n8k.img hd0 -c 0 # hole begin # zero length diff --git a/test/015_#f70_#f70s0_#xfs_#v5_#s05k_read_without_holes.ref.log b/test/015_#f70_#f70s0_#xfs_#v5_#s05k_read_without_holes.ref.log index f0a4da1..dce5543 100644 --- a/test/015_#f70_#f70s0_#xfs_#v5_#s05k_read_without_holes.ref.log +++ b/test/015_#f70_#f70s0_#xfs_#v5_#s05k_read_without_holes.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v5_files_s05k_b4k_n8k.img hd0 -c 0 /hd0/1: xfs # zero length diff --git a/test/015_#f70_#f70s0_#xfs_#v5_#s05k_read_without_holes.t b/test/015_#f70_#f70s0_#xfs_#v5_#s05k_read_without_holes.t index 356730a..011b138 100644 --- a/test/015_#f70_#f70s0_#xfs_#v5_#s05k_read_without_holes.t +++ b/test/015_#f70_#f70s0_#xfs_#v5_#s05k_read_without_holes.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v5_files_s05k_b4k_n8k.img hd0 -c 0 # zero length read70 /hd0/1/no_hole 0 0 -b diff --git a/test/016_#f01_#draw_all.ref.log b/test/016_#f01_#draw_all.ref.log index 38877c2..0415afe 100644 --- a/test/016_#f01_#draw_all.ref.log +++ b/test/016_#f01_#draw_all.ref.log @@ -1,3 +1,4 @@ +/> umka_init #disk_add ../img/kolibri.img rd -c 0 /> ramdisk_init ../img/kolibri.img /rd/1: fat diff --git a/test/016_#f01_#draw_all.t b/test/016_#f01_#draw_all.t index 5c2dbd9..1b8c72b 100644 --- a/test/016_#f01_#draw_all.t +++ b/test/016_#f01_#draw_all.t @@ -1,3 +1,4 @@ +umka_init #disk_add ../img/kolibri.img rd -c 0 ramdisk_init ../img/kolibri.img set_skin /sys/DEFAULT.SKN diff --git a/test/017_#f70_#f70s0_#xfs_#s05k_read_above_4GiB.ref.log b/test/017_#f70_#f70s0_#xfs_#s05k_read_above_4GiB.ref.log index aba6c12..5ce831c 100644 --- a/test/017_#f70_#f70s0_#xfs_#s05k_read_above_4GiB.ref.log +++ b/test/017_#f70_#f70s0_#xfs_#s05k_read_above_4GiB.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v4_files_s05k_b4k_n8k.img hd0 -c 0 /hd0/1: xfs diff --git a/test/017_#f70_#f70s0_#xfs_#s05k_read_above_4GiB.t b/test/017_#f70_#f70s0_#xfs_#s05k_read_above_4GiB.t index 7d6ac59..3249ab7 100644 --- a/test/017_#f70_#f70s0_#xfs_#s05k_read_above_4GiB.t +++ b/test/017_#f70_#f70s0_#xfs_#s05k_read_above_4GiB.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v4_files_s05k_b4k_n8k.img hd0 -c 0 read70 /hd0/1/4GiB_plus 0x3ff4 11 -b diff --git a/test/018_#xfs_#coverage_all.ref.log b/test/018_#xfs_#coverage_all.ref.log index b0584cf..9fe528d 100644 --- a/test/018_#xfs_#coverage_all.ref.log +++ b/test/018_#xfs_#coverage_all.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/jfs.img hd0 -c 0 /hd0/1: ??? /> disk_del hd0 diff --git a/test/018_#xfs_#coverage_all.t b/test/018_#xfs_#coverage_all.t index 25ef404..7fd559b 100644 --- a/test/018_#xfs_#coverage_all.t +++ b/test/018_#xfs_#coverage_all.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/jfs.img hd0 -c 0 disk_del hd0 disk_add ../img/xfs_borg_bit.img hd0 -c 0 diff --git a/test/019_#xfs_deep_btree.ref.log b/test/019_#xfs_deep_btree.ref.log index 894d9fa..ea50b31 100644 --- a/test/019_#xfs_deep_btree.ref.log +++ b/test/019_#xfs_deep_btree.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> disk_add ../img/xfs_v4_btrees_l2.img hd0 -c 0 /hd0/1: xfs diff --git a/test/019_#xfs_deep_btree.t b/test/019_#xfs_deep_btree.t index e204b76..cb4c3da 100644 --- a/test/019_#xfs_deep_btree.t +++ b/test/019_#xfs_deep_btree.t @@ -1,3 +1,4 @@ +umka_init disk_add ../img/xfs_v4_btrees_l2.img hd0 -c 0 ls80 /hd0/1/dir_btree_l2 -f 0 -c 1 diff --git a/test/021_#i40_all.ref.log b/test/021_#i40_all.ref.log index d570922..f97cef4 100644 --- a/test/021_#i40_all.ref.log +++ b/test/021_#i40_all.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> i40 18 16 eax = 00040000 262144 262144 ebx = 00000010 16 16 diff --git a/test/021_#i40_all.t b/test/021_#i40_all.t index fb9b6b9..61ad73d 100644 --- a/test/021_#i40_all.t +++ b/test/021_#i40_all.t @@ -1 +1,2 @@ +umka_init i40 18 16 diff --git a/test/026_#acpi_m000.ref.log b/test/026_#acpi_m000.ref.log index c1a6a4e..7daa05c 100644 --- a/test/026_#acpi_m000.ref.log +++ b/test/026_#acpi_m000.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> pci_set_path machines/000/pci /> acpi_set_usage 2 diff --git a/test/026_#acpi_m000.t b/test/026_#acpi_m000.t index f866c18..f3785ea 100644 --- a/test/026_#acpi_m000.t +++ b/test/026_#acpi_m000.t @@ -1,3 +1,4 @@ +umka_init pci_set_path machines/000/pci acpi_set_usage 2 diff --git a/test/027_#acpi_m001.ref.log b/test/027_#acpi_m001.ref.log index cb9f026..1841b6c 100644 --- a/test/027_#acpi_m001.ref.log +++ b/test/027_#acpi_m001.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> pci_set_path machines/001/pci /> acpi_set_usage 2 diff --git a/test/027_#acpi_m001.t b/test/027_#acpi_m001.t index f209915..bdc3a95 100644 --- a/test/027_#acpi_m001.t +++ b/test/027_#acpi_m001.t @@ -1,3 +1,4 @@ +umka_init pci_set_path machines/001/pci acpi_set_usage 2 diff --git a/test/028_#acpi_m002.ref.log b/test/028_#acpi_m002.ref.log index 34b4a9e..625db00 100644 --- a/test/028_#acpi_m002.ref.log +++ b/test/028_#acpi_m002.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> pci_set_path machines/002/pci # some _ADR's are methods with memory access diff --git a/test/028_#acpi_m002.t b/test/028_#acpi_m002.t index 5ff3310..768933b 100644 --- a/test/028_#acpi_m002.t +++ b/test/028_#acpi_m002.t @@ -1,3 +1,4 @@ +umka_init pci_set_path machines/002/pci # some _ADR's are methods with memory access diff --git a/test/029_#acpi_m003.ref.log b/test/029_#acpi_m003.ref.log index 571c15b..480d5be 100644 --- a/test/029_#acpi_m003.ref.log +++ b/test/029_#acpi_m003.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> pci_set_path machines/003/pci /> acpi_set_usage 2 diff --git a/test/029_#acpi_m003.t b/test/029_#acpi_m003.t index ca94a64..3026ce6 100644 --- a/test/029_#acpi_m003.t +++ b/test/029_#acpi_m003.t @@ -1,3 +1,4 @@ +umka_init pci_set_path machines/003/pci acpi_set_usage 2 diff --git a/test/030_#acpi_m004.ref.log b/test/030_#acpi_m004.ref.log index 2aecea8..f0ef103 100644 --- a/test/030_#acpi_m004.ref.log +++ b/test/030_#acpi_m004.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> acpi_set_usage 1 /> acpi_preload_table machines/004/acpi/DSDT diff --git a/test/030_#acpi_m004.t b/test/030_#acpi_m004.t index a0bc702..bfcb29c 100644 --- a/test/030_#acpi_m004.t +++ b/test/030_#acpi_m004.t @@ -1,3 +1,4 @@ +umka_init acpi_set_usage 1 acpi_preload_table machines/004/acpi/DSDT diff --git a/test/031_#acpi_#unit_scope.ref.log b/test/031_#acpi_#unit_scope.ref.log index 49016b2..048e495 100644 --- a/test/031_#acpi_#unit_scope.ref.log +++ b/test/031_#acpi_#unit_scope.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> acpi_set_usage 1 /> acpi_preload_table machines/unit/acpi/scope_empty.aml diff --git a/test/031_#acpi_#unit_scope.t b/test/031_#acpi_#unit_scope.t index 71b69fc..aee823a 100644 --- a/test/031_#acpi_#unit_scope.t +++ b/test/031_#acpi_#unit_scope.t @@ -1,3 +1,4 @@ +umka_init acpi_set_usage 1 acpi_preload_table machines/unit/acpi/scope_empty.aml diff --git a/test/032_#acpi_m005.ref.log b/test/032_#acpi_m005.ref.log index f68e892..268d7bc 100644 --- a/test/032_#acpi_m005.ref.log +++ b/test/032_#acpi_m005.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> pci_set_path machines/005/pci /> acpi_set_usage 2 diff --git a/test/032_#acpi_m005.t b/test/032_#acpi_m005.t index c9a570a..5e19dd7 100644 --- a/test/032_#acpi_m005.t +++ b/test/032_#acpi_m005.t @@ -1,3 +1,4 @@ +umka_init pci_set_path machines/005/pci acpi_set_usage 2 diff --git a/test/033_#acpi_debug_object.ref.log b/test/033_#acpi_debug_object.ref.log index 13e3971..0e68aaf 100644 --- a/test/033_#acpi_debug_object.ref.log +++ b/test/033_#acpi_debug_object.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> acpi_set_usage 1 /> acpi_preload_table machines/unit/acpi/debug_object.aml diff --git a/test/033_#acpi_debug_object.t b/test/033_#acpi_debug_object.t index f280451..720c0af 100644 --- a/test/033_#acpi_debug_object.t +++ b/test/033_#acpi_debug_object.t @@ -1,3 +1,4 @@ +umka_init acpi_set_usage 1 acpi_preload_table machines/unit/acpi/debug_object.aml diff --git a/test/034_#acpi_#unit_fieldio.ref.log b/test/034_#acpi_#unit_fieldio.ref.log index 1bb3b52..c555fbd 100644 --- a/test/034_#acpi_#unit_fieldio.ref.log +++ b/test/034_#acpi_#unit_fieldio.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> acpi_set_usage 1 /> acpi_preload_table machines/unit/acpi/field.aml diff --git a/test/034_#acpi_#unit_fieldio.t b/test/034_#acpi_#unit_fieldio.t index 21c5b1e..72b3b26 100644 --- a/test/034_#acpi_#unit_fieldio.t +++ b/test/034_#acpi_#unit_fieldio.t @@ -1,3 +1,4 @@ +umka_init acpi_set_usage 1 acpi_preload_table machines/unit/acpi/field.aml diff --git a/test/035_#acpi_m006.ref.log b/test/035_#acpi_m006.ref.log index ffb46dc..abca6f3 100644 --- a/test/035_#acpi_m006.ref.log +++ b/test/035_#acpi_m006.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> pci_set_path machines/006/pci /> acpi_set_usage 2 diff --git a/test/035_#acpi_m006.t b/test/035_#acpi_m006.t index 1d4d0b0..b74d9ef 100644 --- a/test/035_#acpi_m006.t +++ b/test/035_#acpi_m006.t @@ -1,3 +1,4 @@ +umka_init pci_set_path machines/006/pci acpi_set_usage 2 diff --git a/test/036_#acpi_m007.ref.log b/test/036_#acpi_m007.ref.log index a24802b..a4a1ee0 100644 --- a/test/036_#acpi_m007.ref.log +++ b/test/036_#acpi_m007.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> pci_set_path machines/007/pci /> acpi_set_usage 2 diff --git a/test/036_#acpi_m007.t b/test/036_#acpi_m007.t index b7d874d..70cac47 100644 --- a/test/036_#acpi_m007.t +++ b/test/036_#acpi_m007.t @@ -1,3 +1,4 @@ +umka_init pci_set_path machines/007/pci acpi_set_usage 2 diff --git a/test/038_#acpi_m008.ref.log b/test/038_#acpi_m008.ref.log index 4b69bfb..2b3ff72 100644 --- a/test/038_#acpi_m008.ref.log +++ b/test/038_#acpi_m008.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> acpi_set_usage 1 /> acpi_preload_table machines/008/acpi/dsdt.dat diff --git a/test/038_#acpi_m008.t b/test/038_#acpi_m008.t index f08e70a..59336e7 100644 --- a/test/038_#acpi_m008.t +++ b/test/038_#acpi_m008.t @@ -1,3 +1,4 @@ +umka_init acpi_set_usage 1 acpi_preload_table machines/008/acpi/dsdt.dat diff --git a/test/040_#acpi_m010.ref.log b/test/040_#acpi_m010.ref.log index 667f33c..3a08de7 100644 --- a/test/040_#acpi_m010.ref.log +++ b/test/040_#acpi_m010.ref.log @@ -1,3 +1,4 @@ +/> umka_init /> acpi_set_usage 1 /> acpi_preload_table machines/010/acpi/dsdt.dat diff --git a/test/040_#acpi_m010.t b/test/040_#acpi_m010.t index 7784728..02bea06 100644 --- a/test/040_#acpi_m010.t +++ b/test/040_#acpi_m010.t @@ -1,3 +1,4 @@ +umka_init acpi_set_usage 1 acpi_preload_table machines/010/acpi/dsdt.dat diff --git a/test/041_#acpi_alloc_free.ref.log b/test/041_#acpi_alloc_free.ref.log index d95c4d1..99bf395 100644 --- a/test/041_#acpi_alloc_free.ref.log +++ b/test/041_#acpi_alloc_free.ref.log @@ -5,9 +5,9 @@ table #0 /> acpi_enable acpi.aml.process_table begin -table length 0x00000032 +table length 0x0000012C Table signature: 'DSDT' -Table length (with header): 0x00000032 +Table length (with header): 0x0000012C Revision: 0x01 OEM ID: 'UMKA ' OEM Table ID: 'UMKADSDT' @@ -44,13 +44,64 @@ table/position: [0x0000002B] aml._.term_obj begin aml._.object begin aml._.namespace_modifier_obj begin +aml._.name begin +aml._.name_string begin +aml._.name_string begin again +offset: 0x0000002C +aml._.name_path begin +aml._.name_path end +name_string: REF5 +aml._.name_string end +aml._.get_node_by_name begin +name: '' +aml._.get_node_by_name end +aml._.data_ref_object begin +aml._.data_object begin +aml._.computational_data begin +aml._.byte_const begin +aml._.byte_const end +aml._.computational_data end +aml._.data_object end +aml._.data_ref_object end +aml._.name end +aml._.namespace_modifier_obj end +aml._.object end +aml._.term_obj end +table/position: [0x00000032] +aml._.term_obj begin +aml._.object begin +aml._.namespace_modifier_obj begin aml._.namespace_modifier_obj end aml._.named_obj begin aml._.method begin -pkg_length: 0x00000006 +pkg_length: 0x000000EA aml._.name_string begin aml._.name_string begin again -offset: 0x0000002D +offset: 0x00000035 +aml._.name_path begin +aml._.name_path end +name_string: AREF +aml._.name_string end +aml._.attach_node begin +aml._.get_node_by_name begin +name: '' +aml._.get_node_by_name end +aml._.attach_node end +aml._.method end +aml._.named_obj end +aml._.object end +aml._.term_obj end +table/position: [0x0000011D] +aml._.term_obj begin +aml._.object begin +aml._.namespace_modifier_obj begin +aml._.namespace_modifier_obj end +aml._.named_obj begin +aml._.method begin +pkg_length: 0x0000000E +aml._.name_string begin +aml._.name_string begin again +offset: 0x0000011F aml._.name_path begin aml._.name_path end name_string: MAIN @@ -65,7 +116,9 @@ aml._.named_obj end aml._.object end aml._.term_obj end ==========ACPI_TREE========== -\MAIN Method length:0x00000000 Args:0 serialize:0 sync_level:0 +\MAIN Method length:0x00000008 Args:0 serialize:0 sync_level:0 +\AREF Method length:0x000000E3 Args:1 serialize:0 sync_level:0 +\REF5 Integer = 0x0000000000000002 \INT5 Integer = 0x0000000000000005 \_TZ_ Scope \_SI_ Scope @@ -75,7 +128,9 @@ aml._.term_obj end ----------------------------- acpi.aml.process_table end ==========ACPI_TREE========== -\MAIN Method length:0x00000000 Args:0 serialize:0 sync_level:0 +\MAIN Method length:0x00000008 Args:0 serialize:0 sync_level:0 +\AREF Method length:0x000000E3 Args:1 serialize:0 sync_level:0 +\REF5 Integer = 0x0000000000000002 \INT5 Integer = 0x0000000000000005 \_TZ_ Scope \_SI_ Scope @@ -85,11 +140,11 @@ acpi.aml.process_table end ----------------------------- /> acpi_get_node_alloc_cnt -nodes allocated: 9 +nodes allocated: 11 /> acpi_get_node_free_cnt nodes freed: 0 /> acpi_get_node_cnt -nodes in namespace: 9 +nodes in namespace: 11 /> acpi_call \MAIN acpi.call_name begin @@ -98,17 +153,270 @@ name: '\MAIN' aml._.get_node_by_name end acpi.call_node begin # func name MAIN -# bytes 0x00000000 -# bytes 0x00000000 -# bytes 0xDF590000 -acpi.call_node end -acpi.call_name end -calling acpi method: '\MAIN' -acpi method returned +# bytes 0x46455241 +# bytes 0x35544E49 +# bytes 0x0001DE69 +table/position: [0x00000124] +aml._.term_obj begin +aml._.object begin +aml._.namespace_modifier_obj begin +aml._.namespace_modifier_obj end +aml._.named_obj begin +aml._.named_obj end +aml._.object end +aml._.type1opcode begin +aml._.type1opcode end +aml._.name_string begin +aml._.name_string begin again +offset: 0x00000124 +aml._.name_path begin +aml._.name_path end +name_string: AREF +aml._.name_string end +aml._.get_node_by_name begin +name: 'AREF' +aml._.get_node_by_name end +aml._.method_invocation begin +arg_count: 1 +aml._.term_arg begin +aml._.name_string begin +aml._.name_string begin again +offset: 0x00000128 +aml._.name_path begin +aml._.name_path end +name_string: INT5 +aml._.name_string end +aml._.get_node_by_name begin +name: 'INT5' +aml._.get_node_by_name end +aml._.data_object begin +aml._.computational_data begin +aml._.computational_data end +aml._.data_object end +aml._.name_string begin +aml._.name_string begin again +offset: 0x00000128 +aml._.name_path begin +aml._.name_path end +name_string: INT5 +aml._.name_string end +aml._.get_node_by_name begin +name: 'INT5' +aml._.get_node_by_name end +aml._.term_arg end +table/position: [0x0000003A] +aml._.term_obj begin +aml._.object begin +aml._.namespace_modifier_obj begin +aml._.namespace_modifier_obj end +aml._.named_obj begin +aml._.named_obj end +aml._.object end +aml._.type1opcode begin +aml._.type1opcode end +aml._.store begin +aml._.term_arg begin +aml._.name_string begin +aml._.name_string begin again +offset: 0x0000003B +aml._.name_path begin +aml._.name_path end +name_string: INT5 +aml._.name_string end +aml._.get_node_by_name begin +name: 'INT5' +aml._.get_node_by_name end +aml._.data_object begin +aml._.computational_data begin +aml._.computational_data end +aml._.data_object end +aml._.name_string begin +aml._.name_string begin again +offset: 0x0000003B +aml._.name_path begin +aml._.name_path end +name_string: INT5 +aml._.name_string end +aml._.get_node_by_name begin +name: 'INT5' +aml._.get_node_by_name end +aml._.term_arg end +aml._.super_name begin +aml._.simple_name begin +aml._.name_string begin +aml._.name_string end +aml._.simple_name end +aml._.debug_obj begin +aml._.debug_obj end +aml._.super_name end +aml._.store_table begin +types 2 to 19 +aml._.store_table.integer_to_debug_object begin +AML_DBG: 0x0000000000000005 +aml._.store_table.integer_to_debug_object end +aml._.store_table end +aml._.store end +aml._.term_obj end +table/position: [0x00000041] +aml._.term_obj begin +aml._.object begin +aml._.namespace_modifier_obj begin +aml._.namespace_modifier_obj end +aml._.named_obj begin +aml._.named_obj end +aml._.object end +aml._.type1opcode begin +aml._.type1opcode end +aml._.store begin +aml._.term_arg begin +aml._.name_string begin +aml._.name_string end +aml._.data_object begin +aml._.computational_data begin +aml._.computational_data end +aml._.data_object end +aml._.arg_obj begin +aml._.arg_obj end +aml._.term_arg end +aml._.super_name begin +aml._.simple_name begin +aml._.name_string begin +aml._.name_string end +aml._.simple_name end +aml._.debug_obj begin +aml._.debug_obj end +aml._.super_name end +aml._.store_table begin +types 2 to 19 +aml._.store_table.integer_to_debug_object begin +AML_DBG: 0x0000000000000005 +aml._.store_table.integer_to_debug_object end +aml._.store_table end +aml._.store end +aml._.term_obj end +table/position: [0x00000045] +aml._.term_obj begin +aml._.object begin +aml._.namespace_modifier_obj begin +aml._.namespace_modifier_obj end +aml._.named_obj begin +aml._.named_obj end +aml._.object end +aml._.type1opcode begin +aml._.type1opcode end +aml._.store begin +aml._.term_arg begin +aml._.name_string begin +aml._.name_string begin again +offset: 0x00000046 +aml._.name_path begin +aml._.name_path end +name_string: REF5 +aml._.name_string end +aml._.get_node_by_name begin +name: 'REF5' +aml._.get_node_by_name end +aml._.data_object begin +aml._.computational_data begin +aml._.computational_data end +aml._.data_object end +aml._.name_string begin +aml._.name_string begin again +offset: 0x00000046 +aml._.name_path begin +aml._.name_path end +name_string: REF5 +aml._.name_string end +aml._.get_node_by_name begin +name: 'REF5' +aml._.get_node_by_name end +aml._.term_arg end +aml._.super_name begin +aml._.simple_name begin +aml._.name_string begin +aml._.name_string end +aml._.simple_name end +aml._.debug_obj begin +aml._.debug_obj end +aml._.super_name end +aml._.store_table begin +types 2 to 19 +aml._.store_table.integer_to_debug_object begin +AML_DBG: 0x0000000000000002 +aml._.store_table.integer_to_debug_object end +aml._.store_table end +aml._.store end +aml._.term_obj end +table/position: [0x0000004C] +aml._.term_obj begin +aml._.object begin +aml._.namespace_modifier_obj begin +aml._.namespace_modifier_obj end +aml._.named_obj begin +aml._.named_obj end +aml._.object end +aml._.type1opcode begin +aml._.type1opcode end +aml._.store begin +aml._.term_arg begin +aml._.name_string begin +aml._.name_string end +aml._.data_object begin +aml._.computational_data begin +aml._.string begin +aml._.string end +aml._.computational_data end +aml._.data_object end +aml._.term_arg end +aml._.super_name begin +aml._.simple_name begin +aml._.name_string begin +aml._.name_string end +aml._.simple_name end +aml._.debug_obj begin +aml._.debug_obj end +aml._.super_name end +aml._.store_table begin +types 3 to 19 +aml._.store_table.string_to_debug_object begin +AML_DBG: -/> acpi_get_node_alloc_cnt -nodes allocated: 9 -/> acpi_get_node_free_cnt -nodes freed: 0 -/> acpi_get_node_cnt -nodes in namespace: 9 +aml._.store_table.string_to_debug_object end +aml._.store_table end +aml._.store end +aml._.term_obj end +table/position: [0x00000052] +aml._.term_obj begin +aml._.object begin +aml._.namespace_modifier_obj begin +aml._.namespace_modifier_obj end +aml._.named_obj begin +aml._.named_obj end +aml._.object end +aml._.type1opcode begin +aml._.type1opcode end +aml._.store begin +aml._.term_arg begin +aml._.name_string begin +aml._.name_string end +aml._.data_object begin +aml._.computational_data begin +aml._.computational_data end +aml._.data_object end +aml._.name_string begin +aml._.name_string end +error: unknown term_arg: 0x71 +aml._.term_arg end +aml._.super_name begin +aml._.simple_name begin +aml._.name_string begin +aml._.name_string end +aml._.simple_name end +aml._.name_string begin +aml._.name_string end +aml._.super_name end +aml._.store end +aml._.name_string begin +aml._.name_string end +aml._.term_obj end +error: unknown bytes: 0x7168 diff --git a/test/042_#acpi_m011.ref.log b/test/042_#acpi_m011.ref.log index 04995d0..8aa645d 100644 --- a/test/042_#acpi_m011.ref.log +++ b/test/042_#acpi_m011.ref.log @@ -1,3 +1,4 @@ +/> umka_init #pci_set_path machines/011/pci /> acpi_set_usage 1 diff --git a/test/042_#acpi_m011.t b/test/042_#acpi_m011.t index e163102..4e74bd3 100644 --- a/test/042_#acpi_m011.t +++ b/test/042_#acpi_m011.t @@ -1,3 +1,4 @@ +umka_init #pci_set_path machines/011/pci acpi_set_usage 1 diff --git a/test/044_#f01_#draw_winmap.ref.log b/test/044_#f01_#draw_winmap.ref.log new file mode 100644 index 0000000..2378131 --- /dev/null +++ b/test/044_#f01_#draw_winmap.ref.log @@ -0,0 +1,166 @@ +/> umka_set_boot_params --x_res 44 --y_res 44 +/> umka_init +/> ramdisk_init ../img/kolibri.img +/rd/1: fat +/> set_skin /sys/DEFAULT.SKN +status: 0 + +/> window_redraw 1 +/> draw_window 2 10 4 10 0x000088 1 1 1 0 1 4 hello +/> window_redraw 2 + +/> set_window_caption hi_there 0 + +/> new_sys_thread +tid: 3 +/> switch_to_thread 3 + +/> window_redraw 1 +/> draw_window 4 5 8 5 0x000088 1 1 1 0 1 4 hello +/> window_redraw 2 + +/> dump_win_map +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11223333332221111111111111111111111111111111 +11223333332221111111111111111111111111111111 +11223333332221111111111111111111111111111111 +11223333332221111111111111111111111111111111 +11223333332221111111111111111111111111111111 +11223333332221111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 + +/> set redraw_background 0 +/> move_window 6 8 5 5 +/> dump_win_map +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11222233333321111111111111111111111111111111 +11222233333321111111111111111111111111111111 +11222233333321111111111111111111111111111111 +11222233333321111111111111111111111111111111 +11222233333321111111111111111111111111111111 +11222233333321111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 + +/> set redraw_background 0 +/> move_window 6 10 5 5 +/> dump_win_map +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11222222222221111111111111111111111111111111 +11222233333321111111111111111111111111111111 +11222233333321111111111111111111111111111111 +11222233333321111111111111111111111111111111 +11222233333321111111111111111111111111111111 +11222233333321111111111111111111111111111111 +11111133333311111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 +11111111111111111111111111111111111111111111 + +/> scrot 044_#f01_#draw_winmap.out.png + +/> disk_del rd diff --git a/test/044_#f01_#draw_winmap.ref.png b/test/044_#f01_#draw_winmap.ref.png new file mode 100644 index 0000000000000000000000000000000000000000..ba6403bd10e0f862924a05a4652a4355b415263c GIT binary patch literal 159 zcmeAS@N?(olHy`uVBq!ia0vp^Iv~u#3?$#IayJ4}`~f~8u0T2^CFT6}y9W*&`2YWZ z@pCy1ppdtxi(^Oy 1 && *argv[optind] != '-') { - infile = argv[optind++]; - strncpy(outfile, infile, PATH_MAX-2); // ".t" is shorter than ".out" - char *last_dot = strrchr(outfile, '.'); - if (!last_dot) { - printf("test file must have '.t' suffix\n"); - return 1; - } - strcpy(last_dot, ".out.log"); - } + kos_boot.bpp = 32; + kos_boot.x_res = UMKA_DEFAULT_DISPLAY_WIDTH; + kos_boot.y_res = UMKA_DEFAULT_DISPLAY_HEIGHT; + kos_boot.pitch = UMKA_DEFAULT_DISPLAY_WIDTH*4; // 32bpp - if (infile) { - fin = fopen(infile, "r"); - } - if (*outfile) { - fout = fopen(outfile, "w"); - } - if (!fin || !fout) { - printf("can't open in/out files\n"); - return 1; - } + // skip 'umka_shell' + argc -= 1; + argv += 1; - while ((opt = getopt(argc, argv, "c")) != -1) { - switch (opt) { - case 'c': + while (argc) { + if (!strcmp(argv[0], "-c")) { coverage = 1; - break; - default: + argc -= 1; + argv += 1; + continue; + } else if (!strcmp(argv[0], "-i") && argc > 1) { + infile = argv[1]; + strncpy(outfile, infile, PATH_MAX-2); // ".t" is shorter than ".out" + char *last_dot = strrchr(outfile, '.'); + if (!last_dot) { + printf("[!] test file must have '.t' suffix\n"); + exit(1); + } + strcpy(last_dot, ".out.log"); + fin = fopen(infile, "r"); + if (!fin) { + perror("[!] can't open file"); + exit(1); + } + fout = fopen(outfile, "w"); + if (!fout) { + perror("[!] can't open file"); + exit(1); + } + argc -= 2; + argv += 2; + continue; + } else { + printf("bad option: %s\n", argv[0]); puts(usage); - return 1; + exit(1); } } if (coverage) trace_begin(); - COVERAGE_ON(); - umka_init(); - COVERAGE_OFF(); - run_test(fin, fout, 1); if (coverage)