mirror of
https://github.com/ceph/ceph-csi.git
synced 2024-11-09 16:00:22 +00:00
rbd: rename ndbType parameter
Fix "ndb" typo.
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
(cherry picked from commit d3f31187fc
)
This commit is contained in:
parent
2a090b785c
commit
6918cbe950
@ -289,7 +289,7 @@ func detachRBDDevice(ctx context.Context, devicePath, volumeID, unmapOptions str
|
|||||||
|
|
||||||
// detachRBDImageOrDeviceSpec detaches an rbd imageSpec or devicePath, with additional checking
|
// detachRBDImageOrDeviceSpec detaches an rbd imageSpec or devicePath, with additional checking
|
||||||
// when imageSpec is used to decide if image is already unmapped.
|
// when imageSpec is used to decide if image is already unmapped.
|
||||||
func detachRBDImageOrDeviceSpec(ctx context.Context, imageOrDeviceSpec string, isImageSpec, ndbType, encrypted bool, volumeID, unmapOptions string) error {
|
func detachRBDImageOrDeviceSpec(ctx context.Context, imageOrDeviceSpec string, isImageSpec, isNbd, encrypted bool, volumeID, unmapOptions string) error {
|
||||||
if encrypted {
|
if encrypted {
|
||||||
mapperFile, mapperPath := util.VolumeMapper(volumeID)
|
mapperFile, mapperPath := util.VolumeMapper(volumeID)
|
||||||
mappedDevice, mapper, err := util.DeviceEncryptionStatus(ctx, mapperPath)
|
mappedDevice, mapper, err := util.DeviceEncryptionStatus(ctx, mapperPath)
|
||||||
@ -311,7 +311,7 @@ func detachRBDImageOrDeviceSpec(ctx context.Context, imageOrDeviceSpec string, i
|
|||||||
}
|
}
|
||||||
|
|
||||||
accessType := accessTypeKRbd
|
accessType := accessTypeKRbd
|
||||||
if ndbType {
|
if isNbd {
|
||||||
accessType = accessTypeNbd
|
accessType = accessTypeNbd
|
||||||
}
|
}
|
||||||
unmapArgs := []string{"unmap", "--device-type", accessType, imageOrDeviceSpec}
|
unmapArgs := []string{"unmap", "--device-type", accessType, imageOrDeviceSpec}
|
||||||
|
Loading…
Reference in New Issue
Block a user