* [committed] MIPS: Complete `status' to `err' renaming in `mips_breakpoint_from_pc'
@ 2016-01-07 19:27 Maciej W. Rozycki
0 siblings, 0 replies; only message in thread
From: Maciej W. Rozycki @ 2016-01-07 19:27 UTC (permalink / raw)
To: gdb-patches
Complement commit d09f2c3f [target_read_memory&co: no longer return
target_xfer_status] and apply the same change made to the big-endian leg
of the function to the little-endian leg as well.
gdb/
* mips-tdep.c (mips_breakpoint_from_pc): Rename local `status'
to `err' in the little-endian leg.
diff --git a/gdb/mips-tdep.c b/gdb/mips-tdep.c
index c8e12e8..ca17864 100644
--- a/gdb/mips-tdep.c
+++ b/gdb/mips-tdep.c
@@ -7170,12 +7170,13 @@ mips_breakpoint_from_pc (struct gdbarch *gdbarch,
static gdb_byte micromips16_little_breakpoint[] = { 0x85, 0x46 };
static gdb_byte micromips32_little_breakpoint[] = { 0x5, 0, 0x7, 0 };
ULONGEST insn;
- int status;
+ int err;
int size;
- insn = mips_fetch_instruction (gdbarch, ISA_MICROMIPS, pc, &status);
- size = status ? 2
- : mips_insn_size (ISA_MICROMIPS, insn) == 2 ? 2 : 4;
+ insn = mips_fetch_instruction (gdbarch, ISA_MICROMIPS, pc, &err);
+ size = (err != 0
+ ? 2 : (mips_insn_size (ISA_MICROMIPS, insn) == 2
+ ? 2 : 4));
*pcptr = unmake_compact_addr (pc);
*lenptr = size;
return (size == 2) ? micromips16_little_breakpoint
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2016-01-07 19:27 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-01-07 19:27 [committed] MIPS: Complete `status' to `err' renaming in `mips_breakpoint_from_pc' Maciej W. Rozycki
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).