Hi guys,
This is a new version of the QEMUAccel work. To start with, I decided
to keep the name for now. We don't have that many functions that are not
cpu-related to justify splitting the structure into many. Plus, this is one
of the less confusing names we came up with.
The code I'm posting is
This patch introduces QEMUAccel, a placeholder for function pointers
that aims at helping qemu to abstract accelerators such as kqemu and
kvm (actually, the 'accelerator' name was proposed by avi kivity, since
he loves referring to kvm that way).
To begin with, the accelerator is given the
we separate kqemu_init() into a part that depends on env,
and other that does not. The later can be initialized earlier
---
exec.c|3 +++
kqemu.c | 10 +++---
target-i386/helper2.c |2 +-
3 files changed, 11 insertions(+), 4 deletions(-)
diff --git
we put all the code that needs to be executed only at cpu0
out of cpu_exec_init(), in exec_init(). It is executed
before machine_init(), and only once. With this change,
code cpu_exec_init() is completely symmetric.
---
exec-all.h |1 +
exec.c | 15 +--
vl.c |1 +
---
exec-all.h|8 +++-
kqemu.c |1 +
target-i386/helper2.c |4 +---
3 files changed, 9 insertions(+), 4 deletions(-)
diff --git a/exec-all.h b/exec-all.h
index 7b2d97d..9e211dc 100644
--- a/exec-all.h
+++ b/exec-all.h
@@ -580,6 +580,7 @@ static inline
---
exec-all.h |8 +++-
exec.c | 24 +---
kqemu.c| 26 +++---
3 files changed, 31 insertions(+), 27 deletions(-)
diff --git a/exec-all.h b/exec-all.h
index ed96a22..04112e0 100644
--- a/exec-all.h
+++ b/exec-all.h
@@ -586,6 +586,7 @@
---
exec-all.h |8
kqemu.c| 35 +++
monitor.c | 27 ++-
3 files changed, 49 insertions(+), 21 deletions(-)
diff --git a/exec-all.h b/exec-all.h
index f1bd7ae..689973d 100644
--- a/exec-all.h
+++ b/exec-all.h
@@ -584,6
---
cpu-all.h |5 -
kqemu.h |6 ++
2 files changed, 6 insertions(+), 5 deletions(-)
diff --git a/cpu-all.h b/cpu-all.h
index 7e77f76..5336a29 100644
--- a/cpu-all.h
+++ b/cpu-all.h
@@ -1053,14 +1053,9 @@ static inline int64_t profile_getclock(void)
return
---
exec-all.h |8
kqemu.c| 24
monitor.c | 36 +---
3 files changed, 45 insertions(+), 23 deletions(-)
diff --git a/exec-all.h b/exec-all.h
index bfc6576..f1bd7ae 100644
--- a/exec-all.h
+++ b/exec-all.h
@@ -583,6
---
exec-all.h |8 +++-
exec.c | 18 +++---
kqemu.c| 23 +++
3 files changed, 25 insertions(+), 24 deletions(-)
diff --git a/exec-all.h b/exec-all.h
index 689973d..ed96a22 100644
--- a/exec-all.h
+++ b/exec-all.h
@@ -585,6 +585,7 @@ typedef
Instead, route cpu_get_ticks through accel driver.
---
exec-all.h | 11 +++
hw/pc.c| 13 ++---
kqemu.c|4
3 files changed, 17 insertions(+), 11 deletions(-)
diff --git a/exec-all.h b/exec-all.h
index 04112e0..f62ff38 100644
--- a/exec-all.h
+++ b/exec-all.h
instead of hardcoding kqemu_start() in exec.c, which would require
such a hack for all available accelerators, semantics of register_qemu_accel()
is changed a little bit. It only builds a list of available accelerators.
The last one registered is the first tried.
This is a temporary solution,
this is for the case in which we run more than one cpu
---
kqemu.c |3 ++-
vl.c|4
2 files changed, 2 insertions(+), 5 deletions(-)
diff --git a/kqemu.c b/kqemu.c
index 6d46dfb..94366ec 100644
--- a/kqemu.c
+++ b/kqemu.c
@@ -164,6 +164,7 @@ static void
---
exec-all.h | 16 ++--
exec.c | 12 ++--
kqemu.c| 15 +--
3 files changed, 25 insertions(+), 18 deletions(-)
diff --git a/exec-all.h b/exec-all.h
index 9e211dc..bfc6576 100644
--- a/exec-all.h
+++ b/exec-all.h
@@ -581,6 +581,8 @@ static inline
Marcelo Tosatti wrote:
On Wed, May 07, 2008 at 08:45:12PM +0200, Gerd Hoffmann wrote:
Ok folks, here is the band aid fix for testing from the odd bugs
department. Goes on top of the four patches of this series. A real,
clean solution is TBD. Tomorrow I hope (some urgent private problems
qemu recently added support for 3dnow instructions. Because of
that, 3dnow will be featured among cpuid bits. But this will
break kvm in cpus that don't have those instructions (which includes
my laptop). So we fixup our cpuid before exposing it to the guest.
Signed-off-by: Glauber Costa [EMAIL
Alexander Graf wrote:
On May 6, 2008, at 6:27 PM, Glauber Costa wrote:
qemu recently added support for 3dnow instructions. Because of
that, 3dnow will be featured among cpuid bits. But this will
break kvm in cpus that don't have those instructions (which includes
my laptop). So we fixup
Hey guys,
This was already discussed, mostly on kvm-devel (but qemu list always copied,
if you remember),
and here is the pre work I've done. I don't feel it to be mergeable yet, but
with your
comments, I expect to get it in a good shape soon. This is not extensibly
tested (but it will).
---
exec-all.h | 16 ++--
exec.c | 12 ++--
kqemu.c|2 ++
3 files changed, 18 insertions(+), 12 deletions(-)
diff --git a/exec-all.h b/exec-all.h
index 784d0ac..9925a80 100644
--- a/exec-all.h
+++ b/exec-all.h
@@ -578,6 +578,8 @@ typedef struct QEMUAccel {
---
cpu-exec.c | 29 ++---
exec-all.h | 10 ++
kqemu.c|3 +++
3 files changed, 31 insertions(+), 11 deletions(-)
diff --git a/cpu-exec.c b/cpu-exec.c
index 3246264..79da619 100644
--- a/cpu-exec.c
+++ b/cpu-exec.c
@@ -35,6 +35,22 @@
#include
---
exec-all.h|8 +++-
kqemu.c |1 +
target-i386/helper2.c |4 +---
3 files changed, 9 insertions(+), 4 deletions(-)
diff --git a/exec-all.h b/exec-all.h
index 621e1ca..784d0ac 100644
--- a/exec-all.h
+++ b/exec-all.h
@@ -577,6 +577,7 @@ static inline
-off-by: Glauber Costa [EMAIL PROTECTED]
---
block-raw-posix.c |5 -
exec-all.h| 18 +-
exec.c|2 ++
kqemu.c | 26 --
vl.c |6 +-
5 files changed, 36 insertions(+), 21 deletions(-)
diff --git
Jamie Lokier wrote:
Glauber Costa wrote:
This patch introduces QEMUAccel, a placeholder for function pointers
that aims at helping qemu to abstract accelerators such as kqemu and
kvm (actually, the 'accelerator' name was proposed by avi kivity, since
he loves referring to kvm that way
Paul Brook wrote:
Maybe 'VCPU' would be a clearer name? QEMU provides its own VCPU, and
KQEMU+QEMU also provide one toegether. While KVM provides essentially
one or more whole VCPUs by itself and uses QEMU's drivers only doesn't
it?
-- Jamie
VCPU is rather confusing with the vcpus
since the pv_apic_ops are only present if CONFIG_X86_LOCAL_APIC is compiled
in, kvmclock failed to build without this option. This patch fixes this
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/kvmclock.c |4
1 files changed, 4 insertions(+), 0 deletions(-)
diff
There is no reason why should i386 and x86_64 code for rdtsc be different.
Unify them.
---
cpu-all.h | 11 +--
1 files changed, 1 insertions(+), 10 deletions(-)
diff --git a/cpu-all.h b/cpu-all.h
index 2a2b197..1c9e2a3 100644
--- a/cpu-all.h
+++ b/cpu-all.h
@@ -930,16 +930,7 @@ static
This patch goes towards the direction of increasing general modularity of the
code. Code in vl.c that used to live inside target ifdefs, are moved to inside
the
target directories, in a new file called machine.c. They are the cpu save/load
and machine
registration
---
Makefile.target|
Hi. This is a proposal for reducing the impact of kvm functions in core qemu
code. This is by all means not ready, but I felt like posting it, so a
discussion
on it could follow.
The idea in this patch is to replace the specific kvm details from core qemu
files
like vl.c, with driver_yyy()
Avi Kivity wrote:
Glauber Costa wrote:
Hi. This is a proposal for reducing the impact of kvm functions in
core qemu
code. This is by all means not ready, but I felt like posting it, so a
discussion
on it could follow.
The idea in this patch is to replace the specific kvm details from
Anthony Liguori wrote:
Glauber Costa wrote:
Avi Kivity wrote:
Glauber Costa wrote:
Hi. This is a proposal for reducing the impact of kvm functions in
core qemu
code. This is by all means not ready, but I felt like posting it, so
a discussion
on it could follow.
The idea
Gerd Hoffmann wrote:
Glauber Costa wrote:
Gerd Hoffmann wrote:
Jeremy Fitzhardinge wrote:
Xen could change the parameters in the instant after
get_time_values(). That change could be as a result of
suspend-resume, so the parameters
and the tsc could be wildly different.
Ah, ok, forgot
by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
ads! ads!
--
Glauber Costa.
Free as in Freedom
http://glommer.net
The less
ts.tv_sec;
}
Here it is. Despite some needed cleanups, patches look beautiful to me.
--
Glauber Costa.
Free as in Freedom
http://glommer.net
The less confident you are, the more serious you have to act.
-
This SF.net email
anyone that is able to
reproduce this problem (a subgroup of human beings that does not
include me) test it with them applied?
If it still fails, please let me know asap
--
Glauber Costa.
Free as in Freedom
http://glommer.net
The less confident you are, the more serious you have to act
On Sat, Apr 19, 2008 at 6:11 PM, Glauber Costa [EMAIL PROTECTED] wrote:
On Fri, Apr 18, 2008 at 1:27 PM, Avi Kivity [EMAIL PROTECTED] wrote:
Glauber de Oliveira Costa wrote:
Hi,
I've got some qemu crashes while trying to passthrough an ide device
to a kvm guest. After some
Hi,
This series is an (initial) attempt to make qemu code a little bit
more modular. In this patch series specifically, I'm removing
some #ifdef TARGET_* from the general-purpose translate.c,
and rather, replacing them with a common function implemented in
architecture specific files.
Any rants
this patch replaced code inside specific ifdef in translate-all.c
with a generic architecture-implemented function. This leads to a
cleaner and more modular code in the generic part.
---
target-arm/translate.c |5 +
translate-all.c|2 +-
2 files changed, 6 insertions(+), 1
this patch replaced code inside specific ifdef in translate-all.c
with a generic architecture-implemented function. This leads to a
cleaner and more modular code in the generic part.
---
exec-all.h |3 +++
target-i386/translate.c | 23 +++
translate-all.c
this patch replaced code inside specific ifdef in translate-all.c
with a generic architecture-implemented function. This leads to a
cleaner and more modular code in the generic part.
---
target-sparc/translate.c | 20
translate-all.c | 18 +-
2
this patch replaced code inside specific ifdef in translate-all.c
with a generic architecture-implemented function. This leads to a
cleaner and more modular code in the generic part.
---
target-ppc/translate.c | 42 ++
translate-all.c| 40
this patch replaced code inside specific ifdef in translate-all.c
with a generic architecture-implemented function. This leads to a
cleaner and more modular code in the generic part.
---
target-m68k/translate.c |5 +
translate-all.c |2 +-
2 files changed, 6 insertions(+), 1
this patch replaced code inside specific ifdef in translate-all.c
with a generic architecture-implemented function. This leads to a
cleaner and more modular code in the generic part.
---
target-mips/translate.c |8
translate-all.c |4 +---
2 files changed, 9
this patch replaced code inside specific ifdef in translate-all.c
with a generic architecture-implemented function. This leads to a
cleaner and more modular code in the generic part.
---
target-alpha/translate.c |5 +
translate-all.c |2 +-
2 files changed, 6 insertions(+), 1
this patch replaced code inside specific ifdef in translate-all.c
with a generic architecture-implemented function. This leads to a
cleaner and more modular code in the generic part.
---
target-sh4/translate.c |7 +++
translate-all.c|3 +--
2 files changed, 8 insertions(+), 2
this patch replaced code inside specific ifdef in translate-all.c
with a generic architecture-implemented function. This leads to a
cleaner and more modular code in the generic part.
---
target-cris/translate.c |6 ++
translate-all.c |2 +-
2 files changed, 7 insertions(+), 1
As the current state of matters, all architectures call a function
with the same name and signature for updating the pc. Remove the ifdefs,
leading to a cleaner code
---
translate-all.c | 19 +--
1 files changed, 1 insertions(+), 18 deletions(-)
diff --git a/translate-all.c
Gerd Hoffmann wrote:
Jeremy Fitzhardinge wrote:
Xen could change the parameters in the instant after get_time_values().
That change could be as a result of suspend-resume, so the parameters
and the tsc could be wildly different.
Ah, ok, forgot the rdtsc in the picture. With that in mind I
and host), while I'm off ?
--
Glauber Costa.
Free as in Freedom
http://glommer.net
The less confident you are, the more serious you have to act.
-
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss
at that.
--
Glauber Costa.
Free as in Freedom
http://glommer.net
The less confident you are, the more serious you have to act.
-
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event
It makes no sense for the clock initialization to be
hanging around in setup_32.c when we have a generic kvm guest
initialization function available. So, we move kvmclock_init()
inside such a function, leading to a cleaner code.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel
Amit Shah wrote:
* On Tuesday 08 April 2008 22:34:36 Glauber Costa wrote:
Instead of artificially limiting irq numbers, use arch provided NR_IRQS
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
Thanks, applied.
Going forward, we're going to use the in-kernel approach for interrupt
Hi,
This is the final integration of dma_ops between x86_64 and i386.
The final code is closer to x86_64 than to i386, which is obviously expected.
At the end, pci-dma_{32,64}.c are gone, pci-nommu_64.c is gone, and the
temporary
pci-base_32.c is gone too.
This patchset received the same level
This functions are now called conditionally on their
existence in the struct. So just delete them, instead
of keeping an empty implementation.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-nommu_64.c | 15 ---
1 files changed, 0 insertions(+), 15 deletions
This patch introduces pci-dma.c, a common file for pci dma
between i386 and x86_64. As a start, dma_set_mask() is the same
between architectures, and is placed there.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/Makefile |2 +-
arch/x86/kernel/pci-dma.c| 14
inconditionally.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-nommu_64.c | 12
1 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/arch/x86/kernel/pci-nommu_64.c b/arch/x86/kernel/pci-nommu_64.c
index 90a7c40..a4e8ccf 100644
--- a/arch/x86/kernel/pci
To make the code usable in i386, where we have high memory mappings,
we drop te virt_to_bus(sg_virt()) construction in favour of sg_phys.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-nommu_64.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git
This is done to get the code closer to x86_64.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-base_32.c |1 +
include/asm-x86/scatterlist.h |2 --
2 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/arch/x86/kernel/pci-base_32.c b/arch/x86/kernel/pci
we merge the iommu initialization parameters in pci-dma.c
Nice thing, that both architectures at least recognize the same
parameters.
usedac i386 parameter is marked for deprecation
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
Documentation/feature-removal-schedule.txt |7 +++
arch
This patch moves the bootmem functions, that are largely
x86_64-specific into pci-dma.c. The code goes inside an ifdef.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma.c| 73 ++
arch/x86/kernel/pci-dma_64.c | 68
They are placed in an ifdef, since they are i386 specific
the structure definition goes to dma-mapping.h.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma.c | 81 +++
arch/x86/kernel/pci-dma_32.c | 85
i386 implements the declare coherent memory API, and x86_64 does not
it is reflected in pieces of dma_alloc_coherent and dma_free_coherent.
Those pieces are isolated in separate functions, that are declared
as empty macros in x86_64. This way we can make the code the same.
Signed-off-by: Glauber
It goes to pci-dma.c, and is removed from the arch-specific files.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma.c|2 ++
arch/x86/kernel/pci-dma_32.c |4
arch/x86/kernel/pci-dma_64.c |2 --
3 files changed, 2 insertions(+), 6 deletions(-)
diff
This patch puts in the code to retry allocation in case it fails. By its
own, it does not make much sense but making the code look like x86_64.
But later patches in this series will make we try to allocate from
zones other than DMA first, which will possibly fail.
Signed-off-by: Glauber Costa
We call unmap_single, if available.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma_32.c |2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/arch/x86/kernel/pci-dma_32.c b/arch/x86/kernel/pci-dma_32.c
index 78c7640..49166a4 100644
--- a/arch/x86
We can do it here to, in the same way x86_64 does.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma_32.c | 27 ++-
1 files changed, 22 insertions(+), 5 deletions(-)
diff --git a/arch/x86/kernel/pci-dma_32.c b/arch/x86/kernel/pci-dma_32.c
index
If we fail, we'll loop into the allocation again,
and then allocate in the DMA zone.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma_32.c |3 ---
1 files changed, 0 insertions(+), 3 deletions(-)
diff --git a/arch/x86/kernel/pci-dma_32.c b/arch/x86/kernel/pci
We can use a fallback dev for cases of a NULL device being passed (mostly ISA)
This comes from x86_64 implementation.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma_32.c | 13 +
1 files changed, 13 insertions(+), 0 deletions(-)
diff --git a/arch/x86
The claim is that i386 does it. Just it does not.
So remove it.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma_64.c |4
1 files changed, 0 insertions(+), 4 deletions(-)
diff --git a/arch/x86/kernel/pci-dma_64.c b/arch/x86/kernel/pci-dma_64.c
index b956f59
Just return our allocation if we don't have an mmu. For i386, where this patch
is being applied, we never have. So our goal is just to have the code to look
like
x86_64's.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma_32.c | 34
if the device hasn't provided a mask, abort allocation.
Note that we're using a fallback device now, so it does not cover
the case of a NULL device: just drivers passing NULL masks around.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma_32.c |3 +++
1 files changed
The code in pci-dma_{32,64}.c are now sufficiently
close to each other. We merge them in pci-dma.c.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/Makefile |2 +-
arch/x86/kernel/pci-dma.c| 175 ++
arch/x86/kernel/pci
merge pci-base_32.c and pci-nommu_64.c into pci-nommu.c
Their code were made the same, so now they can be merged.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/Makefile |5 +-
arch/x86/kernel/pci-base_32.c | 60
arch/x86/kernel/pci-dma.c
via_no_dac provides a fixup that is the same for both
architectures. Move it to pci-dma.c.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma.c | 18 ++
arch/x86/kernel/pci-dma_32.c | 13 -
arch/x86/kernel/pci-dma_64.c | 15
initcalls that triggers the various possibiities for
dma subsys are moved to pci-dma.c.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma.c| 25 +
arch/x86/kernel/pci-dma_64.c | 23 ---
2 files changed, 25 insertions
Move dma_ops structure definition to pci-dma.c, where it
belongs.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-base_32.c | 11 ---
arch/x86/kernel/pci-dma.c |3 +++
arch/x86/mm/init_64.c |3 ---
3 files changed, 11 insertions(+), 6
This patch adds flush_write_buffers() in some functions of pci-nommu_64.c
They are added anywhere i386 would also have it. This is not a problem
for x86_64, since flush_rite_buffers() an nop for it.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-nommu_64.c |2 ++
1
The code for both arches are very similar, so this patch merge them.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma.c| 44 ++
arch/x86/kernel/pci-dma_32.c | 24 --
arch/x86/kernel/pci-dma_64.c | 44
Instead of artificially limiting irq numbers, use arch provided NR_IRQS
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
irqhook/irqhook_main.c | 16 +++-
1 files changed, 7 insertions(+), 9 deletions(-)
diff --git a/irqhook/irqhook_main.c b/irqhook/irqhook_main.c
index 5f414d1
Use the same gfp masks for x86_64 and i386.
It involves using HIGHMEM or DMA32 where necessary, for the sake
of code compatibility, (no real effect), and using the NORETRY
mask for i386.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-dma_32.c |6 --
arch/x86
Aurelien Jarno wrote:
On Wed, Mar 26, 2008 at 09:57:16PM -0300, Glauber Costa wrote:
They seem legal in real hardware, even though the EOI
is a write-only register. By legal I mean they are completely
ignored, but at least, don't cause any bits to be set at ESR.
Without this patch, some
Avi Kivity wrote:
Glauber Costa wrote:
If we fail after we have allocated the pci device, we have
to get rid of it. Otherwise, a bogus device will be found on
the bus
Maybe, alter the order so the device is registered last thing. This may
help avoid races with pci passthrough hotplug
Ingo Molnar wrote:
* Ingo Molnar [EMAIL PROTECTED] wrote:
what i came up is the prototype 32-bit fix below - this works on
32-bit but breaks 64-bit because we pass in physical addresses instead
of virtual direct addresses.
i'll fix the 64-bit side but that means materially touching all
Amit,
those fixups apply ontop of your kvm-userspace tree.
They are general small fixups for the whole thing
thanks
-
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just
If we fail after we have allocated the pci device, we have
to get rid of it. Otherwise, a bogus device will be found on
the bus
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
qemu/hw/passthrough/passthrough.c | 11 +++
qemu/hw/pci.c |6 ++
qemu/hw/pci.h
Hello,
Here there is a series of 20 patches that lays the foundations for
using dma_ops in i386 in the very same way x86_64, as well as many other
architectures already do.
The functions themselves for i386 are placed in a pci-base_32.c, but just
a few among them are actually implemented. Most
take it off the x86_64 specific header
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
include/asm-x86/dma-mapping.h| 54 ++
include/asm-x86/dma-mapping_64.h | 49 --
2 files changed, 54 insertions(+), 49 deletions
the old i386 implementation is moved to pci-base_32.c
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-base_32.c| 19 +++
include/asm-x86/dma-mapping.h|8 +++-
include/asm-x86/dma-mapping_32.h | 20
include/asm-x86
i386 base does not need it, so it gets an empty function
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-base_32.c|1 +
include/asm-x86/dma-mapping.h| 10 ++
include/asm-x86/dma-mapping_32.h |7 ---
include/asm-x86/dma-mapping_64.h |8
i386 gets an empty function
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-base_32.c|1 +
include/asm-x86/dma-mapping.h| 12
include/asm-x86/dma-mapping_32.h |6 --
include/asm-x86/dma-mapping_64.h | 11 ---
4 files changed, 13
That's already the name of the game for x86_64. For i386,
we add a pci-base_32.c, that will hold the default operations.
The function call itself goes through dma-mapping.h , the common
header
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/Makefile |1 +
arch/x86
i386 gets an empty function
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-base_32.c|1 +
include/asm-x86/dma-mapping.h| 11 +++
include/asm-x86/dma-mapping_32.h |7 ---
include/asm-x86/dma-mapping_64.h | 11 ---
4 files changed, 12
i386 gets an empty function
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-base_32.c|1 +
include/asm-x86/dma-mapping.h|9 +
include/asm-x86/dma-mapping_32.h |8
include/asm-x86/dma-mapping_64.h |8
4 files changed, 10
i386 gets an empty function
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-base_32.c|1 +
include/asm-x86/dma-mapping.h| 14 ++
include/asm-x86/dma-mapping_32.h |8
include/asm-x86/dma-mapping_64.h | 12
4 files
i386 gets an empty function
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-base_32.c|1 +
include/asm-x86/dma-mapping.h| 11 +++
include/asm-x86/dma-mapping_32.h |7 ---
include/asm-x86/dma-mapping_64.h | 12
4 files changed
i386 gets an empty function
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-base_32.c|1 +
include/asm-x86/dma-mapping.h|9 +
include/asm-x86/dma-mapping_32.h |6 --
include/asm-x86/dma-mapping_64.h | 11 ---
4 files changed, 10
they are the same between architectures (except for the fact
that x86_64 has duplicate code)
move them to dma-mapping.h
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
include/asm-x86/dma-mapping.h| 10 ++
include/asm-x86/dma-mapping_32.h |9 -
include/asm-x86/dma
Do it instead of using the conservative approach we're currently
doing. This is the way x86_64 does, and this patch makes this piece
of code the same between them, ready to be integrated
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
include/asm-x86/dma-mapping_32.h |2 +-
1 files
i386 gets an empty function
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
arch/x86/kernel/pci-base_32.c|1 +
include/asm-x86/dma-mapping.h| 11 +++
include/asm-x86/dma-mapping_32.h |7 ---
include/asm-x86/dma-mapping_64.h | 12
4 files changed
all the code that is left is ready to be merged as-is
in dma-mapping.h
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
include/asm-x86/dma-mapping.h| 19 +--
include/asm-x86/dma-mapping_32.h | 23 ---
include/asm-x86/dma-mapping_64.h | 17
they are the same in both architectures.
Signed-off-by: Glauber Costa [EMAIL PROTECTED]
---
include/asm-x86/dma-mapping.h|6 ++
include/asm-x86/dma-mapping_32.h |7 ---
include/asm-x86/dma-mapping_64.h |7 ---
3 files changed, 6 insertions(+), 14 deletions(-)
diff
1 - 100 of 186 matches
Mail list logo