feat: implemented errno, strtol. Started ustar. Reformatted headers and

code. Added some self-tests. Started prepwork for vfs.
This commit is contained in:
2021-03-14 21:14:22 +01:00
parent 586b8191b4
commit 77c8dca72a
39 changed files with 504 additions and 60 deletions

View File

@@ -11,14 +11,20 @@
#include <myke/mem/mem.h>
#include <myke/mem/malloc.h>
#include <myke/cpu/timer.h>
#include <myke/drivers/pci.h>
#include <myke/drivers/ide.h>
#include <myke/drivers/pci/pci.h>
#include <myke/drivers/pci/ide.h>
#include <myke/fs/blockdev.h>
#include <myke/fs/mbr.h>
#include <readline/readline.h>
#include <myke/attributes.h>
#include <myke/util/power.h>
#ifdef ENABLE_SELF_TEST
#include <myke/debug/debug.h>
#endif
#define BOOTLOADER_NAME_MAX_LENGTH 64
#define CMDLINE_MAX_LENGTH 256
@@ -44,16 +50,29 @@ void shutdown(const char *args);
void explode(const char *args);
#ifdef ENABLE_SELF_TEST
void exec_self_test(const char *args);
#endif
cmd_handler cmd_handlers[] = {
{"help\0", help},
{"echo\0", echo},
{"print\0", print},
{"ide\0", ide},
{"help", help},
{"echo", echo},
{"print", print},
{"ide", ide},
{"shutdown", shutdown},
{"explode", explode},
{"explode", explode},
#ifdef ENABLE_SELF_TEST
{"self-test", exec_self_test},
#endif
{NULL, NULL},
};
void exec_self_test(const char *args) {
self_test();
}
void explode(const char *args) {
uint32_t x = 0;