summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>2008-11-07 22:46:22 +0100
committerWolfgang Denk <wd@denx.de>2008-12-07 01:29:31 +0100
commit1cb82a9207a550557399eabc7fe47f21bbd9ddf8 (patch)
tree9df13dd30f69b13e8901a24ee2bbc8a6abf17703
parentbcdf1d2cf6b24fb905fd7da80da4b3c65a7995b5 (diff)
drivers/bios_emulator: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
-rw-r--r--drivers/bios_emulator/Makefile3
-rw-r--r--drivers/bios_emulator/atibios.c5
-rw-r--r--drivers/bios_emulator/besys.c4
-rw-r--r--drivers/bios_emulator/bios.c4
-rw-r--r--drivers/bios_emulator/biosemu.c4
-rw-r--r--drivers/bios_emulator/x86emu/debug.c5
-rw-r--r--drivers/bios_emulator/x86emu/decode.c5
-rw-r--r--drivers/bios_emulator/x86emu/ops.c5
-rw-r--r--drivers/bios_emulator/x86emu/ops2.c5
-rw-r--r--drivers/bios_emulator/x86emu/prim_ops.c5
-rw-r--r--drivers/bios_emulator/x86emu/sys.c5
11 files changed, 2 insertions, 48 deletions
diff --git a/drivers/bios_emulator/Makefile b/drivers/bios_emulator/Makefile
index 90c64dad602..c73da97b474 100644
--- a/drivers/bios_emulator/Makefile
+++ b/drivers/bios_emulator/Makefile
@@ -6,7 +6,7 @@ X86DIR = x86emu
$(shell mkdir -p $(obj)$(X86DIR))
-COBJS = atibios.o biosemu.o besys.o bios.o \
+COBJS-$(CONFIG_BIOSEMU) = atibios.o biosemu.o besys.o bios.o \
$(X86DIR)/decode.o \
$(X86DIR)/ops2.o \
$(X86DIR)/ops.o \
@@ -14,6 +14,7 @@ COBJS = atibios.o biosemu.o besys.o bios.o \
$(X86DIR)/sys.o \
$(X86DIR)/debug.o
+COBJS := $(COBJS-y)
SRCS := $(COBJS:.o=.c)
OBJS := $(addprefix $(obj),$(COBJS))
diff --git a/drivers/bios_emulator/atibios.c b/drivers/bios_emulator/atibios.c
index 5779f99f1f6..d950b18478c 100644
--- a/drivers/bios_emulator/atibios.c
+++ b/drivers/bios_emulator/atibios.c
@@ -46,9 +46,6 @@
* BIOS in u-boot.
****************************************************************************/
#include <common.h>
-
-#ifdef CONFIG_BIOSEMU
-
#include "biosemui.h"
#include <malloc.h>
@@ -336,5 +333,3 @@ int BootVideoCardBIOS(pci_dev_t pcidev, BE_VGAInfo ** pVGAInfo, int cleanUp)
*pVGAInfo = VGAInfo;
return true;
}
-
-#endif
diff --git a/drivers/bios_emulator/besys.c b/drivers/bios_emulator/besys.c
index cb1b0c1b958..cbc5062ee52 100644
--- a/drivers/bios_emulator/besys.c
+++ b/drivers/bios_emulator/besys.c
@@ -48,9 +48,6 @@
****************************************************************************/
#include <common.h>
-
-#if defined(CONFIG_BIOSEMU)
-
#include "biosemui.h"
/*------------------------- Global Variables ------------------------------*/
@@ -721,4 +718,3 @@ void X86API BE_outl(X86EMU_pioAddr port, u32 val)
#endif
LOG_outpd(port, val);
}
-#endif
diff --git a/drivers/bios_emulator/bios.c b/drivers/bios_emulator/bios.c
index d41511c1d48..edda27622e8 100644
--- a/drivers/bios_emulator/bios.c
+++ b/drivers/bios_emulator/bios.c
@@ -42,9 +42,6 @@
****************************************************************************/
#include <common.h>
-
-#if defined(CONFIG_BIOSEMU)
-
#include "biosemui.h"
/*----------------------------- Implementation ----------------------------*/
@@ -323,4 +320,3 @@ void _BE_bios_init(u32 * intrTab)
bios_intr_tab[0x6D] = int10;
X86EMU_setupIntrFuncs(bios_intr_tab);
}
-#endif
diff --git a/drivers/bios_emulator/biosemu.c b/drivers/bios_emulator/biosemu.c
index decdb79a747..d0c65215778 100644
--- a/drivers/bios_emulator/biosemu.c
+++ b/drivers/bios_emulator/biosemu.c
@@ -47,9 +47,6 @@
#include <malloc.h>
#include <common.h>
-
-#if defined(CONFIG_BIOSEMU)
-
#include "biosemui.h"
BE_sysEnv _BE_env = {{0}};
@@ -372,4 +369,3 @@ int X86API BE_int86x(int intno, RMREGS * in, RMREGS * out, RMSREGS * sregs)
sregs->gs = M.x86.R_GS;
return out->x.ax;
}
-#endif
diff --git a/drivers/bios_emulator/x86emu/debug.c b/drivers/bios_emulator/x86emu/debug.c
index 29fe3f169ed..241acf3a89a 100644
--- a/drivers/bios_emulator/x86emu/debug.c
+++ b/drivers/bios_emulator/x86emu/debug.c
@@ -39,9 +39,6 @@
#include <stdarg.h>
#include <common.h>
-
-#if defined(CONFIG_BIOSEMU)
-
#include "x86emu/x86emui.h"
/*----------------------------- Implementation ----------------------------*/
@@ -463,5 +460,3 @@ void x86emu_dump_xregs(void)
printk("NC ");
printk("\n");
}
-
-#endif
diff --git a/drivers/bios_emulator/x86emu/decode.c b/drivers/bios_emulator/x86emu/decode.c
index 7a9a1ddbff9..a782b817b70 100644
--- a/drivers/bios_emulator/x86emu/decode.c
+++ b/drivers/bios_emulator/x86emu/decode.c
@@ -37,9 +37,6 @@
*
****************************************************************************/
#include <common.h>
-
-#if defined(CONFIG_BIOSEMU)
-
#include "x86emu/x86emui.h"
/*----------------------------- Implementation ----------------------------*/
@@ -1145,5 +1142,3 @@ unsigned decode_rmXX_address(int mod, int rm)
return decode_rm01_address(rm);
return decode_rm10_address(rm);
}
-
-#endif
diff --git a/drivers/bios_emulator/x86emu/ops.c b/drivers/bios_emulator/x86emu/ops.c
index 10f27579403..d63c99fd218 100644
--- a/drivers/bios_emulator/x86emu/ops.c
+++ b/drivers/bios_emulator/x86emu/ops.c
@@ -76,9 +76,6 @@
****************************************************************************/
#include <common.h>
-
-#if defined(CONFIG_BIOSEMU)
-
#include "x86emu/x86emui.h"
/*----------------------------- Implementation ----------------------------*/
@@ -5434,5 +5431,3 @@ void (*x86emu_optab[256])(u8) __attribute__ ((section(GOT2_TYPE))) =
/* 0xfe */ x86emuOp_opcFE_byte_RM,
/* 0xff */ x86emuOp_opcFF_word_RM,
};
-
-#endif
diff --git a/drivers/bios_emulator/x86emu/ops2.c b/drivers/bios_emulator/x86emu/ops2.c
index d90d36629fc..51e20e1c594 100644
--- a/drivers/bios_emulator/x86emu/ops2.c
+++ b/drivers/bios_emulator/x86emu/ops2.c
@@ -45,9 +45,6 @@
****************************************************************************/
#include <common.h>
-
-#if defined(CONFIG_BIOSEMU)
-
#include "x86emu/x86emui.h"
/*----------------------------- Implementation ----------------------------*/
@@ -1772,5 +1769,3 @@ void (*x86emu_optab2[256])(u8) __attribute__((section(GOT2_TYPE))) =
/* 0xfe */ x86emuOp2_illegal_op,
/* 0xff */ x86emuOp2_illegal_op,
};
-
-#endif
diff --git a/drivers/bios_emulator/x86emu/prim_ops.c b/drivers/bios_emulator/x86emu/prim_ops.c
index 2a254a4e671..7553087b263 100644
--- a/drivers/bios_emulator/x86emu/prim_ops.c
+++ b/drivers/bios_emulator/x86emu/prim_ops.c
@@ -100,9 +100,6 @@
#include <common.h>
#define PRIM_OPS_NO_REDEFINE_ASM
-
-#if defined(CONFIG_BIOSEMU)
-
#include "x86emu/x86emui.h"
/*------------------------- Global Variables ------------------------------*/
@@ -2448,5 +2445,3 @@ DB( if (CHECK_SP_ACCESS())
M.x86.R_SP += 4;
return res;
}
-
-#endif
diff --git a/drivers/bios_emulator/x86emu/sys.c b/drivers/bios_emulator/x86emu/sys.c
index dd44ff1e738..21f9730bece 100644
--- a/drivers/bios_emulator/x86emu/sys.c
+++ b/drivers/bios_emulator/x86emu/sys.c
@@ -40,9 +40,6 @@
****************************************************************************/
#include <common.h>
-
-#if defined(CONFIG_BIOSEMU)
-
#include "x86emu/x86emui.h"
/*------------------------- Global Variables ------------------------------*/
@@ -324,5 +321,3 @@ void X86EMU_prepareForInt(int num)
M.x86.R_IP = mem_access_word(num * 4);
M.x86.intr = 0;
}
-
-#endif