qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 1/9] Add stub functions for PCI device models to


From: Gerd Hoffmann
Subject: Re: [Qemu-devel] [PATCH 1/9] Add stub functions for PCI device models to do PCI DMA
Date: Wed, 12 Oct 2011 11:08:17 +0200
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.23) Gecko/20110927 Red Hat/3.1.15-1.el6_1 Thunderbird/3.1.15

  Hi,

Yes.. as do the stX_pci_dma() helpers.  They assume LE, rather than
having two variants, because PCI is an LE spec, and all normal PCI
devices work in LE.

IMO, not really. PCI devices do DMA any way they like.  LE is
probably more common because both ARM and x86 processors are LE.

Also having _le_ in the function name makes explicitly clear that the functions read/write little endian values and byteswaps if needed, which makes the code more readable. I'd suggest to add it even if there is no need for a _be_ companion as devices needing that are rare.

cheers,
  Gerd




reply via email to

[Prev in Thread] Current Thread [Next in Thread]