aboutsummaryrefslogtreecommitdiff
path: root/modutils/insmod.c
diff options
context:
space:
mode:
authorlandley <landley@69ca8d6d-28ef-0310-b511-8ec308f3f277>2006-03-04 22:40:25 +0000
committerlandley <landley@69ca8d6d-28ef-0310-b511-8ec308f3f277>2006-03-04 22:40:25 +0000
commitc75de5a0265065291fd66479e6214d9d9bb630a2 (patch)
tree123b85ec83aede5c1323d95297dc6d67f3b9e1f5 /modutils/insmod.c
parent6c391a67d3fb72ad56f1e5fddf62b5c687aae041 (diff)
downloadbusybox-w32-c75de5a0265065291fd66479e6214d9d9bb630a2.tar.gz
busybox-w32-c75de5a0265065291fd66479e6214d9d9bb630a2.tar.bz2
busybox-w32-c75de5a0265065291fd66479e6214d9d9bb630a2.zip
Patch from Robert P. Day, moving byte order checks to use platform.h macros.
git-svn-id: svn://busybox.net/trunk/busybox@14448 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'modutils/insmod.c')
-rw-r--r--modutils/insmod.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/modutils/insmod.c b/modutils/insmod.c
index d40012d70..14322d978 100644
--- a/modutils/insmod.c
+++ b/modutils/insmod.c
@@ -268,8 +268,8 @@ extern int insmod_ng_main( int argc, char **argv);
268#define CONFIG_USE_SINGLE 268#define CONFIG_USE_SINGLE
269/* the SH changes have only been tested in =little endian= mode */ 269/* the SH changes have only been tested in =little endian= mode */
270/* I'm not sure about big endian, so let's warn: */ 270/* I'm not sure about big endian, so let's warn: */
271#if defined(__sh__) && defined(__BIG_ENDIAN__) 271#if defined(__sh__) && BB_BIG_ENDIAN
272#error insmod.c may require changes for use on big endian SH 272# error insmod.c may require changes for use on big endian SH
273#endif 273#endif
274/* it may or may not work on the SH1/SH2... Error on those also */ 274/* it may or may not work on the SH1/SH2... Error on those also */
275#if ((!(defined(__SH3__) || defined(__SH4__) || defined(__SH5__)))) && (defined(__sh__)) 275#if ((!(defined(__SH3__) || defined(__SH4__) || defined(__SH5__)))) && (defined(__sh__))
@@ -511,10 +511,10 @@ static const int MODUTILS_OBJ_H = 1;
511#include <elf.h> 511#include <elf.h>
512#include <endian.h> 512#include <endian.h>
513 513
514#if __BYTE_ORDER == __LITTLE_ENDIAN 514#if BB_LITTLE_ENDIAN
515#define ELFDATAM ELFDATA2LSB 515# define ELFDATAM ELFDATA2LSB
516#elif __BYTE_ORDER == __BIG_ENDIAN 516#else
517#define ELFDATAM ELFDATA2MSB 517# define ELFDATAM ELFDATA2MSB
518#endif 518#endif
519 519
520#ifndef ElfW 520#ifndef ElfW