Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NAS-129539 / 24.10 / always show rear nvme on m-series #13964

Merged
merged 1 commit into from
Jul 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/middlewared/middlewared/plugins/enclosure_/nvme2.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,11 +239,12 @@ def map_nvme(dmi):
# all nvme systems which we need to handle separately
return map_r30_or_fseries(model, ctx)
elif model in (
ControllerModels.M30.value,
ControllerModels.M40.value,
ControllerModels.M50.value,
ControllerModels.M60.value,
ControllerModels.R50BM.value,
):
# M50, M60 and R50BM use same plx nvme bridge
return map_plx_nvme(model, ctx)
else:
return []
19 changes: 19 additions & 0 deletions src/middlewared/middlewared/plugins/enclosure_/slot_mappings.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ def get_nvme_slot_info(model):
ControllerModels.F60.value,
ControllerModels.F100.value,
ControllerModels.F130.value,
ControllerModels.M30.value,
ControllerModels.M40.value,
ControllerModels.M50.value,
ControllerModels.M60.value,
ControllerModels.R30.value,
Expand All @@ -68,6 +70,23 @@ def get_nvme_slot_info(model):
i: {SYSFS_SLOT_KEY: i, MAPPED_SLOT_KEY: i, SUPPORTS_IDENTIFY_KEY: True}
for i in range(1, 25)
},
# ALL m-series platforms have 4 rear nvme drive bays.
# The R50BM platform does as well and uses same plx
# nvme bridge. HOWEVER, the m30 and the gen1/2 m40's do
# NOT have the pcie switch that connects those 4 drive
# bays but the gen3 M40 with 192GB RAM does. Since we
# don't have (at time of writing) a proper way to track
# generational m40's, we will always return 4 nvme drive
# bays for all m-series platforms and they will be empty
# on the platforms that can't physically support these drives
'm30_nvme_enclosure': {
i: {SYSFS_SLOT_KEY: i, MAPPED_SLOT_KEY: j, SUPPORTS_IDENTIFY_KEY: False}
for i, j in zip(range(1, 5), range(25, 29))
},
'm40_nvme_enclosure': {
i: {SYSFS_SLOT_KEY: i, MAPPED_SLOT_KEY: j, SUPPORTS_IDENTIFY_KEY: False}
for i, j in zip(range(1, 5), range(25, 29))
},
'm50_nvme_enclosure': {
i: {SYSFS_SLOT_KEY: i, MAPPED_SLOT_KEY: j, SUPPORTS_IDENTIFY_KEY: False}
for i, j in zip(range(1, 5), range(25, 29))
Expand Down
Loading