summaryrefslogtreecommitdiff
path: root/src/sys/io/ic
AgeCommit message (Collapse)Author
43 hourskern: ahci: Implement DMS read interfaceIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
43 hourskern: dms: Make DMS block size awareIan Moffett
In order to safely copy between disk and host memory through a programming interface, DMS must be aware of the hardware disk block size Signed-off-by: Ian Moffett <ian@osmora.org>
43 hourskern: ahci: Don't hardcode block sizesIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
43 hourskern: ahci: Register SATA drives to DMSIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
43 hourskern: ahci: Correct buffer order during ahci r/wIan Moffett
Move to the buffer given to us if there it is a read, move from the buffer given to us if it is a write Signed-off-by: Ian Moffett <ian@osmora.org>
47 hourskern: ahci: Implement r/w of SATA drivesIan Moffett
Introduces reading and writing of SATA drives via a bufargs structure to describe the buffer as well as its attributes Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayskern: ahci: Add cmdslot allocation + identifyIan Moffett
Implements command slot allocation, command submission and the ATA identify command Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayskern: ahci: Allocate raw physical memoryIan Moffett
No need to overcomplicate things for now, just use a simple vm_alloc_frame() for DMA allocations Signed-off-by: Ian Moffett <ian@osmora.org>
5 dayskern: ahci: Enable PCI MMIO and bus masteringIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
5 dayskern: pci: Use LU types instead of classrev fieldIan Moffett
Instead of using bitfields to say which kind identification we are doing, it is a better idea to just use the lookup type directly as it is more scalable Signed-off-by: Ian Moffett <ian@osmora.org>
2025-09-22kern: ahci: Bring up ports via COMRESETIan Moffett
As we rely on resetting the controller via GHC.HR, we'll need to re-establish a link with each implemented port to actually bring them online. Signed-off-by: Ian Moffett <ian@osmora.org>
2025-09-22kern: ahci: Replace printf calls with dtrace()Ian Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-09-22kern: ahci: Add initial port bring-up logicIan Moffett
This commit introduces this initial bring-up logic for ports on the HBA. We have allocated the command headers and each FIS RX area for each respective command slot. More work to be done but this lays the groundwork Signed-off-by: Ian Moffett <ian@osmora.org>
2025-09-22kern: ahci: Fix typo in dtrace() macroIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-09-22kern: ahci: Keep track of number of command slotsIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-09-21kern: ahci: Only support 64-bit HBAs for nowIan Moffett
Abort if the host controller does not support 64-bit addressing Signed-off-by: Ian Moffett <ian@osmora.org>
2025-09-21kern: ahci: Add initial port startup logicIan Moffett
Here we ensure that the port is in a stopped state, we have also added port descriptor lists to keep track of each port. Signed-off-by: Ian Moffett <ian@osmora.org>
2025-09-21kern: ahci: Scan for implemented ports with PI regIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-09-21kern: ahci: Add debug tracingIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-09-21kern: ahci: Ensure HBA is in AHCI-mode after resetIan Moffett
The global host control register (described by section 3.1.2 in the AHCI spec) has an HBA reset bit which resets *everything* to a known state. This means that after the reset, we'll have to indicate to the HBA that we want to speak to it over the AHCI interface. We do it once before the reset if needed, then we do it again after. Signed-off-by: Ian Moffett <ian@osmora.org>
2025-09-21kern: ahci: Add AHCI host bus adapter reset implIan Moffett
This commit introduces this initial ahci_init() logic by resetting HBA state on startup. Signed-off-by: Ian Moffett <ian@osmora.org>
2025-09-19kern: pci: Implement PCI leaf drivers + AHCI stubIan Moffett
This commit introduces the support for having PCI specific device drivers while providing a tiny AHCI stub that logs the existence of the host bus adapter. The PCI bus itself has a driver for enumerating the devices and associating a specific driver to it, the device drivers themselve must advertise themselves to the PCI driver. Signed-off-by: Ian Moffett <ian@osmora.org>