Messages in this thread Patch in this message | | | From | Todd Poynor <> | Subject | [PATCH 07/32] staging: gasket: Return EBUSY on mapping create when already in use | Date | Tue, 17 Jul 2018 13:56:47 -0700 |
| |
From: Todd Poynor <toddpoynor@google.com>
gasket_sysfs_create_mapping() return EBUSY if sysfs mapping already in use, as a more appropriate error code than the current return of EINVAL, which would indicate invalid parameters.
Signed-off-by: Zhongze Hu <frankhu@chromium.org> Signed-off-by: Todd Poynor <toddpoynor@google.com> --- drivers/staging/gasket/gasket_sysfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/gasket/gasket_sysfs.c b/drivers/staging/gasket/gasket_sysfs.c index e3d770630961b..dd4d3aaa57e2f 100644 --- a/drivers/staging/gasket/gasket_sysfs.c +++ b/drivers/staging/gasket/gasket_sysfs.c @@ -194,7 +194,7 @@ int gasket_sysfs_create_mapping( "0x%p.", device); put_mapping(mapping); mutex_unlock(&function_mutex); - return -EINVAL; + return -EBUSY; } /* Find the first empty entry in the array. */ -- 2.18.0.203.gfac676dfb9-goog
| |