mirror of
https://github.com/opnsense/src.git
synced 2026-04-21 14:17:06 -04:00
nit: xpt_bus_deregister has to be called with the sim lock held.
MFC after: 1 month
This commit is contained in:
parent
1eadf156c2
commit
f0b41ca4fc
1 changed files with 4 additions and 0 deletions
|
|
@ -1208,14 +1208,18 @@ mpt_cam_detach(struct mpt_softc *mpt)
|
|||
|
||||
if (mpt->sim != NULL) {
|
||||
xpt_free_path(mpt->path);
|
||||
MPT_LOCK(mpt);
|
||||
xpt_bus_deregister(cam_sim_path(mpt->sim));
|
||||
MPT_UNLOCK(mpt);
|
||||
cam_sim_free(mpt->sim, TRUE);
|
||||
mpt->sim = NULL;
|
||||
}
|
||||
|
||||
if (mpt->phydisk_sim != NULL) {
|
||||
xpt_free_path(mpt->phydisk_path);
|
||||
MPT_LOCK(mpt);
|
||||
xpt_bus_deregister(cam_sim_path(mpt->phydisk_sim));
|
||||
MPT_UNLOCK(mpt);
|
||||
cam_sim_free(mpt->phydisk_sim, TRUE);
|
||||
mpt->phydisk_sim = NULL;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue