linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com>
To: Stephen Rothwell <sfr@canb.auug.org.au>,
	Andrew Morton <akpm@linux-foundation.org>
Cc: linux-next@vger.kernel.org, linux-kernel@vger.kernel.org,
	Hugh Dickins <hughd@google.com>
Subject: Re: linux-next: manual merge of the akpm-current tree with the powerpc tree
Date: Mon, 02 May 2016 16:47:27 +0530	[thread overview]
Message-ID: <87eg9kzp2w.fsf@skywalker.in.ibm.com> (raw)
In-Reply-To: <20160502172015.0914d9ec@canb.auug.org.au>

Stephen Rothwell <sfr@canb.auug.org.au> writes:

> Hi Andrew,
>
> Today's linux-next merge of the akpm-current tree got a conflict in:
>
>   arch/powerpc/include/asm/book3s/64/pgtable.h
>
> between commit:
>
>   dbaba7a16b7b ("powerpc/mm: THP is only available on hash64 as of now")
>
> from the powerpc tree and commit:
>
>   383b50a4e356 ("arch: fix has_transparent_hugepage()")
>
> from the akpm-current tree.
>
> I fixed it up (see below - the code moved) and can carry the fix as
> necessary. This is now fixed as far as linux-next is concerned, but any
> non trivial conflicts should be mentioned to your upstream maintainer
> when your tree is submitted for merging.  You may also want to consider
> cooperating with the maintainer of the conflicting tree to minimise any
> particularly complex conflicts.
>


looks good.

