]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - include/coff/ti.h
Introduce new section flag: SEC_ELF_OCTETS
[thirdparty/binutils-gdb.git] / include / coff / ti.h
index 61010a21086858bf576659b6697213e652719321..17bac8c0fc5d3a19272fc7f51fdaf5eb68e093e3 100644 (file)
@@ -2,8 +2,7 @@
    customized in a target-specific file, and then this file included (see
    tic54x.h for an example).
    
-   Copyright 2000, 2001, 2002, 2003, 2005, 2008, 2009, 2010
-   Free Software Foundation, Inc.
+   Copyright (C) 2000-2019 Free Software Foundation, Inc.
 
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -314,9 +313,9 @@ struct external_scnhdr {
 /* TI COFF stores section size as number of bytes (address units, not octets),
    so adjust to be number of octets, which is what BFD expects */ 
 #define GET_SCNHDR_SIZE(ABFD, SZP) \
-  (H_GET_32 (ABFD, SZP) * bfd_octets_per_byte (ABFD))
+  (H_GET_32 (ABFD, SZP) * bfd_octets_per_byte (ABFD, NULL))
 #define PUT_SCNHDR_SIZE(ABFD, SZ, SZP) \
-  H_PUT_32 (ABFD, (SZ) / bfd_octets_per_byte (ABFD), SZP)
+  H_PUT_32 (ABFD, (SZ) / bfd_octets_per_byte (ABFD, NULL), SZP)
 
 #define COFF_ADJUST_SCNHDR_IN_POST(ABFD, EXT, INT) \
   do                                                                   \
@@ -472,9 +471,9 @@ union external_auxent {
 
 /* section lengths are in target bytes (not host bytes) */
 #define GET_SCN_SCNLEN(ABFD, EXT) \
-  (H_GET_32 (ABFD, (EXT)->x_scn.x_scnlen) * bfd_octets_per_byte (ABFD))
+  (H_GET_32 (ABFD, (EXT)->x_scn.x_scnlen) * bfd_octets_per_byte (ABFD, NULL))
 #define PUT_SCN_SCNLEN(ABFD, INT, EXT) \
-  H_PUT_32 (ABFD, (INT) / bfd_octets_per_byte (ABFD), (EXT)->x_scn.x_scnlen)
+  H_PUT_32 (ABFD, (INT) / bfd_octets_per_byte (ABFD, NULL), (EXT)->x_scn.x_scnlen)
 
 /* lnsz size is in bits in COFF file, in bytes in BFD */
 #define GET_LNSZ_SIZE(abfd, ext) \
@@ -546,6 +545,9 @@ struct external_reloc
 #define RELSZ_V0 10                 /* FIXME -- coffcode.h needs fixing */
 #define RELSZ 12                    /* for COFF1/2 */
 
+#define SWAP_OUT_RELOC_EXTRA(abfd, src, dst) \
+  do memset (dst->r_reserved, 0, sizeof (dst->r_reserved)); while (0)
+
 /* various relocation types.  */
 #define R_ABS     0x0000            /* no relocation */
 #define R_REL13   0x002A            /* 13-bit direct reference (???) */