From: vdmit11@gmail.com (Dmitry Vasilyanov)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: mm: fix address check in change_memory_common()
Date: Mon, 7 Mar 2016 16:17:18 +0300 [thread overview]
Message-ID: <1457356638-16410-1-git-send-email-vdmit11@gmail.com> (raw)
The (start >= MODULES_END) is checked twice.
The second check has no sense.
Clearly, the intention was: (end >= MODULE_CHECK).
Seems to be a typo, so this patch fixes it.
---
arch/arm/mm/pageattr.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm/mm/pageattr.c b/arch/arm/mm/pageattr.c
index d19b1ad..9edf6b0 100644
--- a/arch/arm/mm/pageattr.c
+++ b/arch/arm/mm/pageattr.c
@@ -55,7 +55,7 @@ static int change_memory_common(unsigned long addr, int numpages,
if (start < MODULES_VADDR || start >= MODULES_END)
return -EINVAL;
- if (end < MODULES_VADDR || start >= MODULES_END)
+ if (end < MODULES_VADDR || end >= MODULES_END)
return -EINVAL;
data.set_mask = set_mask;
--
2.1.4
reply other threads:[~2016-03-07 13:17 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1457356638-16410-1-git-send-email-vdmit11@gmail.com \
--to=vdmit11@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
/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;
as well as URLs for NNTP newsgroup(s).