mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 08:13:54 -06:00
dma: do not depend on kvm_enabled()
Memory barriers are needed also by Xen and, when the ioeventfd bugs are fixed, by TCG as well. sysemu/kvm.h is not anymore needed in sysemu/dma.h, move it to the actual users. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
da16384560
commit
77ac58ddc6
8 changed files with 8 additions and 5 deletions
|
@ -15,7 +15,6 @@
|
|||
#include "hw/hw.h"
|
||||
#include "block/block.h"
|
||||
#include "block/accounting.h"
|
||||
#include "sysemu/kvm.h"
|
||||
|
||||
typedef struct ScatterGatherEntry ScatterGatherEntry;
|
||||
|
||||
|
@ -67,9 +66,7 @@ static inline void dma_barrier(AddressSpace *as, DMADirection dir)
|
|||
* use lighter barriers based on the direction of the
|
||||
* transfer, the DMA context, etc...
|
||||
*/
|
||||
if (kvm_enabled()) {
|
||||
smp_mb();
|
||||
}
|
||||
smp_mb();
|
||||
}
|
||||
|
||||
/* Checks that the given range of addresses is valid for DMA. This is
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue