OvmfPkg/QemuFwCfg: introduce FW_CFG_IO_DATA, adapt the package
Introduce the FW_CFG_IO_DATA macro for IO Port 0x511 (the Data Register), and update all references in OvmfPkg. Cc: Jordan Justen <jordan.l.justen@intel.com> Suggested-by: Jordan Justen <jordan.l.justen@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
This commit is contained in:
@@ -135,7 +135,7 @@ InternalQemuFwCfgReadBytes (
|
||||
InternalQemuFwCfgDmaBytes ((UINT32)Size, Buffer, FW_CFG_DMA_CTL_READ);
|
||||
return;
|
||||
}
|
||||
IoReadFifo8 (0x511, Size, Buffer);
|
||||
IoReadFifo8 (FW_CFG_IO_DATA, Size, Buffer);
|
||||
}
|
||||
|
||||
|
||||
@@ -187,7 +187,7 @@ QemuFwCfgWriteBytes (
|
||||
InternalQemuFwCfgDmaBytes ((UINT32)Size, Buffer, FW_CFG_DMA_CTL_WRITE);
|
||||
return;
|
||||
}
|
||||
IoWriteFifo8 (0x511, Size, Buffer);
|
||||
IoWriteFifo8 (FW_CFG_IO_DATA, Size, Buffer);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -230,7 +230,7 @@ QemuFwCfgSkipBytes (
|
||||
//
|
||||
while (Size > 0) {
|
||||
ChunkSize = MIN (Size, sizeof SkipBuffer);
|
||||
IoReadFifo8 (0x511, ChunkSize, SkipBuffer);
|
||||
IoReadFifo8 (FW_CFG_IO_DATA, ChunkSize, SkipBuffer);
|
||||
Size -= ChunkSize;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user