lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1458315564.9556.56.camel@perches.com>
Date:	Fri, 18 Mar 2016 08:39:24 -0700
From:	Joe Perches <joe@...ches.com>
To:	Gustavo Padovan <gustavo@...ovan.org>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc:	linux-kernel@...r.kernel.org, devel@...verdev.osuosl.org,
	dri-devel@...ts.freedesktop.org,
	Daniel Stone <daniels@...labora.com>,
	Arve Hjønnevåg <arve@...roid.com>,
	Riley Andrews <riandrews@...roid.com>,
	Daniel Vetter <daniel.vetter@...ll.ch>,
	Rob Clark <robdclark@...il.com>,
	Greg Hackmann <ghackmann@...gle.com>,
	John Harrison <John.C.Harrison@...el.com>,
	Maarten Lankhorst <maarten.lankhorst@...ux.intel.com>,
	Gustavo Padovan <gustavo.padovan@...labora.co.uk>,
	akpm@...ux-foundation.org, David Airlie <airlied@...ux.ie>,
	Daniel Vetter <daniel.vetter@...el.com>
Subject: Re: [PATCH v10 2/3] kernel.h: add u64_to_user_ptr()

On Fri, 2016-03-18 at 10:27 -0300, Gustavo Padovan wrote:
> From: Gustavo Padovan <gustavo.padovan@...labora.co.uk>
> 
> This function had copies in 3 different files. Unify them in
> kernel.h.

This function might be used more in drm files
in a separate patch too:

$ git grep -n -E "__user.*\(\s*uintptr_t\s*\)" drivers/gpu/drm
drivers/gpu/drm/armada/armada_gem.c:385:        ptr = (char __user *)(uintptr_t)args->ptr;
drivers/gpu/drm/etnaviv/etnaviv_gem_submit.c:33:        return (void __user *)(uintptr_t)address;
drivers/gpu/drm/i915/i915_drv.h:3581:   return (void __user *)(uintptr_t)address;
drivers/gpu/drm/msm/msm_gem_submit.c:33:        return (void __user *)(uintptr_t)address;
drivers/gpu/drm/nouveau/nouveau_gem.c:471:                              (void __force __user *)(uintptr_t)user_pbbo_ptr;
drivers/gpu/drm/nouveau/nouveau_gem.c:568:      void __user *userptr = (void __force __user *)(uintptr_t)user;
drivers/gpu/drm/tegra/drm.c:333:                (void __user *)(uintptr_t)args->cmdbufs;
drivers/gpu/drm/tegra/drm.c:335:                (void __user *)(uintptr_t)args->relocs;
drivers/gpu/drm/tegra/drm.c:337:                (void __user *)(uintptr_t)args->waitchks;
drivers/gpu/drm/tegra/drm.c:392:        if (copy_from_user(&syncpt, (void __user *)(uintptr_t)args->syncpts,
drivers/gpu/drm/vc4/vc4_bo.c:502:                            (void __user *)(uintptr_t)args->data,
drivers/gpu/drm/vc4/vc4_gem.c:123:      if (copy_to_user((void __user *)(uintptr_t)get_state->bo,
drivers/gpu/drm/vc4/vc4_gem.c:553:                           (void __user *)(uintptr_t)args->bo_handles,
drivers/gpu/drm/vc4/vc4_gem.c:627:                         (void __user *)(uintptr_t)args->bin_cl,
drivers/gpu/drm/vc4/vc4_gem.c:634:                         (void __user *)(uintptr_t)args->shader_rec,
drivers/gpu/drm/vc4/vc4_gem.c:641:                         (void __user *)(uintptr_t)args->uniforms,
drivers/gpu/drm/virtio/virtgpu_ioctl.c:126:             user_bo_handles = (void __user *)(uintptr_t)exbuf->bo_handles;
drivers/gpu/drm/virtio/virtgpu_ioctl.c:161:     if (copy_from_user(buf, (void __user *)(uintptr_t)exbuf->command,

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