Reviewed-by: Olivier Martin <[email protected]>

> -----Original Message-----
> From: Laszlo Ersek [mailto:[email protected]]
> Sent: 14 February 2015 22:02
> To: [email protected]; [email protected]; Peter Maydell; Ard
> Biesheuvel; Drew Jones; Wei Huang; Donald Dutile; Wei Liu
> Subject: [edk2] [PATCH 12/27] ArmVirtualizationPkg/PciHostBridgeDxe: IO
> space is emulated with MMIO
> 
> There is no IO space on ARM, and there are no special instructions that
> access it. QEMU emulates the IO space for PCI devices with a special
> MMIO
> range. We're ready to use it at this point, we just have to switch the
> Io(Read|Write)(8|16|32) primitives to their MMIO counterparts, because
> in
> "MdePkg/Library/BaseIoLibIntrinsic/IoLibArm.c", the IO primitives
> correctly ASSERT (FALSE).
> 
> Contributed-under: TianoCore Contribution Agreement 1.0
> Signed-off-by: Laszlo Ersek <[email protected]>
> ---
>  ArmPlatformPkg/ArmVirtualizationPkg/PciHostBridgeDxe/PciRootBridgeIo.c
> | 12 ++++++------
>  1 file changed, 6 insertions(+), 6 deletions(-)
> 
> diff --git
> a/ArmPlatformPkg/ArmVirtualizationPkg/PciHostBridgeDxe/PciRootBridgeIo.
> c
> b/ArmPlatformPkg/ArmVirtualizationPkg/PciHostBridgeDxe/PciRootBridgeIo.
> c
> index 4c5decf..8e7ab0d 100644
> ---
> a/ArmPlatformPkg/ArmVirtualizationPkg/PciHostBridgeDxe/PciRootBridgeIo.
> c
> +++
> b/ArmPlatformPkg/ArmVirtualizationPkg/PciHostBridgeDxe/PciRootBridgeIo.
> c
> @@ -1005,13 +1005,13 @@ RootBridgeIoIoRW (
>      if (Write) {
>        switch (OperationWidth) {
>          case EfiPciWidthUint8:
> -          IoWrite8 ((UINTN)Address, *Uint8Buffer);
> +          MmioWrite8 ((UINTN)Address, *Uint8Buffer);
>            break;
>          case EfiPciWidthUint16:
> -          IoWrite16 ((UINTN)Address, *((UINT16 *)Uint8Buffer));
> +          MmioWrite16 ((UINTN)Address, *((UINT16 *)Uint8Buffer));
>            break;
>          case EfiPciWidthUint32:
> -          IoWrite32 ((UINTN)Address, *((UINT32 *)Uint8Buffer));
> +          MmioWrite32 ((UINTN)Address, *((UINT32 *)Uint8Buffer));
>            break;
>          default:
>            //
> @@ -1024,13 +1024,13 @@ RootBridgeIoIoRW (
>      } else {
>        switch (OperationWidth) {
>          case EfiPciWidthUint8:
> -          *Uint8Buffer = IoRead8 ((UINTN)Address);
> +          *Uint8Buffer = MmioRead8 ((UINTN)Address);
>            break;
>          case EfiPciWidthUint16:
> -          *((UINT16 *)Uint8Buffer) = IoRead16 ((UINTN)Address);
> +          *((UINT16 *)Uint8Buffer) = MmioRead16 ((UINTN)Address);
>            break;
>          case EfiPciWidthUint32:
> -          *((UINT32 *)Uint8Buffer) = IoRead32 ((UINTN)Address);
> +          *((UINT32 *)Uint8Buffer) = MmioRead32 ((UINTN)Address);
>            break;
>          default:
>            //
> --
> 1.8.3.1
> 
> 
> 
> -----------------------------------------------------------------------
> -------
> Dive into the World of Parallel Programming. The Go Parallel Website,
> sponsored by Intel and developed in partnership with Slashdot Media, is
> your
> hub for all things parallel software development, from weekly thought
> leadership blogs to news, videos, case studies, tutorials and more.
> Take a
> look and join the conversation now. http://goparallel.sourceforge.net/
> _______________________________________________
> edk2-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/edk2-devel





------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=190641631&iu=/4140/ostg.clktrk
_______________________________________________
edk2-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-devel

Reply via email to