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]
Date:	Wed, 25 Mar 2015 10:18:29 +0100
From:	Christian Borntraeger <borntraeger@...ibm.com>
To:	Michael Ellerman <mpe@...erman.id.au>, linuxppc-dev@...abs.org
CC:	linux-kernel@...r.kernel.org, aneesh.kumar@...ibm.com,
	akpm@...ux-foundation.org, kirill.shutemov@...ux.intel.com,
	aarcange@...hat.com, steve.capper@...aro.org, linux-mm@...ck.org,
	Jason Low <jason.low2@...com>,
	Linus Torvalds <torvalds@...ux-foundation.org>
Subject: Re: [PATCH 5/6] mm/gup: Replace ACCESS_ONCE with READ_ONCE for STRICT_MM_TYPECHECKS

Am 25.03.2015 um 10:11 schrieb Michael Ellerman:
> If STRICT_MM_TYPECHECKS is enabled the generic gup code fails to build
> because we are using ACCESS_ONCE on non-scalar types.
> 
> Convert all uses to READ_ONCE.

There is a similar patch from Jason Low in Andrews patch.
If that happens in 4.0-rc, we probably want to merge this before 4.0.


> 
> Cc: akpm@...ux-foundation.org
> Cc: kirill.shutemov@...ux.intel.com
> Cc: aarcange@...hat.com
> Cc: borntraeger@...ibm.com
> Cc: steve.capper@...aro.org
> Cc: linux-mm@...ck.org
> Signed-off-by: Michael Ellerman <mpe@...erman.id.au>
> ---
>  mm/gup.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/mm/gup.c b/mm/gup.c
> index a6e24e246f86..120c3adc843c 100644
> --- a/mm/gup.c
> +++ b/mm/gup.c
> @@ -901,7 +901,7 @@ static int gup_pte_range(pmd_t pmd, unsigned long addr, unsigned long end,
>  		 *
>  		 * for an example see gup_get_pte in arch/x86/mm/gup.c
>  		 */
> -		pte_t pte = ACCESS_ONCE(*ptep);
> +		pte_t pte = READ_ONCE(*ptep);
>  		struct page *page;
> 
>  		/*
> @@ -1191,7 +1191,7 @@ int __get_user_pages_fast(unsigned long start, int nr_pages, int write,
>  	local_irq_save(flags);
>  	pgdp = pgd_offset(mm, addr);
>  	do {
> -		pgd_t pgd = ACCESS_ONCE(*pgdp);
> +		pgd_t pgd = READ_ONCE(*pgdp);
> 
>  		next = pgd_addr_end(addr, end);
>  		if (pgd_none(pgd))
> 

--
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