Re: [RFC v3] Support volatile range for anon vma

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Dec 11, 2012 at 08:17:42AM +0100, Mike Hommey wrote:
> On Tue, Dec 11, 2012 at 11:41:04AM +0900, Minchan Kim wrote:
> > - What's the madvise(addr, length, MADV_VOLATILE)?
> > 
> >   It's a hint that user deliver to kernel so kernel can *discard*
> >   pages in a range anytime.
> > 
> > - What happens if user access page(ie, virtual address) discarded
> >   by kernel?
> > 
> >   The user can see zero-fill-on-demand pages as if madvise(DONTNEED).
> 
> What happened to getting SIGBUS?

I thought it could force for user to handle signal.
If user can receive signal, what can he do?
Maybe he can call madivse(NOVOLATILE) in my old version but I removed it
in this version so user don't need handle signal handling.

The problem of madvise(NOVOLATILE) is that time delay between allocator
allocats a free chunk to user and the user really access the memory.
Normally, when allocator return free chunk to customer, allocator should
call madvise(NOVOLATILE) but user could access the memory long time after.
So during that time difference, that pages could be swap out. It means to
mitigate the patch's goal.

Yes. It's not good for tmpfs volatile pages. If you have an interesting
about tmpfs-volatile, please look at this.

https://lkml.org/lkml/2012/12/10/695

> 
> Mike
> 
> --
> To unsubscribe, send a message with 'unsubscribe linux-mm' in
> the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
> see: http://www.linux-mm.org/ .
> Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>

-- 
Kind regards,
Minchan Kim

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]