From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Kumar Gala <galak@kernel.crashing.org>
Cc: linuxppc-dev@ozlabs.org
Subject: Re: [PATCH 1/3] powerpc: Fix pte_update for CONFIG_PTE_64BIT and !PTE_ATOMIC_UPDATES
Date: Tue, 15 Jul 2008 15:43:03 +1000 [thread overview]
Message-ID: <1216100583.7740.70.camel@pasglop> (raw)
In-Reply-To: <Pine.LNX.4.64.0807140808090.9284@blarg.am.freescale.net>
On Mon, 2008-07-14 at 08:08 -0500, Kumar Gala wrote:
> Because the pte is now 64-bits the compiler was optimizing the update
> to always clear the upper 32-bits of the pte. We need to ensure the
> clr mask is treated as an unsigned long long to get the proper behavior.
>
> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
> Acked-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
Putting that one into my tree. I'll let you put the 2 others in yours.
Cheers,
Ben.
> ---
> include/asm-powerpc/pgtable-ppc32.h | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/include/asm-powerpc/pgtable-ppc32.h b/include/asm-powerpc/pgtable-ppc32.h
> index 11eede4..73015f0 100644
> --- a/include/asm-powerpc/pgtable-ppc32.h
> +++ b/include/asm-powerpc/pgtable-ppc32.h
> @@ -624,7 +624,7 @@ static inline unsigned long long pte_update(pte_t *p,
> : "cc" );
> #else /* PTE_ATOMIC_UPDATES */
> unsigned long long old = pte_val(*p);
> - *p = __pte((old & ~clr) | set);
> + *p = __pte((old & ~(unsigned long long)clr) | set);
> #endif /* !PTE_ATOMIC_UPDATES */
>
> #ifdef CONFIG_44x
prev parent reply other threads:[~2008-07-15 5:43 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-07-14 13:08 [PATCH 1/3] powerpc: Fix pte_update for CONFIG_PTE_64BIT and !PTE_ATOMIC_UPDATES Kumar Gala
2008-07-14 13:09 ` [PATCH 2/3] powerpc: rework FSL Book-E PTE access and TLB miss Kumar Gala
2008-07-14 13:11 ` [PATCH 3/3] powerpc/fsl: Minor TLBSYNC cleanup for FSL Book-E Kumar Gala
2008-07-15 5:43 ` Benjamin Herrenschmidt [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1216100583.7740.70.camel@pasglop \
--to=benh@kernel.crashing.org \
--cc=galak@kernel.crashing.org \
--cc=linuxppc-dev@ozlabs.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.