|
Re: weak declarations for set_breakpoint and remove_breakpoint: msg#00072linux.kernel.debugging.kgdb.bugs
On Tue, Jan 10, 2006 at 09:10:03PM +0530, Milind Dumbare wrote: > Patch attached below puts weak declaration of kgdb_arch_set_breakpoint & > kgdb_arch_remove_breakpoint in kernel/kgdb.c and changes > kgdb_activate_sw_breakpoints & kgdb_deactivate_sw_breakpoints > accordingly. [snip] > +return 0; > +} [snip] > +return 0; > +} Odd spacing. > @@ -776,26 +801,12 @@ > int kgdb_activate_sw_breakpoints(void) > { > int i; > - int error = 0; > unsigned long addr; > for (i = 0; i < MAX_BREAKPOINTS; i++) { > if (kgdb_break[i].state != bp_set) > continue; > addr = kgdb_break[i].bpt_addr; > - if (kgdb_ops->set_breakpoint) { > - if ((error = kgdb_ops->set_breakpoint(addr, > - kgdb_break[i].saved_instr)) < 0) > - return error; > - } else { > - if ((error = kgdb_get_mem((char *)addr, > - kgdb_break[i].saved_instr, > - BREAK_INSTR_SIZE)) < 0) > - return error; > - > - if ((error = kgdb_set_mem((char *)addr, > kgdb_ops->gdb_bpt_instr, > - BREAK_INSTR_SIZE)) < 0) > - return error; > - } > + kgdb_arch_set_breakpoint(addr, kgdb_break[i].saved_instr); This should be: if ((error = kgdb_arch_set_breakpoint(addr, kgdb_break[i].saved_instr)) return error; > @@ -850,21 +861,12 @@ > int kgdb_deactivate_sw_breakpoints(void) Same. -- Tom Rini http://gate.crashing.org/~trini/ ------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | weak declarations for set_breakpoint and remove_breakpoint: 00072, Milind Dumbare |
|---|---|
| Next by Date: | Re: Re: BUG: soft lockup detected on CPU#: 00072, Milind Dumbare |
| Previous by Thread: | weak declarations for set_breakpoint and remove_breakpointi: 00072, Milind Dumbare |
| Next by Thread: | Re: weak declarations for set_breakpoint and remove_breakpoint: 00072, Milind Dumbare |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |