636 Commits

Author SHA1 Message Date
wash 15ddd2fe0b x86_64: use e64patch to generate kernel binary for QEMU 2023-02-07 11:25:58 +00:00
wash 2f69bfd4f0 build: add support for building tools targeting host machine 2023-02-07 11:25:33 +00:00
wash 625eac9ca7 x86_64: implement bootstrap function for pmap interface 2023-02-06 20:50:38 +00:00
wash 52b3a5d6a5 x86_64: enable hugepage support in QEMU 2023-02-06 20:50:38 +00:00
wash 5e20bbe223 x86_64: use higher-half pointer for VGA framebuffer 2023-02-06 20:50:38 +00:00
wash 0516ef06a3 vm: explicitly initialise kmalloc in vm_bootstrap
if kmalloc is called with count=N before vm_bootstrap is finished,
the request will be fulfilled using memblock_alloc.

if N is a power of 2, the returned pointer will be aligned to
an N-byte boundary.
2023-02-06 20:50:38 +00:00
wash fe0b7e043f x86_64: move stack pointer to higher-half in start_64 2023-02-06 20:50:38 +00:00
wash 5c7bde4fdf vm: add alignment parameter to cache allocator
caches with object size N, where N is a power of two, will naturally
align their objects on N-byte boundaries.

all other caches will align to an 8-byte boundary by default.
2023-02-06 20:50:38 +00:00
wash 109616ec30 vm: add memblock support to vm_virt_to_phys, add vm_phys_to_virt 2023-02-06 20:50:38 +00:00
wash 998f05d337 memblock: add functions to convert allocated pointers between virt/phys 2023-02-06 20:50:38 +00:00
wash 6afb3bd10d memblock: add alignment parameter to alloc functions 2023-02-06 20:50:38 +00:00
wash a72117abcd x86_64: move start_64 to .boot.text 2023-02-06 10:41:06 +00:00
wash b7f872bf3b build: enable -Os flag 2023-02-05 11:08:22 +00:00
wash b9b3794aee x86_64: initialise memblock using e820 2023-02-05 10:50:13 +00:00
wash 21907010bd memblock: return NULL on virtual alloc failure 2023-02-05 10:49:59 +00:00
wash 58171df912 vm: move arch-specific definitions to arch/ 2023-02-05 10:28:07 +00:00
wash 72b2d8d525 x86_64: re-implement ml_halt_cpu() in pure assembly 2023-02-05 10:27:29 +00:00
wash 2b2c5a24da x86_64: fix broken multiboot pointer boot arg 2023-02-05 10:26:47 +00:00
wash 1abc7a4f6c x86_64: move non-ML headers to include/arch/ 2023-02-05 09:45:17 +00:00
wash 17b90a484a kernel: print version banner on boot 2023-02-04 19:19:48 +00:00
wash 49d2b0a847 x86_64: make vgacon clear the display on init 2023-02-04 19:19:37 +00:00
wash dee639968b x86_64: remove vga functions from start_32 and start_64 2023-02-04 19:18:25 +00:00
wash 31cb7aab8b kernel: add basic console registration system and printk() 2023-02-04 19:03:45 +00:00
wash d0a431c860 kernel: add basic spinlocks 2023-02-04 19:03:30 +00:00
wash 6e290ee18a x86_64: cleanup 2023-02-04 15:25:39 +00:00
wash 6eb9c5ad6c sandbox: delete orphaned test files 2023-02-03 20:53:48 +00:00
wash 247bb2b530 kernel: port sandbox components 2023-02-03 20:51:23 +00:00
wash 40f83922da sandbox: moved all sources to main kernel tree 2023-02-03 20:43:38 +00:00
wash e714d619ba kernel: remove placeholder vm subsystem 2023-02-03 20:37:45 +00:00
wash bcdf101779 kernel: add stub logging function 2023-02-03 20:26:02 +00:00
wash c65f034e0e kernel: x86_64: add machine init function called by kernel_init 2023-02-03 20:24:27 +00:00
wash dba6269fcb kernel: remove printf() (but keep other string formatters) 2023-02-03 20:23:36 +00:00
wash 453ccd4596 sandbox: multi-threaded kmalloc() stress-test 2023-02-02 21:16:17 +00:00
wash d4e8754f21 sandbox: vm: implement vm_cache_free() and kfree() 2023-02-02 21:15:59 +00:00
wash 4237b6ca20 sandbox: vm: add synchronisation using spinlocks 2023-02-02 21:14:02 +00:00
wash d4449b8d87 sandbox: vm: make kmalloc(size: 0) return NULL 2023-02-02 21:12:14 +00:00
wash ba415b2942 sandbox: vm: fix double evaluation of queue_pop_front() 2023-02-02 21:11:29 +00:00
wash 4175f67b9b sandbox: vm: replace calls to queue_length() with queue_empty() 2023-02-02 21:10:37 +00:00
wash a33c490852 sandbox: vm: vm_page p_slab field is now set for slab pages 2023-02-02 21:07:22 +00:00
wash c47da5864c sandbox: vm: add temporary vm_virt_to_phys() implementation 2023-02-02 21:06:04 +00:00
wash 90dd51008f sandbox: vm: fix vm_cache.c_hdr_size not being calculated 2023-02-02 21:03:27 +00:00
wash d43347436f sandbox: memblock: align allocated pointers to 16-byte boundary 2023-02-02 21:01:22 +00:00
wash 799a23014a sandbox: add locking primitives 2023-02-02 21:00:40 +00:00
wash 7d3000e84d sandbox: queue: remove q_length field, add queue_empty() 2023-02-02 21:00:23 +00:00
wash 662be5ec1f sandbox: vm: add cache allocator, generic size-N caches for kmalloc() 2023-02-02 16:58:48 +00:00
wash 3c781a4cb3 sandbox: vm: make vm_page queue entry private, owner-defined usage 2023-02-02 16:58:24 +00:00
wash e5a7546996 sandbox: vm: temporary implementation of vm_page_get_vaddr() 2023-02-02 16:57:03 +00:00
wash 7331bdefda sandbox: vm: reduce vm_page order field size to 4 bits 2023-02-02 16:54:48 +00:00
wash ab46b7cd13 sandbox: vm: fix bad array index in replenish_free_page_list 2023-02-02 16:47:32 +00:00
wash 49e23849a5 sandbox: queue: check list is not empty before popping entries 2023-02-02 16:45:13 +00:00