mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
mm: treewide: clarify pgtable_page_{ctor,dtor}() naming
The naming of pgtable_page_{ctor,dtor}() seems to have confused a few
people, and until recently arm64 used these erroneously/pointlessly for
other levels of page table.
To make it incredibly clear that these only apply to the PTE level, and to
align with the naming of pgtable_pmd_page_{ctor,dtor}(), let's rename them
to pgtable_pte_page_{ctor,dtor}().
These changes were generated with the following shell script:
----
git grep -lw 'pgtable_page_.tor' | while read FILE; do
sed -i '{s/pgtable_page_ctor/pgtable_pte_page_ctor/}' $FILE;
sed -i '{s/pgtable_page_dtor/pgtable_pte_page_dtor/}' $FILE;
done
----
... with the documentation re-flowed to remain under 80 columns, and
whitespace fixed up in macros to keep backslashes aligned.
There should be no functional change as a result of this patch.
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Mark Rutland <[email protected]>
Reviewed-by: Mike Rapoport <[email protected]>
Acked-by: Geert Uytterhoeven <[email protected]> [m68k]
Cc: Anshuman Khandual <[email protected]>
Cc: Matthew Wilcox <[email protected]>
Cc: Michal Hocko <[email protected]>
Cc: Yu Zhao <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
cc22c800e1
commit
b4ed71f557
26 changed files with 48 additions and 48 deletions
|
|
@ -2903,7 +2903,7 @@ pgtable_t pte_alloc_one(struct mm_struct *mm)
|
|||
struct page *page = alloc_page(GFP_KERNEL | __GFP_ZERO);
|
||||
if (!page)
|
||||
return NULL;
|
||||
if (!pgtable_page_ctor(page)) {
|
||||
if (!pgtable_pte_page_ctor(page)) {
|
||||
free_unref_page(page);
|
||||
return NULL;
|
||||
}
|
||||
|
|
@ -2919,7 +2919,7 @@ static void __pte_free(pgtable_t pte)
|
|||
{
|
||||
struct page *page = virt_to_page(pte);
|
||||
|
||||
pgtable_page_dtor(page);
|
||||
pgtable_pte_page_dtor(page);
|
||||
__free_page(page);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -378,7 +378,7 @@ pgtable_t pte_alloc_one(struct mm_struct *mm)
|
|||
if ((pte = (unsigned long)pte_alloc_one_kernel(mm)) == 0)
|
||||
return NULL;
|
||||
page = pfn_to_page(__nocache_pa(pte) >> PAGE_SHIFT);
|
||||
if (!pgtable_page_ctor(page)) {
|
||||
if (!pgtable_pte_page_ctor(page)) {
|
||||
__free_page(page);
|
||||
return NULL;
|
||||
}
|
||||
|
|
@ -389,7 +389,7 @@ void pte_free(struct mm_struct *mm, pgtable_t pte)
|
|||
{
|
||||
unsigned long p;
|
||||
|
||||
pgtable_page_dtor(pte);
|
||||
pgtable_pte_page_dtor(pte);
|
||||
p = (unsigned long)page_address(pte); /* Cached address (for test) */
|
||||
if (p == 0)
|
||||
BUG();
|
||||
|
|
|
|||
Loading…
Reference in a new issue