Skip to content

Commit

Permalink
[sled-agent] Allow synthetic disks to be used as M.2s and U.2s. (#2976)
Browse files Browse the repository at this point in the history
This fixes a bug where the internal zpools created by
`./tools/create_virtual_hardware.sh` were ignored by the sled agent -
this utility is used in other locations to access "m.2 datasets".
  • Loading branch information
smklein authored May 1, 2023
1 parent 8984c3b commit b37d202
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions sled-agent/src/storage_manager.rs
Original file line number Diff line number Diff line change
Expand Up @@ -230,11 +230,9 @@ impl StorageResources {
disks
.values()
.filter_map(|disk| {
if let DiskWrapper::Real { disk, .. } = disk {
if disk.variant() == variant {
return Some(disk.zpool_name().clone());
}
};
if disk.variant() == variant {
return Some(disk.zpool_name().clone());
}
None
})
.collect()
Expand Down

0 comments on commit b37d202

Please sign in to comment.