* elf32-m68k.c: Update uses of EF_M68K_*.

binutils/
	* readelf.c: Update uses of EF_M68K_*.

gas/
	* config/tc-m68k.c: Update uses of EF_M68K_*.

include/elf
	* m68k.h (EF_M68K_ISA_MASK, EF_M68K_ISA_A_NODIV,
	EF_M68K_ISA_A, EF_M68K_ISA_A_PLUS, EF_M68K_ISA_B_NOUSP,
	EF_M68K_ISA_B, EF_M68K_ISA_C, EF_M68K_MAC_MASK, EF_M68K_MAC,
	EF_M68K_EMAC, EF_M68K_EMAC_B, EF_M68K_FLOAT): Rename to
	EF_M68K_CF_ISA_MASK, EF_M68K_CF_ISA_A_NODIV, EF_M68K_CF_ISA_A,
	EF_M68K_CF_ISA_A_PLUS, EF_M68K_CF_ISA_B_NOUSP,
	EF_M68K_CF_ISA_B, EF_M68K_CF_ISA_C, EF_M68K_CF_MAC_MASK,
	EF_M68K_CF_MAC, EF_M68K_CF_EMAC, EF_M68K_CF_EMAC_B,
	EF_M68K_CF_FLOAT, respectively.
This commit is contained in:
Kazu Hirata 2006-12-07 15:39:02 +00:00
parent e5d080028d
commit c694fd509c
8 changed files with 79 additions and 55 deletions

View File

@ -1,3 +1,7 @@
2006-12-07 Kazu Hirata <kazu@codesourcery.com>
* elf32-m68k.c: Update uses of EF_M68K_*.
2006-12-07 H.J. Lu <hjl@gnu.org>
PR ld/3666

View File

