• The DisplayState refactoring changed the machine init function to create a
    DisplayState for each VGA device instead of being passed an existing
    DisplayState.  This change is critical to enable multiple graphics device
    support.
    
    Unfortunately, the serial/parallel/console code is structured today to run
    before machine init to fill out the CharDriverState table which the machine
    init function uses to determine whether to create the required devices.
    
    Since a 'vc' is a type of CharDriverState, the CharDriverState code requires
    that a DisplayState exist before it runs creating a circular dependency.
    
    To fix this, this splits the creation of the initial CharDriverState from
    the initialization of the text console.  We can then in a second step associate
    a DisplayState with all TextConsoles.  This allows us to create the
    CharDriverState's first, machine init, then associate the TextConsoles with
    a DisplayState.
    
    This code screams for more cleanup.
    
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6352 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse File »
  • Patch 5/7
    
    This patch changes the graphical_console_init function to return an
    allocated DisplayState instead of a QEMUConsole.
    
    This patch contains just the graphical_console_init change and few other
    modifications mainly in console.c and vl.c.
    It was necessary to move the display frontends (e.g. sdl and vnc)
    initialization after machine->init in vl.c.
    
    This patch does *not* include any required changes to any device, these
    changes come with the following patches.
    
    Patch 6/7
    
    This patch changes the QEMUMachine init functions not to take a
    DisplayState as an argument because is not needed any more;
    
    In few places the graphic hardware initialization function was called
    only if DisplayState was not NULL, now they are always called.
    Apart from these cases, the rest are all mechanical substitutions.
    
    Patch 7/7
    
    This patch updates the graphic device code to use the new
    graphical_console_init function.
    
    As for the previous patch, in few places graphical_console_init was called
    only if DisplayState was not NULL, now it is always called.
    Apart from these cases, the rest are all mechanical substitutions.
    
    Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6344 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse Code »

  • This is a large patch that changes all occurrences of logfile/loglevel
    global variables to use the new qemu_log*() macros.
    
    Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6338 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse Code »
  • This patch changes the DisplayState interface adding support for
    multiple frontends at the same time (sdl and vnc) and implements most
    of the benefit of the shared_buf patch without the added complexity.
    
    Currently DisplayState is managed by sdl (or vnc) and sdl (or vnc) is
    also responsible for allocating the data and setting the depth.
    Vga.c (or another backend) will do any necessary conversion.
    
    The idea is to change it so that is vga.c (or another backend) together
    with console.c that fully manage the DisplayState interface allocating
    data and setting the depth (either 16 or 32 bit, if the guest uses a
    different resolution or is in text mode, vga.c (or another backend) is
    in charge of doing the conversion seamlessly).
    
    The other idea is that DisplayState supports *multiple* frontends
    like sdl and vnc; each of them can register some callbacks to be called
    when a display event occurs.
    
    The interesting changes are:
    
    - the new structures and related functions in console.h and console.c
    
    in particular the following functions are very helpful to manage a
    DisplaySurface:
    
    qemu_create_displaysurface
    qemu_resize_displaysurface
    qemu_create_displaysurface_from
    qemu_free_displaysurface
    
    - console_select and qemu_console_resize in console.c
    this two functions manage multiple consoles on a single host display
    
    - moving code around in hw/vga.c
    as for the shared_buf patch this is necessary to be able to handle a dynamic
    DisplaySurface bpp
    
    - changes to vga_draw_graphic in hw/vga.c
    this is the place where the DisplaySurface buffer is shared with the
    videoram, when possible;
    
    
    Compared to the last version the only changes are:
    
    - do not remove support to dpy_copy in cirrus_vga
    - change the name of the displaysurface handling functions
    
    Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6336 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse File »
  • Use macros to avoid #ifdefs on debugging code.
    
    This patch doesn't try to merge logging macros from different files,
    but just unify the debugging code #ifdefs onto a macro on each file. A
    further cleanup can unify the debugging macros on a common header, later
    
    Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6332 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse Dir »
  • currently there is no way to fully disable any graphic card device for
    the PC architecture.
    You can have no graphical output, thanks to -nographic, but you would
    have the VGA device connected to your PCI bus anyway.
    There is already a convenient -vga option to choose between std, cirrus
    and vmware; this patch add the new option "none" to select no graphic
    card at all.
    
    Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6322 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse Code »
  • After my last patch to fix interrupt coalescing was rejected
    on the basis that it is too intrusive we decided to make the
    fix much more localized and only fix the problem for RTC time
    source. Unfortunately it is impossible to fix the problem entirely
    inside RTC code like Andrzej proposed since Windows reads RTC
    register C more then once on each time interrupt so it is impossible
    to count reliably how many interrupt windows actually handled.
    Proposed solution is localized to I386 target and is disabled by
    default. To enable it "-rtc-td-hack" flag should be used.
    
    Signed-off-by: Gleb Natapov <gleb@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6320 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse Dir »
  • This patch adds the typical qemu console command line switch to the virtio
    console. using -virtioconsole ARG it can now be specified what output a guest
    hvc should be redirected to.
    
    Signed-off-by: Christian Ehrhardt <ehrhardt@linux.vnet.ibm.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6317 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse Code »
  • This patch adds the virtio console to qemu. This console can be found after the
    serial and parallel outputs as another virtual console. In the -nographic case
    it is redirected to the null output by default.
    
    Signed-off-by: Christian Ehrhardt <ehrhardt@linux.vnet.ibm.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6315 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse Code »











  • qcow2 writes a cluster reference count on every cluster update.  This causes
    performance to crater when using anything but cache=writeback.  This is most
    noticeable when using savevm.  Right now, qcow2 isn't a reliable format
    regardless of the type of cache your using because metadata is not updated in
    the correct order.  Considering this, I think it's somewhat reasonable to use
    writeback caching by default with qcow2 files.
    
    It at least avoids the massive performance regression for users until we sort
    out the issues in qcow2. 
    
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5879 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse Code »
  • Balloon devices allow you to ask the guest to allocate memory.  This allows you
    to release that memory.  It's mostly useful for freeing up large chunks of
    memory from cooperative guests.
    
    Ballooning is supported by both Xen and VirtIO.
    
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5873 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse File »
  • Virtio-blk is a paravirtual block device based on VirtIO.  It can be used by
    specifying the if=virtio parameter to the -drive parameter.
    
    When using -enable-kvm, it can achieve very good performance compared to IDE or
    SCSI.
    
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5870 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse Code »

  • Changeset r5636 changed the timers to run in the alarm callback.  The 
    alarm callback can only be called as frequently as the host alarm timer 
    fires.  For older Linux hosts and possibly non-Linux hosts, this can be 
    as high as a 1ms granularity.
    
    icount calculates the select timeout based on the next deadline and 
    select is usually capable of sleeping for a short period of time than 
    alarm timer granularity.  This means that changing the timer callbacks 
    to be based on alarm firing caused timers to fire much later than they 
    ought to when using icount.
    
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5796 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse Code »

  • This patch enhances QEMU's built-in debugger for SMP guest debugging.
    Using the thread support of the gdb remote protocol, each VCPU is mapped
    on a pseudo thread and exposed to the gdb frontend. This way you can
    easy switch the focus of gdb between the VCPUs and observe their states.
    On breakpoint hit, the focus is automatically adjusted just as for
    normal multi-threaded application under gdb control.
    
    Furthermore, the patch propagates breakpoint and watchpoint insertions
    or removals to all CPUs, not just the current one as it was the case so
    far. Without this, SMP guest debugging was practically unfeasible.
    
    Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    
    
    
    git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5743 c046a42c-6fe2-441c-8c8c-71466251a162
    aliguori authored
     
    Browse Code »