spapr/xive: skip partially initialized vCPUs in presenter
commit627fa61746f70f7c799f08e9048bb6a482402138
authorCédric Le Goater <clg@kaod.org>
Tue, 1 Oct 2019 08:57:22 +0000 (1 10:57 +0200)
committerDavid Gibson <david@gibson.dropbear.id.au>
Fri, 4 Oct 2019 09:08:21 +0000 (4 19:08 +1000)
treeb7e8d31fafe4b06e40d406d5a2efd3f4c7b85563
parent428115c3a9d0f64e1b9189986dbba4be0548c4a5
spapr/xive: skip partially initialized vCPUs in presenter

When vCPUs are hotplugged, they are added to the QEMU CPU list before
being fully realized. This can crash the XIVE presenter because the
'tctx' pointer is not necessarily initialized when looking for a
matching target.

These vCPUs are not valid targets for the presenter. Skip them.

Signed-off-by: Cédric Le Goater <clg@kaod.org>
Message-Id: <20191001085722.32755-1-clg@kaod.org>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Reviewed-by: Greg Kurz <groug@kaod.org>
hw/intc/xive.c