[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4955B7EC.7050002@kernel.org>
Date: Fri, 26 Dec 2008 21:06:52 -0800
From: Yinghai Lu <yinghai@...nel.org>
To: Sam Ravnborg <sam@...nborg.org>,
David Howells <dhowells@...hat.com>, mingo@...e.hu
CC: Kamalesh Babulal <kamalesh@...ux.vnet.ibm.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Stephen Rothwell <sfr@...b.auug.org.au>,
linux-next@...r.kernel.org, LKML <linux-kernel@...r.kernel.org>,
mel@....ul.ie
Subject: [PATCH] kgdb: more barrier in blank weak function
Impact: fix panic possible panic etc
some compiler seems to inline the weak global function if no line in it
Signed-off-by: Yinghai Lu <yinghai@...nel.org>
diff --git a/kernel/kgdb.c b/kernel/kgdb.c
index e4dcfb2..70d2e36 100644
--- a/kernel/kgdb.c
+++ b/kernel/kgdb.c
@@ -223,7 +223,7 @@ int __weak kgdb_skipexception(int exception, struct pt_regs *regs)
void __weak
kgdb_post_primary_code(struct pt_regs *regs, int e_vector, int err_code)
{
- return;
+ barrier();
}
/**
@@ -236,6 +236,7 @@ kgdb_post_primary_code(struct pt_regs *regs, int e_vector, int err_code)
*/
void __weak kgdb_disable_hw_debug(struct pt_regs *regs)
{
+ barrier();
}
/*
--
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