> -- 
> Cheers,
> Stephen Rothwell
>
> diff --cc arch/powerpc/include/asm/book3s/64/pgtable.h
> index 48dc76c13094,8fe6f6b48aa5..000000000000
> --- a/arch/powerpc/include/asm/book3s/64/pgtable.h
> +++ b/arch/powerpc/include/asm/book3s/64/pgtable.h
> @@@ -820,86 -265,9 +820,87 @@@ static inline int pmd_protnone(pmd_t pm
>   #define __HAVE_ARCH_PMD_WRITE
>   #define pmd_write(pmd)		pte_write(pmd_pte(pmd))
>   
>  +#ifdef CONFIG_TRANSPARENT_HUGEPAGE
>  +extern pmd_t pfn_pmd(unsigned long pfn, pgprot_t pgprot);
>  +extern pmd_t mk_pmd(struct page *page, pgprot_t pgprot);
>  +extern pmd_t pmd_modify(pmd_t pmd, pgprot_t newprot);
>  +extern void set_pmd_at(struct mm_struct *mm, unsigned long addr,
>  +		       pmd_t *pmdp, pmd_t pmd);
>  +extern void update_mmu_cache_pmd(struct vm_area_struct *vma, unsigned long addr,
>  +				 pmd_t *pmd);
>  +extern int hash__has_transparent_hugepage(void);
> ++#define has_transparent_hugepage has_transparent_hugepage
>  +static inline int has_transparent_hugepage(void)
>  +{
>  +	if (radix_enabled())
>  +		return radix__has_transparent_hugepage();
>  +	return hash__has_transparent_hugepage();
>  +}
>  +
>  +static inline unsigned long
>  +pmd_hugepage_update(struct mm_struct *mm, unsigned long addr, pmd_t *pmdp,
>  +		    unsigned long clr, unsigned long set)
>  +{
>  +	if (radix_enabled())
>  +		return radix__pmd_hugepage_update(mm, addr, pmdp, clr, set);
>  +	return hash__pmd_hugepage_update(mm, addr, pmdp, clr, set);
>  +}
>  +
>  +static inline int pmd_large(pmd_t pmd)
>  +{
>  +	return !!(pmd_val(pmd) & _PAGE_PTE);
>  +}
>  +
>  +static inline pmd_t pmd_mknotpresent(pmd_t pmd)
>  +{
>  +	return __pmd(pmd_val(pmd) & ~_PAGE_PRESENT);
>  +}
>  +/*
>  + * For radix we should always find H_PAGE_HASHPTE zero. Hence
>  + * the below will work for radix too
>  + */
>  +static inline int __pmdp_test_and_clear_young(struct mm_struct *mm,
>  +					      unsigned long addr, pmd_t *pmdp)
>  +{
>  +	unsigned long old;
>  +
>  +	if ((pmd_val(*pmdp) & (_PAGE_ACCESSED | H_PAGE_HASHPTE)) == 0)
>  +		return 0;
>  +	old = pmd_hugepage_update(mm, addr, pmdp, _PAGE_ACCESSED, 0);
>  +	return ((old & _PAGE_ACCESSED) != 0);
>  +}
>  +
>  +#define __HAVE_ARCH_PMDP_SET_WRPROTECT
>  +static inline void pmdp_set_wrprotect(struct mm_struct *mm, unsigned long addr,
>  +				      pmd_t *pmdp)
>  +{
>  +
>  +	if ((pmd_val(*pmdp) & _PAGE_WRITE) == 0)
>  +		return;
>  +
>  +	pmd_hugepage_update(mm, addr, pmdp, _PAGE_WRITE, 0);
>  +}
>  +
>  +static inline int pmd_trans_huge(pmd_t pmd)
>  +{
>  +	if (radix_enabled())
>  +		return radix__pmd_trans_huge(pmd);
>  +	return hash__pmd_trans_huge(pmd);
>  +}
>  +
>  +#define __HAVE_ARCH_PMD_SAME
>  +static inline int pmd_same(pmd_t pmd_a, pmd_t pmd_b)
>  +{
>  +	if (radix_enabled())
>  +		return radix__pmd_same(pmd_a, pmd_b);
>  +	return hash__pmd_same(pmd_a, pmd_b);
>  +}
>  +
>   static inline pmd_t pmd_mkhuge(pmd_t pmd)
>   {
>  -	return __pmd(pmd_val(pmd) | (_PAGE_PTE | _PAGE_THP_HUGE));
>  +	if (radix_enabled())
>  +		return radix__pmd_mkhuge(pmd);
>  +	return hash__pmd_mkhuge(pmd);
>   }
>   
>   #define __HAVE_ARCH_PMDP_SET_ACCESS_FLAGS

  reply	other threads:[~2016-05-02 11:18 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-02  7:20 linux-next: manual merge of the akpm-current tree with the powerpc tree Stephen Rothwell
2016-05-02 11:17 ` Aneesh Kumar K.V [this message]
  -- strict thread matches above, loose matches on Subject: below --
2021-06-18  9:44 Stephen Rothwell
2021-06-19  2:54 ` Nicholas Piggin
2021-05-05  1:39 Stephen Rothwell
2021-05-05  4:57 ` Michael Ellerman
2021-05-05  5:46   ` Stephen Rothwell
2021-05-05 23:43 ` Stephen Rothwell
2021-04-15  9:44 Stephen Rothwell
2021-04-15  9:58 ` Stephen Rothwell
2021-04-15 10:07   ` Christophe Leroy
2021-04-15 10:08     ` Christophe Leroy
2021-04-15 10:15       ` Christophe Leroy
2020-12-08  9:40 Stephen Rothwell
2020-12-17  0:48 ` Stephen Rothwell
2020-09-17  8:57 Stephen Rothwell
2020-06-03  8:50 Stephen Rothwell
2019-07-08 11:43 Stephen Rothwell
2019-04-23  8:57 Stephen Rothwell
2019-02-25  6:42 Stephen Rothwell
2019-02-25  6:44 ` Stephen Rothwell
2019-02-25  6:16 Stephen Rothwell
2018-12-06  6:44 Stephen Rothwell
2018-12-07  1:40 ` Joel Fernandes
2016-03-04  7:49 Stephen Rothwell
2015-12-18  5:33 Stephen Rothwell
2016-01-07  9:15 ` Stephen Rothwell
2016-01-07 17:15   ` Aneesh Kumar K.V
2016-01-07 20:03     ` Stephen Rothwell
2015-12-15  5:53 Stephen Rothwell
2015-12-15  6:44 ` Stephen Rothwell
2015-12-15  9:37 ` Aneesh Kumar K.V

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=87eg9kzp2w.fsf@skywalker.in.ibm.com \
    --to=aneesh.kumar@linux.vnet.ibm.com \
    --cc=akpm@linux-foundation.org \
    --cc=hughd@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=sfr@canb.auug.org.au \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).