From: <wangkefeng.wang@huawei.com>
To: Ingo Molnar <mingo@redhat.com>, "H. Peter Anvin" <hpa@zytor.com>
Cc: Alexander Kuleshov <kuleshovmail@gmail.com>,
<guohanjun@huawei.com>, <linux-kernel@vger.kernel.org>
Subject: [PATCH] x86/mm: use PAGE_ALIGNED instead of IS_ALIGNED
Date: Tue, 12 Jan 2016 10:19:30 +0800 [thread overview]
Message-ID: <1452565170-11083-1-git-send-email-wangkefeng.wang@huawei.com> (raw)
From: Kefeng Wang <wangkefeng.wang@huawei.com>
Use PAGE_ALIGEND macro in <linux/mm.h> to simplify code.
Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>
---
arch/x86/mm/init_64.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/arch/x86/mm/init_64.c b/arch/x86/mm/init_64.c
index ec081fe..8829482 100644
--- a/arch/x86/mm/init_64.c
+++ b/arch/x86/mm/init_64.c
@@ -814,8 +814,7 @@ remove_pte_table(pte_t *pte_start, unsigned long addr, unsigned long end,
if (phys_addr < (phys_addr_t)0x40000000)
return;
- if (IS_ALIGNED(addr, PAGE_SIZE) &&
- IS_ALIGNED(next, PAGE_SIZE)) {
+ if (PAGE_ALIGNED(addr) && PAGE_ALIGNED(next)) {
/*
* Do not free direct mapping pages since they were
* freed when offlining, or simplely not in use.
--
2.6.0.GIT
next reply other threads:[~2016-01-12 2:20 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-12 2:19 wangkefeng.wang [this message]
2016-01-12 10:25 ` [tip:x86/urgent] x86/mm: Use " tip-bot for Kefeng Wang
2022-05-26 14:20 [PATCH] x86/mm: use " bh1scw
2022-05-27 2:00 ` Muchun Song
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1452565170-11083-1-git-send-email-wangkefeng.wang@huawei.com \
--to=wangkefeng.wang@huawei.com \
--cc=guohanjun@huawei.com \
--cc=hpa@zytor.com \
--cc=kuleshovmail@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®