cxlflash: Fix to avoid virtual LUN failover failure
[firefly-linux-kernel-4.4.55.git] / drivers / scsi / cxlflash / vlun.c
index a53f583e2d7b1ea5b58e817e66715a35567698da..50f8e93007704667fb0c1311834c0a5f0d50ff52 100644 (file)
@@ -1008,6 +1008,8 @@ int cxlflash_disk_virtual_open(struct scsi_device *sdev, void *arg)
        virt->last_lba = last_lba;
        virt->rsrc_handle = rsrc_handle;
 
+       if (lli->port_sel == BOTH_PORTS)
+               virt->hdr.return_flags |= DK_CXLFLASH_ALL_PORTS_ACTIVE;
 out:
        if (likely(ctxi))
                put_context(ctxi);