• We want to do (at least) two things to the virtio-balloon device:
    suppress it, and control its PCI address.  Option -no-virtio-balloon
    lets us do only the former.  To get the latter, replace
    -no-virtio-balloon with
    
        -balloon none   disable balloon device
        -balloon virtio[,addr=str]
                        enable virtio balloon device (default)
    
    Syntax suggested by Anthony Liguori.
    
    Signed-off-by: Markus Armbruster <armbru@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Markus Armbruster authored
     
    Browse Code »
  • At this point, this refactoring looks like overkill. But we will need it
    for CPU hotplugging, and qemu-kvm already carries it. Merging it early
    would help qemu-kvm when rebasing against upstream.
    
    Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Jan Kiszka authored
     
    Browse Code »
  • This reverts commit 8217606e (and
    updates later added users of qemu_register_reset), we solved the
    problem it originally addressed less invasively.
    
    Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Jan Kiszka authored
     
    Browse Code »
  • Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Jan Kiszka authored
     
    Browse Code »
  • During startup and after reset we have to synchronize user space to the
    in-kernel KVM state. Namely, we need to transfer the VCPU registers when
    they change due to VCPU as well as APIC reset.
    
    This patch refactors the required hooks so that kvm_init_vcpu registers
    its own per-VCPU reset handler and adds a cpu_synchronize_state to the
    APIC reset. That way we no longer depend on the new reset order (and can
    drop this disliked interface again) and we can even drop a KVM hook in
    main().
    
    Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Jan Kiszka authored
     
    Browse Code »
  • The "pci_addr=" prefix currently required by pci_add/remove and
    drive_add has no practical use. Drop it, but still silently accept it
    for backward compatibility.
    
    Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Jan Kiszka authored
     
    Browse Code »
  • This patch implements support for Multiboot on x86 for -kernel.
    Multiboot is a "new" approach to get rid of different bootloaders, providing
    a unified interface for the kernel. It supports command line options and
    kernel modules.
    
    The two probably best known projects using multiboot are Xen and GNU Hurd.
    
    This implementation should be mostly feature-complete. It is missing VBE
    extensions, but as no system uses them currently it does not really hurt.
    
    To use multiboot, specify the kernel as -kernel option. Modules should be given
    as -initrd options, seperated by a comma (,). -append also works.
    
    Please bear in mind that grub also does gzip decompression, which qemu does
    not do yet. To run existing images, please ungzip them first.
    
    The guest multiboot loader code is implemented as option rom using int 19.
    Parts of the work are based on efforts by Rene Rebe, who originally ported
    my code to int 19.
    
    Signed-off-by: Alexander Graf <agraf@suse.de>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Alexander Graf authored
     
    Browse Code »
  • Multiboot passes options to the option rom using the fw_cfg device.
    Right now, that device is local to the bochs_bios_init function.
    
    Let's change that and expose it, so everyone may put data in there.
    
    Signed-off-by: Alexander Graf <agraf@suse.de>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Alexander Graf authored
     
    Browse Code »
  • For multiboot support, we need bochs_bios_init to happen before
    load_linux, so we get the fw_cfg device.
    
    Signed-off-by: Alexander Graf <agraf@suse.de>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Alexander Graf authored
     
    Browse Code »
  • Introduce qemu_find_vlan_client_by_name for VLANClientState lookup based
    on VLAN ID and client name. This is useful for monitor commands.
    
    Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Jan Kiszka authored
     
    Browse Dir »

  • [brought forward to current qemu-kvm.git]
    
    This patch implements the missing qemu logic to
    interpret a '-drive .. serial=XYZ ..' flag for
    a virtio_blk device.
    
    The serial number string is contained in a
    skeletal IDENTIFY DEVICE data structure and
    this structure is made available to the guest
    virtio_blk driver via pci i/o region 0.
    
    Signed-off-by: john cooper <john.cooper@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    john cooper authored
     
    Browse Code »
  • Add an option to specify the number of MSI-X vectors for PCI NIC cards. This
    can also be used to disable MSI-X, for compatibility with old qemu. This
    option currently only affects virtio cards.
    
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Michael S. Tsirkin authored
     
    Browse Code »
  • Request up to 3 vectors in virtio-net. Actual bindings might supply
    less.
    
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Michael S. Tsirkin authored
     
    Browse Code »
  • Add pci_get/set_byte to keep *_word and *_long access functions company.
    They are unused for now.
    
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Michael S. Tsirkin authored
     
    Browse Code »
  • Implement bindings for virtio save/load. Use them in virtio pci.
    
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Michael S. Tsirkin authored
     
    Browse Code »
  • This enables actual support for MSI-X in virtio PCI.
    First user will be virtio-net.
    
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Michael S. Tsirkin authored
     
    Browse Code »
  • Extend virtio to support many interrupt vectors, and rearrange code in
    preparation for multi-vector support (mostly move reset out to bindings,
    because we will have to reset the vectors in transport-specific code).
    Actual bindings in pci, and use in net, to follow.
    Load and save are not connected to bindings yet, so they are left
    stubbed out for now.
    
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Michael S. Tsirkin authored
     
    Browse Code »
  • Implement MSI support in APIC. Note that MSI and MMIO APIC registers
    are at the same memory location, but actually not on the global bus: MSI
    is on PCI bus, APIC is connected directly to the CPU. We map them on the
    global bus at the same address which happens to work because MSI
    registers are reserved in APIC MMIO and vice versa.
    
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Michael S. Tsirkin authored
     
    Browse Code »
  • Add functions implementing MSI-X support. First user will be virtio-pci.
    Note that platform must set a flag to declare MSI supported: this
    is a safety measure to avoid breaking platforms which should support
    MSI-X but currently lack this in the interrupt controller emulation.
    For PC this will be set by APIC.
    
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Michael S. Tsirkin authored
     
    Browse Code »
  • Add "cmask" table of constant register masks: if a bit is not writeable
    and is set in cmask table, this bit is checked on load.  An attempt to
    load an image that would change such a register causes load to fail.
    Use this table to make sure that load does not modify registers that
    guest can not change (directly or indirectly).
    
    Note: we can't just assume that read-only registers never change,
    because the guest could change a register indirectly.
    
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Michael S. Tsirkin authored
     
    Browse Code »
  • Add routines to manage PCI capability list. First user will be MSI-X.
    
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Michael S. Tsirkin authored
     
    Browse Code »
  • Add inline routines for convenient access to pci devices
    with correct (little) endianness. Will be used by MSI-X support.
    
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Michael S. Tsirkin authored
     
    Browse Code »
  • Change much of hw/pci to use symbolic constants and a table-driven
    design: add a mask table with writable bits set and readonly bits unset.
    Detect change by comparing original and new registers.
    
    This makes it easy to support capabilities where read-only/writeable
    bit layout differs between devices, depending on capabilities present.
    
    As a result, writing a single byte in BAR registers now works as
    it should. Writing to upper limit registers in the bridge
    also works as it should. Code is also shorter.
    
    Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
    Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
    Michael S. Tsirkin authored
     
    Browse Dir »