dmaengine: idxd: return 0 if wq already enabled instead of error

commit 3a5e5ffd0d28c0c9b71f047668baca77723b6875 Intel-BKC.

If wq is already enabled and idxd_wq_enable() is called, return 0 instead
of error since it's not a real error.

Signed-off-by: Dave Jiang <dave.jiang@intel.com>
Signed-off-by: Chen Zhuo <sagazchen@tencent.com>
Signed-off-by: Xinghui Li <korantli@tencent.com>
This commit is contained in:
Dave Jiang 2022-04-21 10:16:24 -07:00 committed by Jianping Liu
parent fe0fe2a1b8
commit 27de8b7ebc
1 changed files with 1 additions and 1 deletions

View File

@ -248,7 +248,7 @@ int idxd_wq_enable(struct idxd_wq *wq, u32 *status)
if (wq->state == IDXD_WQ_ENABLED) {
dev_dbg(dev, "WQ %d already enabled\n", wq->id);
return -ENXIO;
return 0;
}
idxd_cmd_exec(idxd, IDXD_CMD_ENABLE_WQ, wq->id, &stat);