aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/kgdb.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/kgdb.c')
-rw-r--r--kernel/kgdb.c16
1 files changed, 4 insertions, 12 deletions
diff --git a/kernel/kgdb.c b/kernel/kgdb.c
index 1bd0ec1c80b2..14787de568b3 100644
--- a/kernel/kgdb.c
+++ b/kernel/kgdb.c
@@ -61,7 +61,7 @@ struct kgdb_state {
61 int err_code; 61 int err_code;
62 int cpu; 62 int cpu;
63 int pass_exception; 63 int pass_exception;
64 long threadid; 64 unsigned long threadid;
65 long kgdb_usethreadid; 65 long kgdb_usethreadid;
66 struct pt_regs *linux_regs; 66 struct pt_regs *linux_regs;
67}; 67};
@@ -146,7 +146,7 @@ atomic_t kgdb_cpu_doing_single_step = ATOMIC_INIT(-1);
146 * the other CPUs might interfere with your debugging context, so 146 * the other CPUs might interfere with your debugging context, so
147 * use this with care: 147 * use this with care:
148 */ 148 */
149int kgdb_do_roundup = 1; 149static int kgdb_do_roundup = 1;
150 150
151static int __init opt_nokgdbroundup(char *str) 151static int __init opt_nokgdbroundup(char *str)
152{ 152{
@@ -346,14 +346,6 @@ static void put_packet(char *buffer)
346 } 346 }
347} 347}
348 348
349static char *pack_hex_byte(char *pkt, u8 byte)
350{
351 *pkt++ = hexchars[byte >> 4];
352 *pkt++ = hexchars[byte & 0xf];
353
354 return pkt;
355}
356
357/* 349/*
358 * Convert the memory pointed to by mem into hex, placing result in buf. 350 * Convert the memory pointed to by mem into hex, placing result in buf.
359 * Return a pointer to the last char put in buf (null). May return an error. 351 * Return a pointer to the last char put in buf (null). May return an error.
@@ -438,7 +430,7 @@ int kgdb_hex2mem(char *buf, char *mem, int count)
438 * While we find nice hex chars, build a long_val. 430 * While we find nice hex chars, build a long_val.
439 * Return number of chars processed. 431 * Return number of chars processed.
440 */ 432 */
441int kgdb_hex2long(char **ptr, long *long_val) 433int kgdb_hex2long(char **ptr, unsigned long *long_val)
442{ 434{
443 int hex_val; 435 int hex_val;
444 int num = 0; 436 int num = 0;
@@ -709,7 +701,7 @@ int kgdb_isremovedbreak(unsigned long addr)
709 return 0; 701 return 0;
710} 702}
711 703
712int remove_all_break(void) 704static int remove_all_break(void)
713{ 705{
714 unsigned long addr; 706 unsigned long addr;
715 int error; 707 int error;