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: <20080129163158.GX3058@sgi.com>
Date:	Tue, 29 Jan 2008 10:31:58 -0600
From:	Robin Holt <holt@....com>
To:	Christoph Lameter <clameter@....com>
Cc:	Andrea Arcangeli <andrea@...ranet.com>, Robin Holt <holt@....com>,
	Avi Kivity <avi@...ranet.com>, Izik Eidus <izike@...ranet.com>,
	Nick Piggin <npiggin@...e.de>, kvm-devel@...ts.sourceforge.net,
	Benjamin Herrenschmidt <benh@...nel.crashing.org>,
	Peter Zijlstra <a.p.zijlstra@...llo.nl>, steiner@....com,
	linux-kernel@...r.kernel.org, linux-mm@...ck.org,
	daniel.blueman@...drics.com, Hugh Dickins <hugh@...itas.com>
Subject: Re: [patch 6/6] mmu_notifier: Add invalidate_all()

What is the status of getting invalidate_all adjusted to indicate a need
to also call _release?

Thanks,
Robin

On Mon, Jan 28, 2008 at 12:28:46PM -0800, Christoph Lameter wrote:
> when a task exits we can remove all external pts at once. At that point the
> extern mmu may also unregister itself from the mmu notifier chain to avoid
> future calls.
> 
> Note the complications because of RCU. Other processors may not see that the
> notifier was unlinked until a quiescent period has passed!
> 
> Signed-off-by: Christoph Lameter <clameter@....com>
> 
> ---
>  include/linux/mmu_notifier.h |    4 ++++
>  mm/mmap.c                    |    1 +
>  2 files changed, 5 insertions(+)
> 
> Index: linux-2.6/include/linux/mmu_notifier.h
> ===================================================================
> --- linux-2.6.orig/include/linux/mmu_notifier.h	2008-01-28 11:43:03.000000000 -0800
> +++ linux-2.6/include/linux/mmu_notifier.h	2008-01-28 12:21:33.000000000 -0800
> @@ -62,6 +62,10 @@ struct mmu_notifier_ops {
>  				struct mm_struct *mm,
>  				unsigned long address);
>  
> +	/* Dummy needed because the mmu_notifier() macro requires it */
> +	void (*invalidate_all)(struct mmu_notifier *mn, struct mm_struct *mm,
> +				int dummy);
> +
>  	/*
>  	 * lock indicates that the function is called under spinlock.
>  	 */
> Index: linux-2.6/mm/mmap.c
> ===================================================================
> --- linux-2.6.orig/mm/mmap.c	2008-01-28 11:47:53.000000000 -0800
> +++ linux-2.6/mm/mmap.c	2008-01-28 11:57:45.000000000 -0800
> @@ -2034,6 +2034,7 @@ void exit_mmap(struct mm_struct *mm)
>  	unsigned long end;
>  
>  	/* mm's last user has gone, and its about to be pulled down */
> +	mmu_notifier(invalidate_all, mm, 0);
>  	arch_exit_mmap(mm);
>  
>  	lru_add_drain();
> 
> -- 
--
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