summaryrefslogtreecommitdiff
path: root/drivers/misc/habanalabs/common/command_buffer.c
diff options
context:
space:
mode:
authorOded Gabbay <ogabbay@kernel.org>2021-12-19 17:06:59 +0300
committerOded Gabbay <ogabbay@kernel.org>2021-12-26 09:59:10 +0300
commit519f4ed0a09cdf3834c5cbde1416acd9a979a709 (patch)
treea9f49dd97437cb129801cf1883d7daf7c829a614 /drivers/misc/habanalabs/common/command_buffer.c
parent0a63ac769b4cb79dfe68efd06528e9174fb88162 (diff)
downloadlinux-519f4ed0a09cdf3834c5cbde1416acd9a979a709.tar.xz
habanalabs: replace some -ENOTTY with -EINVAL
-ENOTTY is returned in case of error in the ioctl arguments themselves, such as function that doesn't exists. In all other cases, where the error is in the arguments of the custom data structures that we define that are passed in the various ioctls, we need to return -EINVAL. Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
Diffstat (limited to 'drivers/misc/habanalabs/common/command_buffer.c')
-rw-r--r--drivers/misc/habanalabs/common/command_buffer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/misc/habanalabs/common/command_buffer.c b/drivers/misc/habanalabs/common/command_buffer.c
index d4eb9fb9ea12..e7534b5129fa 100644
--- a/drivers/misc/habanalabs/common/command_buffer.c
+++ b/drivers/misc/habanalabs/common/command_buffer.c
@@ -475,7 +475,7 @@ int hl_cb_ioctl(struct hl_fpriv *hpriv, void *data)
break;
default:
- rc = -ENOTTY;
+ rc = -EINVAL;
break;
}