diff options
Diffstat (limited to 'kernel/arch/sh/mm')
-rw-r--r-- | kernel/arch/sh/mm/hugetlbpage.c | 5 | ||||
-rw-r--r-- | kernel/arch/sh/mm/init.c | 9 | ||||
-rw-r--r-- | kernel/arch/sh/mm/numa.c | 4 |
3 files changed, 7 insertions, 11 deletions
diff --git a/kernel/arch/sh/mm/hugetlbpage.c b/kernel/arch/sh/mm/hugetlbpage.c index 534bc978a..6385f6020 100644 --- a/kernel/arch/sh/mm/hugetlbpage.c +++ b/kernel/arch/sh/mm/hugetlbpage.c @@ -62,11 +62,6 @@ pte_t *huge_pte_offset(struct mm_struct *mm, unsigned long addr) return pte; } -int huge_pmd_unshare(struct mm_struct *mm, unsigned long *addr, pte_t *ptep) -{ - return 0; -} - int pmd_huge(pmd_t pmd) { return 0; diff --git a/kernel/arch/sh/mm/init.c b/kernel/arch/sh/mm/init.c index 2790b6a64..75491862d 100644 --- a/kernel/arch/sh/mm/init.c +++ b/kernel/arch/sh/mm/init.c @@ -485,10 +485,10 @@ void free_initrd_mem(unsigned long start, unsigned long end) #endif #ifdef CONFIG_MEMORY_HOTPLUG -int arch_add_memory(int nid, u64 start, u64 size) +int arch_add_memory(int nid, u64 start, u64 size, bool for_device) { pg_data_t *pgdat; - unsigned long start_pfn = start >> PAGE_SHIFT; + unsigned long start_pfn = PFN_DOWN(start); unsigned long nr_pages = size >> PAGE_SHIFT; int ret; @@ -496,7 +496,8 @@ int arch_add_memory(int nid, u64 start, u64 size) /* We only have ZONE_NORMAL, so this is easy.. */ ret = __add_pages(nid, pgdat->node_zones + - zone_for_memory(nid, start, size, ZONE_NORMAL), + zone_for_memory(nid, start, size, ZONE_NORMAL, + for_device), start_pfn, nr_pages); if (unlikely(ret)) printk("%s: Failed, __add_pages() == %d\n", __func__, ret); @@ -517,7 +518,7 @@ EXPORT_SYMBOL_GPL(memory_add_physaddr_to_nid); #ifdef CONFIG_MEMORY_HOTREMOVE int arch_remove_memory(u64 start, u64 size) { - unsigned long start_pfn = start >> PAGE_SHIFT; + unsigned long start_pfn = PFN_DOWN(start); unsigned long nr_pages = size >> PAGE_SHIFT; struct zone *zone; int ret; diff --git a/kernel/arch/sh/mm/numa.c b/kernel/arch/sh/mm/numa.c index bce52ba66..05713d190 100644 --- a/kernel/arch/sh/mm/numa.c +++ b/kernel/arch/sh/mm/numa.c @@ -33,8 +33,8 @@ void __init setup_bootmem_node(int nid, unsigned long start, unsigned long end) /* Don't allow bogus node assignment */ BUG_ON(nid >= MAX_NUMNODES || nid <= 0); - start_pfn = start >> PAGE_SHIFT; - end_pfn = end >> PAGE_SHIFT; + start_pfn = PFN_DOWN(start); + end_pfn = PFN_DOWN(end); pmb_bolt_mapping((unsigned long)__va(start), start, end - start, PAGE_KERNEL); |