From 2a7df081194176aa9f57e30899e9e31970c0712a Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Wed, 28 Feb 2007 18:25:14 +0000 Subject: [PATCH] mark uml as broken and add some cleanups (not working yet) SVN-Revision: 6439 --- target/Config.in | 4 + target/imagebuilder/Config.in | 1 + target/linux/uml-2.6/Makefile | 17 ++- target/linux/uml-2.6/config/{default => i386} | 28 ++--- target/linux/uml-2.6/config/x86_64 | 116 ++++++++++++++++++ toolchain/kernel-headers/Makefile | 12 +- 6 files changed, 153 insertions(+), 25 deletions(-) rename target/linux/uml-2.6/config/{default => i386} (87%) create mode 100644 target/linux/uml-2.6/config/x86_64 diff --git a/target/Config.in b/target/Config.in index 8ff7bee52b..780ee421fc 100644 --- a/target/Config.in +++ b/target/Config.in @@ -85,6 +85,9 @@ config sparc select BIG_ENDIAN bool +config x86_64 + bool + config ARCH string default "arm" if arm @@ -100,4 +103,5 @@ config ARCH default "sh4" if sh4 default "sh4eb" if sh4eb default "sparc" if sparc + default "x86_64" if x86_64 diff --git a/target/imagebuilder/Config.in b/target/imagebuilder/Config.in index 50b5825812..1615b60a4b 100644 --- a/target/imagebuilder/Config.in +++ b/target/imagebuilder/Config.in @@ -2,6 +2,7 @@ config IB bool "Build the OpenWrt Image Builder" depends !TARGET_ROOTFS_INITRAMFS depends !PROFILE_KCONFIG + depends !LINUX_2_6_UML default y if ALL help This is essentially a stripped-down version of the buildroot diff --git a/target/linux/uml-2.6/Makefile b/target/linux/uml-2.6/Makefile index 33bf8060fe..25624108ab 100644 --- a/target/linux/uml-2.6/Makefile +++ b/target/linux/uml-2.6/Makefile @@ -5,10 +5,25 @@ # See /LICENSE for more information. # include $(TOPDIR)/rules.mk +include $(INCLUDE_DIR)/host.mk -ARCH:=i386 +# UML only makes sense on linux +ifeq ($(HOST_OS),Linux) + +ARCH:=$(shell uname -m | sed \ + -e 's/i[3-9]86/i386/' \ + -e 's/mipsel/mips/' \ + -e 's/mipseb/mips/' \ + -e 's/powerpc/ppc/' \ + -e 's/sh[234]/sh/' \ + -e 's/armeb/arm/' \ +) BOARD:=uml BOARDNAME:=User Mode Linux +FEATURES:=broken +LINUX_CONFIG:=$(CURDIR)/config/$(ARCH) include $(INCLUDE_DIR)/kernel-build.mk +endif + $(eval $(call BuildKernel)) diff --git a/target/linux/uml-2.6/config/default b/target/linux/uml-2.6/config/i386 similarity index 87% rename from target/linux/uml-2.6/config/default rename to target/linux/uml-2.6/config/i386 index 53707e4062..ddfda832b7 100644 --- a/target/linux/uml-2.6/config/default +++ b/target/linux/uml-2.6/config/i386 @@ -1,7 +1,7 @@ CONFIG_3_LEVEL_PGTABLES=y -CONFIG_64BIT=y -# CONFIG_ARCH_HAS_SC_SIGNALS is not set -# CONFIG_ARCH_REUSE_HOST_VSYSCALL_AREA is not set +# CONFIG_64BIT is not set +CONFIG_ARCH_HAS_SC_SIGNALS=y +CONFIG_ARCH_REUSE_HOST_VSYSCALL_AREA=y # CONFIG_ATM is not set CONFIG_BASE_SMALL=0 CONFIG_BINFMT_MISC=m @@ -13,9 +13,7 @@ CONFIG_CON_CHAN="xterm" CONFIG_CON_ZERO_CHAN="fd:0,fd:1" CONFIG_CRAMFS=y # CONFIG_CRYPTO_AES_586 is not set -# CONFIG_CRYPTO_AES_X86_64 is not set # CONFIG_CRYPTO_TWOFISH_586 is not set -# CONFIG_CRYPTO_TWOFISH_X86_64 is not set CONFIG_DEFAULT_AS=y # CONFIG_DEFAULT_DEADLINE is not set CONFIG_DEFAULT_IOSCHED="anticipatory" @@ -49,7 +47,7 @@ CONFIG_KALLSYMS=y CONFIG_KALLSYMS_EXTRA_PASS=y CONFIG_KERNEL_STACK_ORDER=2 CONFIG_LBD=y -CONFIG_LD_SCRIPT_DYN=y +CONFIG_LD_SCRIPT_STATIC=y CONFIG_LEGACY_PTYS=y CONFIG_LEGACY_PTY_COUNT=256 # CONFIG_M386 is not set @@ -57,7 +55,7 @@ CONFIG_LEGACY_PTY_COUNT=256 # CONFIG_M586 is not set # CONFIG_M586MMX is not set # CONFIG_M586TSC is not set -CONFIG_M686=y +# CONFIG_M686 is not set # CONFIG_MAC_PARTITION is not set CONFIG_MAGIC_SYSRQ=y CONFIG_MCONSOLE=y @@ -73,7 +71,7 @@ CONFIG_MCONSOLE=y # CONFIG_MMAPPER is not set CONFIG_MODE_SKAS=y # CONFIG_MPENTIUM4 is not set -# CONFIG_MPENTIUMII is not set +CONFIG_MPENTIUMII=y # CONFIG_MPENTIUMIII is not set # CONFIG_MPENTIUMM is not set # CONFIG_MVIAC3_2 is not set @@ -104,23 +102,20 @@ CONFIG_QFMT_V2=y CONFIG_QUOTA=y CONFIG_QUOTACTL=y CONFIG_RELAY=y -CONFIG_RESOURCES_64BIT=y -CONFIG_RWSEM_GENERIC_SPINLOCK=y CONFIG_RWSEM_XCHGADD_ALGORITHM=y CONFIG_SEMAPHORE_SLEEPERS=y -CONFIG_SMP_BROKEN=y CONFIG_SOFT_WATCHDOG=m # CONFIG_SPARSEMEM_STATIC is not set CONFIG_SQUASHFS_EMBEDDED=y CONFIG_SSL=y CONFIG_SSL_CHAN="pty" -# CONFIG_STATIC_LINK is not set +CONFIG_STATIC_LINK=y CONFIG_STDERR_CONSOLE=y CONFIG_STDIO_CONSOLE=y -CONFIG_STUB_CODE=0x7fbfffe000 -CONFIG_STUB_DATA=0x7fbffff000 -CONFIG_STUB_START=0x7fbfffe000 -CONFIG_TOP_ADDR=0x80000000 +CONFIG_STUB_CODE=0xbfffe000 +CONFIG_STUB_DATA=0xbffff000 +CONFIG_STUB_START=0xbfffe000 +CONFIG_TOP_ADDR=0xC0000000 # CONFIG_TRACE_IRQFLAGS_SUPPORT is not set CONFIG_TTY_CHAN=y CONFIG_UID16=y @@ -150,7 +145,6 @@ CONFIG_X86_INTEL_USERCOPY=y CONFIG_X86_INVLPG=y CONFIG_X86_L1_CACHE_SHIFT=7 CONFIG_X86_POPAD_OK=y -CONFIG_X86_PPRO_FENCE=y CONFIG_X86_TSC=y CONFIG_X86_USE_PPRO_CHECKSUM=y CONFIG_X86_WP_WORKS_OK=y diff --git a/target/linux/uml-2.6/config/x86_64 b/target/linux/uml-2.6/config/x86_64 new file mode 100644 index 0000000000..12f1a105d4 --- /dev/null +++ b/target/linux/uml-2.6/config/x86_64 @@ -0,0 +1,116 @@ +CONFIG_3_LEVEL_PGTABLES=y +CONFIG_64BIT=y +# CONFIG_ARCH_HAS_SC_SIGNALS is not set +# CONFIG_ARCH_REUSE_HOST_VSYSCALL_AREA is not set +# CONFIG_ATM is not set +CONFIG_BASE_SMALL=0 +CONFIG_BINFMT_MISC=m +CONFIG_BLK_DEV_COW_COMMON=y +CONFIG_BLK_DEV_UBD=y +CONFIG_BLK_DEV_UBD_SYNC=y +# CONFIG_BT is not set +CONFIG_CON_CHAN="xterm" +CONFIG_CON_ZERO_CHAN="fd:0,fd:1" +CONFIG_CRAMFS=y +# CONFIG_CRYPTO_AES_X86_64 is not set +# CONFIG_CRYPTO_TWOFISH_X86_64 is not set +CONFIG_DEFAULT_AS=y +# CONFIG_DEFAULT_DEADLINE is not set +CONFIG_DEFAULT_IOSCHED="anticipatory" +CONFIG_DEFCONFIG_LIST="arch/$ARCH/defconfig" +CONFIG_DNOTIFY=y +CONFIG_ELF_CORE=y +# CONFIG_EMBEDDED is not set +CONFIG_EXT2_FS=y +CONFIG_EXT3_FS=y +CONFIG_FS_POSIX_ACL=y +# CONFIG_FW_LOADER is not set +# CONFIG_HAMRADIO is not set +CONFIG_HOSTAUDIO=m +CONFIG_HOSTFS=y +# CONFIG_HPPFS is not set +# CONFIG_HW_RANDOM is not set +# CONFIG_IFB is not set +CONFIG_INITRAMFS_SOURCE="" +CONFIG_INIT_ENV_ARG_LIMIT=128 +CONFIG_IOSCHED_AS=y +CONFIG_IOSCHED_CFQ=y +CONFIG_IRQ_RELEASE_METHOD=y +CONFIG_ISO9660_FS=y +CONFIG_JBD=y +CONFIG_KALLSYMS=y +CONFIG_KALLSYMS_EXTRA_PASS=y +CONFIG_KERNEL_STACK_ORDER=2 +CONFIG_LBD=y +CONFIG_LD_SCRIPT_STATIC=y +CONFIG_LEGACY_PTYS=y +CONFIG_LEGACY_PTY_COUNT=256 +# CONFIG_MAC_PARTITION is not set +CONFIG_MAGIC_SYSRQ=y +CONFIG_MCONSOLE=y +# CONFIG_MINI_FO is not set +# CONFIG_MMAPPER is not set +CONFIG_MODE_SKAS=y +CONFIG_NEST_LEVEL=0 +# CONFIG_NET_RADIO is not set +CONFIG_NET_SCH_CLK_GETTIMEOFDAY=y +# CONFIG_NET_SCH_CLK_JIFFIES is not set +CONFIG_NFSD_V2_ACL=y +CONFIG_NFSD_V3_ACL=y +# CONFIG_NFSD_V4 is not set +CONFIG_NFS_ACL_SUPPORT=m +CONFIG_NFS_V3_ACL=y +# CONFIG_NFS_V4 is not set +CONFIG_NLS=y +# CONFIG_NLS_CODEPAGE_850 is not set +# CONFIG_NLS_ISO8859_15 is not set +# CONFIG_NLS_KOI8_R is not set +# CONFIG_NOCONFIG_CHAN is not set +CONFIG_NULL_CHAN=y +CONFIG_PORT_CHAN=y +CONFIG_POSIX_MQUEUE=y +CONFIG_PTY_CHAN=y +CONFIG_QFMT_V1=y +CONFIG_QFMT_V2=y +CONFIG_QUOTA=y +CONFIG_QUOTACTL=y +CONFIG_RELAY=y +CONFIG_RESOURCES_64BIT=y +CONFIG_RWSEM_GENERIC_SPINLOCK=y +CONFIG_SEMAPHORE_SLEEPERS=y +CONFIG_SMP_BROKEN=y +CONFIG_SOFT_WATCHDOG=m +# CONFIG_SPARSEMEM_STATIC is not set +CONFIG_SQUASHFS_EMBEDDED=y +CONFIG_SSL=y +CONFIG_SSL_CHAN="pty" +CONFIG_STATIC_LINK=y +CONFIG_STDERR_CONSOLE=y +CONFIG_STDIO_CONSOLE=y +CONFIG_STUB_CODE=0x7fbfffe000 +CONFIG_STUB_DATA=0x7fbffff000 +CONFIG_STUB_START=0x7fbfffe000 +CONFIG_TOP_ADDR=0x80000000 +# CONFIG_TRACE_IRQFLAGS_SUPPORT is not set +CONFIG_TTY_CHAN=y +CONFIG_UID16=y +CONFIG_UML=y +CONFIG_UML_NET=y +CONFIG_UML_NET_DAEMON=y +CONFIG_UML_NET_ETHERTAP=y +CONFIG_UML_NET_MCAST=y +# CONFIG_UML_NET_PCAP is not set +CONFIG_UML_NET_SLIP=y +CONFIG_UML_NET_SLIRP=y +CONFIG_UML_NET_TUNTAP=y +CONFIG_UML_RANDOM=y +CONFIG_UML_REAL_TIME_CLOCK=y +CONFIG_UML_SOUND=m +CONFIG_UML_WATCHDOG=m +CONFIG_UML_X86=y +# CONFIG_UNUSED_SYMBOLS is not set +CONFIG_UNWIND_INFO=y +CONFIG_VM_EVENT_COUNTERS=y +CONFIG_XTERM_CHAN=y +CONFIG_ZISOFS_FS=y +CONFIG_ZLIB_DEFLATE=m diff --git a/toolchain/kernel-headers/Makefile b/toolchain/kernel-headers/Makefile index dbeb144c95..0ef907976d 100644 --- a/toolchain/kernel-headers/Makefile +++ b/toolchain/kernel-headers/Makefile @@ -33,15 +33,13 @@ define Build/Configure/powerpc endef ifneq (,$(findstring uml,$(BOARD))) - KMAKE := $(MAKE) -C $(PKG_BUILD_DIR) \ - ARCH=i386 \ - CONFIG_SHELL=$(BASH) -else - KMAKE := $(MAKE) -C $(PKG_BUILD_DIR) \ - ARCH=$(LINUX_KARCH) \ - CONFIG_SHELL=$(BASH) + LINUX_KARCH:=$(ARCH) endif +KMAKE := $(MAKE) -C $(PKG_BUILD_DIR) \ + ARCH=$(LINUX_KARCH) \ + CONFIG_SHELL=$(BASH) + define Build/Configure yes '' | $(KMAKE) oldconfig $(KMAKE) include/linux/version.h include/asm -- 2.25.1