aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/hw_breakpoint.c
diff options
context:
space:
mode:
authorJaswinder Singh Rajput <jaswinder@kernel.org>2009-06-17 05:14:19 -0400
committerIngo Molnar <mingo@elte.hu>2009-06-17 12:56:30 -0400
commit4555835b707d5c778ee1c9076670bc99b1eeaf61 (patch)
tree101b6e6f5c10aece8b1387e1218b4db5ef8d5ea7 /arch/x86/kernel/hw_breakpoint.c
parenteadb8a091b27a840de7450f84ecff5ef13476424 (diff)
x86: hw_breakpoint.c arch_check_va_in_kernelspace and hw_breakpoint_handler should be static
arch_check_va_in_kernelspace() and hw_breakpoint_handler() is used only by same file so it should be static. Also fixed non-ANSI function declaration of function 'arch_uninstall_thread_hw_breakpoint' Fixed following sparse warnings : arch/x86/kernel/hw_breakpoint.c:124:42: warning: non-ANSI function declaration of function 'arch_uninstall_thread_hw_breakpoint' arch/x86/kernel/hw_breakpoint.c:169:5: warning: symbol 'arch_check_va_in_kernelspace' was not declared. Should it be static? arch/x86/kernel/hw_breakpoint.c:313:15: warning: symbol 'hw_breakpoint_handler' was not declared. Should it be static? Signed-off-by: Jaswinder Singh Rajput <jaswinderrajput@gmail.com> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: "K.Prasad" <prasad@linux.vnet.ibm.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> LKML-Reference: <1245230059.2662.4.camel@ht.satnam> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/hw_breakpoint.c')
-rw-r--r--arch/x86/kernel/hw_breakpoint.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/x86/kernel/hw_breakpoint.c b/arch/x86/kernel/hw_breakpoint.c
index 51d959528b1d..9316a9de4de3 100644
--- a/arch/x86/kernel/hw_breakpoint.c
+++ b/arch/x86/kernel/hw_breakpoint.c
@@ -121,7 +121,7 @@ void arch_install_thread_hw_breakpoint(struct task_struct *tsk)
121/* 121/*
122 * Install the debug register values for just the kernel, no thread. 122 * Install the debug register values for just the kernel, no thread.
123 */ 123 */
124void arch_uninstall_thread_hw_breakpoint() 124void arch_uninstall_thread_hw_breakpoint(void)
125{ 125{
126 /* Clear the user-space portion of debugreg7 by setting only kdr7 */ 126 /* Clear the user-space portion of debugreg7 by setting only kdr7 */
127 set_debugreg(kdr7, 7); 127 set_debugreg(kdr7, 7);
@@ -166,7 +166,7 @@ int arch_check_va_in_userspace(unsigned long va, u8 hbp_len)
166/* 166/*
167 * Check for virtual address in kernel space. 167 * Check for virtual address in kernel space.
168 */ 168 */
169int arch_check_va_in_kernelspace(unsigned long va, u8 hbp_len) 169static int arch_check_va_in_kernelspace(unsigned long va, u8 hbp_len)
170{ 170{
171 unsigned int len; 171 unsigned int len;
172 172
@@ -310,7 +310,7 @@ void arch_flush_thread_hw_breakpoint(struct task_struct *tsk)
310 * NOTIFY_STOP returned for all other cases 310 * NOTIFY_STOP returned for all other cases
311 * 311 *
312 */ 312 */
313int __kprobes hw_breakpoint_handler(struct die_args *args) 313static int __kprobes hw_breakpoint_handler(struct die_args *args)
314{ 314{
315 int i, cpu, rc = NOTIFY_STOP; 315 int i, cpu, rc = NOTIFY_STOP;
316 struct hw_breakpoint *bp; 316 struct hw_breakpoint *bp;