Commit 4c99ceda authored by Benjamin Gaignard's avatar Benjamin Gaignard Committed by Bartlomiej Zolnierkiewicz

fbdev: make get_fb_unmapped_area depends of !MMU

Even if CONFIG_FB_PROVIDE_GET_FB_UNMAPPED_AREA flag is selected
do not compile and use get_fb_unmapped_area() if CONFIG_MMU is
also set. This will avoid mmap errors when compiling multi
architectures at same time.
Signed-off-by: default avatarBenjamin Gaignard <benjamin.gaignard@linaro.org>
Reviewed-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Cc: Noralf Trønnes <noralf@tronnes.org>
Cc: Emil Velikov <emil.l.velikov@gmail.com>
Cc: Yannick Fertre <yannick.fertre@st.com>
Cc: Eric Engestrom <eric.engestrom@imgtec.com>
Signed-off-by: default avatarBartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
parent fa43bc2a
...@@ -1492,7 +1492,7 @@ __releases(&info->lock) ...@@ -1492,7 +1492,7 @@ __releases(&info->lock)
return 0; return 0;
} }
#ifdef CONFIG_FB_PROVIDE_GET_FB_UNMAPPED_AREA #if defined(CONFIG_FB_PROVIDE_GET_FB_UNMAPPED_AREA) && !defined(CONFIG_MMU)
unsigned long get_fb_unmapped_area(struct file *filp, unsigned long get_fb_unmapped_area(struct file *filp,
unsigned long addr, unsigned long len, unsigned long addr, unsigned long len,
unsigned long pgoff, unsigned long flags) unsigned long pgoff, unsigned long flags)
...@@ -1519,7 +1519,8 @@ static const struct file_operations fb_fops = { ...@@ -1519,7 +1519,8 @@ static const struct file_operations fb_fops = {
.open = fb_open, .open = fb_open,
.release = fb_release, .release = fb_release,
#if defined(HAVE_ARCH_FB_UNMAPPED_AREA) || \ #if defined(HAVE_ARCH_FB_UNMAPPED_AREA) || \
defined(CONFIG_FB_PROVIDE_GET_FB_UNMAPPED_AREA) (defined(CONFIG_FB_PROVIDE_GET_FB_UNMAPPED_AREA) && \
!defined(CONFIG_MMU))
.get_unmapped_area = get_fb_unmapped_area, .get_unmapped_area = get_fb_unmapped_area,
#endif #endif
#ifdef CONFIG_FB_DEFERRED_IO #ifdef CONFIG_FB_DEFERRED_IO
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment