From ee824ca663bb513ba3c2637e154b19f2ef373349 Mon Sep 17 00:00:00 2001 From: Stu Grossman Date: Tue, 14 Nov 1995 23:40:18 +0000 Subject: [PATCH] * monitor.c (monitor_load_srec monitor_make_srec): Move all S-record download code into srec.c. * srec.c srec.h: New files. Contain S-record loading routines formerly in monitor.c. * serial.c serial.h: New routine just like fprintf, but uses serial_t instead of FILE *. * sh-tdep.c (frame_find_saved_regs init_extra_frame_info): Don't add four to saved pc (makes things match manual). Also, fix bug where we didn't get pc from stack frame correctly. * config/sh/tm-sh.h (SAVED_PC_AFTER_CALL): Don't add four to saved pc. Real hardware does this for you. * sh3-rom.c (sh3_load): New routine. Sets up for download then calls generic S-record loader. * config/h8300/h8300.mt, config/h8500/h8500.mt, config/m68k/monitor.mt, config/pa/hppapro.mt, config/sh/sh.mt: Add srec.o to TDEPFILES. --- gdb/config/h8500/h8500.mt | 2 +- gdb/config/pa/hppapro.mt | 2 +- gdb/config/sh/sh.mt | 2 +- gdb/config/sh/tm-sh.h | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/gdb/config/h8500/h8500.mt b/gdb/config/h8500/h8500.mt index 711fdbe..6167761 100644 --- a/gdb/config/h8500/h8500.mt +++ b/gdb/config/h8500/h8500.mt @@ -1,5 +1,5 @@ # Target: H8500 with HMS monitor and H8 simulator -TDEPFILES= h8500-tdep.o monitor.o remote-hms.o +TDEPFILES= h8500-tdep.o monitor.o remote-hms.o srec.o TM_FILE= tm-h8500.h SIM_OBS = remote-sim.o diff --git a/gdb/config/pa/hppapro.mt b/gdb/config/pa/hppapro.mt index af4b188..b1d1cbb 100644 --- a/gdb/config/pa/hppapro.mt +++ b/gdb/config/pa/hppapro.mt @@ -1,3 +1,3 @@ # Target: PA based debug monitor -TDEPFILES= hppa-tdep.o op50-rom.o w89k-rom.o monitor.o xmodem.o +TDEPFILES= hppa-tdep.o op50-rom.o w89k-rom.o monitor.o xmodem.o srec.o TM_FILE= tm-pro.h diff --git a/gdb/config/sh/sh.mt b/gdb/config/sh/sh.mt index 6182b87..c08948b 100644 --- a/gdb/config/sh/sh.mt +++ b/gdb/config/sh/sh.mt @@ -1,5 +1,5 @@ # Target: Hitachi Super-H with ICE and simulator -TDEPFILES= sh-tdep.o monitor.o sh3-rom.o remote-e7000.o ser-e7kpc.o +TDEPFILES= sh-tdep.o monitor.o sh3-rom.o remote-e7000.o ser-e7kpc.o srec.o TM_FILE= tm-sh.h SIM_OBS = remote-sim.o diff --git a/gdb/config/sh/tm-sh.h b/gdb/config/sh/tm-sh.h index 8f56ebb..726cb96 100644 --- a/gdb/config/sh/tm-sh.h +++ b/gdb/config/sh/tm-sh.h @@ -49,7 +49,7 @@ extern CORE_ADDR sh_skip_prologue (); The return address is the value saved in the PR register + 4 */ #define SAVED_PC_AFTER_CALL(frame) \ - (ADDR_BITS_REMOVE(read_register(PR_REGNUM))+4) + (ADDR_BITS_REMOVE(read_register(PR_REGNUM))) /* Stack grows downward. */ -- 2.7.4