Commit 6cc2baf6 authored by Michal Hocko's avatar Michal Hocko Committed by Linus Torvalds
Browse files

mm, memory_hotplug: drop pointless block alignment checks from __offline_pages

This function is never called from a context which would provide
misaligned pfn range so drop the pointless check.


Signed-off-by: default avatarMichal Hocko <>
Reviewed-by: default avatarAndrew Morton <>
Reviewed-by: default avatarOscar Salvador <>
Reviewed-by: default avatarAnshuman Khandual <>
Cc: Baoquan He <>
Cc: Oscar Salvador <>
Cc: William Kucharski <>
Signed-off-by: default avatarAndrew Morton <>
Signed-off-by: default avatarLinus Torvalds <>
parent e0392cf7
......@@ -1554,12 +1554,6 @@ static int __ref __offline_pages(unsigned long start_pfn,
struct zone *zone;
struct memory_notify arg;
/* at least, alignment against pageblock is necessary */
if (!IS_ALIGNED(start_pfn, pageblock_nr_pages))
return -EINVAL;
if (!IS_ALIGNED(end_pfn, pageblock_nr_pages))
return -EINVAL;
/* This makes hotplug much easier...and readable.
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment