bunch of bug fixes with dummy lun0 feature

1) add dummy lun0
2) fix report lun
3) fix inquiry command with correct version
This commit is contained in:
Le Zhang
2016-10-07 23:54:08 +08:00
parent 97fb41fc98
commit 681f1003b9
9 changed files with 180 additions and 59 deletions

View File

@@ -33,7 +33,7 @@ func TestSPCReportLuns(t *testing.T) {
cmd.Device = device
lu := new(api.SCSILu)
target := new(api.SCSITarget)
target.Devices = map[uint64]*api.SCSILu{lu.Lun: lu}
target.Devices = map[uint64]*api.SCSILu{0: lu}
cmd.Target = target
cmd.SCB = &bytes.Buffer{}
cmd.SenseBuffer = &bytes.Buffer{}