Move to kernel/
diff --git a/src/Makefile b/src/Makefile
index a1527de..55265bc 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -1,49 +1,2 @@
-SOURCES = 	boot.o \
-			main.o \
-			descriptor_tables.o \
-			io.o \
-			vga.o \
-			gdt_flush.o \
-			idt.o \
-			log.o \
-			irq.o \
-			pic.o \
-			timer.o \
-			paging.o \
-			switch_table.o \
-			scan_codes.o
-CFLAGS = -nostdlib -nostdinc -fno-builtin -fno-stack-protector -ffreestanding -m32 -O2 -g
-LDFLAGS = -Tlink.ld -melf_i386
-ASMFLAGS = -felf
-QEMUFLAGS = -d cpu_reset
-
-kernel.elf: $(SOURCES)
-	ld $(LDFLAGS) -o $@ $^
-
-clean:
-	rm -f *.o *.bin *.elf ../bin/*.iso
-
-debug: kernel.elf
-	qemu-system-i386 -s -S -kernel kernel.elf &
-	@echo run "target remote localhost:1234" to connect to qemu
-	gdb
-	@pkill qemu-system-i38
-
-qemu: kernel.elf
-	qemu-system-i386 $(QEMUFLAGS) -monitor stdio -kernel kernel.elf -no-reboot
-
-qemu-iso: install
-	qemu-system-i386 $(QEMUFLAGS) -monitor stdio ../bin/bluejay.iso
-
-scan_codes.c: gen_scan_codes.py scan_codes.tsv 
-	python3 $< > $@
-
-.s.o:
-	nasm $(ASMFLAGS) $<
-
-install: kernel.elf
-	cp kernel.elf ../boot/
-	rm -f ../bin/bluejay.iso
-	grub-mkrescue -o ../bin/bluejay.iso ..
-
-.PHONY: install qemu clean qemu-iso debug
+kernel:
+	$(MAKE) -C kernel install
diff --git a/src/.gdbinit b/src/kernel/.gdbinit
similarity index 100%
rename from src/.gdbinit
rename to src/kernel/.gdbinit
diff --git a/src/kernel/Makefile b/src/kernel/Makefile
new file mode 100644
index 0000000..f369294
--- /dev/null
+++ b/src/kernel/Makefile
@@ -0,0 +1,51 @@
+SOURCES = 	boot.o \
+			main.o \
+			descriptor_tables.o \
+			io.o \
+			vga.o \
+			gdt_flush.o \
+			idt.o \
+			log.o \
+			irq.o \
+			pic.o \
+			timer.o \
+			paging.o \
+			switch_table.o \
+			scan_codes.o
+CFLAGS = -nostdlib -nostdinc -fno-builtin -fno-stack-protector -ffreestanding -m32 -O2 -g
+LDFLAGS = -Tlink.ld -melf_i386
+ASMFLAGS = -felf
+QEMUFLAGS = -d cpu_reset
+
+JAYROOT = ../../
+
+kernel.elf: $(SOURCES)
+	ld $(LDFLAGS) -o $@ $^
+
+clean:
+	rm -f *.o *.bin *.elf $(JAYROOT)/bin/*.iso
+
+debug: kernel.elf
+	qemu-system-i386 -s -S -kernel kernel.elf &
+	@echo run "target remote localhost:1234" to connect to qemu
+	gdb
+	@pkill qemu-system-i38
+
+qemu: kernel.elf
+	qemu-system-i386 $(QEMUFLAGS) -monitor stdio -kernel kernel.elf -no-reboot
+
+qemu-iso: install
+	qemu-system-i386 $(QEMUFLAGS) -monitor stdio $(JAYROOT)/bin/bluejay.iso
+
+scan_codes.c: gen_scan_codes.py scan_codes.tsv 
+	python3 $< > $@
+
+.s.o:
+	nasm $(ASMFLAGS) $<
+
+install: kernel.elf
+	cp kernel.elf ../boot/
+	rm -f $(JAYROOT)/bin/bluejay.iso
+	grub-mkrescue -o $(JAYROOT)/bin/bluejay.iso ..
+
+.PHONY: install qemu clean qemu-iso debug
diff --git a/src/boot.s b/src/kernel/boot.s
similarity index 100%
rename from src/boot.s
rename to src/kernel/boot.s
diff --git a/src/descriptor_tables.c b/src/kernel/descriptor_tables.c
similarity index 100%
rename from src/descriptor_tables.c
rename to src/kernel/descriptor_tables.c
diff --git a/src/descriptor_tables.h b/src/kernel/descriptor_tables.h
similarity index 100%
rename from src/descriptor_tables.h
rename to src/kernel/descriptor_tables.h
diff --git a/src/gdt_flush.s b/src/kernel/gdt_flush.s
similarity index 100%
rename from src/gdt_flush.s
rename to src/kernel/gdt_flush.s
diff --git a/src/gen_scan_codes.py b/src/kernel/gen_scan_codes.py
similarity index 100%
rename from src/gen_scan_codes.py
rename to src/kernel/gen_scan_codes.py
diff --git a/src/idt.s b/src/kernel/idt.s
similarity index 100%
rename from src/idt.s
rename to src/kernel/idt.s
diff --git a/src/io.c b/src/kernel/io.c
similarity index 100%
rename from src/io.c
rename to src/kernel/io.c
diff --git a/src/io.h b/src/kernel/io.h
similarity index 100%
rename from src/io.h
rename to src/kernel/io.h
diff --git a/src/irq.s b/src/kernel/irq.s
similarity index 100%
rename from src/irq.s
rename to src/kernel/irq.s
diff --git a/src/kbd.h b/src/kernel/kbd.h
similarity index 100%
rename from src/kbd.h
rename to src/kernel/kbd.h
diff --git a/src/kint.h b/src/kernel/kint.h
similarity index 100%
rename from src/kint.h
rename to src/kernel/kint.h
diff --git a/src/link.ld b/src/kernel/link.ld
similarity index 100%
rename from src/link.ld
rename to src/kernel/link.ld
diff --git a/src/log.c b/src/kernel/log.c
similarity index 100%
rename from src/log.c
rename to src/kernel/log.c
diff --git a/src/log.h b/src/kernel/log.h
similarity index 100%
rename from src/log.h
rename to src/kernel/log.h
diff --git a/src/main.c b/src/kernel/main.c
similarity index 100%
rename from src/main.c
rename to src/kernel/main.c
diff --git a/src/paging.c b/src/kernel/paging.c
similarity index 100%
rename from src/paging.c
rename to src/kernel/paging.c
diff --git a/src/paging.h b/src/kernel/paging.h
similarity index 100%
rename from src/paging.h
rename to src/kernel/paging.h
diff --git a/src/pic.c b/src/kernel/pic.c
similarity index 100%
rename from src/pic.c
rename to src/kernel/pic.c
diff --git a/src/pic.h b/src/kernel/pic.h
similarity index 100%
rename from src/pic.h
rename to src/kernel/pic.h
diff --git a/src/registers.h b/src/kernel/registers.h
similarity index 100%
rename from src/registers.h
rename to src/kernel/registers.h
diff --git a/src/scan_codes.c b/src/kernel/scan_codes.c
similarity index 100%
rename from src/scan_codes.c
rename to src/kernel/scan_codes.c
diff --git a/src/scan_codes.tsv b/src/kernel/scan_codes.tsv
similarity index 100%
rename from src/scan_codes.tsv
rename to src/kernel/scan_codes.tsv
diff --git a/src/srcmap.txt b/src/kernel/srcmap.txt
similarity index 100%
rename from src/srcmap.txt
rename to src/kernel/srcmap.txt
diff --git a/src/stdarg.h b/src/kernel/stdarg.h
similarity index 100%
rename from src/stdarg.h
rename to src/kernel/stdarg.h
diff --git a/src/switch_table.s b/src/kernel/switch_table.s
similarity index 100%
rename from src/switch_table.s
rename to src/kernel/switch_table.s
diff --git a/src/timer.c b/src/kernel/timer.c
similarity index 100%
rename from src/timer.c
rename to src/kernel/timer.c
diff --git a/src/timer.h b/src/kernel/timer.h
similarity index 100%
rename from src/timer.h
rename to src/kernel/timer.h
diff --git a/src/vga.c b/src/kernel/vga.c
similarity index 100%
rename from src/vga.c
rename to src/kernel/vga.c
diff --git a/src/vga.h b/src/kernel/vga.h
similarity index 100%
rename from src/vga.h
rename to src/kernel/vga.h