[Qemu-devel] Re: [PATCH v2] qemu-kvm: Speed up of the dirty-bitmap-traveling

2010-02-14 Thread OHMURA Kei
dirty-bitmap-traveling is carried out by byte size in qemu-kvm.c. But We think that dirty-bitmap-traveling by long size is faster than by byte size especially when most of memory is not dirty. Signed-off-by: OHMURA Kei --- bswap.h|2 ++ qemu-kvm.c | 31 ---

[Qemu-devel] [PATCH] pcnet APROMWE bit location

2010-02-14 Thread Chris Kilgour
I don't subscribe to the list, so please excuse any breach of etiquette. According to AMD document 21485D pp.141, APROMWE is bit 8 of BCR2. Signed-off-by: Christopher Kilgour whiterocker.com> --- diff --git a/hw/pcnet.c b/hw/pcnet.c index 44b5b31..f889898 100644 --- a/hw/pcnet.c +++ b/hw/pcnet

[Qemu-devel] Re: [PATCH 1/3] qemu-kvm: Wrap phys_ram_dirty with additional inline functions.

2010-02-14 Thread Yoshiaki Tamura
Avi Kivity wrote: On 02/12/2010 04:08 AM, OHMURA Kei wrote: Why do you need a counter? It may be sufficient to set a single bit. This reduces the memory overhead and perhaps cache thrashing. Thanks for looking into this. I agree with your opinion. Our motivation here is to skip traveling when

[Qemu-devel] EHCI support in QEMU

2010-02-14 Thread Taimoor Mirza
Hi all, I downloaded version 0.12.2 of QEMU and I am unable to find EHCI support in it. Does QEMU support EHCI emulation? Do I need to download some other patch for it? QEMU documentation also does not tell anything about EHCI. -Taimoor

Re: [Qemu-devel] [PATCH 1/3] Add FreeBSD/ppc host ppc_init_cacheline_sizes() implementation.

2010-02-14 Thread malc
On Sun, 14 Feb 2010, Juergen Lock wrote: > Submitted by: Andreas Tobler > > Signed-off-by: Juergen Lock > > --- a/cache-utils.c > +++ b/cache-utils.c > @@ -57,6 +57,23 @@ > } > #endif > > +#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) __FreeBSD_kernel__ is for something like Deb

Re: [Qemu-devel] [PATCH 1/3] Add FreeBSD/ppc host ppc_init_cacheline_sizes() implementation.

2010-02-14 Thread malc
On Sun, 14 Feb 2010, Juergen Lock wrote: > Submitted by: Andreas Tobler > > Signed-off-by: Juergen Lock > > --- a/cache-utils.c > +++ b/cache-utils.c > @@ -57,6 +57,23 @@ > } > #endif > > +#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) > +#include > +#include > +#include > + >

[Qemu-devel] [PATCH 0/3] FreeBSD/ppc host patches

2010-02-14 Thread Juergen Lock
Hi! These are patches submitted by Andreas Tobler to get qemu working on FreeBSD/ppc hosts. There is one other patch to ppc.ld that's needed because of FreeBSD's older binutils that probably should stay FreeBSD-specific, here is the link to it in FreeBSD ports: http://www.freebsd.org/cg

[Qemu-devel] [PATCH 2/3] Add FreeBSD/ppc host ucontext definitions.

2010-02-14 Thread Juergen Lock
Submitted by: Andreas Tobler Signed-off-by: Juergen Lock --- a/cpu-exec.c +++ b/cpu-exec.c @@ -933,6 +933,20 @@ # define TRAP_sig(context) REG_sig(trap, context) #endif /* linux */ +#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) +#include +# define IAR_sig(cont

[Qemu-devel] [PATCH 1/3] Add FreeBSD/ppc host ppc_init_cacheline_sizes() implementation.

2010-02-14 Thread Juergen Lock
Submitted by: Andreas Tobler Signed-off-by: Juergen Lock --- a/cache-utils.c +++ b/cache-utils.c @@ -57,6 +57,23 @@ } #endif +#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) +#include +#include +#include + +static void ppc_init_cacheline_sizes(void) +{ +size_t len = 4; +u

[Qemu-devel] [PATCH 3/3] Add FreeBSD/ppc host TCG_TARGET_CALL_{ALIGN_ARGS,STACK_OFFSET} definitions.

