Skip to content

Not using DMA Physical Address Space in AHCI Driver #2

@FilipToth

Description

@FilipToth

Description

Currently, the AHCI driver allocates a new buffer layout and only passes its virtual address to the Host Bus Adapter (HBA) Port. On some machines, this results in the port's command issue (port.ci) polling running indefinitely due to misallocation of the Frame Information Structure (FIS).

Expected Behavior

  • Read buffers should be allocated in a way that ensures the HBA Port receives a valid physical address.
  • port.ci polling should complete as expected without hanging.

Actual Behavior

  • The current implementation provides only a virtual address, which causes port.ci polling to run indefinitely on some machines.
  • The Frame Information Structure (FIS) is misallocated, preventing proper command execution.

Steps to Reproduce

  1. Run the AHCI driver on affected hardware.
  2. Issue a read operation.
  3. Observe that port.ci polling does not complete.

Proposed Fix

Modify the AHCI driver to allocate read buffers in the physical address space before passing them to the HBA Port.

Environment

  • Affected machines: will specify Firmware and Open TianoCore version later
  • Kernel version: 0.4 - bubblewrap

Additional Context

This issue seems to arise due to improper memory allocation for the FIS. Ensuring that read buffers reside in the correct physical address space should resolve the problem.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions