remove unnecessary code and doc

This commit is contained in:
Lei Xue
2016-11-28 14:36:13 +08:00
parent 05b6f88de4
commit 82ae696822
10 changed files with 49 additions and 73 deletions

View File

@@ -1,5 +1,5 @@
/*
Copyright 2015 The GoStor Authors All rights reserved.
Copyright 2016 The GoStor Authors All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
@@ -28,9 +28,11 @@ import (
type BackendType string
type SCSILUMap struct {
mutex sync.RWMutex
AllDevices api.LUNMap /* use UUID as the key for all LUs*/
TargetsLUNMap map[string]api.LUNMap /* use target name as the key for target's LUN map*/
mutex sync.RWMutex
// use UUID as the key for all LUs
AllDevices api.LUNMap
// use target name as the key for target's LUN map
TargetsLUNMap map[string]api.LUNMap
}
var globalSCSILUMap = SCSILUMap{AllDevices: make(api.LUNMap), TargetsLUNMap: make(map[string]api.LUNMap)}
@@ -85,7 +87,7 @@ func InitSCSILUMap(config *config.Config) error {
return errors.New("LU Number must be a number")
}
mappingLUN(deviceID, lun, tgtName)
//Init SCSISimpleReservationOperator
// Init SCSISimpleReservationOperator
op := GetSCSIReservationOperator()
if simpleOp, ok = op.(*SCSISimpleReservationOperator); ok {
simpleOp.InitLUReservation(tgtName, deviceID)