diff options
| author | Dan Williams <dan.j.williams@intel.com> | 2017-04-12 21:59:01 -0700 |
|---|---|---|
| committer | Dan Williams <dan.j.williams@intel.com> | 2017-04-12 21:59:01 -0700 |
| commit | bfca9acf1a5df0ff98fbf47e363adb48612bb7ec (patch) | |
| tree | a50287c88fdc60a73912d205d7bce41b7af53827 /drivers/crypto/ccp/ccp-dev.c | |
| parent | device-dax: utilize new cdev_device_add helper function (diff) | |
| parent | x86, pmem: fix broken __copy_user_nocache cache-bypass assumptions (diff) | |
| download | linux-bfca9acf1a5df0ff98fbf47e363adb48612bb7ec.tar.gz linux-bfca9acf1a5df0ff98fbf47e363adb48612bb7ec.zip | |
Merge branch 'for-4.11/libnvdimm' into for-4.12/dax
Diffstat (limited to 'drivers/crypto/ccp/ccp-dev.c')
| -rw-r--r-- | drivers/crypto/ccp/ccp-dev.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/crypto/ccp/ccp-dev.c b/drivers/crypto/ccp/ccp-dev.c index 511ab042b5e7..92d1c6959f08 100644 --- a/drivers/crypto/ccp/ccp-dev.c +++ b/drivers/crypto/ccp/ccp-dev.c @@ -283,11 +283,14 @@ EXPORT_SYMBOL_GPL(ccp_version); */ int ccp_enqueue_cmd(struct ccp_cmd *cmd) { - struct ccp_device *ccp = ccp_get_device(); + struct ccp_device *ccp; unsigned long flags; unsigned int i; int ret; + /* Some commands might need to be sent to a specific device */ + ccp = cmd->ccp ? cmd->ccp : ccp_get_device(); + if (!ccp) return -ENODEV; |
