]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
UBUNTU: SAUCE: cxlflash: Setup OCXL transaction layer
authorUma Krishnan <ukrishn@linux.vnet.ibm.com>
Thu, 16 Nov 2017 21:18:17 +0000 (15:18 -0600)
committerSeth Forshee <seth.forshee@canonical.com>
Tue, 27 Mar 2018 19:10:08 +0000 (14:10 -0500)
BugLink: http://bugs.launchpad.net/bugs/1752672
The first function of the link needs to configure the transaction layer
between the host and device. This is accomplished by a call to the OCXL
provider services.

Signed-off-by: Uma Krishnan <ukrishn@linux.vnet.ibm.com>
Acked-by: Matthew R. Ochs <mrochs@linux.vnet.ibm.com>
Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
drivers/scsi/cxlflash/ocxl_hw.c

index ea2906dc967bdc42be5f9e159202d570723d5b5c..a38898162d4ce86ad416db29c11bfb53338dcff7 100644 (file)
@@ -419,8 +419,18 @@ static int ocxlflash_config_fn(struct pci_dev *pdev, struct ocxl_hw_afu *afu)
                        __func__, rc);
                goto out;
        }
+
+       rc = ocxl_config_set_TL(pdev, fcfg->dvsec_tl_pos);
+       if (unlikely(rc)) {
+               dev_err(dev, "%s: ocxl_config_set_TL failed rc=%d\n",
+                       __func__, rc);
+               goto err;
+       }
 out:
        return rc;
+err:
+       ocxl_link_release(pdev, afu->link_token);
+       goto out;
 }
 
 /**