josh
0ae3c6c96d
Document xHCI operational registers
2023-09-23 11:59:20 -04:00
josh
4814b51daf
Dump xHCI extended capabilities
2023-09-19 11:07:18 -04:00
josh
14bb3adf37
Document xHCI capability registers
2023-09-19 11:07:02 -04:00
josh
cda45b205d
Remove legacy PCI bus scanning
2023-09-17 16:13:37 -04:00
josh
cfd42550fc
Add struct definitions for all PCI header types
2023-09-17 15:22:58 -04:00
josh
673ce8f097
Scan PCI devices via MCFG table
2023-09-17 14:49:02 -04:00
josh
ba0befa21b
Check that needed ACPI tables are found
2023-09-17 13:40:26 -04:00
josh
fa4de31aa4
Store pertinent ACPI table pointers
2023-09-17 11:22:58 -04:00
josh
3412d9ece9
Add Klog.fatal_error()
2023-09-17 11:15:02 -04:00
josh
e8978c73f2
Move PCI initialization after ACPI/APIC/RTC
2023-09-17 11:00:48 -04:00
josh
f79b0098c5
Map ACPI tables as disable cache + no execute
2023-09-17 09:12:20 -04:00
josh
10d7e7f0c6
Move parsing of ACPI tables into table structures
...
Move mapping ACPI table memory into common location
2023-09-17 09:08:01 -04:00
josh
e088f942d1
Use Acpi.Header in ACPI table structures
2023-09-17 08:53:34 -04:00
josh
6514af8e94
Begin parsing MCFG ACPI table
2023-09-17 08:41:08 -04:00
josh
602a7525d2
Add %p format specifier for printing pointers
2023-09-16 17:09:55 -04:00
josh
617b861524
Size to hulk.elf.size
2023-09-15 13:38:25 -04:00
josh
2f968de7ed
Disassemble to hulk.elf.txt
2023-09-15 13:37:48 -04:00
josh
68e85999fb
Drop unused sections when linking HULK
2023-09-15 13:37:00 -04:00
josh
6b1445935c
Update mk-vmdk task to have a file template since VBoxManage createmedium command was failing
2023-09-15 11:04:36 -04:00
josh
665d8aef80
Update qemu command to change machine to q35
...
This enables PCIe
2023-09-15 11:04:12 -04:00
josh
af5ad73cf7
Update instructions for VirtualBox to change machine chipset
...
This enables PCIe
2023-09-15 11:03:39 -04:00
josh
4c67faaad4
Rework Kfont to store glyph top as offset from top of text row
2023-09-13 13:48:11 -04:00
josh
4fcea6a283
Reverse framebuffer vertical coordinates to start with 0 at top
2023-09-13 11:57:47 -04:00
josh
c958b9ffcc
Remove alpha-blending framebuffer functions
2023-09-13 10:57:45 -04:00
josh
3d911ab191
Adjust console text height by font baseline offset
...
This fixes having leftover pixels on screen bottom when scrolling the
console up.
2023-09-13 10:52:24 -04:00
josh
d04c5444c7
fontgen: put character number before character data
2023-09-13 08:54:09 -04:00
josh
209658ee09
Use cache to mkdir_p for HulkBinObj builder
2023-09-10 09:48:07 -04:00
josh
f3f45445b3
Determine XHCI controller addresses
2023-09-07 14:04:30 -04:00
josh
459d5c36aa
Set alignment of XSDT table pointers to 4 instead of 8
2023-09-07 12:57:26 -04:00
josh
22c9891c4f
Add page_address()
2023-09-07 12:51:41 -04:00
josh
2a832bfb8b
Print progress messages for cross compiler toolchain installation
2023-09-06 22:58:18 -04:00
josh
496445e533
Fix linker script section placement
2023-09-06 16:40:17 -04:00
josh
156642293f
Debug output HULK memory range end addresses
2023-09-04 21:20:10 -04:00
josh
4e46b98efc
Capture QEMU serial port output
2023-09-04 21:13:35 -04:00
josh
ce3e2c55df
Store QEMU files in local qemu directory
2023-09-04 21:12:36 -04:00
josh
cb24d00e5f
Document running in QEMU in README
2023-09-04 21:04:30 -04:00
josh
4500f3cbca
Write HELLO memory map debug data to serial port
2023-09-04 20:59:38 -04:00
josh
0781962e9f
Rework HELLO console module to use hulk.writef
2023-09-04 16:17:47 -04:00
josh
e25d28ebc7
Add serial module
2023-09-04 14:56:12 -04:00
josh
93a4065dea
Add path to OVMF.fd for Arch
2023-09-04 14:07:05 -04:00
josh
5b017fb810
Add some xHCI register structures
2023-06-11 17:22:50 -04:00
josh
37814b4f86
Start on XHCI struct
2023-06-10 22:55:08 -04:00
josh
238659e94b
Store PCI device mapped memory ranges
2023-06-10 22:22:09 -04:00
josh
c16aa0e9c3
Add hulk.range
2023-06-10 22:21:55 -04:00
josh
2935903bae
Map PCI device memory regions
2023-06-10 20:12:46 -04:00
josh
5179b5881b
Read PCI device header type
2023-06-10 12:01:06 -04:00
josh
a0c62937ff
Remove Pci.init_device() for now
2023-06-10 11:28:51 -04:00
josh
657287c160
Move Pci.scan() recursion into scan() itself
2023-06-10 11:20:50 -04:00
josh
d600e089e5
Add Pci.Device class
2023-06-10 11:16:27 -04:00
josh
dd07a08388
Fix A1 allocator to map the correct pages
2023-06-10 11:06:41 -04:00
josh
63fbbc9051
Use ulong for round_up_power_2()
2023-06-10 10:59:46 -04:00
josh
3e32802862
Add A1.allocate() template to allocate struct/class instances
2023-06-10 10:30:56 -04:00
josh
40ff805f7d
Add Pci.Address struct
2023-06-10 09:35:52 -04:00
josh
9ac69c9003
Add Pci.write_config_register()
2023-06-10 09:19:58 -04:00
josh
7aa28da1ef
Allow pointers or integers for Hurl.*map_range()
2023-06-09 23:38:52 -04:00
josh
222a1efea4
Fix address calculation in Hurl.identity_map_range()
2023-06-09 23:27:20 -04:00
josh
7a4edf38f0
Scan for multi-function PCI devices
2023-06-08 20:28:32 -04:00
josh
dda1b6379f
Fix in32()/out32() to use uint instead of ulong
2023-06-08 16:07:44 -04:00
josh
98134957e7
Print APIC table signatures found
2023-06-08 13:21:43 -04:00
josh
22463e729b
writef: add %c format specifier support
2023-06-08 13:21:24 -04:00
josh
8de86dd647
Add Pci.init_device() skeleton
2023-06-07 16:49:54 -04:00
josh
f6fde01b06
Fix build error -- import hulk.util
2023-04-05 01:08:55 -04:00
josh
ea6f485bd9
Add hulk.util and round_up_power_2()
2023-02-24 21:15:33 -05:00
josh
2ab388f2e9
Remove seconds counter printout
2023-02-24 20:58:11 -05:00
josh
cc891f6d4d
Assign PCI header fields to named variables
2023-02-24 20:53:46 -05:00
josh
f5e5c40c12
Reduce Hurl.map() template overhead
2023-01-02 20:46:12 -05:00
josh
7b09c9beed
Add A1 memory allocator
2023-01-01 22:02:48 -05:00
josh
103205bff2
Move address constants into Hurl struct
2023-01-01 21:04:29 -05:00
josh
25ee1775f0
Capitalize namespacing structs
...
This helps to avoid name clashes when breaking up modules into packages.
2023-01-01 17:34:41 -05:00
josh
a423cdf1b1
Fix RTC clock reading in 24-hour mode
2022-12-19 11:32:08 -05:00
josh
7c8744d1e0
Read RTC date and time
2022-12-18 22:29:12 -05:00
josh
4081a220ef
Route I/O APIC interrupts, enable RTC tick interrupt
2022-12-16 00:32:49 -05:00
josh
9adc248225
Initialize rtc module
2022-12-15 20:41:44 -05:00
josh
676fd17bf5
Add pit and rtc modules
2022-12-15 20:41:15 -05:00
josh
b1a8f8d348
Handle local APIC exceptions
2022-12-07 23:24:01 -05:00
josh
9b52ae58e8
Get local APIC timer ready to run
2022-12-07 23:13:51 -05:00
josh
5799f94efe
Configure local APIC interrupt vectors
2022-12-06 22:06:57 -05:00
josh
400a7b22db
Enable local APIC interrupts
2022-12-06 21:22:56 -05:00
josh
2bba0dfca4
Add hulk.mtrr module
2022-11-08 21:49:41 -05:00
josh
edba40b2c6
Implement frame buffer double-buffering
...
This slowed down drawing to video in QEMU/VirtualBox but greatly sped up
doing so on real hardware (no longer reading from video memory).
Despite the speed-up, it is still quite slow though.
2022-11-08 06:19:03 -05:00
josh
55604468c8
Allocate framebuffer buffer1 in HELLO
2022-11-07 21:27:52 -05:00
josh
71c30fa932
Reclaim bootloader page table pages
2022-11-06 21:59:42 -05:00
josh
b3fb599b25
Move EFER initialization to initialize_cpu()
2022-11-05 22:49:57 -04:00
josh
d357aada75
Map HULK regions separately
2022-11-05 22:45:35 -04:00
josh
1fef8ada29
Define acpi structs as static
2022-11-05 22:26:21 -04:00
josh
5231930543
Clean up ApicRegister
2022-11-05 22:22:09 -04:00
josh
95b9e4558a
Move hulk.writef buffer variables to stack
...
Previously ldc2 was emitting AVX/SSE instructions to initialize these
buffers.
2022-11-05 22:06:18 -04:00
josh
354555d7f1
Disable AVX and SSE instruction generation for HULK
2022-11-05 22:03:13 -04:00
josh
1b69810e8f
Turn on OSXSAVE
2022-11-05 21:17:30 -04:00
josh
64190b04cb
Add initialize_cpu()
2022-11-05 20:27:48 -04:00
josh
d7b12c7896
Run qemu with maximum supported host CPU features
2022-11-05 20:15:30 -04:00
josh
11f922da33
Add write_cr0()
2022-11-05 19:58:10 -04:00
josh
59e084c234
Add cpuid1() and output bit enums
2022-11-04 19:28:34 -04:00
josh
f21ee0d149
Add enums for a few CPU register bits
2022-11-04 00:08:40 -04:00
josh
2a7c783bba
Add write_cr4()
2022-11-03 23:31:55 -04:00
josh
1f2a2bea48
Add xgetbv()/xsetbv()
2022-11-03 22:45:35 -04:00
josh
8eedf4e267
Switch klog buffer to ubyte array to move it to bss section
2022-11-03 16:34:03 -04:00
josh
ae49c29c75
Fail build if thread-local data is found
2022-11-03 16:17:42 -04:00
josh
4d88810fc1
Move hulk.writef hex character strings out of data section
2022-11-03 16:03:12 -04:00
josh
ba9cf30e67
Clean up linker script symbols
2022-11-03 15:41:14 -04:00