qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] PCI 64-bit BAR access with qemu


From: Max Filippov
Subject: Re: [Qemu-devel] PCI 64-bit BAR access with qemu
Date: Wed, 12 Oct 2011 15:00:06 +0400

>    I've read a few days ago that it was possible to emulate PCI device with
> 64-bit BARs and have a real 64-bit memory access.
> Thus, I've created a virtual device named toto accessible through a 64-bit
> BAR

You've probably confused an ability to locate BAR anywhere in 64-bit
address space (such BAR actually spans 2 consecutive PCI BAR registers
and has 100 in its 3 least significant bits) and an ability to access
BAR-mapped memory in 64 bit items.

You obviously want the latter but currently it is not implemented, see e.g.

static inline DATA_TYPE glue(io_read, SUFFIX)(target_phys_addr_t physaddr,
                                              target_ulong addr,
                                              void *retaddr)

definition in the softmmu_template.h.

And it's quite simple to fix it, you only need to change
io_{read,write} in the softmmu_template.h and extend
io_mem_{read,write} loops in exec.c to 4 elements, taking care that
io_mem_{read,write}[3] can pass uint64_t.

-- 
Thanks.
-- Max



reply via email to

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