1. 15 8月, 2014 1 次提交
  2. 27 6月, 2014 6 次提交
    • A
      xics: Implement xics_ics_free() · 51bba713
      Alexey Kardashevskiy 提交于
      This implements interrupt release function so IRQs can be returned back
      to the pool for reuse in cases such as PCI hot plug.
      Signed-off-by: NAlexey Kardashevskiy <aik@ozlabs.ru>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      51bba713
    • A
      spapr: Move interrupt allocator to xics · bee763db
      Alexey Kardashevskiy 提交于
      The current allocator returns IRQ numbers from a pool and does not
      support IRQs reuse in any form as it did not keep track of what it
      previously returned, it only keeps the last returned IRQ. Some use
      cases such as PCI hot(un)plug may require IRQ release and reallocation.
      
      This moves an allocator from SPAPR to XICS.
      
      This switches IRQ users to use new API.
      
      This uses LSI/MSI flags to know if interrupt is allocated.
      
      The interrupt release function will be posted as a separate patch.
      Signed-off-by: NAlexey Kardashevskiy <aik@ozlabs.ru>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      bee763db
    • A
      xics: Disable flags reset on xics reset · a7e519a8
      Alexey Kardashevskiy 提交于
      Since islsi[] array has been merged into the ICSState struct,
      we must not reset flags as they tell if the interrupt is in use.
      Signed-off-by: NAlexey Kardashevskiy <aik@ozlabs.ru>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      a7e519a8
    • A
      xics: Add xics_find_source() · 641c3493
      Alexey Kardashevskiy 提交于
      PAPR allows having multiple interrupt sources such as PHB.
      
      This adds a source lookup function and makes use of it.
      
      Since at the moment QEMU only supports a single source,
      no change in behaviour is expected.
      Signed-off-by: NAlexey Kardashevskiy <aik@ozlabs.ru>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      641c3493
    • A
      xics: Add flags for interrupts · 4af88944
      Alexey Kardashevskiy 提交于
      The existing interrupt allocation scheme in SPAPR assumes that
      interrupts are allocated at the start time, continously and the config
      will not change. However, there are cases when this is not going to work
      such as:
      
      1. migration - we will have to have an ability to choose interrupt
      numbers for devices in the command line and this will create gaps in
      interrupt space.
      
      2. PCI hotplug - interrupts from unplugged device need to be returned
      back to interrupt pool, otherwise we will quickly run out of interrupts.
      
      This replaces a separate lslsi[] array with a byte in the ICSIRQState
      struct and defines "LSI" and "MSI" flags. Neither of these flags set
      signals that the descriptor is not allocated and not in use.
      Signed-off-by: NAlexey Kardashevskiy <aik@ozlabs.ru>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      4af88944
    • A
      spapr: Fix RTAS token numbers · 3a3b8502
      Alexey Kardashevskiy 提交于
      At the moment spapr_rtas_register() allocates a new token number for every
      new RTAS callback so numbers are not fixed and depend on the number of
      supported RTAS handlers and the exact order of spapr_rtas_register() calls.
      These tokens are copied into the device tree and remain the same during
      the guest lifetime.
      
      When we start another guest to receive a migration, it calls
      spapr_rtas_register() as well. If the number of RTAS handlers or their
      order is different in QEMU on source and destination sides, the "/rtas"
      node in the device tree will differ. Since migration overwrites the device
      tree (as it overwrites the entire RAM), the actual RTAS config on
      the destination side gets broken.
      
      This defines global contant values for every RTAS token which QEMU
      is using today.
      
      This changes spapr_rtas_register() to accept a token number instead of
      allocating one. This changes all users of spapr_rtas_register().
      
      This changes XICS-KVM not to cache tokens registered with KVM as they
      constant now.
      
      This makes TOKEN_BASE global as RTAS_XXX use TOKEN_BASE as
      a base. TOKEN_MAX is moved and renamed too and its value is changed
      to the last token + 1. Boundary checks for token values are adjusted.
      
      This reserves token numbers for "os-term" handlers and PCI hotplug
      which we are working on.
      Signed-off-by: NAlexey Kardashevskiy <aik@ozlabs.ru>
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      3a3b8502
  3. 20 6月, 2014 1 次提交
  4. 16 6月, 2014 5 次提交
  5. 10 6月, 2014 3 次提交
  6. 09 6月, 2014 1 次提交
  7. 20 5月, 2014 3 次提交
  8. 14 5月, 2014 1 次提交
  9. 13 5月, 2014 4 次提交
  10. 07 5月, 2014 2 次提交
  11. 06 5月, 2014 3 次提交
  12. 01 5月, 2014 1 次提交
  13. 30 4月, 2014 1 次提交
  14. 27 4月, 2014 1 次提交
  15. 18 4月, 2014 2 次提交
  16. 03 4月, 2014 1 次提交
  17. 02 4月, 2014 1 次提交
  18. 27 3月, 2014 3 次提交