[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v1 7/9] memory: introduce RAM_NORESERVE and wire it up in qem
From: |
Peter Xu |
Subject: |
Re: [PATCH v1 7/9] memory: introduce RAM_NORESERVE and wire it up in qemu_ram_mmap() |
Date: |
Tue, 2 Mar 2021 15:54:32 -0500 |
On Tue, Mar 02, 2021 at 08:02:34PM +0100, David Hildenbrand wrote:
> > > @@ -174,12 +175,18 @@ void *qemu_ram_mmap(int fd,
> > > size_t align,
> > > bool readonly,
> > > bool shared,
> > > - bool is_pmem)
> > > + bool is_pmem,
> > > + bool noreserve)
> >
> > Maybe at some point we should use flags too here to cover all bools.
> >
>
> Right. I guess the main point was to not reuse RAM_XXX.
>
> Should I introduce RAM_MMAP_XXX ?
Maybe we can directly use MAP_*? Since I see qemu_ram_mmap() should only exist
with CONFIG_POSIX. However indeed I see no sign to extend more bools in the
near future either, so maybe also fine to keep it as is, as 4 bools still looks
okay - your call. :)
--
Peter Xu