drm/tegra: gem: Return 64-bit offset for mmap(2)
authorSean Paul <seanpaul@chromium.org>
Fri, 30 Jan 2015 18:57:01 +0000 (13:57 -0500)
committerThierry Reding <treding@nvidia.com>
Thu, 2 Apr 2015 16:49:23 +0000 (18:49 +0200)
On 64-bit targets, tegra_gem_mmap() only returns a partial offset to
userspace. As such, subsequent calls to mmap(2) may fail. Change the
arguments to use a 64-bit offset to fix this.

Signed-off-by: Sean Paul <seanpaul@chromium.org>
Acked-by: Erik Faye-Lund <kusmabite@gmail.com>
[treding@nvidia.com: tweak commit message]
Signed-off-by: Thierry Reding <treding@nvidia.com>
include/uapi/drm/tegra_drm.h

index c15d781ecc0f306ce5fd575192f547b8e756273f..5391780c2b054ba63ec6a2a24effe66bec248af0 100644 (file)
@@ -36,7 +36,8 @@ struct drm_tegra_gem_create {
 
 struct drm_tegra_gem_mmap {
        __u32 handle;
-       __u32 offset;
+       __u32 pad;
+       __u64 offset;
 };
 
 struct drm_tegra_syncpt_read {