diff options
-rw-r--r-- | Makefrag.am | 28 | ||||
-rw-r--r-- | arch/x86/machine/acpimp.c | 10 | ||||
-rw-r--r-- | arch/x86/machine/biosmem.c | 10 | ||||
-rw-r--r-- | arch/x86/machine/boot.c | 7 | ||||
-rw-r--r-- | arch/x86/machine/boot.h | 2 | ||||
-rw-r--r-- | arch/x86/machine/cpu.c | 10 | ||||
-rw-r--r-- | arch/x86/machine/cpu.h | 6 | ||||
-rw-r--r-- | arch/x86/machine/io.h | 2 | ||||
-rw-r--r-- | arch/x86/machine/lapic.c | 5 | ||||
-rw-r--r-- | arch/x86/machine/lapic.h | 2 | ||||
-rw-r--r-- | arch/x86/machine/multiboot.h | 4 | ||||
-rw-r--r-- | arch/x86/machine/param.h | 2 | ||||
-rw-r--r-- | arch/x86/machine/pic.c | 4 | ||||
-rw-r--r-- | arch/x86/machine/pit.c | 2 | ||||
-rw-r--r-- | arch/x86/machine/pmap.c | 8 | ||||
-rw-r--r-- | arch/x86/machine/pmap.h | 4 | ||||
-rw-r--r-- | arch/x86/machine/trap.c | 4 | ||||
-rw-r--r-- | arch/x86/machine/trap.h | 2 | ||||
-rw-r--r-- | arch/x86/machine/vga.c | 6 | ||||
-rw-r--r-- | arch/x86/machine/vga.h | 2 | ||||
-rw-r--r-- | kern/assert.h (renamed from lib/assert.h) | 8 | ||||
-rw-r--r-- | kern/init.h | 2 | ||||
-rw-r--r-- | kern/kmem.c | 18 | ||||
-rw-r--r-- | kern/kmem.h | 6 | ||||
-rw-r--r-- | kern/limits.h (renamed from lib/limits.h) | 6 | ||||
-rw-r--r-- | kern/list.h (renamed from lib/list.h) | 10 | ||||
-rw-r--r-- | kern/macros.h (renamed from lib/macros.h) | 8 | ||||
-rw-r--r-- | kern/panic.h | 2 | ||||
-rw-r--r-- | kern/printk.c | 2 | ||||
-rw-r--r-- | kern/printk.h | 2 | ||||
-rw-r--r-- | kern/rbtree.c (renamed from lib/rbtree.c) | 10 | ||||
-rw-r--r-- | kern/rbtree.h (renamed from lib/rbtree.h) | 14 | ||||
-rw-r--r-- | kern/rbtree_i.h (renamed from lib/rbtree_i.h) | 12 | ||||
-rw-r--r-- | kern/sprintf.c (renamed from lib/sprintf.c) | 8 | ||||
-rw-r--r-- | kern/sprintf.h (renamed from lib/sprintf.h) | 8 | ||||
-rw-r--r-- | kern/stddef.h (renamed from lib/stddef.h) | 6 | ||||
-rw-r--r-- | kern/stdint.h (renamed from lib/stdint.h) | 6 | ||||
-rw-r--r-- | kern/string.c (renamed from lib/string.c) | 4 | ||||
-rw-r--r-- | kern/string.h (renamed from lib/string.h) | 8 | ||||
-rw-r--r-- | vm/vm_kmem.c | 4 | ||||
-rw-r--r-- | vm/vm_map.c | 12 | ||||
-rw-r--r-- | vm/vm_map.h | 6 | ||||
-rw-r--r-- | vm/vm_page.h | 4 | ||||
-rw-r--r-- | vm/vm_phys.c | 12 |
44 files changed, 149 insertions, 149 deletions
diff --git a/Makefrag.am b/Makefrag.am index e2639a68..22cc0121 100644 --- a/Makefrag.am +++ b/Makefrag.am @@ -1,6 +1,7 @@ include arch/x86/Makefrag.am x15_SOURCES += \ + kern/assert.h \ kern/config.h \ kern/error.h \ kern/init.h \ @@ -8,30 +9,27 @@ x15_SOURCES += \ kern/kernel.h \ kern/kmem.c \ kern/kmem.h \ + kern/limits.h \ + kern/list.h \ + kern/macros.h \ kern/panic.c \ kern/panic.h \ kern/param.h \ kern/printk.c \ kern/printk.h \ + kern/rbtree.c \ + kern/rbtree.h \ + kern/rbtree_i.h \ kern/spinlock.h \ + kern/sprintf.c \ + kern/sprintf.h \ + kern/stddef.h \ + kern/stdint.h \ + kern/string.c \ + kern/string.h \ kern/types.h x15_SOURCES += \ - lib/assert.h \ - lib/limits.h \ - lib/list.h \ - lib/macros.h \ - lib/rbtree.c \ - lib/rbtree.h \ - lib/rbtree_i.h \ - lib/sprintf.c \ - lib/sprintf.h \ - lib/stddef.h \ - lib/stdint.h \ - lib/string.c \ - lib/string.h - -x15_SOURCES += \ vm/vm_inherit.h \ vm/vm_kmem.c \ vm/vm_kmem.h \ diff --git a/arch/x86/machine/acpimp.c b/arch/x86/machine/acpimp.c index 92b28ebd..0b13cd25 100644 --- a/arch/x86/machine/acpimp.c +++ b/arch/x86/machine/acpimp.c @@ -15,16 +15,16 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +#include <kern/assert.h> #include <kern/init.h> #include <kern/kmem.h> +#include <kern/macros.h> #include <kern/panic.h> #include <kern/printk.h> +#include <kern/stddef.h> +#include <kern/stdint.h> +#include <kern/string.h> #include <kern/types.h> -#include <lib/assert.h> -#include <lib/macros.h> -#include <lib/stddef.h> -#include <lib/stdint.h> -#include <lib/string.h> #include <machine/acpimp.h> #include <machine/biosmem.h> #include <machine/cpu.h> diff --git a/arch/x86/machine/biosmem.c b/arch/x86/machine/biosmem.c index 77bc8d0c..a72a8016 100644 --- a/arch/x86/machine/biosmem.c +++ b/arch/x86/machine/biosmem.c @@ -15,16 +15,16 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +#include <kern/assert.h> #include <kern/init.h> +#include <kern/macros.h> #include <kern/panic.h> #include <kern/param.h> #include <kern/printk.h> +#include <kern/stddef.h> +#include <kern/stdint.h> +#include <kern/string.h> #include <kern/types.h> -#include <lib/assert.h> -#include <lib/macros.h> -#include <lib/stddef.h> -#include <lib/stdint.h> -#include <lib/string.h> #include <machine/biosmem.h> #include <machine/boot.h> #include <machine/multiboot.h> diff --git a/arch/x86/machine/boot.c b/arch/x86/machine/boot.c index 691605f5..35fabb53 100644 --- a/arch/x86/machine/boot.c +++ b/arch/x86/machine/boot.c @@ -45,12 +45,13 @@ #include <kern/init.h> #include <kern/kmem.h> #include <kern/kernel.h> +#include <kern/macros.h> #include <kern/panic.h> #include <kern/param.h> #include <kern/printk.h> -#include <lib/stddef.h> -#include <lib/stdint.h> -#include <lib/string.h> +#include <kern/stddef.h> +#include <kern/stdint.h> +#include <kern/string.h> #include <machine/biosmem.h> #include <machine/boot.h> #include <machine/cpu.h> diff --git a/arch/x86/machine/boot.h b/arch/x86/machine/boot.h index 41d3ca49..992e533a 100644 --- a/arch/x86/machine/boot.h +++ b/arch/x86/machine/boot.h @@ -18,7 +18,7 @@ #ifndef _X86_BOOT_H #define _X86_BOOT_H -#include <lib/macros.h> +#include <kern/macros.h> #include <machine/param.h> /* diff --git a/arch/x86/machine/cpu.c b/arch/x86/machine/cpu.c index 57a3e465..18dcadac 100644 --- a/arch/x86/machine/cpu.c +++ b/arch/x86/machine/cpu.c @@ -15,15 +15,15 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +#include <kern/assert.h> #include <kern/init.h> +#include <kern/macros.h> #include <kern/panic.h> #include <kern/param.h> #include <kern/printk.h> -#include <lib/assert.h> -#include <lib/macros.h> -#include <lib/stddef.h> -#include <lib/stdint.h> -#include <lib/string.h> +#include <kern/stddef.h> +#include <kern/stdint.h> +#include <kern/string.h> #include <machine/acpimp.h> #include <machine/biosmem.h> #include <machine/boot.h> diff --git a/arch/x86/machine/cpu.h b/arch/x86/machine/cpu.h index 1543baa1..c2dce19b 100644 --- a/arch/x86/machine/cpu.h +++ b/arch/x86/machine/cpu.h @@ -87,10 +87,10 @@ #ifndef __ASSEMBLER__ +#include <kern/macros.h> #include <kern/param.h> -#include <lib/macros.h> -#include <lib/stddef.h> -#include <lib/stdint.h> +#include <kern/stddef.h> +#include <kern/stdint.h> #include <machine/pit.h> #define CPU_VENDOR_ID_SIZE 13 diff --git a/arch/x86/machine/io.h b/arch/x86/machine/io.h index d99d180f..6b10f0eb 100644 --- a/arch/x86/machine/io.h +++ b/arch/x86/machine/io.h @@ -18,7 +18,7 @@ #ifndef _X86_IO_H #define _X86_IO_H -#include <lib/stdint.h> +#include <kern/stdint.h> /* * Read a byte from an I/O port. diff --git a/arch/x86/machine/lapic.c b/arch/x86/machine/lapic.c index 03a2820f..c2a2b3aa 100644 --- a/arch/x86/machine/lapic.c +++ b/arch/x86/machine/lapic.c @@ -16,11 +16,12 @@ */ #include <kern/init.h> +#include <kern/macros.h> #include <kern/panic.h> #include <kern/param.h> #include <kern/printk.h> -#include <lib/macros.h> -#include <lib/stdint.h> +#include <kern/stddef.h> +#include <kern/stdint.h> #include <machine/cpu.h> #include <machine/lapic.h> #include <machine/pmap.h> diff --git a/arch/x86/machine/lapic.h b/arch/x86/machine/lapic.h index 8e74f617..24d104cd 100644 --- a/arch/x86/machine/lapic.h +++ b/arch/x86/machine/lapic.h @@ -18,7 +18,7 @@ #ifndef _X86_LAPIC_H #define _X86_LAPIC_H -#include <lib/stdint.h> +#include <kern/stdint.h> #include <machine/trap.h> /* diff --git a/arch/x86/machine/multiboot.h b/arch/x86/machine/multiboot.h index 7b604a98..b0d31524 100644 --- a/arch/x86/machine/multiboot.h +++ b/arch/x86/machine/multiboot.h @@ -45,8 +45,8 @@ #ifndef __ASSEMBLER__ -#include <lib/macros.h> -#include <lib/stdint.h> +#include <kern/macros.h> +#include <kern/stdint.h> /* * A multiboot module. diff --git a/arch/x86/machine/param.h b/arch/x86/machine/param.h index e7241fd6..73e1ced1 100644 --- a/arch/x86/machine/param.h +++ b/arch/x86/machine/param.h @@ -18,7 +18,7 @@ #ifndef _X86_PARAM_H #define _X86_PARAM_H -#include <lib/macros.h> +#include <kern/macros.h> #include <machine/pmap.h> #define __LITTLE_ENDIAN__ diff --git a/arch/x86/machine/pic.c b/arch/x86/machine/pic.c index ddb895bd..3e5d8bbb 100644 --- a/arch/x86/machine/pic.c +++ b/arch/x86/machine/pic.c @@ -15,10 +15,10 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +#include <kern/assert.h> #include <kern/init.h> #include <kern/panic.h> -#include <lib/assert.h> -#include <lib/stdint.h> +#include <kern/stdint.h> #include <machine/io.h> #include <machine/cpu.h> #include <machine/pic.h> diff --git a/arch/x86/machine/pit.c b/arch/x86/machine/pit.c index e5113ceb..ea7a1a58 100644 --- a/arch/x86/machine/pit.c +++ b/arch/x86/machine/pit.c @@ -15,8 +15,8 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +#include <kern/assert.h> #include <kern/init.h> -#include <lib/assert.h> #include <machine/io.h> #include <machine/pit.h> diff --git a/arch/x86/machine/pmap.c b/arch/x86/machine/pmap.c index 8365b8a8..703d842a 100644 --- a/arch/x86/machine/pmap.c +++ b/arch/x86/machine/pmap.c @@ -15,14 +15,14 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +#include <kern/assert.h> #include <kern/init.h> +#include <kern/macros.h> #include <kern/panic.h> #include <kern/param.h> +#include <kern/stddef.h> +#include <kern/string.h> #include <kern/types.h> -#include <lib/assert.h> -#include <lib/macros.h> -#include <lib/stddef.h> -#include <lib/string.h> #include <machine/biosmem.h> #include <machine/boot.h> #include <machine/cpu.h> diff --git a/arch/x86/machine/pmap.h b/arch/x86/machine/pmap.h index 7865f5fa..81cc998c 100644 --- a/arch/x86/machine/pmap.h +++ b/arch/x86/machine/pmap.h @@ -21,7 +21,7 @@ #ifndef _X86_PMAP_H #define _X86_PMAP_H -#include <lib/macros.h> +#include <kern/macros.h> /* * Page table entry flags. @@ -100,8 +100,8 @@ #ifndef __ASSEMBLER__ +#include <kern/stdint.h> #include <kern/types.h> -#include <lib/stdint.h> #ifdef X86_PAE typedef uint64_t pmap_pte_t; diff --git a/arch/x86/machine/trap.c b/arch/x86/machine/trap.c index 56715c81..4b450ecf 100644 --- a/arch/x86/machine/trap.c +++ b/arch/x86/machine/trap.c @@ -15,11 +15,11 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +#include <kern/assert.h> #include <kern/init.h> +#include <kern/macros.h> #include <kern/panic.h> #include <kern/printk.h> -#include <lib/assert.h> -#include <lib/macros.h> #include <machine/cpu.h> #include <machine/lapic.h> #include <machine/pic.h> diff --git a/arch/x86/machine/trap.h b/arch/x86/machine/trap.h index 161694de..f25c5893 100644 --- a/arch/x86/machine/trap.h +++ b/arch/x86/machine/trap.h @@ -57,7 +57,7 @@ #ifndef __ASSEMBLER__ -#include <lib/macros.h> +#include <kern/macros.h> #ifdef __LP64__ diff --git a/arch/x86/machine/vga.c b/arch/x86/machine/vga.c index 60911943..08b72332 100644 --- a/arch/x86/machine/vga.c +++ b/arch/x86/machine/vga.c @@ -16,9 +16,9 @@ */ #include <kern/init.h> -#include <lib/macros.h> -#include <lib/stdint.h> -#include <lib/string.h> +#include <kern/macros.h> +#include <kern/stdint.h> +#include <kern/string.h> #include <machine/io.h> #include <machine/pmap.h> #include <machine/vga.h> diff --git a/arch/x86/machine/vga.h b/arch/x86/machine/vga.h index f6836cd9..6e7c6043 100644 --- a/arch/x86/machine/vga.h +++ b/arch/x86/machine/vga.h @@ -18,7 +18,7 @@ #ifndef _X86_VGA_H #define _X86_VGA_H -#include <lib/stdint.h> +#include <kern/stdint.h> /* * Initialize the vga module. diff --git a/lib/assert.h b/kern/assert.h index 79e23680..d0fd08a5 100644 --- a/lib/assert.h +++ b/kern/assert.h @@ -15,15 +15,15 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -#ifndef _LIB_ASSERT_H -#define _LIB_ASSERT_H +#ifndef _KERN_ASSERT_H +#define _KERN_ASSERT_H #ifdef NDEBUG #define assert(expression) ((void)(expression)) #else /* NDEBUG */ +#include <kern/macros.h> #include <kern/panic.h> -#include <lib/macros.h> /* * Panic if the given expression is false. @@ -37,4 +37,4 @@ MACRO_END #endif /* NDEBUG */ -#endif /* _LIB_ASSERT_H */ +#endif /* _KERN_ASSERT_H */ diff --git a/kern/init.h b/kern/init.h index e9762724..6e437c0a 100644 --- a/kern/init.h +++ b/kern/init.h @@ -18,7 +18,7 @@ #ifndef _KERN_INIT_H #define _KERN_INIT_H -#include <lib/macros.h> +#include <kern/macros.h> /* * These sections should contain code and data which can be discarded once diff --git a/kern/kmem.c b/kern/kmem.c index 663cafe2..70aeebb6 100644 --- a/kern/kmem.c +++ b/kern/kmem.c @@ -48,20 +48,20 @@ * handled likewise. */ +#include <kern/assert.h> #include <kern/init.h> +#include <kern/limits.h> +#include <kern/list.h> #include <kern/kmem.h> +#include <kern/macros.h> #include <kern/panic.h> #include <kern/param.h> #include <kern/printk.h> -#include <lib/assert.h> -#include <lib/limits.h> -#include <lib/list.h> -#include <lib/macros.h> -#include <lib/rbtree.h> -#include <lib/sprintf.h> -#include <lib/stddef.h> -#include <lib/stdint.h> -#include <lib/string.h> +#include <kern/rbtree.h> +#include <kern/sprintf.h> +#include <kern/stddef.h> +#include <kern/stdint.h> +#include <kern/string.h> #include <machine/cpu.h> #include <vm/vm_kmem.h> diff --git a/kern/kmem.h b/kern/kmem.h index dee4a857..350c8977 100644 --- a/kern/kmem.h +++ b/kern/kmem.h @@ -21,10 +21,10 @@ #ifndef _KERN_KMEM_H #define _KERN_KMEM_H +#include <kern/list.h> #include <kern/param.h> -#include <lib/list.h> -#include <lib/rbtree.h> -#include <lib/stddef.h> +#include <kern/rbtree.h> +#include <kern/stddef.h> /* * Per-processor cache of pre-constructed objects. diff --git a/lib/limits.h b/kern/limits.h index 8f0bd4df..48f4b945 100644 --- a/lib/limits.h +++ b/kern/limits.h @@ -15,9 +15,9 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -#ifndef _LIB_LIMITS_H -#define _LIB_LIMITS_H +#ifndef _KERN_LIMITS_H +#define _KERN_LIMITS_H #define CHAR_BIT 8 -#endif /* _LIB_LIMITS_H */ +#endif /* _KERN_LIMITS_H */ diff --git a/lib/list.h b/kern/list.h index b530d6c4..647e94c9 100644 --- a/lib/list.h +++ b/kern/list.h @@ -18,11 +18,11 @@ * Simple doubly-linked list. */ -#ifndef _LIB_LIST_H -#define _LIB_LIST_H +#ifndef _KERN_LIST_H +#define _KERN_LIST_H -#include <lib/macros.h> -#include <lib/stddef.h> +#include <kern/macros.h> +#include <kern/stddef.h> /* * Structure used as both head and node. @@ -361,4 +361,4 @@ for (entry = list_entry(list_last(list), typeof(*entry), member), \ entry = tmp, tmp = list_entry(list_prev(&entry->member), \ typeof(*entry), member)) -#endif /* _LIB_LIST_H */ +#endif /* _KERN_LIST_H */ diff --git a/lib/macros.h b/kern/macros.h index 99837147..012dd15b 100644 --- a/lib/macros.h +++ b/kern/macros.h @@ -18,11 +18,11 @@ * Helper macros. */ -#ifndef _LIB_MACROS_H -#define _LIB_MACROS_H +#ifndef _KERN_MACROS_H +#define _KERN_MACROS_H #ifndef __ASSEMBLER__ -#include <lib/stddef.h> +#include <kern/stddef.h> #endif /* __ASSEMBLER__ */ #define MACRO_BEGIN ({ @@ -70,4 +70,4 @@ #define __format_printf(fmt, args) \ __attribute__((format(printf, fmt, args))) -#endif /* _LIB_MACROS_H */ +#endif /* _KERN_MACROS_H */ diff --git a/kern/panic.h b/kern/panic.h index a3bfbbe2..9d1d31e0 100644 --- a/kern/panic.h +++ b/kern/panic.h @@ -18,7 +18,7 @@ #ifndef _KERN_PANIC_H #define _KERN_PANIC_H -#include <lib/macros.h> +#include <kern/macros.h> /* * Print the given message and halt the system immediately. diff --git a/kern/printk.c b/kern/printk.c index 38d835c0..386ac979 100644 --- a/kern/printk.c +++ b/kern/printk.c @@ -17,7 +17,7 @@ #include <kern/printk.h> #include <kern/spinlock.h> -#include <lib/sprintf.h> +#include <kern/sprintf.h> /* * Size of the static buffer. diff --git a/kern/printk.h b/kern/printk.h index 37f25453..5e2a871b 100644 --- a/kern/printk.h +++ b/kern/printk.h @@ -29,7 +29,7 @@ #include <stdarg.h> -#include <lib/macros.h> +#include <kern/macros.h> int printk(const char *format, ...) __format_printf(1, 2); int vprintk(const char *format, va_list ap) __format_printf(1, 0); diff --git a/lib/rbtree.c b/kern/rbtree.c index 16718968..569d3fac 100644 --- a/lib/rbtree.c +++ b/kern/rbtree.c @@ -15,11 +15,11 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -#include <lib/assert.h> -#include <lib/macros.h> -#include <lib/rbtree.h> -#include <lib/rbtree_i.h> -#include <lib/stddef.h> +#include <kern/assert.h> +#include <kern/macros.h> +#include <kern/rbtree.h> +#include <kern/rbtree_i.h> +#include <kern/stddef.h> /* * Return the index of a node in the children array of its parent. diff --git a/lib/rbtree.h b/kern/rbtree.h index e607fcea..45521c13 100644 --- a/lib/rbtree.h +++ b/kern/rbtree.h @@ -18,12 +18,12 @@ * Red-black tree. */ -#ifndef _LIB_RBTREE_H -#define _LIB_RBTREE_H +#ifndef _KERN_RBTREE_H +#define _KERN_RBTREE_H -#include <lib/assert.h> -#include <lib/macros.h> -#include <lib/stddef.h> +#include <kern/assert.h> +#include <kern/macros.h> +#include <kern/stddef.h> /* * Indexes of the left and right nodes in the children array of a node. @@ -46,7 +46,7 @@ struct rbtree; */ #define RBTREE_INITIALIZER { NULL } -#include "rbtree_i.h" +#include <kern/rbtree_i.h> /* * Initialize a tree. @@ -296,4 +296,4 @@ for (node = rbtree_postwalk_deepest(tree), \ node != NULL; \ node = tmp, tmp = rbtree_postwalk_unlink(node)) \ -#endif /* _LIB_RBTREE_H */ +#endif /* _KERN_RBTREE_H */ diff --git a/lib/rbtree_i.h b/kern/rbtree_i.h index 1f85c1a9..7f9650e7 100644 --- a/lib/rbtree_i.h +++ b/kern/rbtree_i.h @@ -15,12 +15,12 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -#ifndef _LIB_RBTREE_I_H -#define _LIB_RBTREE_I_H +#ifndef _KERN_RBTREE_I_H +#define _KERN_RBTREE_I_H -#include <lib/assert.h> -#include <lib/macros.h> -#include <lib/stddef.h> +#include <kern/assert.h> +#include <kern/macros.h> +#include <kern/stddef.h> /* * Red-black node structure. @@ -184,4 +184,4 @@ struct rbtree_node * rbtree_postwalk_deepest(const struct rbtree *tree); */ struct rbtree_node * rbtree_postwalk_unlink(struct rbtree_node *node); -#endif /* _LIB_RBTREE_I_H */ +#endif /* _KERN_RBTREE_I_H */ diff --git a/lib/sprintf.c b/kern/sprintf.c index 7cf1e136..13f2671e 100644 --- a/lib/sprintf.c +++ b/kern/sprintf.c @@ -17,10 +17,10 @@ #include <stdarg.h> -#include <lib/limits.h> -#include <lib/sprintf.h> -#include <lib/stddef.h> -#include <lib/stdint.h> +#include <kern/limits.h> +#include <kern/sprintf.h> +#include <kern/stddef.h> +#include <kern/stdint.h> /* * Formatting flags. diff --git a/lib/sprintf.h b/kern/sprintf.h index af9e841b..0c097953 100644 --- a/lib/sprintf.h +++ b/kern/sprintf.h @@ -25,12 +25,12 @@ * The supported length modifiers are: hh h l ll z t */ -#ifndef _LIB_SPRINTF_H -#define _LIB_SPRINTF_H +#ifndef _KERN_SPRINTF_H +#define _KERN_SPRINTF_H #include <stdarg.h> -#include <lib/macros.h> +#include <kern/macros.h> int sprintf(char *str, const char *format, ...) __format_printf(2, 3); int vsprintf(char *str, const char *format, va_list ap) __format_printf(2, 0); @@ -40,4 +40,4 @@ int snprintf(char *str, size_t size, const char *format, ...) int vsnprintf(char *str, size_t size, const char *format, va_list ap) __format_printf(3, 0); -#endif /* _LIB_SPRINTF_H */ +#endif /* _KERN_SPRINTF_H */ diff --git a/lib/stddef.h b/kern/stddef.h index 2cbb7a9e..b07c9924 100644 --- a/lib/stddef.h +++ b/kern/stddef.h @@ -15,8 +15,8 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -#ifndef _LIB_STDDEF_H -#define _LIB_STDDEF_H +#ifndef _KERN_STDDEF_H +#define _KERN_STDDEF_H #define NULL ((void *)0) @@ -32,4 +32,4 @@ typedef int ssize_t; typedef int ptrdiff_t; #endif /* __LP64__ */ -#endif /* _LIB_STDDEF_H */ +#endif /* _KERN_STDDEF_H */ diff --git a/lib/stdint.h b/kern/stdint.h index 17cb9a2b..d6794c4e 100644 --- a/lib/stdint.h +++ b/kern/stdint.h @@ -15,8 +15,8 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -#ifndef _LIB_STDINT_H -#define _LIB_STDINT_H +#ifndef _KERN_STDINT_H +#define _KERN_STDINT_H typedef signed char int8_t; typedef unsigned char uint8_t; @@ -27,4 +27,4 @@ typedef unsigned int uint32_t; typedef signed long long int64_t; typedef unsigned long long uint64_t; -#endif /* _LIB_STDINT_H */ +#endif /* _KERN_STDINT_H */ diff --git a/lib/string.c b/kern/string.c index f0ed626c..82bcd2f1 100644 --- a/lib/string.c +++ b/kern/string.c @@ -18,8 +18,8 @@ * Trivial, portable implementations. */ -#include <lib/stddef.h> -#include <lib/string.h> +#include <kern/stddef.h> +#include <kern/string.h> void * memcpy(void *dest, const void *src, size_t n) diff --git a/lib/string.h b/kern/string.h index 936892bd..8dd4d9d0 100644 --- a/lib/string.h +++ b/kern/string.h @@ -15,10 +15,10 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -#ifndef _LIB_STRING_H -#define _LIB_STRING_H +#ifndef _KERN_STRING_H +#define _KERN_STRING_H -#include <lib/stddef.h> +#include <kern/stddef.h> void * memcpy(void *dest, const void *src, size_t n); void * memmove(void *dest, const void *src, size_t n); @@ -28,4 +28,4 @@ size_t strlen(const char *s); char * strcpy(char *dest, const char *src); int strcmp(const char *s1, const char *s2); -#endif /* _LIB_STRING_H */ +#endif /* _KERN_STRING_H */ diff --git a/vm/vm_kmem.c b/vm/vm_kmem.c index 72d02899..a90fb058 100644 --- a/vm/vm_kmem.c +++ b/vm/vm_kmem.c @@ -15,12 +15,12 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +#include <kern/assert.h> #include <kern/init.h> #include <kern/panic.h> #include <kern/param.h> +#include <kern/stddef.h> #include <kern/types.h> -#include <lib/assert.h> -#include <lib/stddef.h> #include <machine/pmap.h> #include <vm/vm_map.h> #include <vm/vm_kmem.h> diff --git a/vm/vm_map.c b/vm/vm_map.c index 6eecab73..8343472f 100644 --- a/vm/vm_map.c +++ b/vm/vm_map.c @@ -19,18 +19,18 @@ * needed for kernel allocation. */ +#include <kern/assert.h> #include <kern/error.h> #include <kern/init.h> #include <kern/kmem.h> +#include <kern/list.h> +#include <kern/macros.h> #include <kern/panic.h> #include <kern/param.h> #include <kern/printk.h> -#include <lib/assert.h> -#include <lib/list.h> -#include <lib/macros.h> -#include <lib/rbtree.h> -#include <lib/stddef.h> -#include <lib/stdint.h> +#include <kern/rbtree.h> +#include <kern/stddef.h> +#include <kern/stdint.h> #include <machine/pmap.h> #include <vm/vm_map.h> #include <vm/vm_kmem.h> diff --git a/vm/vm_map.h b/vm/vm_map.h index 7231b6a3..9759ff4b 100644 --- a/vm/vm_map.h +++ b/vm/vm_map.h @@ -21,9 +21,9 @@ #ifndef _VM_VM_MAP_H #define _VM_VM_MAP_H -#include <lib/list.h> -#include <lib/rbtree.h> -#include <lib/stdint.h> +#include <kern/list.h> +#include <kern/rbtree.h> +#include <kern/stdint.h> #include <machine/pmap.h> /* diff --git a/vm/vm_page.h b/vm/vm_page.h index e499dc52..e5ad8fc5 100644 --- a/vm/vm_page.h +++ b/vm/vm_page.h @@ -18,8 +18,8 @@ #ifndef _VM_VM_PAGE_H #define _VM_VM_PAGE_H -#include <lib/list.h> -#include <lib/macros.h> +#include <kern/list.h> +#include <kern/macros.h> #include <kern/param.h> #include <kern/types.h> diff --git a/vm/vm_phys.c b/vm/vm_phys.c index 81e655bf..9fcc7cc9 100644 --- a/vm/vm_phys.c +++ b/vm/vm_phys.c @@ -29,17 +29,17 @@ * The symmetric case is handled likewise. */ +#include <kern/assert.h> #include <kern/init.h> +#include <kern/list.h> +#include <kern/macros.h> #include <kern/panic.h> #include <kern/param.h> #include <kern/printk.h> +#include <kern/sprintf.h> +#include <kern/stddef.h> +#include <kern/string.h> #include <kern/types.h> -#include <lib/assert.h> -#include <lib/list.h> -#include <lib/macros.h> -#include <lib/sprintf.h> -#include <lib/stddef.h> -#include <lib/string.h> #include <machine/cpu.h> #include <vm/vm_kmem.h> #include <vm/vm_page.h> |