1. 25 9月, 2015 1 次提交
  2. 21 9月, 2015 1 次提交
  3. 03 6月, 2015 1 次提交
  4. 12 3月, 2015 1 次提交
  5. 10 3月, 2015 1 次提交
  6. 09 3月, 2015 1 次提交
    • M
      PPC: Clean up misuse of qdev_init() in kvm-openpic creation · fe656ebd
      Markus Armbruster 提交于
      We call ppce500_init_mpic_kvm() to create a "kvm-openpic".  If it
      fails, we call ppce500_init_mpic_qemu() to fall back to plain
      "openpic".
      
      ppce500_init_mpic_kvm() uses qdev_init().  qdev_init()'s error
      handling has an unwanted side effect: it calls qerror_report_err(),
      which prints to stderr.  Looks like an error, but isn't.
      
      In QMP context, it would stash the error in the monitor instead,
      making the QMP command fail.  Fortunately, it's only called from board
      initialization, never in QMP context.
      
      Clean up by cutting out the qdev_init() middle-man: set property
      "realized" directly.
      
      While there, improve the error message when we can't satisfy an
      explicit user request for "kvm-openpic", and exit(1) instead of
      abort().
      Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      fe656ebd
  7. 07 1月, 2015 3 次提交
    • A
      PPC: e500: Fix GPIO controller interrupt number · 82e345f5
      Amit Tomar 提交于
      The GPIO controller lives at IRQ 47, not 43 on real hardware. This is a problem
      because IRQ 43 is occupied by the I2C controller which we want to implement
      next, so we'd have a conflict on that IRQ number.
      
      Move the GPIO controller to IRQ 47 where it belongs.
      Signed-off-by: NAmit Singh Tomar <amit.tomar@freescale.com>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      82e345f5
    • A
      PPC: e500 pci host: Add support for ATMUs · cb3778a0
      Alexander Graf 提交于
      The e500 PCI controller has configurable windows that allow a guest OS
      to selectively map parts of the PCI bus space to CPU address space and
      to selectively map parts of the CPU address space for DMA requests into
      PCI visible address ranges.
      
      So far, we've simply assumed that this mapping is 1:1 and ignored it.
      
      However, the PCICSRBAR (CCSR mapped in PCI bus space) always has to live
      inside the first 32bits of address space. This means if we always treat
      all mappings as 1:1, this map will collide with our RAM map from the CPU's
      point of view.
      
      So this patch adds proper ATMU support which allows us to keep the PCICSRBAR
      below 32bits local to the PCI bus and have another, different window to PCI
      BARs at the upper end of address space. We leverage this on e500plat though,
      mpc8544ds stays virtually 1:1 like it was before, but now also goes via ATMU.
      
      With this patch, I can run guests with lots of RAM and not coincidently access
      MSI-X mappings while I really want to access RAM.
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      cb3778a0
    • A
      PPC: e500: Move CCSR definition to params · 2eaaac1f
      Alexander Graf 提交于
      We want to have different MMIO region offsets for the mpc8544ds machine
      and our e500 PV machine, so move the definitions of those into the machine
      specific params struct.
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      2eaaac1f
  8. 05 11月, 2014 4 次提交
  9. 03 11月, 2014 1 次提交
    • M
      hw/core/loader: implement address translation in uimage loader · 25bda50a
      Max Filippov 提交于
      Such address translation is needed when load address recorded in uImage
      is a virtual address. When the actual load address is requested, return
      untranslated address: user that needs the translated address can always
      apply translation function to it and those that need it untranslated
      don't need to do the inverse translation.
      
      Add translation function pointer and its parameter to uimage_load
      prototype. Update all existing users.
      
      No user-visible functional changes.
      
      Cc: qemu-stable@nongnu.org
      Signed-off-by: NMax Filippov <jcmvbkbc@gmail.com>
      Reviewed-by: NAlexander Graf <agraf@suse.de>
      25bda50a
  10. 15 8月, 2014 1 次提交
  11. 15 7月, 2014 1 次提交
  12. 27 6月, 2014 1 次提交
  13. 16 6月, 2014 4 次提交
    • A
      PPC: e500: Move to u-boot as firmware · 3812c71f
      Alexander Graf 提交于
      Almost all platforms QEMU emulates have some sort of firmware they can load
      to expose a guest environment that closely resembles the way it would look
      like on real hardware.
      
      This patch introduces such a firmware on our e500 platforms. U-boot is the
      default firmware for most of these systems and as such our preferred choice.
      
      For backwards compatibility reasons (and speed and simplicity) we skip u-boot
      when you use -kernel and don't pass in -bios. For all other combinations like
      -kernel and -bios or no -kernel you get u-boot as firmware.
      
      This allows you to modify the boot environment, execute a networked boot through
      the e1000 emulation and execute u-boot payloads.
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      3812c71f
    • A
      PPC: e500: Expose kernel load address in dt · 903585de
      Alexander Graf 提交于
      We want to move to a model where firmware loads our kernel. To achieve
      this we need to be able to tell firmware where the kernel lies.
      
      Let's copy the mechanism we already use for -M pseries and expose the
      kernel load address and size through the device tree.
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      903585de
    • B
      PPC: e500: implement PCI INTx routing · 3016dca0
      Bharat Bhushan 提交于
      This patch adds pci pin to irq_num routing callback.
      This callback is called from pci_device_route_intx_to_irq to
      find which pci device maps to which irq.
      This fix is required for pci-device passthrough using vfio.
      
      Also without this patch we gets below prints
      
      "
        PCI: Bug - unimplemented PCI INTx routing (e500-pcihost)
        qemu-system-ppc64: PCI: Bug - unimplemented PCI INTx routing (e500-pcihost) "
      
      and Legacy interrupt does not work with pci device passthrough.
      Signed-off-by: NBharat Bhushan <Bharat.Bhushan@freescale.com>
      Acked-by: NMichael S. Tsirkin <mst@redhat.com>
      [agraf: remove double semicolon]
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      3016dca0
    • B
      PPC: e500: some pci related cleanup · d575a6ce
      Bharat Bhushan 提交于
      - Use PCI_NUM_PINS rather than hardcoding
       - use "pin" wherever possible
      Signed-off-by: NBharat Bhushan <Bharat.Bhushan@freescale.com>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      d575a6ce
  14. 28 5月, 2014 1 次提交
  15. 08 4月, 2014 1 次提交
  16. 14 3月, 2014 1 次提交
  17. 05 3月, 2014 1 次提交
  18. 20 12月, 2013 1 次提交
  19. 03 9月, 2013 1 次提交
  20. 02 9月, 2013 1 次提交
    • A
      PPC: E500: Generate device tree on reset · 28290f37
      Alexander Graf 提交于
      Today we generate the device tree once on machine initialization and then
      store the finalized blob in memory to reload it on reset.
      
      This is bad for 2 reasons. First we potentially waste a bunch of RAM for no
      good reason, as we have all information required to regenerate the device
      tree available anyways.
      
      The second reason is even more important. On machine init when we generate
      the device tree for the first time, we don't have all of the devices fully
      initialized yet. But the device tree needs to potentially walk devices to
      put information about them into the device tree.
      
      Move the generation into a reset function. That way we just generate it new
      every time we reset, solving both of the above issues.
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      28290f37
  21. 22 8月, 2013 1 次提交
  22. 10 7月, 2013 3 次提交
    • A
      cpu: Make first_cpu and next_cpu CPUState · 182735ef
      Andreas Färber 提交于
      Move next_cpu from CPU_COMMON to CPUState.
      Move first_cpu variable to qom/cpu.h.
      
      gdbstub needs to use CPUState::env_ptr for now.
      cpu_copy() no longer needs to save and restore cpu_next.
      Acked-by: NPaolo Bonzini <pbonzini@redhat.com>
      [AF: Rebased, simplified cpu_copy()]
      Signed-off-by: NAndreas Färber <afaerber@suse.de>
      182735ef
    • M
      Simplify -machine option queries with qemu_get_machine_opts() · 2ff3de68
      Markus Armbruster 提交于
      The previous two commits fixed bugs in -machine option queries.  I
      can't find fault with the remaining queries, but let's use
      qemu_get_machine_opts() everywhere, for consistency, simplicity and
      robustness.
      Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
      Message-id: 1372943363-24081-7-git-send-email-armbru@redhat.com
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      2ff3de68
    • M
      Fix -machine options accel, kernel_irqchip, kvm_shadow_mem · 36ad0e94
      Markus Armbruster 提交于
      Multiple -machine options with the same ID are merged.  All but the
      one without an ID are to be silently ignored.
      
      In most places, we query these options with a null ID.  This is
      correct.
      
      In some places, we instead query whatever options come first in the
      list.  This is wrong.  When the -machine processed first happens to
      have an ID, options are taken from that ID, and the ones specified
      without ID are silently ignored.
      
      Example:
      
          $ upstream-qemu -nodefaults -S -display none -monitor stdio -machine id=foo -machine accel=kvm,usb=on
          $ upstream-qemu -nodefaults -S -display none -monitor stdio -machine id=foo,accel=kvm,usb=on -machine accel=xen
          $ upstream-qemu -nodefaults -S -display none -monitor stdio -machine accel=xen -machine id=foo,accel=kvm,usb=on
      
          $ qemu-system-x86_64 -nodefaults -S -display none -monitor stdio -machine accel=kvm,usb=on
          QEMU 1.5.50 monitor - type 'help' for more information
          (qemu) info kvm
          kvm support: enabled
          (qemu) info usb
          (qemu) q
          $ qemu-system-x86_64 -nodefaults -S -display none -monitor stdio -machine id=foo -machine accel=kvm,usb=on
          QEMU 1.5.50 monitor - type 'help' for more information
          (qemu) info kvm
          kvm support: disabled
          (qemu) info usb
          (qemu) q
          $ qemu-system-x86_64 -nodefaults -S -display none -monitor stdio -machine id=foo,accel=kvm,usb=on -machine accel=xen
          QEMU 1.5.50 monitor - type 'help' for more information
          (qemu) info kvm
          kvm support: enabled
          (qemu) info usb
          USB support not enabled
          (qemu) q
          $ qemu-system-x86_64 -nodefaults -S -display none -monitor stdio -machine accel=xen -machine id=foo,accel=kvm,usb=on
          xc: error: Could not obtain handle on privileged command interface (2 = No such file or directory): Internal error
          xen be core: can't open xen interface
          failed to initialize Xen: Operation not permitted
      
      Option usb is queried correctly, and the one without an ID wins,
      regardless of option order.
      
      Option accel is queried incorrectly, and which one wins depends on
      option order and ID.
      
      Affected options are accel (and its sugared forms -enable-kvm and
      -no-kvm), kernel_irqchip, kvm_shadow_mem.
      
      Additionally, option kernel_irqchip is normally on by default, except
      it's off when no -machine options are given.  Bug can't bite, because
      kernel_irqchip is used only when KVM is enabled, KVM is off by
      default, and enabling always creates -machine options.  Downstreams
      that enable KVM by default do get bitten, though.
      
      Use qemu_get_machine_opts() to fix these bugs.
      Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
      Message-id: 1372943363-24081-5-git-send-email-armbru@redhat.com
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      36ad0e94
  23. 08 7月, 2013 1 次提交
    • D
      pci: Add root bus parameter to pci_nic_init() · 29b358f9
      David Gibson 提交于
      At present, pci_nic_init() and pci_nic_init_nofail() assume that they will
      only create a NIC under the primary PCI root.  As we add support for
      multiple PCI roots, that may no longer be the case.  This patch adds a root
      bus parameter to pci_nic_init() (and updates callers accordingly) to allow
      the machine init code using it to specify the right PCI root for NICs
      created by old-style -net nic parameters.  NICs created new-style, with
      -device can of course be put anywhere.
      Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au>
      Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
      29b358f9
  24. 04 7月, 2013 2 次提交
  25. 01 7月, 2013 4 次提交
  26. 06 5月, 2013 1 次提交