[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20250130164836.1163f66bede77ec4bcc9d4b9@linux-foundation.org>
Date: Thu, 30 Jan 2025 16:48:36 -0800
From: Andrew Morton <akpm@...ux-foundation.org>
To: "Vishal Moola (Oracle)" <vishal.moola@...il.com>
Cc: linux-mm@...ck.org, linux-kernel@...r.kernel.org, hch@...radead.org,
urezki@...il.com, intel-gfx@...ts.freedesktop.org
Subject: Re: [PATCH 0/2] vmalloc: Introduce vmap_file()
On Thu, 30 Jan 2025 16:18:04 -0800 "Vishal Moola (Oracle)" <vishal.moola@...il.com> wrote:
> Currently, users have to call vmap() or vmap_pfn() to map pages to
> kernel virtual space. vmap() requires the page references, and
> vmap_pfn() requires page pfns. If we have a file but no page references,
> we have to do extra work to map them.
>
> Create a function, vmap_file(), to map a specified range of a given
> file to kernel virtual space. Also convert a user that benefits from
> vmap_file().
>
Seems like a pretty specialized thing. Have you identified any other
potential users of vmap_file()? I couldn't see any.
If drm is likely to remain the only user of this, perhaps we should
leave the code down in drivers/gpu/drm for now?
Also, the amount of copy-n-pasting from vmap() into vmap_file() is
undesirable - code size, maintenance overhead, etc.
Powered by blists - more mailing lists