Mercurial > lcfOS
diff cos/kernel/klib.c @ 32:3a6a9b929db0
Added initial ramdisk and some virtual file system functions
author | windel |
---|---|
date | Fri, 13 Jan 2012 18:18:17 +0100 |
parents | 7e3bdcb391dc |
children | 91f91ff07ea8 |
line wrap: on
line diff
--- a/cos/kernel/klib.c Tue Jan 10 20:40:35 2012 +0100 +++ b/cos/kernel/klib.c Fri Jan 13 18:18:17 2012 +0100 @@ -1,5 +1,6 @@ #include "kernel.h" +/* Panic and shutdown functions */ void magicBochsBreak() { asm volatile("xchg %bx, %bx"); @@ -28,7 +29,7 @@ asm volatile("hlt"); } -// IO port helpers: +/* IO port helpers: */ void outb(uint16_t port, uint8_t value) { asm volatile ("outb %1, %0" : : "dN" (port), "a" (value)); @@ -48,7 +49,7 @@ return ret; } -// string functions: +/* string functions: */ int strncmp(const char* s1, const char* s2, int size) { int i; @@ -59,7 +60,6 @@ return 1; } -// mem functions: void memset(void* data, uint8_t value, uint64_t size) { uint64_t i;