Hardware interview practice
Order a descriptor before an MMIO doorbell
Firmware writes a DMA descriptor in normal memory, then rings a device doorbell through MMIO. The platform does not automatically order those stores. What must firmware do before the doorbell write?
Choose one
Answer choices
- A. Mark only the local descriptor pointer volatile; no ordering operation is needed.
- B. Use the platform's required DMA/write memory barrier before the MMIO doorbell so descriptor stores are visible first.
- C. Read the doorbell twice after writing it; this always orders prior normal-memory stores on every platform.
- D. Write the doorbell first, then issue a barrier before filling the descriptor.
