aboutsummaryrefslogtreecommitdiffstats
path: root/target
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2016-11-22 17:53:36 +0100
committerFelix Fietkau <nbd@nbd.name>2016-11-24 12:53:18 +0100
commit426e4d93bb2a36022f505d7dddeb7571dcd0b524 (patch)
treea8e8928a445775384f5cfe17cca1526b49057f1c /target
parent4081333084a4e52a125f678e905dbbcccb9e4bd0 (diff)
downloadupstream-426e4d93bb2a36022f505d7dddeb7571dcd0b524.tar.gz
upstream-426e4d93bb2a36022f505d7dddeb7571dcd0b524.tar.bz2
upstream-426e4d93bb2a36022f505d7dddeb7571dcd0b524.zip
uml: clean up the kernel config and add squashfs+ext4/f2fs support
Replaces plain ext4 images Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'target')
-rw-r--r--target/linux/uml/Makefile4
-rw-r--r--target/linux/uml/config/i38616
-rw-r--r--target/linux/uml/config/x86_6416
-rw-r--r--target/linux/uml/image/Makefile5
4 files changed, 22 insertions, 19 deletions
diff --git a/target/linux/uml/Makefile b/target/linux/uml/Makefile
index be27179151..91631391a7 100644
--- a/target/linux/uml/Makefile
+++ b/target/linux/uml/Makefile
@@ -20,7 +20,7 @@ ARCH:=$(shell uname -m | sed \
)
BOARD:=uml
BOARDNAME:=User Mode Linux
-FEATURES:=ext4 audio
+FEATURES:=squashfs ext4 audio
MAINTAINER:=Florian Fainelli <florian@openwrt.org>
KERNEL_PATCHVER:=4.4
@@ -35,7 +35,7 @@ endef
LINUX_TARGET_CONFIG:=$(CURDIR)/config/$(ARCH)
-DEFAULT_PACKAGES += wpad-mini kmod-mac80211-hwsim
+DEFAULT_PACKAGES += wpad-mini kmod-mac80211-hwsim mkf2fs e2fsprogs
endif
diff --git a/target/linux/uml/config/i386 b/target/linux/uml/config/i386
index 6893ee02fa..dd14784f2a 100644
--- a/target/linux/uml/config/i386
+++ b/target/linux/uml/config/i386
@@ -7,6 +7,7 @@ CONFIG_ARCH_HAS_SC_SIGNALS=y
CONFIG_ARCH_REUSE_HOST_VSYSCALL_AREA=y
CONFIG_ARCH_WANT_IPC_PARSE_VERSION=y
CONFIG_BLK_DEV_COW_COMMON=y
+CONFIG_BLK_DEV_LOOP=y
CONFIG_BLK_DEV_UBD=y
CONFIG_BLK_DEV_UBD_SYNC=y
CONFIG_CLONE_BACKWARDS=y
@@ -18,7 +19,6 @@ CONFIG_CPU_SUP_CYRIX_32=y
CONFIG_CPU_SUP_INTEL=y
CONFIG_CPU_SUP_TRANSMETA_32=y
CONFIG_CPU_SUP_UMC_32=y
-CONFIG_CRAMFS=y
# CONFIG_CRASHLOG is not set
CONFIG_CRC16=y
CONFIG_CRYPTO_CRC32C=y
@@ -37,6 +37,11 @@ CONFIG_DNOTIFY=y
# CONFIG_EARLY_PRINTK is not set
# CONFIG_EMBEDDED is not set
CONFIG_EXT4_FS=y
+# CONFIG_F2FS_CHECK_FS is not set
+CONFIG_F2FS_FS=y
+# CONFIG_F2FS_FS_SECURITY is not set
+CONFIG_F2FS_FS_XATTR=y
+CONFIG_F2FS_STAT_FS=y
CONFIG_FS_MBCACHE=y
CONFIG_GENERIC_BUG=y
CONFIG_GENERIC_CLOCKEVENTS=y
@@ -62,6 +67,8 @@ CONFIG_IOSCHED_CFQ=y
CONFIG_IRQ_WORK=y
CONFIG_ISO9660_FS=y
CONFIG_JBD2=y
+# CONFIG_JFFS2_CMODE_PRIORITY is not set
+# CONFIG_JFFS2_FS is not set
CONFIG_KALLSYMS=y
CONFIG_KERNEL_STACK_ORDER=2
CONFIG_LD_SCRIPT_STATIC=y
@@ -115,12 +122,6 @@ CONFIG_PRINT_QUOTA_WARNING=y
# CONFIG_PROCESSOR_SELECT is not set
CONFIG_PROC_PAGE_MONITOR=y
CONFIG_PTY_CHAN=y
-CONFIG_QFMT_V1=y
-CONFIG_QFMT_V2=y
-CONFIG_QUOTA=y
-CONFIG_QUOTACTL=y
-# CONFIG_QUOTA_NETLINK_INTERFACE is not set
-CONFIG_QUOTA_TREE=y
# CONFIG_RCU_STALL_COMMON is not set
CONFIG_RD_BZIP2=y
CONFIG_RD_GZIP=y
@@ -140,7 +141,6 @@ CONFIG_SSL_CHAN="pty"
CONFIG_STACKTRACE=y
CONFIG_STATIC_LINK=y
CONFIG_STDERR_CONSOLE=y
-# CONFIG_SUNXI_SRAM is not set
CONFIG_TICK_CPU_ACCOUNTING=y
# CONFIG_TRACE_IRQFLAGS_SUPPORT is not set
CONFIG_TTY_CHAN=y
diff --git a/target/linux/uml/config/x86_64 b/target/linux/uml/config/x86_64
index 29ef1c11ae..342a069684 100644
--- a/target/linux/uml/config/x86_64
+++ b/target/linux/uml/config/x86_64
@@ -7,6 +7,7 @@ CONFIG_ARCH_DEFCONFIG="arch/um/configs/x86_64_defconfig"
# CONFIG_ARCH_REUSE_HOST_VSYSCALL_AREA is not set
CONFIG_BINFMT_MISC=m
CONFIG_BLK_DEV_COW_COMMON=y
+CONFIG_BLK_DEV_LOOP=y
CONFIG_BLK_DEV_UBD=y
CONFIG_BLK_DEV_UBD_SYNC=y
CONFIG_CON_CHAN="xterm"
@@ -14,7 +15,6 @@ CONFIG_CON_ZERO_CHAN="fd:0,fd:1"
CONFIG_CPU_SUP_AMD=y
CONFIG_CPU_SUP_CENTAUR=y
CONFIG_CPU_SUP_INTEL=y
-CONFIG_CRAMFS=y
# CONFIG_CRASHLOG is not set
CONFIG_CRC16=y
# CONFIG_CRYPTO_AES_X86_64 is not set
@@ -37,6 +37,11 @@ CONFIG_DEFAULT_IOSCHED="cfq"
CONFIG_DNOTIFY=y
# CONFIG_EARLY_PRINTK is not set
CONFIG_EXT4_FS=y
+# CONFIG_F2FS_CHECK_FS is not set
+CONFIG_F2FS_FS=y
+# CONFIG_F2FS_FS_SECURITY is not set
+CONFIG_F2FS_FS_XATTR=y
+CONFIG_F2FS_STAT_FS=y
CONFIG_FS_MBCACHE=y
CONFIG_GENERIC_BUG=y
CONFIG_GENERIC_CLOCKEVENTS=y
@@ -63,6 +68,7 @@ CONFIG_IOSCHED_CFQ=y
CONFIG_IRQ_WORK=y
CONFIG_ISO9660_FS=y
CONFIG_JBD2=y
+# CONFIG_JFFS2_FS is not set
CONFIG_KALLSYMS=y
CONFIG_KERNEL_STACK_ORDER=2
CONFIG_LD_SCRIPT_STATIC=y
@@ -89,16 +95,9 @@ CONFIG_PHYS_ADDR_T_64BIT=y
CONFIG_PORT_CHAN=y
CONFIG_POSIX_MQUEUE=y
CONFIG_POSIX_MQUEUE_SYSCTL=y
-# CONFIG_PRINT_QUOTA_WARNING is not set
# CONFIG_PROCESSOR_SELECT is not set
CONFIG_PROC_PAGE_MONITOR=y
CONFIG_PTY_CHAN=y
-CONFIG_QFMT_V1=y
-CONFIG_QFMT_V2=y
-CONFIG_QUOTA=y
-CONFIG_QUOTACTL=y
-# CONFIG_QUOTA_NETLINK_INTERFACE is not set
-CONFIG_QUOTA_TREE=y
# CONFIG_RCU_STALL_COMMON is not set
CONFIG_RD_BZIP2=y
CONFIG_RD_GZIP=y
@@ -118,7 +117,6 @@ CONFIG_SSL_CHAN="pty"
CONFIG_STACKTRACE=y
CONFIG_STATIC_LINK=y
CONFIG_STDERR_CONSOLE=y
-# CONFIG_SUNXI_SRAM is not set
CONFIG_TICK_CPU_ACCOUNTING=y
# CONFIG_TRACE_IRQFLAGS_SUPPORT is not set
CONFIG_TTY_CHAN=y
diff --git a/target/linux/uml/image/Makefile b/target/linux/uml/image/Makefile
index 5e7247ecdd..8e83bfeecc 100644
--- a/target/linux/uml/image/Makefile
+++ b/target/linux/uml/image/Makefile
@@ -11,7 +11,12 @@ define Image/Prepare
cp $(LINUX_DIR)/linux $(KDIR)/vmlinux.elf
endef
+define Image/Build/squashfs
+ dd if=/dev/zero of=$(KDIR)/root.squashfs bs=1024k count=0 seek=$(CONFIG_TARGET_ROOTFS_PARTSIZE)
+endef
+
define Image/Build
+ $(call Image/Build/$(1))
cp $(KDIR)/root.$(1) $(BIN_DIR)/$(IMG_PREFIX)-$(1).img
cp $(KDIR)/vmlinux.elf $(BIN_DIR)/$(IMG_PREFIX)-vmlinux
endef