diff --git a/internal/cephfs/clone.go b/internal/cephfs/clone.go index 3144f28e1..2350d4e61 100644 --- a/internal/cephfs/clone.go +++ b/internal/cephfs/clone.go @@ -45,7 +45,7 @@ const ( func createCloneFromSubvolume(ctx context.Context, volID, cloneID volumeID, volOpt, parentvolOpt *volumeOptions, cr *util.Credentials) error { snapshotID := cloneID - err := parentvolOpt.createSnapshot(ctx, cr, snapshotID, volID) + err := parentvolOpt.createSnapshot(ctx, snapshotID, volID) if err != nil { util.ErrorLog(ctx, "failed to create snapshot %s %v", snapshotID, err) return err diff --git a/internal/cephfs/controllerserver.go b/internal/cephfs/controllerserver.go index 4169f70ab..3d2607aa5 100644 --- a/internal/cephfs/controllerserver.go +++ b/internal/cephfs/controllerserver.go @@ -587,7 +587,7 @@ func doSnapshot(ctx context.Context, volOpt *volumeOptions, subvolumeName, snaps volID := volumeID(subvolumeName) snapID := volumeID(snapshotName) snap := snapshotInfo{} - err := volOpt.createSnapshot(ctx, cr, snapID, volID) + err := volOpt.createSnapshot(ctx, snapID, volID) if err != nil { util.ErrorLog(ctx, "failed to create snapshot %s %v", snapID, err) return snap, err diff --git a/internal/cephfs/snapshot.go b/internal/cephfs/snapshot.go index 8022fbb24..fec7cad4c 100644 --- a/internal/cephfs/snapshot.go +++ b/internal/cephfs/snapshot.go @@ -45,7 +45,7 @@ type cephfsSnapshot struct { ReservedID string } -func (vo *volumeOptions) createSnapshot(ctx context.Context, cr *util.Credentials, snapID, volID volumeID) error { +func (vo *volumeOptions) createSnapshot(ctx context.Context, snapID, volID volumeID) error { fsa, err := vo.conn.GetFSAdmin() if err != nil { util.ErrorLog(ctx, "could not get FSAdmin: %s", err)