spapr: Refactor spapr_drc_detach()
This function has two unused parameters - remove them. It also sets awaiting_release on all paths, except one. On that path setting it is harmless, since it will be immediately cleared by spapr_drc_release(). So factor it out of the if statements. Signed-off-by: David Gibson <david@gibson.dropbear.id.au> Reviewed-by: Greg Kurz <groug@kaod.org> Tested-by: Daniel Barboza <danielhb@linux.vnet.ibm.com>
This commit is contained in:
parent
ba50822ff8
commit
a8dc47fd82
4 changed files with 11 additions and 21 deletions
|
|
@ -242,6 +242,6 @@ int spapr_drc_populate_dt(void *fdt, int fdt_offset, Object *owner,
|
|||
|
||||
void spapr_drc_attach(sPAPRDRConnector *drc, DeviceState *d, void *fdt,
|
||||
int fdt_start_offset, Error **errp);
|
||||
void spapr_drc_detach(sPAPRDRConnector *drc, DeviceState *d, Error **errp);
|
||||
void spapr_drc_detach(sPAPRDRConnector *drc);
|
||||
|
||||
#endif /* HW_SPAPR_DRC_H */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue