diff mbox

[committed] MIPS: Consistently use MIPS_FPU_TYPE for `gdbarch' member

Message ID alpine.DEB.2.00.1708011902430.29991@tp.orcam.me.uk
State Committed
Headers show

Commit Message

Maciej W. Rozycki Aug. 1, 2017, 6:34 p.m. UTC
Complement commit 74ed0bb4148e ("Replace current_gdbarch in *mips*"), 
<https://sourceware.org/ml/gdb-patches/2008-06/msg00490.html>, and 
consistently use the MIPS_FPU_TYPE macro to access the `->mips_fpu_type' 
target-dependent `gdbarch' member.  No functional change.

	gdb/
	* mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
	`->mips_fpu_type'.
---
 gdb/mips-tdep.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

gdb-mips-fpu-type-macro.diff
diff mbox

Patch

Index: binutils/gdb/mips-tdep.c
===================================================================
--- binutils.orig/gdb/mips-tdep.c	2017-08-01 19:02:18.568390767 +0100
+++ binutils/gdb/mips-tdep.c	2017-08-01 19:02:40.261562562 +0100
@@ -8445,7 +8445,7 @@  mips_gdbarch_init (struct gdbarch_info i
 	break;
       }
   else if (arches != NULL)
-    fpu_type = gdbarch_tdep (arches->gdbarch)->mips_fpu_type;
+    fpu_type = MIPS_FPU_TYPE (arches->gdbarch);
   else
     fpu_type = MIPS_FPU_DOUBLE;
   if (gdbarch_debug)
@@ -8485,7 +8485,7 @@  mips_gdbarch_init (struct gdbarch_info i
 	  != mips64_transfers_32bit_regs_p)
 	continue;
       /* Be pedantic about which FPU is selected.  */
-      if (gdbarch_tdep (arches->gdbarch)->mips_fpu_type != fpu_type)
+      if (MIPS_FPU_TYPE (arches->gdbarch) != fpu_type)
 	continue;
 
       if (tdesc_data != NULL)