lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 9 Mar 2007 02:31:54 +0100 (CET)
From:	Martin Drab <drab@...ler.fjfi.cvut.cz>
To:	Carsten Otte <cotte.de@...il.com>
cc:	hugh@...itas.com,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: Question about memory mapping mechanism

On Fri, 9 Mar 2007, Martin Drab wrote:

> On Thu, 8 Mar 2007, Martin Drab wrote:
> 
> > On Thu, 8 Mar 2007, Carsten Otte wrote:
> > 
> > > On 3/8/07, Martin Drab <drab@...ler.fjfi.cvut.cz> wrote:
> > > > 
> > > > The thing is that I'd like to prevent kernel to swap these pages out,
> > > > because then I may loose some data when they are not available in time
> > > > for the next round.
> > > 
> > > One think you could do is grab a reference to the pages upfront.
> > 
> > I'm not really sure what exactly do you mean by "grab a reference 
> > upfront"?
> 
> I seem to get it now. So instead of setting PG_reserved upon allocation of 
> the buffer pages, I should increase the referrence of the pages by calling 
> get_page() on them and that would prevent the pages to get on the lru list 
> and thus preventing them to be swapped out. Is that it?

Well, so I tried it. Truth is that the "Bad page" messages upon munmap(2) 
are gone. But whether the pages are really prevented from being swapped 
out? I don't know. I don't know how to find out.

Martin
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists