All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm: tegra: shut up harmless warning on NOMMU
@ 2017-01-12 11:13 ` Arnd Bergmann
  0 siblings, 0 replies; 8+ messages in thread
From: Arnd Bergmann @ 2017-01-12 11:13 UTC (permalink / raw)
  To: Thierry Reding
  Cc: Alexandre Courbot, Arnd Bergmann, Stephen Warren, Daniel Vetter,
	linux-kernel, dri-devel, Mikko Perttunen, linux-tegra

The tegra DRM driver is almost ok without an MMU, but there
is one small warning that I get:

drivers/gpu/drm/tegra/gem.c: In function 'tegra_drm_mmap':
drivers/gpu/drm/tegra/gem.c:508:12: unused variable 'prot'

This marks the variable as __maybe_unused instead.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/gpu/drm/tegra/gem.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/tegra/gem.c b/drivers/gpu/drm/tegra/gem.c
index 7d853e6b5ff0..63f14b7a59a0 100644
--- a/drivers/gpu/drm/tegra/gem.c
+++ b/drivers/gpu/drm/tegra/gem.c
@@ -505,7 +505,7 @@ int tegra_drm_mmap(struct file *file, struct vm_area_struct *vma)
 
 		vma->vm_pgoff = vm_pgoff;
 	} else {
-		pgprot_t prot = vm_get_page_prot(vma->vm_flags);
+		pgprot_t prot __maybe_unused = vm_get_page_prot(vma->vm_flags);
 
 		vma->vm_flags |= VM_MIXEDMAP;
 		vma->vm_flags &= ~VM_PFNMAP;
-- 
2.9.0

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2017-01-25  6:52 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-01-12 11:13 [PATCH] drm: tegra: shut up harmless warning on NOMMU Arnd Bergmann
2017-01-12 11:13 ` Arnd Bergmann
2017-01-19 11:00 ` Thierry Reding
2017-01-19 11:00   ` Thierry Reding
2017-01-19 15:09   ` Arnd Bergmann
2017-01-19 15:09     ` Arnd Bergmann
2017-01-25  6:52     ` Thierry Reding
2017-01-25  6:52       ` Thierry Reding

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.