From 1ed18ec1a386492c7905eaab54ac58d36c45966c Mon Sep 17 00:00:00 2001 From: Nick Clifton Date: Wed, 12 Apr 2000 17:59:32 +0000 Subject: [PATCH] Apply Andrew Cagney's patch to fix use of 'struct fix'. --- gas/ChangeLog | 9 +++++++++ gas/config/tc-d10v.c | 4 ++-- gas/config/tc-d10v.h | 6 +++++- 3 files changed, 16 insertions(+), 3 deletions(-) diff --git a/gas/ChangeLog b/gas/ChangeLog index c6651e5ffb7..db2a9fb400d 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,12 @@ +2000-04-12 Andrew Cagney + + * config/tc-d10v.h: Include "write.h" to get definition of fixS. + (md_pcrel_from_section): Add prototype. + (d10v_fix_adjustable): Add prototype. + (d10v_force_relocation): Replace 'struct fix' with 'fixS'. + + * config/tc-d10v.c (md_apply_fix3): Add paren around &&. + 2000-04-10 Alan Modra * config/tc-i386.c (fits_in_signed_byte): Change arg to offsetT. diff --git a/gas/config/tc-d10v.c b/gas/config/tc-d10v.c index d20ae10475f..f84dcb9fff6 100644 --- a/gas/config/tc-d10v.c +++ b/gas/config/tc-d10v.c @@ -1518,8 +1518,8 @@ md_apply_fix3 (fixp, valuep, seg) rep = (struct d10v_opcode *) hash_find (d10v_hash, "rep"); repi = (struct d10v_opcode *) hash_find (d10v_hash, "repi"); if ((insn & FM11) == FM11 - && (repi != NULL && (insn & repi->mask) == repi->opcode - || rep != NULL && (insn & rep->mask) == rep->opcode) + && ((repi != NULL && (insn & repi->mask) == repi->opcode) + || (rep != NULL && (insn & rep->mask) == rep->opcode)) && value < 4) as_fatal (_("line %d: rep or repi must include at least 4 instructions"), diff --git a/gas/config/tc-d10v.h b/gas/config/tc-d10v.h index 18e6e30b711..2f244a3b29a 100644 --- a/gas/config/tc-d10v.h +++ b/gas/config/tc-d10v.h @@ -19,6 +19,8 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ +#include "write.h" /* For the definition of fixS. */ + #define TC_D10V #define TARGET_BYTES_BIG_ENDIAN 0 @@ -36,6 +38,7 @@ /* call md_pcrel_from_section, not md_pcrel_from */ #define MD_PCREL_FROM_SECTION(FIXP, SEC) md_pcrel_from_section(FIXP, SEC) +long md_pcrel_from_section PARAMS ((fixS *, segT)); /* Permit temporary numeric labels. */ #define LOCAL_LABELS_FB 1 @@ -57,7 +60,8 @@ int d10v_cleanup PARAMS ((void)); } while (0) #define obj_fix_adjustable(fixP) d10v_fix_adjustable(fixP) +boolean d10v_fix_adjustable PARAMS ((fixS *)); #define TC_FORCE_RELOCATION(fixp) d10v_force_relocation(fixp) -extern int d10v_force_relocation PARAMS ((struct fix *)); +extern int d10v_force_relocation PARAMS ((fixS *)); #define md_flush_pending_output d10v_cleanup -- 2.30.2