diff options
| author | Dan Carpenter <[email protected]> | 2022-04-26 11:48:03 +0300 |
|---|---|---|
| committer | Alex Deucher <[email protected]> | 2022-04-26 11:52:20 -0400 |
| commit | a52ad5b6ce0df125d0d9ea169b61ae6cc098f047 (patch) | |
| tree | 20b3218dfc5a938d1515dc457833eb89ce31080c /drivers/usb/cdns3/cdns3-trace.h | |
| parent | a6f2e0d9fe6399ff060ae3de28089a4e0462b6cf (diff) | |
drm/amdgpu: debugfs: fix error codes in write functions
There are two error code bugs here. The copy_to/from_user() functions
return the number of bytes remaining (a positive number). We should
return -EFAULT if the copy fails.
Second if we fail because "context.resp_status" is non-zero then return
-EINVAL instead of zero.
Fixes: e50d9ba0d2cd ("drm/amdgpu: Add debugfs TA load/unload/invoke support")
Signed-off-by: Dan Carpenter <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
Diffstat (limited to 'drivers/usb/cdns3/cdns3-trace.h')
0 files changed, 0 insertions, 0 deletions