2010-02-14 Thread Juergen Lock
Submitted by: Andreas Tobler Signed-off-by: Juergen Lock --- a/tcg/ppc/tcg-target.h +++ b/tcg/ppc/tcg-target.h @@ -69,7 +69,7 @@ #define TCG_TARGET_CALL_STACK_OFFSET 24 #elif defined _AIX #define TCG_TARGET_CALL_STACK_OFFSET 52 -#elif defined __linux__ +#elif defined __linux__ || defined __F

Re: [Qemu-devel] Thumb-2 Support

2010-02-14 Thread Rabin Vincent
On Wed, Sep 23, 2009 at 02:30:01PM +0200, Crooks (Rigante) wrote: > I was wondering what level of support there is for Thumb-2. (Qemu 0.11 RC2) > I've compiled two linux-kernels, one with Thumb-2, and one without Thumb-2, > using the codesourcery compilers. I've then tried to boot these kernels wit

[Qemu-devel] [PATCH 3/3] target-arm: support thumb exception handlers

2010-02-14 Thread Rabin Vincent
When handling an exception, switch to the correct mode based on the Thumb Exception (TE) bit in the SCTLR. Signed-off-by: Rabin Vincent --- target-arm/helper.c |5 ++--- 1 files changed, 2 insertions(+), 3 deletions(-) diff --git a/target-arm/helper.c b/target-arm/helper.c index 27001e8..43

[Qemu-devel] [PATCH 1/3] target-arm: fix thumb CPS

2010-02-14 Thread Rabin Vincent
The Thumb CPS currently does not work correctly: CPSID touches more bits than the instruction wants to, and CPSIE does nothing. Fix it by passing the correct mask (the "affect" bits) and value. Signed-off-by: Rabin Vincent --- target-arm/translate.c |2 +- 1 files changed, 1 insertions(+),

[Qemu-devel] [PATCH 2/3] target-arm: implement Thumb-2 exception return

2010-02-14 Thread Rabin Vincent
Support the "subs pc, lr" Thumb-2 exception return instruction. Signed-off-by: Rabin Vincent --- target-arm/translate.c | 13 +++-- 1 files changed, 11 insertions(+), 2 deletions(-) diff --git a/target-arm/translate.c b/target-arm/translate.c index 10a516b..f0667e5 100644 --- a/target

[Qemu-devel] [PATCH 0/3] target-arm: Thumb(-2) exception support

2010-02-14 Thread Rabin Vincent
This series adds Thumb exception support and fixes a couple of instructions related to it. With these patches, QEMU can boot a Linux kernel built with Thumb-2. Rabin Vincent (3): target-arm: fix thumb CPS target-arm: implement Thumb-2 exception return target-arm: support thumb exception han

[Qemu-devel] Re: [PATCH] Give sdl-config higher priority than pkg-config

2010-02-14 Thread Jacob Meuser
On Sun, Feb 14, 2010 at 01:04:31PM +0100, Paolo Bonzini wrote: > On 02/14/2010 08:23 AM, Blue Swirl wrote: > >On OpenBSD, pkg-config sdl --cflags forgets to add -I/usr/local/include > >which is needed for iconv.h (included from SDL.h). This makes SDL > >detection fail. > > > >Try sdl-config first,

[Qemu-devel] [PATCH 19/20] eepro100: Remove C++ comments

2010-02-14 Thread Stefan Weil
C++ comments are unwanted, so this is fixed here. * Replace C++ comments by C comments. * Put code which was deactivated by a C++ comment in #if 0...#endif. Signed-off-by: Stefan Weil --- hw/eepro100.c | 185 +++-- 1 files changed, 126 insert

[Qemu-devel] [PATCH 20/20] eepro100: Keep includes sorted

2010-02-14 Thread Stefan Weil
I always try to keep standard includes sorted and add a comment why they are there (so they can be removed when they are no longer needed). Signed-off-by: Stefan Weil --- hw/eepro100.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index 0

[Qemu-devel] [PATCH 18/20] eepro100: Add diagnose command

2010-02-14 Thread Stefan Weil
Real hardware would run an internal self-test. The emulation just returns a passed status. Original patch was from Reimar Döffinger, thanks. Signed-off-by: Stefan Weil --- hw/eepro100.c |5 + 1 files changed, 5 insertions(+), 0 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c in

