Skip to content

Commit

Permalink
powerpc/mm: Rename pte fragment functions
Browse files Browse the repository at this point in the history
We rename the alloc and get_from_cache to indicate they operate on pte
fragments. In later patch we will add pmd fragment support.

No functional change in this patch.

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
  • Loading branch information
Aneesh Kumar K.V authored and Michael Ellerman committed May 15, 2018
1 parent af60a4c commit 8ce74cf
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions arch/powerpc/mm/pgtable_64.c
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@ struct page *pmd_page(pmd_t pmd)
}

#ifdef CONFIG_PPC_64K_PAGES
static pte_t *get_from_cache(struct mm_struct *mm)
static pte_t *get_pte_from_cache(struct mm_struct *mm)
{
void *pte_frag, *ret;

Expand All @@ -333,7 +333,7 @@ static pte_t *get_from_cache(struct mm_struct *mm)
return (pte_t *)ret;
}

static pte_t *__alloc_for_cache(struct mm_struct *mm, int kernel)
static pte_t *__alloc_for_ptecache(struct mm_struct *mm, int kernel)
{
void *ret = NULL;
struct page *page;
Expand Down Expand Up @@ -372,12 +372,13 @@ pte_t *pte_fragment_alloc(struct mm_struct *mm, unsigned long vmaddr, int kernel
{
pte_t *pte;

pte = get_from_cache(mm);
pte = get_pte_from_cache(mm);
if (pte)
return pte;

return __alloc_for_cache(mm, kernel);
return __alloc_for_ptecache(mm, kernel);
}

#endif /* CONFIG_PPC_64K_PAGES */

void pte_fragment_free(unsigned long *table, int kernel)
Expand Down

0 comments on commit 8ce74cf

Please sign in to comment.