Skip to content

Commit

Permalink
Try #1553:
Browse files Browse the repository at this point in the history
  • Loading branch information
mayastor-bors committed Nov 29, 2023
2 parents e9bbfcb + 670fd33 commit 655a324
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions io-engine/src/bdev/nexus/nexus_bdev_children.rs
Original file line number Diff line number Diff line change
Expand Up @@ -899,6 +899,15 @@ impl<'n> Nexus<'n> {
nexus_name,
child_device, "Unplugging nexus child device",
);
// The child could be open in case of spdk bdev child. Close
// the child here so that the unplug
// correctly identifies the child device
// as destroying. In case of a child fault, we'd reach here
// via retiral path and child must be
// closed already.
if child.is_opened() {
child.close().await.ok();
}
child.unplug();
}
None => {
Expand Down

0 comments on commit 655a324

Please sign in to comment.