提交 b500f77b 编写于 作者: K Kefeng Wang 提交者: Ingo Molnar

x86/mm: Use PAGE_ALIGNED instead of IS_ALIGNED

Use PAGE_ALIGEND macro in <linux/mm.h> to simplify code.
Signed-off-by: NKefeng Wang <wangkefeng.wang@huawei.com>
Cc: <guohanjun@huawei.com>
Cc: Alexander Kuleshov <kuleshovmail@gmail.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: http://lkml.kernel.org/r/1452565170-11083-1-git-send-email-wangkefeng.wang@huawei.comSigned-off-by: NIngo Molnar <mingo@kernel.org>
上级 0f672809
...@@ -814,8 +814,7 @@ remove_pte_table(pte_t *pte_start, unsigned long addr, unsigned long end, ...@@ -814,8 +814,7 @@ remove_pte_table(pte_t *pte_start, unsigned long addr, unsigned long end,
if (phys_addr < (phys_addr_t)0x40000000) if (phys_addr < (phys_addr_t)0x40000000)
return; return;
if (IS_ALIGNED(addr, PAGE_SIZE) && if (PAGE_ALIGNED(addr) && PAGE_ALIGNED(next)) {
IS_ALIGNED(next, PAGE_SIZE)) {
/* /*
* Do not free direct mapping pages since they were * Do not free direct mapping pages since they were
* freed when offlining, or simplely not in use. * freed when offlining, or simplely not in use.
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册