From: Boris Brezillon <boris.brezillon@collabora.com>
To: "Loïc Molinari" <loic.molinari@collabora.com>
Cc: dri-devel@lists.freedesktop.org,
Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
Maxime Ripard <mripard@kernel.org>,
Thomas Zimmermann <tzimmermann@suse.de>,
David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>,
kernel@collabora.com
Subject: Re: [PATCH] drm/gem: Fix builds with CONFIG_MMU=n
Date: Wed, 10 Dec 2025 14:53:08 +0100 [thread overview]
Message-ID: <20251210145308.210c4df4@fedora> (raw)
In-Reply-To: <c35eb3b9-2f8c-429d-b177-16f2f0c65dda@collabora.com>
On Wed, 10 Dec 2025 14:35:51 +0100
Loïc Molinari <loic.molinari@collabora.com> wrote:
> Hi Boris,
>
> I missed that one, thanks for the fix.
>
> On 09/12/2025 18:11, Boris Brezillon wrote:
> > drm_gem_get_unmapped_area() relies on mm_get_unmapped_area() which is
> > only available if CONFIG_MMU=y.
> >
> > Fixes: 99bda20d6d4c ("drm/gem: Introduce drm_gem_get_unmapped_area() fop")
> > Cc: Loïc Molinari <loic.molinari@collabora.com>
> > Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
>
> Reviewed-by: Loïc Molinari <loic.molinari@collabora.com>
Thanks, queued to drm-misc-next immediately so we don't get new kbot
reports.
>
> Regards,
> Loïc
>
> > ---
> > drivers/gpu/drm/drm_gem.c | 2 ++
> > include/drm/drm_gem.h | 5 +++++
> > 2 files changed, 7 insertions(+)
> >
> > diff --git a/drivers/gpu/drm/drm_gem.c b/drivers/gpu/drm/drm_gem.c
> > index 6021c4087a08..ca1956608261 100644
> > --- a/drivers/gpu/drm/drm_gem.c
> > +++ b/drivers/gpu/drm/drm_gem.c
> > @@ -1267,6 +1267,7 @@ drm_gem_object_lookup_at_offset(struct file *filp, unsigned long start,
> > return obj;
> > }
> >
> > +#ifdef CONFIG_MMU
> > /**
> > * drm_gem_get_unmapped_area - get memory mapping region routine for GEM objects
> > * @filp: DRM file pointer
> > @@ -1309,6 +1310,7 @@ unsigned long drm_gem_get_unmapped_area(struct file *filp, unsigned long uaddr,
> > return ret;
> > }
> > EXPORT_SYMBOL_GPL(drm_gem_get_unmapped_area);
> > +#endif
> >
> > /**
> > * drm_gem_mmap - memory map routine for GEM objects
> > diff --git a/include/drm/drm_gem.h b/include/drm/drm_gem.h
> > index cca815dc87f3..f4da8ed0d630 100644
> > --- a/include/drm/drm_gem.h
> > +++ b/include/drm/drm_gem.h
> > @@ -537,9 +537,14 @@ void drm_gem_vm_close(struct vm_area_struct *vma);
> > int drm_gem_mmap_obj(struct drm_gem_object *obj, unsigned long obj_size,
> > struct vm_area_struct *vma);
> > int drm_gem_mmap(struct file *filp, struct vm_area_struct *vma);
> > +
> > +#ifdef CONFIG_MMU
> > unsigned long drm_gem_get_unmapped_area(struct file *filp, unsigned long uaddr,
> > unsigned long len, unsigned long pgoff,
> > unsigned long flags);
> > +#else
> > +#define drm_gem_get_unmapped_area NULL
> > +#endif
> >
> > /**
> > * drm_gem_object_get - acquire a GEM buffer object reference
>
prev parent reply other threads:[~2025-12-10 13:53 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-09 17:11 [PATCH] drm/gem: Fix builds with CONFIG_MMU=n Boris Brezillon
2025-12-10 13:35 ` Loïc Molinari
2025-12-10 13:53 ` Boris Brezillon [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20251210145308.210c4df4@fedora \
--to=boris.brezillon@collabora.com \
--cc=airlied@gmail.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=kernel@collabora.com \
--cc=loic.molinari@collabora.com \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--cc=simona@ffwll.ch \
--cc=tzimmermann@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.