Skip to content

Commit

Permalink
[POWERPC] TLB insertion cleanup
Browse files Browse the repository at this point in the history
This patch changes handling return value of ppc_md.hpte_insert() into
the same way as __hash_page_*().

Signed-off-by: Kou Ishizaki <kou.ishizaki@toshiba.co.jp>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
  • Loading branch information
Ishizaki Kou authored and Paul Mackerras committed Jan 24, 2007
1 parent 3650cfe commit d649bd7
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions arch/powerpc/mm/hugetlbpage.c
Original file line number Diff line number Diff line change
Expand Up @@ -1014,7 +1014,6 @@ int hash_huge_page(struct mm_struct *mm, unsigned long access,

/* Primary is full, try the secondary */
if (unlikely(slot == -1)) {
new_pte |= _PAGE_F_SECOND;
hpte_group = ((~hash & htab_hash_mask) *
HPTES_PER_GROUP) & ~0x7UL;
slot = ppc_md.hpte_insert(hpte_group, va, pa, rflags,
Expand All @@ -1033,7 +1032,7 @@ int hash_huge_page(struct mm_struct *mm, unsigned long access,
if (unlikely(slot == -2))
panic("hash_huge_page: pte_insert failed\n");

new_pte |= (slot << 12) & _PAGE_F_GIX;
new_pte |= (slot << 12) & (_PAGE_F_SECOND | _PAGE_F_GIX);
}

/*
Expand Down

0 comments on commit d649bd7

Please sign in to comment.