arm: propagate the calling convention changes down to csum_partial_copy_from_user()

... and get rid of the "clean the destination on error" crap.
Simplifies the fault handlers and the function itself...

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
Al Viro
2020-07-12 22:56:34 -04:00
parent b712139543
commit 1d60be3c25
4 changed files with 9 additions and 26 deletions

View File

@@ -38,20 +38,17 @@ __wsum
csum_partial_copy_nocheck(const void *src, void *dst, int len);
__wsum
csum_partial_copy_from_user(const void __user *src, void *dst, int len, __wsum sum, int *err_ptr);
csum_partial_copy_from_user(const void __user *src, void *dst, int len);
#define _HAVE_ARCH_COPY_AND_CSUM_FROM_USER
#define _HAVE_ARCH_CSUM_AND_COPY
static inline
__wsum csum_and_copy_from_user(const void __user *src, void *dst, int len)
{
int err = 0;
if (!access_ok(src, len))
return 0;
sum = csum_partial_copy_from_user(src, dst, len, ~0U, &err);
return err ? 0 : sum;
return csum_partial_copy_from_user(src, dst, len);
}
/*