📚 AOS Docs

AHCI Storage Driver

Advanced Host Controller Interface for Serial ATA

Overview

AHCI is the modern standard for SATA (Serial ATA) storage. It replaces the legacy IDE/ATA interface with a more efficient DMA-based approach. AOS supports AHCI for faster disk I/O.

AHCI vs Legacy ATA

Feature Legacy ATA AHCI
Data Transfer PIO (slow) DMA (fast)
Command Queue One at a time 32 parallel
Interface I/O ports Memory-mapped

AHCI Command Submission

  1. Write command table to memory
  2. Set command list entry
  3. Write command issue register
  4. Controller executes command via DMA
  5. IRQ signals completion
  6. Read command completion status

Key Takeaways

  • ✓ AHCI is modern SATA standard
  • ✓ DMA-based for efficient transfers
  • ✓ Supports command queueing
  • ✓ Memory-mapped register access
  • ✓ Interrupt-driven completion