1 /* SPDX-License-Identifier: GPL-2.0 */
3 * Copyright (C) 2002-2003 David McCullough <davidm@snapgear.com>
4 * Copyright (C) 1998 Kenneth Albanowski <kjahds@kjahds.com>
5 * The Silver Hammer Group, Ltd.
7 * This file provides the definitions and structures needed to
8 * support uClinux flat-format executables.
13 #include <uapi/linux/flat.h>
17 * While it would be nice to keep this header clean, users of older
18 * tools still need this support in the kernel. So this section is
19 * purely for compatibility with old tool chains.
21 * DO NOT make changes or enhancements to the old format please, just work
22 * with the format above, except to fix bugs with old format support.
25 #include <asm/byteorder.h>
27 #define OLD_FLAT_VERSION 0x00000002L
28 #define OLD_FLAT_RELOC_TYPE_TEXT 0
29 #define OLD_FLAT_RELOC_TYPE_DATA 1
30 #define OLD_FLAT_RELOC_TYPE_BSS 2
35 # if defined(mc68000) && !defined(CONFIG_COLDFIRE)
36 signed long offset : 30;
37 unsigned long type : 2;
38 # define OLD_FLAT_FLAG_RAM 0x1 /* load program entirely into RAM */
39 # elif defined(__BIG_ENDIAN_BITFIELD)
40 unsigned long type : 2;
41 signed long offset : 30;
42 # define OLD_FLAT_FLAG_RAM 0x1 /* load program entirely into RAM */
43 # elif defined(__LITTLE_ENDIAN_BITFIELD)
44 signed long offset : 30;
45 unsigned long type : 2;
46 # define OLD_FLAT_FLAG_RAM 0x1 /* load program entirely into RAM */
48 # error "Unknown bitfield order for flat files."
53 #endif /* _LINUX_FLAT_H */