Tal Nisan has posted comments on this change.

Change subject: core: allow read-only for VirtIO-SCSI DirectLUN disks
......................................................................


Patch Set 5:

(1 comment)

http://gerrit.ovirt.org/#/c/30123/5/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/validator/DiskValidator.java
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/validator/DiskValidator.java:

Line 108:                         String.format("$interface %1$s", 
diskInterface));
Line 109:             }
Line 110: 
Line 111:             boolean isVirtioScsiDirectLunPassthrough = diskInterface 
== DiskInterface.VirtIO_SCSI &&
Line 112:                     disk.getDiskStorageType() == DiskStorageType.LUN 
&& disk.isScsiPassthrough();
Can't you just check is disk.isScsiPassthrough()?
If the rest of the condition has to be true otherwise you'll get thrown before 
with the validation failure
Line 113:             if (isVirtioScsiDirectLunPassthrough) {
Line 114:                 return new 
ValidationResult(VdcBllMessages.SCSI_PASSTHROUGH_IS_NOT_SUPPORTED_FOR_READ_ONLY_DISK);
Line 115:             }
Line 116:         }


-- 
To view, visit http://gerrit.ovirt.org/30123
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Ic317722be9ef8978b50352c12bc06ea8c906dcd0
Gerrit-PatchSet: 5
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Daniel Erez <[email protected]>
Gerrit-Reviewer: Allon Mureinik <[email protected]>
Gerrit-Reviewer: Daniel Erez <[email protected]>
Gerrit-Reviewer: Eyal Edri <[email protected]>
Gerrit-Reviewer: Paolo Bonzini <[email protected]>
Gerrit-Reviewer: Tal Nisan <[email protected]>
Gerrit-Reviewer: Vered Volansky <[email protected]>
Gerrit-Reviewer: [email protected]
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to