1. 22 5月, 2012 5 次提交
  2. 17 5月, 2012 4 次提交
  3. 10 5月, 2012 1 次提交
  4. 13 4月, 2012 3 次提交
  5. 15 3月, 2012 2 次提交
    • D
      kvm: Comparison with ioctl number macros needs to be unsigned · 92e4b519
      David Gibson 提交于
      In kvm-all.c we store an ioctl cmd number in the irqchip_inject_ioctl field
      of KVMState, which has type 'int'.  This seems to make sense since the
      ioctl() man page says that the cmd parameter has type int.
      
      However, the kernel treats ioctl numbers as unsigned - sys_ioctl() takes an
      unsigned int, and the macros which generate ioctl numbers expand to
      unsigned expressions.  Furthermore, some ioctls (IOC_READ ioctls on x86
      and IOC_WRITE ioctls on powerpc) have bit 31 set, and so would be negative
      if interpreted as an int. This has the surprising and compile-breaking
      consequence that in kvm_irqchip_set_irq() where we do:
          return (s->irqchip_inject_ioctl == KVM_IRQ_LINE) ? 1 : event.status;
      We will get a "comparison is always false due to limited range of data
      type" warning from gcc if KVM_IRQ_LINE is one of the bit-31-set ioctls,
      which it is on powerpc.
      
      So, despite the fact that the man page and posix say ioctl numbers are
      signed, they're actually unsigned.  The kernel uses unsigned, the glibc
      header uses unsigned long, and FreeBSD, NetBSD and OSX also use unsigned
      long ioctl numbers in the code.
      
      Therefore, this patch changes the variable to be unsigned, fixing the
      compile.
      Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      92e4b519
    • A
      Rename CPUState -> CPUArchState · 9349b4f9
      Andreas Färber 提交于
      Scripted conversion:
        for file in *.[hc] hw/*.[hc] hw/kvm/*.[hc] linux-user/*.[hc] linux-user/m68k/*.[hc] bsd-user/*.[hc] darwin-user/*.[hc] tcg/*/*.[hc] target-*/cpu.h; do
          sed -i "s/CPUState/CPUArchState/g" $file
        done
      
      All occurrences of CPUArchState are expected to be replaced by QOM CPUState,
      once all targets are QOM'ified and common fields have been extracted.
      Signed-off-by: NAndreas Färber <afaerber@suse.de>
      Reviewed-by: NAnthony Liguori <aliguori@us.ibm.com>
      9349b4f9
  6. 08 3月, 2012 1 次提交
  7. 07 3月, 2012 2 次提交
  8. 01 3月, 2012 1 次提交
    • A
      kvm: fix unaligned slots · 8f6f962b
      Avi Kivity 提交于
      kvm_set_phys_mem() may be passed sections that are not aligned to a page
      boundary.  The current code simply brute-forces the alignment which leads
      to an inconsistency and an abort().
      
      Fix by aligning the start and the end of the section correctly, discarding
      and unaligned head or tail.
      
      This was triggered by a guest sizing a 64-bit BAR that is smaller than a page
      with PCI_COMMAND_MEMORY enabled and the upper dword clear.
      Signed-off-by: NAvi Kivity <avi@redhat.com>
      8f6f962b
  9. 29 2月, 2012 4 次提交
  10. 18 2月, 2012 1 次提交
  11. 09 2月, 2012 1 次提交
  12. 02 2月, 2012 1 次提交
  13. 26 1月, 2012 1 次提交
  14. 21 1月, 2012 1 次提交
  15. 19 1月, 2012 2 次提交
    • J
      kvm: x86: Establish IRQ0 override control · 9b5b76d4
      Jan Kiszka 提交于
      KVM is forced to disable the IRQ0 override when we run with in-kernel
      irqchip but without IRQ routing support of the kernel. Set the fwcfg
      value correspondingly. This aligns us with qemu-kvm.
      Signed-off-by: NJan Kiszka <jan.kiszka@siemens.com>
      9b5b76d4
    • J
      kvm: Introduce core services for in-kernel irqchip support · 84b058d7
      Jan Kiszka 提交于
      Add the basic infrastructure to active in-kernel irqchip support, inject
      interrupts into these models, and maintain IRQ routes.
      
      Routing is optional and depends on the host arch supporting
      KVM_CAP_IRQ_ROUTING. When it's not available on x86, we looe the HPET as
      we can't route GSI0 to IOAPIC pin 2.
      
      In-kernel irqchip support will once be controlled by the machine
      property 'kernel_irqchip', but this is not yet wired up.
      Signed-off-by: NJan Kiszka <jan.kiszka@siemens.com>
      84b058d7
  16. 15 1月, 2012 1 次提交
  17. 04 1月, 2012 1 次提交
  18. 20 12月, 2011 2 次提交
  19. 16 12月, 2011 1 次提交
  20. 02 11月, 2011 1 次提交
  21. 25 10月, 2011 1 次提交
  22. 04 10月, 2011 1 次提交
    • L
      RunState: Rename enum values as generated by the QAPI · 0461d5a6
      Luiz Capitulino 提交于
      Next commit will convert the query-status command to use the
      RunState type as generated by the QAPI.
      
      In order to "transparently" replace the current enum by the QAPI
      one, we have to make some changes to some enum values.
      
      As the changes are simple renames, I'll do them in one shot. The
      changes are:
      
       - Rename the prefix from RSTATE_ to RUN_STATE_
       - RUN_STATE_SAVEVM to RUN_STATE_SAVE_VM
       - RUN_STATE_IN_MIGRATE to RUN_STATE_INMIGRATE
       - RUN_STATE_PANICKED to RUN_STATE_INTERNAL_ERROR
       - RUN_STATE_POST_MIGRATE to RUN_STATE_POSTMIGRATE
       - RUN_STATE_PRE_LAUNCH to RUN_STATE_PRELAUNCH
       - RUN_STATE_PRE_MIGRATE to RUN_STATE_PREMIGRATE
       - RUN_STATE_RESTORE to RUN_STATE_RESTORE_VM
       - RUN_STATE_PRE_MIGRATE to RUN_STATE_FINISH_MIGRATE
      Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com>
      0461d5a6
  23. 16 9月, 2011 1 次提交
    • L
      Replace the VMSTOP macros with a proper state type · 1dfb4dd9
      Luiz Capitulino 提交于
      Today, when notifying a VM state change with vm_state_notify(),
      we pass a VMSTOP macro as the 'reason' argument. This is not ideal
      because the VMSTOP macros tell why qemu stopped and not exactly
      what the current VM state is.
      
      One example to demonstrate this problem is that vm_start() calls
      vm_state_notify() with reason=0, which turns out to be VMSTOP_USER.
      
      This commit fixes that by replacing the VMSTOP macros with a proper
      state type called RunState.
      Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com>
      1dfb4dd9
  24. 02 9月, 2011 1 次提交
    • A
      main: force enabling of I/O thread · 12d4536f
      Anthony Liguori 提交于
      Enabling the I/O thread by default seems like an important part of declaring
      1.0.  Besides allowing true SMP support with KVM, the I/O thread means that the
      TCG VCPU doesn't have to multiplex itself with the I/O dispatch routines which
      currently requires a (racey) signal based alarm system.
      
      I know there have been concerns about performance.  I think so far the ones that
      have come up (virtio-net) are most likely due to secondary reasons like
      decreased batching.
      
      I think we ought to force enabling I/O thread early in 1.0 development and
      commit to resolving any lingering issues.
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      12d4536f