[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-ppc] [PATCH 08/10] ppc/xics: allow ICSState to have an offset 0
From: |
Cédric Le Goater |
Subject: |
[Qemu-ppc] [PATCH 08/10] ppc/xics: allow ICSState to have an offset 0 |
Date: |
Wed, 2 Jan 2019 06:57:41 +0100 |
commit 15ed653fa49a ("ppc/xics: An ICS with offset 0 is assumed to be
uninitialized") introduced an extra check on the ICS offset which is
not strictly necessary.
Revert the change to be able to map the XICS IRQ number space on the
XIVE IRQ number space.
Signed-off-by: Cédric Le Goater <address@hidden>
---
include/hw/ppc/xics.h | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/include/hw/ppc/xics.h b/include/hw/ppc/xics.h
index 7668c381a887..07508cbd217e 100644
--- a/include/hw/ppc/xics.h
+++ b/include/hw/ppc/xics.h
@@ -139,8 +139,7 @@ struct ICSState {
static inline bool ics_valid_irq(ICSState *ics, uint32_t nr)
{
- return (ics->offset != 0) && (nr >= ics->offset)
- && (nr < (ics->offset + ics->nr_irqs));
+ return (nr >= ics->offset) && (nr < (ics->offset + ics->nr_irqs));
}
struct ICSIRQState {
--
2.20.1
- [Qemu-ppc] [PATCH 02/10] ppc/xive: introduce a XiveTCTX pointer under PowerPCCPU, (continued)
- [Qemu-ppc] [PATCH 03/10] ppc: replace the 'Object *intc' by a 'ICPState *icp' pointer under the CPU, Cédric Le Goater, 2019/01/02
- [Qemu-ppc] [PATCH 04/10] spapr/xive: simplify the sPAPR IRQ qirq method for XIVE, Cédric Le Goater, 2019/01/02
- [Qemu-ppc] [PATCH 05/10] ppc: export the XICS and XIVE set_irq handlers, Cédric Le Goater, 2019/01/02
- [Qemu-ppc] [PATCH 06/10] pnv/psi: move the ICSState qemu_irq array under the PSI device model, Cédric Le Goater, 2019/01/02
- [Qemu-ppc] [PATCH 07/10] spapr: move the qemu_irq array under the machine, Cédric Le Goater, 2019/01/02
- [Qemu-ppc] [PATCH 08/10] ppc/xics: allow ICSState to have an offset 0,
Cédric Le Goater <=
[Qemu-ppc] [PATCH 09/10] spapr: introduce a new sPAPR IRQ backend supporting XIVE and XICS, Cédric Le Goater, 2019/01/02
[Qemu-ppc] [PATCH 10/10] spapr: enable XIVE MMIOs at reset, Cédric Le Goater, 2019/01/02
Re: [Qemu-ppc] [PATCH 00/10] spapr: introduce the 'dual' interrupt mode XICS/XIVE, David Gibson, 2019/01/07