Compare commits

..

24 Commits

Author SHA1 Message Date
cbb44a5a10
kernel/ATA: Route interrupts to the correct drive
Some checks failed
continuous-integration/drone/pr Build is failing
2023-06-03 20:59:01 +02:00
7545cb055c
kernel: Start reading the MBR partition table from the ATAPI drive 2023-06-03 20:59:01 +02:00
159bdeffb9
ATA: Mark the CDROM as a block device 2023-06-03 20:59:01 +02:00
6ea67bfb61
kernel/ATA: Pass extra information to DeviceRegistry
This is needed since merging e7d482e from main.
2023-06-03 20:59:01 +02:00
b63f0f8009
kernel+init: Create a device node in /dev to access the CDROM from userspace!
Still using PIO, though.
2023-06-03 20:59:00 +02:00
0ab0aaf129
kernel/ATA: Read the CDROM's first sector using ATAPI PIO!!
Sadly, for some reason, DMA is not working right now.
This is a problem, as PIO is inconvenient. But hey, it works for now!
2023-06-03 20:59:00 +02:00
804bc78dbb
kernel/x86_64: Implement writing to PCI fields 2023-06-03 20:59:00 +02:00
0254849a5c
kernel/PCI: Add bit enum for the Command field 2023-06-03 20:59:00 +02:00
544c6abccd
kernel: Actually register interrupt handlers properly 2023-06-03 20:58:59 +02:00
b8f173bced
kernel/ATA: Calculate block sizes for ATA devices as well 2023-06-03 20:58:59 +02:00
3733b0f26e
kernel/ATA: Send a READ CAPACITY packet to an ATA drive on initialization 2023-06-03 20:58:59 +02:00
d01f751e6d
kernel/ATA: Read the PCI Busmaster registers and start preparing for DMA 2023-06-03 20:58:59 +02:00
963b645ed1
kernel/ATA: Read the Busmaster base port and verify it 2023-06-03 20:58:58 +02:00
73890bc8f3
kernel: Handle device BARs properly 2023-06-03 20:58:58 +02:00
c4249f172d
kernel/ATA: Read ATA strings properly instead of backwards
Now we can see the model string. What does it say...

"QEMU DVD-ROM". Let's go!
2023-06-03 20:58:58 +02:00
6fca8eeeaa
kernel/ATA: Implement enough to send an IDENTIFY command and read the model number :) 2023-06-03 20:58:58 +02:00
9466161213
kernel/ATA: Handle drive IRQs in compatibility mode 2023-06-03 20:58:57 +02:00
ffe970ef60
kernel/CPU: Allow passing arbitrary data to interrupt handlers 2023-06-03 20:58:57 +02:00
805dea84a6
kernel/ATA: Start reading/writing registers and detecting drives 2023-06-03 20:58:57 +02:00
25c9274a66
kernel: Warn if no ATA controller is found 2023-06-03 20:58:57 +02:00
dfd01d3e2a
kernel: Add a KMutex class and use that for ATA::Controller locking 2023-06-03 20:58:57 +02:00
c0ae3df706
kernel/x86_64: Add basic ATA controller and channel identification 2023-06-03 20:58:56 +02:00
476dcaf67d
kernel/PCI: Add more PCI field types 2023-06-03 20:58:56 +02:00
c3c088ba66
kernel/x86_64: Add a way to register IRQ handlers from other kernel subsystems 2023-06-03 20:58:53 +02:00
2 changed files with 0 additions and 7 deletions

View File

@ -62,11 +62,6 @@ namespace Timer
timespecadd(&s_realtime_clock, &s_interval, &s_realtime_clock);
}
usize ticks_ms()
{
return (s_monotonic_clock.tv_sec * 1000) + (s_monotonic_clock.tv_nsec / 1'000'000);
}
struct timespec* monotonic_clock()
{
return &s_monotonic_clock;

View File

@ -16,8 +16,6 @@ namespace Timer
{
void tick();
usize ticks_ms();
struct timespec* monotonic_clock();
struct timespec* realtime_clock();