aboutsummaryrefslogtreecommitdiff
path: root/include/hw/ppc/spapr_drc.h
diff options
context:
space:
mode:
authorDavid Gibson <david@gibson.dropbear.id.au>2017-06-08 00:58:32 +1000
committerDavid Gibson <david@gibson.dropbear.id.au>2017-06-30 14:03:32 +1000
commit0dfabd39d523fc3f6f0f8c441f41c013cc429b52 (patch)
treeac88202439e0536371e015f72bd01a1692dde701 /include/hw/ppc/spapr_drc.h
parent617367321ed6c66118fa981cf61c897f679ab021 (diff)
spapr: Clean up DRC set_isolation_state() path
There are substantial differences in the various paths through set_isolation_state(), both for setting to ISOLATED versus UNISOLATED state and for logical versus physical DRCs. So, split the set_isolation_state() method into isolate() and unisolate() methods, and give it different implementations for the two DRC types. Factor some minimal common checks, including for valid indicator values (which we weren't previously checking) into rtas_set_isolation_state(). Signed-off-by: David Gibson <david@gibson.dropbear.id.au> Reviewed-by: Greg Kurz <groug@kaod.org> Reviewed-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Diffstat (limited to 'include/hw/ppc/spapr_drc.h')
-rw-r--r--include/hw/ppc/spapr_drc.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/include/hw/ppc/spapr_drc.h b/include/hw/ppc/spapr_drc.h
index 1674b668c8..d9cacb368f 100644
--- a/include/hw/ppc/spapr_drc.h
+++ b/include/hw/ppc/spapr_drc.h
@@ -215,10 +215,8 @@ typedef struct sPAPRDRConnectorClass {
const char *drc_name_prefix; /* used other places in device tree */
sPAPRDREntitySense (*dr_entity_sense)(sPAPRDRConnector *drc);
-
- /* accessors for guest-visible (generally via RTAS) DR state */
- uint32_t (*set_isolation_state)(sPAPRDRConnector *drc,
- sPAPRDRIsolationState state);
+ uint32_t (*isolate)(sPAPRDRConnector *drc);
+ uint32_t (*unisolate)(sPAPRDRConnector *drc);
/* QEMU interfaces for managing hotplug operations */
bool (*release_pending)(sPAPRDRConnector *drc);