[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1357772960-4436-4-git-send-email-sasha.levin@oracle.com>
Date: Wed, 9 Jan 2013 18:09:19 -0500
From: Sasha Levin <sasha.levin@...cle.com>
To: tglx@...utronix.de, mingo@...hat.com, hpa@...or.com,
rostedt@...dmis.org, fweisbec@...il.com, rusty@...tcorp.com.au,
ananth@...ibm.com, anil.s.keshavamurthy@...el.com,
masami.hiramatsu.pt@...achi.com, jbaron@...hat.com
Cc: x86@...nel.org, linux-kernel@...r.kernel.org,
Sasha Levin <sasha.levin@...cle.com>
Subject: [PATCH 4/5] alternatives: constify alternatives_text_reserved
Signed-off-by: Sasha Levin <sasha.levin@...cle.com>
---
arch/x86/include/asm/alternative.h | 4 ++--
arch/x86/kernel/alternative.c | 6 +++---
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/arch/x86/include/asm/alternative.h b/arch/x86/include/asm/alternative.h
index 58ed6d9..4d0d2fb 100644
--- a/arch/x86/include/asm/alternative.h
+++ b/arch/x86/include/asm/alternative.h
@@ -61,7 +61,7 @@ extern void alternatives_smp_module_add(struct module *mod, char *name,
void *text, void *text_end);
extern void alternatives_smp_module_del(struct module *mod);
extern void alternatives_enable_smp(void);
-extern int alternatives_text_reserved(void *start, void *end);
+extern int alternatives_text_reserved(const void *start, const void *end);
extern bool skip_smp_alternatives;
#else
static inline void alternatives_smp_module_add(struct module *mod, char *name,
@@ -69,7 +69,7 @@ static inline void alternatives_smp_module_add(struct module *mod, char *name,
void *text, void *text_end) {}
static inline void alternatives_smp_module_del(struct module *mod) {}
static inline void alternatives_enable_smp(void) {}
-static inline int alternatives_text_reserved(void *start, void *end)
+static inline int alternatives_text_reserved(const void *start, const void *end)
{
return 0;
}
diff --git a/arch/x86/kernel/alternative.c b/arch/x86/kernel/alternative.c
index ef5ccca..0994e41 100644
--- a/arch/x86/kernel/alternative.c
+++ b/arch/x86/kernel/alternative.c
@@ -431,12 +431,12 @@ void alternatives_enable_smp(void)
}
/* Return 1 if the address range is reserved for smp-alternatives */
-int alternatives_text_reserved(void *start, void *end)
+int alternatives_text_reserved(const void *start, const void *end)
{
struct smp_alt_module *mod;
const s32 *poff;
- u8 *text_start = start;
- u8 *text_end = end;
+ const u8 *text_start = start;
+ const u8 *text_end = end;
list_for_each_entry(mod, &smp_alt_modules, next) {
if (mod->text > text_end || mod->text_end < text_start)
--
1.8.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists