lkml.org 
[lkml]   [2021]   [Jun]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2 3/5] staging: vchiq: Move vchiq char driver to its own file
On Sun, Jun 20, 2021 at 06:26:34PM +0530, Ojaswin Mujoo wrote:
> +/* read a user pointer value from an array pointers in user space */
> +static inline int vchiq_get_user_ptr(void __user **buf, void __user *ubuf, int index)
> +{
> + int ret;
> +
> + if (in_compat_syscall()) {
> + compat_uptr_t ptr32;
> +
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
When I'm reviewing these sorts of patches then what I'm trying to verify
is that you are not a UMN "researcher" trying to change the code without
anyone noticing. In the orignal code, there was no blank line here

> + compat_uptr_t __user *uptr = ubuf;

but there was a blank line here.

> + ret = get_user(ptr32, uptr + index);
> + *buf = compat_ptr(ptr32);
> + } else {

These sorts of minor white space changes make it hard to verify the code
in an automated way.

> + uintptr_t ptr, __user *uptr = ubuf;
> +
> + ret = get_user(ptr, uptr + index);
> + *buf = (void __user *)ptr;
> + }
> +
> + return ret;
> +}
> +

regards,
dan carpenter

\
 
 \ /
  Last update: 2021-06-21 11:58    [W:0.098 / U:0.404 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site