93c9aea9 | 29-Sep-2014 |
Peter Maydell <peter.maydell@linaro.org> |
hw/intc/imx_avic.c: Remove unused function imx_avic_set_prio()
The function imx_avic_set_prio() is unused; delete it.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Message-id: 1410723223-
hw/intc/imx_avic.c: Remove unused function imx_avic_set_prio()
The function imx_avic_set_prio() is unused; delete it.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Message-id: 1410723223-17711-3-git-send-email-peter.maydell@linaro.org
show more ...
|
c5539cb4 | 24-Aug-2014 |
Gonglei <arei.gonglei@huawei.com> |
Fix debug print warning
Steps:
1.enable qemu debug print, using simply scprit as below: grep "//#define DEBUG" * -rl | xargs sed -i "s/\/\/#define DEBUG/#define DEBUG/g" 2. make -j 3. get some war
Fix debug print warning
Steps:
1.enable qemu debug print, using simply scprit as below: grep "//#define DEBUG" * -rl | xargs sed -i "s/\/\/#define DEBUG/#define DEBUG/g" 2. make -j 3. get some warning: hw/i2c/pm_smbus.c: In function 'smb_ioport_writeb': hw/i2c/pm_smbus.c:142: warning: format '%04x' expects type 'unsigned int', but argument 2 has type 'hwaddr' hw/i2c/pm_smbus.c:142: warning: format '%02x' expects type 'unsigned int', but argument 3 has type 'uint64_t' hw/i2c/pm_smbus.c: In function 'smb_ioport_readb': hw/i2c/pm_smbus.c:209: warning: format '%04x' expects type 'unsigned int', but argument 2 has type 'hwaddr' hw/intc/i8259.c: In function 'pic_ioport_read': hw/intc/i8259.c:373: warning: format '%02x' expects type 'unsigned int', but argument 2 has type 'hwaddr' hw/input/pckbd.c: In function 'kbd_write_command': hw/input/pckbd.c:232: warning: format '%02x' expects type 'unsigned int', but argument 2 has type 'uint64_t' hw/input/pckbd.c: In function 'kbd_write_data': hw/input/pckbd.c:333: warning: format '%02x' expects type 'unsigned int', but argument 2 has type 'uint64_t' hw/isa/apm.c: In function 'apm_ioport_writeb': hw/isa/apm.c:44: warning: format '%x' expects type 'unsigned int', but argument 2 has type 'hwaddr' hw/isa/apm.c:44: warning: format '%02x' expects type 'unsigned int', but argument 3 has type 'uint64_t' hw/isa/apm.c: In function 'apm_ioport_readb': hw/isa/apm.c:67: warning: format '%x' expects type 'unsigned int', but argument 2 has type 'hwaddr' hw/timer/mc146818rtc.c: In function 'cmos_ioport_write': hw/timer/mc146818rtc.c:394: warning: format '%02x' expects type 'unsigned int', but argument 3 has type 'uint64_t' hw/i386/pc.c: In function 'port92_write': hw/i386/pc.c:479: warning: format '%02x' expects type 'unsigned int', but argument 2 has type 'uint64_t'
Fix them.
Cc: qemu-trivial@nongnu.org Signed-off-by: Gonglei <arei.gonglei@huawei.com> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
show more ...
|
b52b81e4 | 29-Aug-2014 |
Sergey Fedorov <serge.fdrv@gmail.com> |
hw/intc/arm_gic: honor target mask in gic_update()
Take IRQ target mask into account when determining the highest priority pending interrupt.
Signed-off-by: Sergey Fedorov <serge.fdrv@gmail.com> Ac
hw/intc/arm_gic: honor target mask in gic_update()
Take IRQ target mask into account when determining the highest priority pending interrupt.
Signed-off-by: Sergey Fedorov <serge.fdrv@gmail.com> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Message-id: 1407947471-26981-1-git-send-email-serge.fdrv@gmail.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
show more ...
|
93b5f6f1 | 29-Aug-2014 |
Adam Lackorzynski <adam@os.inf.tu-dresden.de> |
arm_gic: Use GIC_NR_SGIS constant
Use constant rather than a plain number.
Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Adam Lackorzynski <adam@os.inf.tu-dresden.de> Mess
arm_gic: Use GIC_NR_SGIS constant
Use constant rather than a plain number.
Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Adam Lackorzynski <adam@os.inf.tu-dresden.de> Message-id: 1408372255-12358-5-git-send-email-adam@os.inf.tu-dresden.de Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
show more ...
|
de7a900f | 29-Aug-2014 |
Adam Lackorzynski <adam@os.inf.tu-dresden.de> |
arm_gic: Do not force PPIs to edge-triggered mode
Only SGIs must be WI, done by forcing them to their default (edge-triggered).
Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-b
arm_gic: Do not force PPIs to edge-triggered mode
Only SGIs must be WI, done by forcing them to their default (edge-triggered).
Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Adam Lackorzynski <adam@os.inf.tu-dresden.de> Message-id: 1408372255-12358-4-git-send-email-adam@os.inf.tu-dresden.de Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
show more ...
|
24b790df | 29-Aug-2014 |
Adam Lackorzynski <adam@os.inf.tu-dresden.de> |
arm_gic: GICD_ICFGR: Write model only for pre v1 GICs
Setting the model is only available in pre-v1 GIC models.
Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Adam Lackorzy
arm_gic: GICD_ICFGR: Write model only for pre v1 GICs
Setting the model is only available in pre-v1 GIC models.
Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Adam Lackorzynski <adam@os.inf.tu-dresden.de> Message-id: 1408372255-12358-3-git-send-email-adam@os.inf.tu-dresden.de Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
show more ...
|
71a62046 | 29-Aug-2014 |
Adam Lackorzynski <adam@os.inf.tu-dresden.de> |
arm_gic: Fix read of GICD_ICFGR
The GICD_ICFGR register covers 4 interrupts per byte.
Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Adam Lackorzynski <adam@os.inf.tu-dresd
arm_gic: Fix read of GICD_ICFGR
The GICD_ICFGR register covers 4 interrupts per byte.
Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Signed-off-by: Adam Lackorzynski <adam@os.inf.tu-dresden.de> Message-id: 1408372255-12358-2-git-send-email-adam@os.inf.tu-dresden.de Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
show more ...
|
8945c7f7 | 15-Aug-2014 |
Peter Crosthwaite <peter.crosthwaite@xilinx.com> |
intc: i8259: Convert Array allocation to g_new0
To be more array friendly and to indicate the IRQs are initially disconnected.
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Signed
intc: i8259: Convert Array allocation to g_new0
To be more array friendly and to indicate the IRQs are initially disconnected.
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
show more ...
|
aa2ac1da | 15-Aug-2014 |
Peter Crosthwaite <peter.crosthwaite@xilinx.com> |
ppc: convert g_new(qemu_irq usages to g_new0
To indicate the IRQs are initially disconnected.
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Signed-off-by: Michael Tokarev <mjt@tls
ppc: convert g_new(qemu_irq usages to g_new0
To indicate the IRQs are initially disconnected.
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
show more ...
|
d6c140a7 | 09-Aug-2014 |
Jan Kiszka <jan.kiszka@siemens.com> |
apic: Fix reported DFR content
IA-32 SDM, Figure 10-14: Bits 27:0 are reserved as 1.
Fixes Jailhouse hypervisor start with in-kernel irqchips off.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com
apic: Fix reported DFR content
IA-32 SDM, Figure 10-14: Bits 27:0 are reserved as 1.
Fixes Jailhouse hypervisor start with in-kernel irqchips off.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
show more ...
|
51bba713 | 30-May-2014 |
Alexey Kardashevskiy <aik@ozlabs.ru> |
xics: Implement xics_ics_free()
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: Alexey Kardashevskiy <aik
xics: Implement xics_ics_free()
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: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
bee763db | 30-May-2014 |
Alexey Kardashevskiy <aik@ozlabs.ru> |
spapr: Move interrupt allocator to xics
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
spapr: Move interrupt allocator to xics
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: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
a7e519a8 | 30-May-2014 |
Alexey Kardashevskiy <aik@ozlabs.ru> |
xics: Disable flags reset on xics reset
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: Alexey Kardashe
xics: Disable flags reset on xics reset
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: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
641c3493 | 30-May-2014 |
Alexey Kardashevskiy <aik@ozlabs.ru> |
xics: Add xics_find_source()
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 sour
xics: Add xics_find_source()
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: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
4af88944 | 30-May-2014 |
Alexey Kardashevskiy <aik@ozlabs.ru> |
xics: Add flags for interrupts
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 a
xics: Add flags for interrupts
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: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
3a3b8502 | 23-Jun-2014 |
Alexey Kardashevskiy <aik@ozlabs.ru> |
spapr: Fix RTAS token numbers
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 handler
spapr: Fix RTAS token numbers
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: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
b6fb3a89 | 19-Jun-2014 |
Oran Avraham <oranav@gmail.com> |
armv7m_nvic: fix AIRCR implementation
The returned reset value was wrong (off by one zero nibble), and qemu didn't log unimplemented writes to the PRIGROUP field.
Signed-off-by: Oran Avraham <orana
armv7m_nvic: fix AIRCR implementation
The returned reset value was wrong (off by one zero nibble), and qemu didn't log unimplemented writes to the PRIGROUP field.
Signed-off-by: Oran Avraham <oranav@gmail.com> Message-id: 1403010447-4627-1-git-send-email-oranav@gmail.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
show more ...
|
af354f19 | 22-May-2014 |
Alexander Graf <agraf@suse.de> |
PPC: openpic_kvm: Implement reset
When we trigger a system reset, the in-kernel openpic controller should also get reset. This happens through a write to the GCR.RESET register which is the same mec
PPC: openpic_kvm: Implement reset
When we trigger a system reset, the in-kernel openpic controller should also get reset. This happens through a write to the GCR.RESET register which is the same mechanism a guest would use to manually reset the device.
Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
ffd5e9fe | 22-May-2014 |
Paul Janzen <pcj@pauljanzen.org> |
openpic: Reset IRQ source private members
The openpic emulation code maintains an allowable-CPU's bitmap ("destmask") for each IRQ source which is calculated from the IDR register value whenever the
openpic: Reset IRQ source private members
The openpic emulation code maintains an allowable-CPU's bitmap ("destmask") for each IRQ source which is calculated from the IDR register value whenever the guest OS writes to it. However, if the guest OS relies on the system to set the IDR register to a default value at reset, and does not write IDR, then destmask does not get updated, and interrupts do not get propagated to the guest. Additionally, if an IRQ source is marked as critical, the source's internal "output" and "nomask" fields are not correctly reset when the PIC is reset.
Fix both these issues by calling write_IRQreg_idr from within openpic_reset, instead of simply setting the IDR register to the specified idr_reset value.
Signed-off-by: Paul Janzen <pcj@pauljanzen.org> Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
8ebe65f3 | 21-May-2014 |
Paul Janzen <pcj@pauljanzen.org> |
openpic: Move definition of openpic_reset
This patch moves the definition of openpic_reset after the various register read/write functions. No functional change. It is in preparation for using the
openpic: Move definition of openpic_reset
This patch moves the definition of openpic_reset after the various register read/write functions. No functional change. It is in preparation for using the register read/write functions in openpic_reset.
Signed-off-by: Paul Janzen <pcj@pauljanzen.org> Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
d49805ae | 16-Apr-2014 |
Juan Quintela <quintela@redhat.com> |
savevm: Remove all the unneeded version_minimum_id_old (x86)
After previous Peter patch, they are redundant. This way we don't assign them except when needed. Once there, there were lots of case w
savevm: Remove all the unneeded version_minimum_id_old (x86)
After previous Peter patch, they are redundant. This way we don't assign them except when needed. Once there, there were lots of case where the ".fields" indentation was wrong:
.fields = (VMStateField []) { and .fields = (VMStateField []) {
Change all the combinations to:
.fields = (VMStateField[]){
The biggest problem (appart from aesthetics) was that checkpatch complained when we copy&pasted the code from one place to another.
Signed-off-by: Juan Quintela <quintela@redhat.com> Acked-by: Alexey Kardashevskiy <aik@ozlabs.ru> Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
show more ...
|
3aff6c2f | 16-Apr-2014 |
Juan Quintela <quintela@redhat.com> |
savevm: Remove all the unneeded version_minimum_id_old (ppc)
After previous Peter patch, they are redundant. This way we don't assign them except when needed. Once there, there were lots of case w
savevm: Remove all the unneeded version_minimum_id_old (ppc)
After previous Peter patch, they are redundant. This way we don't assign them except when needed. Once there, there were lots of case where the ".fields" indentation was wrong:
.fields = (VMStateField []) { and .fields = (VMStateField []) {
Change all the combinations to:
.fields = (VMStateField[]){
The biggest problem (appart from aesthetics) was that checkpatch complained when we copy&pasted the code from one place to another.
Signed-off-by: Juan Quintela <quintela@redhat.com> Acked-by: Alexey Kardashevskiy <aik@ozlabs.ru>
show more ...
|
c1d75727 | 07-Jun-2014 |
Peter Maydell <peter.maydell@linaro.org> |
hw/intc/openpic: Remove unused function IRQ_testbit()
The IRQ_testbit() function is never used; remove it.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Michael Tokarev <mj
hw/intc/openpic: Remove unused function IRQ_testbit()
The IRQ_testbit() function is never used; remove it.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
show more ...
|
bbd8bb8e | 12-Mar-2014 |
Cornelia Huck <cornelia.huck@de.ibm.com> |
s390x/kvm: inject via flic
Try to inject floating interrupts via the flic if it is available. This allows us to inject the full range of floating interrupts.
Reviewed-by: Jens Freimann <jfrei@linux
s390x/kvm: inject via flic
Try to inject floating interrupts via the flic if it is available. This allows us to inject the full range of floating interrupts.
Reviewed-by: Jens Freimann <jfrei@linux.vnet.ibm.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
show more ...
|
08da527f | 28-May-2014 |
Cornelia Huck <cornelia.huck@de.ibm.com> |
s390x/kvm: make flic play well with old kernels
If we run with an old kernel that does not support KVM_CAP_IRQ_ROUTING, we don't have to do anything in the ->register_io_adapter and ->io_adapter_map
s390x/kvm: make flic play well with old kernels
If we run with an old kernel that does not support KVM_CAP_IRQ_ROUTING, we don't have to do anything in the ->register_io_adapter and ->io_adapter_map callbacks and therefore should return 0 instead of -ENOSYS (just as the non-kvm flic does).
This fixes using adapter interrupts when running under an older kernel, which broke with "s390x: add I/O adapter registration".
Reported-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
show more ...
|