[Qemu-devel] [PATCH 17/20] eepro100: New function for reading command block

2010-02-14 Thread Stefan Weil
Move code which reads the command block to the new function read_cb. The patch also fixes some endianess issues related to the command block and moves declarations of local variables to the beginning of the block. Signed-off-by: Stefan Weil --- hw/eepro100.c | 42 --

[Qemu-devel] [PATCH 16/20] eepro100: Use tx.status

2010-02-14 Thread Stefan Weil
There is no need for a local variable "status". Using tx.status makes it clearer which status is addressed. Signed-off-by: Stefan Weil --- hw/eepro100.c |6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index 368a9d6..ebf0f7d 100644 --- a

[Qemu-devel] [PATCH 15/20] eepro100: Prettify code (no functional changes)

2010-02-14 Thread Stefan Weil
* Fix indentation. Signed-off-by: Stefan Weil --- hw/eepro100.c |8 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index 8a139f7..368a9d6 100644 --- a/hw/eepro100.c +++ b/hw/eepro100.c @@ -188,11 +188,11 @@ typedef enum { typedef stru

[Qemu-devel] [PATCH 14/20] eepro100: Fix CU Start command

2010-02-14 Thread Stefan Weil
CU Start is allowed when the CU is in the idle or suspended state. Signed-off-by: Stefan Weil --- hw/eepro100.c | 12 ++-- 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index 37176cd..8a139f7 100644 --- a/hw/eepro100.c +++ b/hw/eepro100.c

[Qemu-devel] [PATCH 13/20] eepro100: Support RNR interrupt

2010-02-14 Thread Stefan Weil
The RNR interrupt is triggered under these conditions: * the RU is not ready to receive a frame due to missing resources * the RU is ready and a RU abort command was requested Signed-off-by: Stefan Weil --- hw/eepro100.c | 13 ++--- 1 files changed, 10 insertions(+), 3 deletions(-) d

[Qemu-devel] [PATCH 12/20] eepro100: Replace variable name to fix a compiler warning

2010-02-14 Thread Stefan Weil
When compiling with -Wshadow, gcc gives a warning which is fixed by renaming stat -> status. Signed-off-by: Stefan Weil --- hw/eepro100.c | 12 ++-- 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index 01bcd6d..b5bd05b 100644 --- a/hw/eepro

[Qemu-devel] [PATCH 10/20] eepro100: Remove old unused code

2010-02-14 Thread Stefan Weil
This code is no longer needed. Signed-off-by: Stefan Weil --- hw/eepro100.c | 18 -- 1 files changed, 0 insertions(+), 18 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index 1ce2cd1..c647322 100644 --- a/hw/eepro100.c +++ b/hw/eepro100.c @@ -469,24 +469,6 @@ static v

[Qemu-devel] [PATCH 11/20] eepro100: Use symbolic names for bits in EEPROM id

2010-02-14 Thread Stefan Weil
Signed-off-by: Stefan Weil --- hw/eepro100.c | 17 - 1 files changed, 16 insertions(+), 1 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index c647322..01bcd6d 100644 --- a/hw/eepro100.c +++ b/hw/eepro100.c @@ -272,6 +272,21 @@ typedef enum { eeprom_smbus_addr = 0

[Qemu-devel] [PATCH 09/20] eepro100: Use symbolic names and BIT macros in binary operations

2010-02-14 Thread Stefan Weil
Instead of magic numbers like 0x8000, symbolic names are used for the SCB command and status bits. There are too many configuration bits to use symbolic names there, too. Using the BIT macro is a little help when comparing code and documentation. For the same reason, some other constants were rep

[Qemu-devel] [PATCH 08/20] eepro100: Add device descriptions

2010-02-14 Thread Stefan Weil
Add descriptions for all devices. These descriptions are shown when users call qemu -device ? Signed-off-by: Stefan Weil --- hw/eepro100.c | 12 1 files changed, 12 insertions(+), 0 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index 3e2f008..031fe69 100

[Qemu-devel] [PATCH 07/20] eepro100: Update copyright notice

2010-02-14 Thread Stefan Weil
Signed-off-by: Stefan Weil --- hw/eepro100.c | 10 +- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index b93667a..3e2f008 100644 --- a/hw/eepro100.c +++ b/hw/eepro100.c @@ -1,15 +1,15 @@ /* * QEMU i8255x (PRO100) emulation * - * Copyr

[Qemu-devel] [PATCH 06/20] eepro100: Add TODO list

2010-02-14 Thread Stefan Weil
Signed-off-by: Stefan Weil --- hw/eepro100.c |8 1 files changed, 8 insertions(+), 0 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index 179c544..b93667a 100644 --- a/hw/eepro100.c +++ b/hw/eepro100.c @@ -31,6 +31,14 @@ * * Intel 8255x 10/100 Mbps Ethernet Controller F

[Qemu-devel] [PATCH 05/20] eepro100: Add all supported devices to pci.c

2010-02-14 Thread Stefan Weil
All eepro100 devices work with drivers which only use basic features. They were tested with gpxe boot. Signed-off-by: Stefan Weil --- hw/pci.c | 18 ++ 1 files changed, 18 insertions(+), 0 deletions(-) diff --git a/hw/pci.c b/hw/pci.c index eb2043e..1ba3f92 100644 --- a/hw/pc

[Qemu-devel] [PATCH 03/20] eepro100: Fix PXE boot

2010-02-14 Thread Stefan Weil
The phy handling was wrong for PXE, GPXE boot: GPXE's eepro100 driver did not detect a valid link. This is fixed here. Signed-off-by: Stefan Weil --- hw/eepro100.c | 20 ++-- 1 files changed, 14 insertions(+), 6 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index 12

[Qemu-devel] [PATCH 02/20] eepro100: Add missing SCB register names

2010-02-14 Thread Stefan Weil
Some system control block registers were addressed using their offset value. Use symbolic names now and clean the documentation. Signed-off-by: Stefan Weil --- hw/eepro100.c | 16 ++-- 1 files changed, 10 insertions(+), 6 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c ind

[Qemu-devel] [PATCH 01/20] eepro100: Fix compiler errors from debug messages

2010-02-14 Thread Stefan Weil
When debug output was enabled (by defining DEBUG_EEPRO100), some debug messages resulted in a compiler error. This is fixed here. Signed-off-by: Stefan Weil --- hw/eepro100.c | 13 +++-- 1 files changed, 7 insertions(+), 6 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index

[Qemu-devel] eepro100: New patch series adds full GPXE support

2010-02-14 Thread Stefan Weil
These patches contain fixes, enhancements and improvements for eepro100. Even if some of these patches contain trivial changes which seem to be optional, they help to synchronize my maintainer version with the official QEMU version, so please apply them. 0001-eepro100-Fix-compiler-errors-from-deb

[Qemu-devel] Re: [PATCH] Give sdl-config higher priority than pkg-config

2010-02-14 Thread Paolo Bonzini
Right. I think this patch against ports/devel/sdl should do the trick: --- patches/patch-sdl_pc_in.origSun Feb 14 14:08:41 2010 +++ patches/patch-sdl_pc_in Sun Feb 14 14:10:50 2010 @@ -8,4 +8,4 @@ -Libs: -L${libdir} @SDL_RLD_FLAGS@ @SDL_LIBS@ -Cflags: -I${includedir}/SDL @SDL_CF

Re: [Qemu-devel] qemu-ppc can't run static uClibc binaries.

2010-02-14 Thread Alexander Graf
Am Sun 14 Feb 2010 09:36:27 AM CET schrieb Rob Landley : On Thursday 11 February 2010 06:32:12 Alexander Graf wrote: Rob Landley wrote: > Static binaries that run under the Linux kernel don't run under qemu-ppc. > For example, the prebuilt busybox binaries here: > > http://busybox.net/downlo

Re: [Qemu-devel] qemu-system-ppc -m g3beige -hda is setting /dev/hdc on Linux.

2010-02-14 Thread Alexander Graf
Am Sat 13 Feb 2010 07:29:33 PM CET schrieb Rob Landley : On Saturday 13 February 2010 06:04:03 Alexander Graf wrote: > Exactly, that's the issue to fix here, make DBDMA work with CD-ROM so we > can get rid of the cmd64x controller. Speaking of which - in my PPC64 enabling series I use MacIO fo

[Qemu-devel] [PULL] qemu: pci fixes and cleanups

2010-02-14 Thread Michael S. Tsirkin
The following changes since commit bc798c77e54f73b637e02bdc02bd799660adb7b7: Blue Swirl (1): Remove conditional rom loading support are available in the git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/mst/qemu.git for_anthony Alexander Graf (10): PPC: Uninorth

Re: [Qemu-devel] qemu-system-ppc -m g3beige -hda is setting /dev/hdc on Linux.

2010-02-14 Thread Alexander Graf
Am Sat 13 Feb 2010 07:27:21 PM CET schrieb Rob Landley : On Saturday 13 February 2010 04:28:44 Alexander Graf wrote: On 13.02.2010, at 09:02, Rob Landley wrote: > The -hda, -hdb, -hdc, and -hdd command line options for g3beige don't > match the order the kernel assigns the drives. > > The reaso

[Qemu-devel] Re: [PATCH] Give sdl-config higher priority than pkg-config

2010-02-14 Thread Blue Swirl
On Sun, Feb 14, 2010 at 2:04 PM, Paolo Bonzini wrote: > On 02/14/2010 08:23 AM, Blue Swirl wrote: >> >> On OpenBSD, pkg-config sdl --cflags forgets to add -I/usr/local/include >> which is needed for iconv.h (included from SDL.h). This makes SDL >> detection fail. >> >> Try sdl-config first, only i

[Qemu-devel] Re: [PATCH 2/2] net/macvtap: add vhost support

2010-02-14 Thread Michael S. Tsirkin
On Sat, Feb 13, 2010 at 11:35:08AM +0100, Arnd Bergmann wrote: > This adds support for passing a macvtap file descriptor into > vhost-net, much like we already do for tun/tap. > > Most of the new code is taken from the respective patch > in the tun driver and may get consolidated in the future. >

[Qemu-devel] Re: [PATCH v2] qemu-kvm: Speed up of the dirty-bitmap-traveling

2010-02-14 Thread Avi Kivity
On 02/12/2010 04:03 AM, OHMURA Kei wrote: > On 02/11/2010 Anthony Liguori wrote: > >> Oh, I see what's happening here. Yes, I think a leul_to_cpu() makes more >> sense. >> > Maybe I'm missing something here. > I couldn't find leul_to_cpu(), so have defined it in bswap.h. > Correct? > > ---

[Qemu-devel] Re: [PATCH 0/4] qemu-kvm: prepare for adding eventfd usage to upstream

2010-02-14 Thread Avi Kivity
On 02/13/2010 03:26 PM, Marcelo Tosatti wrote: On Thu, Feb 11, 2010 at 12:09:12AM +0100, Paolo Bonzini wrote: This patch series morphs the code in qemu-kvm's eventfd so that it looks like the code in upstream qemu. Patch 4 is not yet in upstream QEMU, I'm submitting it first to qemu-kvm to

[Qemu-devel] Re: [PATCH] Give sdl-config higher priority than pkg-config

2010-02-14 Thread Paolo Bonzini
On 02/14/2010 08:23 AM, Blue Swirl wrote: On OpenBSD, pkg-config sdl --cflags forgets to add -I/usr/local/include which is needed for iconv.h (included from SDL.h). This makes SDL detection fail. Try sdl-config first, only if it fails try pkg-config. This breaks cross-compilation. I'm CCing t

[Qemu-devel] [PATCH v4 rebased] block: more read-only changes, related to backing files

2010-02-14 Thread Naphtali Sprei
Open backing file read-only where possible Upgrade backing file to read-write during commit, back to read-only after commit If upgrade fail, back to read-only. If also fail, "disconnect" the drive. Signed-off-by: Naphtali Sprei --- block.c | 83 +++

Re: [Qemu-devel] qemu-ppc can't run static uClibc binaries.

2010-02-14 Thread Rob Landley
On Thursday 11 February 2010 06:32:12 Alexander Graf wrote: > Rob Landley wrote: > > Static binaries that run under the Linux kernel don't run under qemu-ppc. > > For example, the prebuilt busybox binaries here: > > > > http://busybox.net/downloads/binaries/1.16.0/busybox-powerpc > > > > Don't r