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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <462932BE.4020005@redhat.com>
Date:	Fri, 20 Apr 2007 17:38:06 -0400
From:	Rik van Riel <riel@...hat.com>
To:	Andrew Morton <akpm@...ux-foundation.org>
CC:	linux-kernel <linux-kernel@...r.kernel.org>,
	linux-mm <linux-mm@...ck.org>
Subject: Re: [PATCH] lazy freeing of memory through MADV_FREE

Andrew Morton wrote:

> I've also merged Nick's "mm: madvise avoid exclusive mmap_sem".
> 
> - Nick's patch also will help this problem.  It could be that your patch
>   no longer offers a 2x speedup when combined with Nick's patch.
> 
>   It could well be that the combination of the two is even better, but it
>   would be nice to firm that up a bit.  

I'll test that.

>   I do go on about that.  But we're adding page flags at about one per
>   year, and when we run out we're screwed - we'll need to grow the
>   pageframe.

If you want, I can take a look at folding this into the
->mapping pointer.  I can guarantee you it won't be
pretty, though :)

> - I need to update your patch for Nick's patch.  Please confirm that
>   down_read(mmap_sem) is sufficient for MADV_FREE.

It is.  MADV_FREE needs no more protection than MADV_DONTNEED.

> Stylistic nit:
> 
>> +	if (PageLazyFree(page) && !migration) {
>> +		/* There is new data in the page.  Reinstate it. */
>> +		if (unlikely(pte_dirty(pteval))) {
>> +			set_pte_at(mm, address, pte, pteval);
>> +			ret = SWAP_FAIL;
>> +			goto out_unmap;
>> +		}
> 
> The comment should be inside the second `if' statement.  As it is, It
> looks like we reinstate the page if (PageLazyFree(page) && !migration).

Want me to move it?

-- 
Politics is the struggle between those who want to make their country
the best in the world, and those who believe it already is.  Each group
calls the other unpatriotic.
-
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