@ -433,36 +433,36 @@ elf32_m68k_object_p (bfd *abfd)
features |= m68000;
else if (eflags & EF_M68K_CPU32)
features |= cpu32;
else if (eflags & EF_M68K_ISA_MASK)
else if (eflags & EF_M68K_CF_ISA_MASK)
{
switch (eflags & EF_M68K_ISA_MASK)
switch (eflags & EF_M68K_CF_ISA_MASK)
{
case EF_M68K_ISA_A_NODIV:
case EF_M68K_CF_ISA_A_NODIV:
features |= mcfisa_a;
break;
case EF_M68K_ISA_A:
case EF_M68K_CF_ISA_A:
features |= mcfisa_a|mcfhwdiv;
break;
case EF_M68K_ISA_A_PLUS:
case EF_M68K_CF_ISA_A_PLUS:
features |= mcfisa_a|mcfisa_aa|mcfhwdiv|mcfusp;
break;
case EF_M68K_ISA_B_NOUSP:
case EF_M68K_CF_ISA_B_NOUSP:
features |= mcfisa_a|mcfisa_b|mcfhwdiv;
break;
case EF_M68K_ISA_B:
case EF_M68K_CF_ISA_B:
features |= mcfisa_a|mcfisa_b|mcfhwdiv|mcfusp;
break;
}
switch (eflags & EF_M68K_MAC_MASK)
switch (eflags & EF_M68K_CF_MAC_MASK)
{
case EF_M68K_MAC:
case EF_M68K_CF_MAC:
features |= mcfmac;
break;
case EF_M68K_EMAC:
case EF_M68K_CF_EMAC:
features |= mcfemac;
break;
}
if (eflags & EF_M68K_FLOAT)
if (eflags & EF_M68K_CF_FLOAT)
features |= cfloat;
}
@ -518,8 +518,8 @@ elf32_m68k_merge_private_bfd_data (ibfd, obfd)
else
{
out_flags = elf_elfheader (obfd)->e_flags;
in_isa = (in_flags & EF_M68K_ISA_MASK);
out_isa = (out_flags & EF_M68K_ISA_MASK);
in_isa = (in_flags & EF_M68K_CF_ISA_MASK);
out_isa = (out_flags & EF_M68K_CF_ISA_MASK);
if (in_isa > out_isa)
out_flags ^= in_isa ^ out_isa;
out_flags |= in_flags ^ in_isa;
@ -557,44 +557,44 @@ elf32_m68k_print_private_bfd_data (abfd, ptr)
if (eflags & EF_M68K_CFV4E)
fprintf (file, " [cfv4e]");
if (eflags & EF_M68K_ISA_MASK)
if (eflags & EF_M68K_CF_ISA_MASK)
{
char const *isa = _("unknown");
char const *mac = _("unknown");
char const *additional = "";
switch (eflags & EF_M68K_ISA_MASK)
switch (eflags & EF_M68K_CF_ISA_MASK)
{
case EF_M68K_ISA_A_NODIV:
case EF_M68K_CF_ISA_A_NODIV:
isa = "A";
additional = " [nodiv]";
break;
case EF_M68K_ISA_A:
case EF_M68K_CF_ISA_A:
isa = "A";
break;
case EF_M68K_ISA_A_PLUS:
case EF_M68K_CF_ISA_A_PLUS:
isa = "A+";
break;
case EF_M68K_ISA_B_NOUSP:
case EF_M68K_CF_ISA_B_NOUSP:
isa = "B";
additional = " [nousp]";
break;
case EF_M68K_ISA_B:
case EF_M68K_CF_ISA_B:
isa = "B";
break;
}
fprintf (file, " [isa %s]%s", isa, additional);
if (eflags & EF_M68K_FLOAT)
if (eflags & EF_M68K_CF_FLOAT)
fprintf (file, " [float]");
switch (eflags & EF_M68K_MAC_MASK)
switch (eflags & EF_M68K_CF_MAC_MASK)
{
case 0:
mac = NULL;
break;
case EF_M68K_MAC:
case EF_M68K_CF_MAC:
mac = "mac";
break;
case EF_M68K_EMAC:
case EF_M68K_CF_EMAC:
mac = "emac";
break;
}

View File

@ -1,3 +1,7 @@
2006-12-07 Kazu Hirata <kazu@codesourcery.com>
* readelf.c: Update uses of EF_M68K_*.
2006-10-30 Paul Brook <paul@codesourcery.com>
* objdump.c (disassemble_section): Set info->symtab_pos.

View File

@ -2016,29 +2016,29 @@ get_machine_flags (unsigned e_flags, unsigned e_machine)
strcat (buf, ", cpu32");
if (e_flags & EF_M68K_M68000)
strcat (buf, ", m68000");
if (e_flags & EF_M68K_ISA_MASK)
if (e_flags & EF_M68K_CF_ISA_MASK)
{
char const *isa = _("unknown");
char const *mac = _("unknown mac");
char const *additional = NULL;
switch (e_flags & EF_M68K_ISA_MASK)
switch (e_flags & EF_M68K_CF_ISA_MASK)
{
case EF_M68K_ISA_A_NODIV:
case EF_M68K_CF_ISA_A_NODIV:
isa = "A";
additional = ", nodiv";
break;
case EF_M68K_ISA_A:
case EF_M68K_CF_ISA_A:
isa = "A";
break;
case EF_M68K_ISA_A_PLUS:
case EF_M68K_CF_ISA_A_PLUS:
isa = "A+";
break;
case EF_M68K_ISA_B_NOUSP:
case EF_M68K_CF_ISA_B_NOUSP:
isa = "B";
additional = ", nousp";
break;
case EF_M68K_ISA_B:
case EF_M68K_CF_ISA_B:
isa = "B";
break;
}
@ -2046,17 +2046,17 @@ get_machine_flags (unsigned e_flags, unsigned e_machine)
strcat (buf, isa);
if (additional)
strcat (buf, additional);
if (e_flags & EF_M68K_FLOAT)
if (e_flags & EF_M68K_CF_FLOAT)
strcat (buf, ", float");
switch (e_flags & EF_M68K_MAC_MASK)
switch (e_flags & EF_M68K_CF_MAC_MASK)
{
case 0:
mac = NULL;
break;
case EF_M68K_MAC:
case EF_M68K_CF_MAC:
mac = "mac";
break;
case EF_M68K_EMAC:
case EF_M68K_CF_EMAC:
mac = "emac";
break;
}

View File

@ -1,3 +1,7 @@
2006-12-07 Kazu Hirata <kazu@codesourcery.com>
* config/tc-m68k.c: Update uses of EF_M68K_*.
2006-12-06 H.J. Lu <hjl@gnu.org>
* config/tc-i386.h: Change the prefix order to SEG_PREFIX,

View File

@ -7507,17 +7507,17 @@ m68k_elf_final_processing (void)
{
static const unsigned isa_features[][2] =
{
{EF_M68K_ISA_A_NODIV, mcfisa_a},
{EF_M68K_ISA_A, mcfisa_a|mcfhwdiv},
{EF_M68K_ISA_A_PLUS,mcfisa_a|mcfisa_aa|mcfhwdiv|mcfusp},
{EF_M68K_ISA_B_NOUSP,mcfisa_a|mcfisa_b|mcfhwdiv},
{EF_M68K_ISA_B, mcfisa_a|mcfisa_b|mcfhwdiv|mcfusp},
{EF_M68K_CF_ISA_A_NODIV, mcfisa_a},
{EF_M68K_CF_ISA_A, mcfisa_a|mcfhwdiv},
{EF_M68K_CF_ISA_A_PLUS,mcfisa_a|mcfisa_aa|mcfhwdiv|mcfusp},
{EF_M68K_CF_ISA_B_NOUSP,mcfisa_a|mcfisa_b|mcfhwdiv},
{EF_M68K_CF_ISA_B, mcfisa_a|mcfisa_b|mcfhwdiv|mcfusp},
{0,0},
};
static const unsigned mac_features[][2] =
{
{EF_M68K_MAC, mcfmac},
{EF_M68K_EMAC, mcfemac},
{EF_M68K_CF_MAC, mcfmac},
{EF_M68K_CF_EMAC, mcfemac},
{0,0},
};
unsigned ix;
@ -7541,7 +7541,7 @@ m68k_elf_final_processing (void)
else
{
if (current_architecture & cfloat)
flags |= EF_M68K_FLOAT | EF_M68K_CFV4E;
flags |= EF_M68K_CF_FLOAT | EF_M68K_CFV4E;
pattern = current_architecture & (mcfmac|mcfemac);
if (pattern)

View File

@ -1,3 +1,15 @@
2006-12-07 Kazu Hirata <kazu@codesourcery.com>
* m68k.h (EF_M68K_ISA_MASK, EF_M68K_ISA_A_NODIV,
EF_M68K_ISA_A, EF_M68K_ISA_A_PLUS, EF_M68K_ISA_B_NOUSP,
EF_M68K_ISA_B, EF_M68K_ISA_C, EF_M68K_MAC_MASK, EF_M68K_MAC,
EF_M68K_EMAC, EF_M68K_EMAC_B, EF_M68K_FLOAT): Rename to
EF_M68K_CF_ISA_MASK, EF_M68K_CF_ISA_A_NODIV, EF_M68K_CF_ISA_A,
EF_M68K_CF_ISA_A_PLUS, EF_M68K_CF_ISA_B_NOUSP,
EF_M68K_CF_ISA_B, EF_M68K_CF_ISA_C, EF_M68K_CF_MAC_MASK,
EF_M68K_CF_MAC, EF_M68K_CF_EMAC, EF_M68K_CF_EMAC_B,
EF_M68K_CF_FLOAT, respectively.
2006-12-05 Michael Tautschnig <tautschn@model.in.tum.de>
Nick Clifton <nickc@redhat.com>

View File

@ -58,18 +58,18 @@ END_RELOC_NUMBERS (R_68K_max)
/* We use the bottom 8 bits to encode information about the
coldfire variant. */
#define EF_M68K_ISA_MASK 0x0F /* Which ISA */
#define EF_M68K_ISA_A_NODIV 0x01 /* ISA A except for div */
#define EF_M68K_ISA_A 0x02
#define EF_M68K_ISA_A_PLUS 0x03
#define EF_M68K_ISA_B_NOUSP 0x04 /* ISA_B except for USP */
#define EF_M68K_ISA_B 0x05
#define EF_M68K_ISA_C 0x06
#define EF_M68K_MAC_MASK 0x30
#define EF_M68K_MAC 0x10 /* MAC */
#define EF_M68K_EMAC 0x20 /* EMAC */
#define EF_M68K_EMAC_B 0x30 /* EMAC_B */
#define EF_M68K_FLOAT 0x40 /* Has float insns */
#define EF_M68K_CF_ISA_MASK 0x0F /* Which ISA */
#define EF_M68K_CF_ISA_A_NODIV 0x01 /* ISA A except for div */
#define EF_M68K_CF_ISA_A 0x02
#define EF_M68K_CF_ISA_A_PLUS 0x03
#define EF_M68K_CF_ISA_B_NOUSP 0x04 /* ISA_B except for USP */
#define EF_M68K_CF_ISA_B 0x05
#define EF_M68K_CF_ISA_C 0x06
#define EF_M68K_CF_MAC_MASK 0x30
#define EF_M68K_CF_MAC 0x10 /* MAC */
#define EF_M68K_CF_EMAC 0x20 /* EMAC */
#define EF_M68K_CF_EMAC_B 0x30 /* EMAC_B */
#define EF_M68K_CF_FLOAT 0x40 /* Has float insns */
#define EF_M68K_CF_MASK 0xFF
#endif