[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-ppc] [PATCH v2 15/17] ppc/pnv: Grab the XiveRouter object from Xiv
From: |
Cédric Le Goater |
Subject: |
[Qemu-ppc] [PATCH v2 15/17] ppc/pnv: Grab the XiveRouter object from XiveTCTX in pnv_xive_get_tctx() |
Date: |
Thu, 18 Jul 2019 13:54:18 +0200 |
It removes a useless call to pnv_xive_get_ic() which is making some
assumption on the chip_id format.
Signed-off-by: Cédric Le Goater <address@hidden>
---
hw/intc/pnv_xive.c | 11 +----------
1 file changed, 1 insertion(+), 10 deletions(-)
diff --git a/hw/intc/pnv_xive.c b/hw/intc/pnv_xive.c
index a48f6750154e..403e8c8ca5b4 100644
--- a/hw/intc/pnv_xive.c
+++ b/hw/intc/pnv_xive.c
@@ -370,22 +370,13 @@ static XiveTCTX *pnv_xive_get_tctx(XiveRouter *xrtr,
CPUState *cs)
{
PowerPCCPU *cpu = POWERPC_CPU(cs);
XiveTCTX *tctx = XIVE_TCTX(pnv_cpu_state(cpu)->intc);
- PnvXive *xive = NULL;
+ PnvXive *xive = PNV_XIVE(tctx->xrtr);
CPUPPCState *env = &cpu->env;
int pir = env->spr_cb[SPR_PIR].default_value;
/*
* Perform an extra check on the HW thread enablement.
- *
- * The TIMA is shared among the chips and to identify the chip
- * from which the access is being done, we extract the chip id
- * from the PIR.
*/
- xive = pnv_xive_get_ic((pir >> 8) & 0xf);
- if (!xive) {
- return NULL;
- }
-
if (!(xive->regs[PC_THREAD_EN_REG0 >> 3] & PPC_BIT(pir & 0x3f))) {
xive_error(PNV_XIVE(xrtr), "IC: CPU %x is not enabled", pir);
}
--
2.21.0
- [Qemu-ppc] [PATCH v2 08/17] ppc/xive: Improve 'info pic' support, (continued)
[Qemu-ppc] [PATCH v2 10/17] ppc/xive: Introduce xive_tctx_ipb_update(), Cédric Le Goater, 2019/07/18
[Qemu-ppc] [PATCH v2 11/17] ppc/xive: Synthesize interrupt from the saved IPB in the NVT, Cédric Le Goater, 2019/07/18
[Qemu-ppc] [PATCH v2 12/17] ppc/pnv: Remove pnv_xive_vst_size() routine, Cédric Le Goater, 2019/07/18
[Qemu-ppc] [PATCH v2 13/17] ppc/pnv: Dump the XIVE NVT table, Cédric Le Goater, 2019/07/18
[Qemu-ppc] [PATCH v2 15/17] ppc/pnv: Grab the XiveRouter object from XiveTCTX in pnv_xive_get_tctx(),
Cédric Le Goater <=
[Qemu-ppc] [PATCH v2 16/17] ppc/pnv: Introduce a pnv_xive_get_block_id() interface to XiveRouter, Cédric Le Goater, 2019/07/18
[Qemu-ppc] [PATCH v2 14/17] ppc/pnv: Skip empty slots of the XIVE NVT table, Cédric Le Goater, 2019/07/18
[Qemu-ppc] [PATCH v2 17/17] ppc/pnv: quiesce some XIVE errors, Cédric Le Goater, 2019/07/18
Re: [Qemu-ppc] [Qemu-devel] [PATCH v2 00/17] ppc/pnv: add XIVE support for KVM guests, no-reply, 2019/07/18
Re: [Qemu-ppc] [PATCH v2 00/17] ppc/pnv: add XIVE support for KVM guests, David Gibson, 2019/07/22