summaryrefslogtreecommitdiff
path: root/target/linux/olpc
diff options
context:
space:
mode:
authorJens Muecke <jens@nons.de>2007-12-12 01:46:24 +0000
committerJens Muecke <jens@nons.de>2007-12-12 01:46:24 +0000
commita3d681bba552ca210d1795845bd1bf89a5c1b38d (patch)
tree88e21330080a61f690137dcc9de87ac12c6a6370 /target/linux/olpc
parent8b4ba82c0efe7848fecd5abba25d21cd56c5921e (diff)
downloadmtk-20170518-a3d681bba552ca210d1795845bd1bf89a5c1b38d.zip
mtk-20170518-a3d681bba552ca210d1795845bd1bf89a5c1b38d.tar.gz
mtk-20170518-a3d681bba552ca210d1795845bd1bf89a5c1b38d.tar.bz2
Removing Grub for olpc (unnecessary) Adding Bootscript Some SD-Card fixes Config changes
SVN-Revision: 9712
Diffstat (limited to 'target/linux/olpc')
-rw-r--r--target/linux/olpc/config-2.6.23123
-rw-r--r--target/linux/olpc/image/Config.in30
-rw-r--r--target/linux/olpc/image/Makefile38
-rwxr-xr-xtarget/linux/olpc/image/gen_image.sh12
-rw-r--r--target/linux/olpc/image/menu.lst15
-rw-r--r--target/linux/olpc/image/olpc.fth4
-rw-r--r--target/linux/olpc/patches/300-block2mtd_init.patch31
7 files changed, 76 insertions, 177 deletions
diff --git a/target/linux/olpc/config-2.6.23 b/target/linux/olpc/config-2.6.23
index 4597d43..99fe878 100644
--- a/target/linux/olpc/config-2.6.23
+++ b/target/linux/olpc/config-2.6.23
@@ -1,7 +1,5 @@
-# CONFIG_3C515 is not set
# CONFIG_60XX_WDT is not set
# CONFIG_8139TOO is not set
-# CONFIG_AC3200 is not set
# CONFIG_ACPI is not set
# CONFIG_ACQUIRE_WDT is not set
# CONFIG_ADVANTECH_WDT is not set
@@ -10,7 +8,6 @@
# CONFIG_ALIM1535_WDT is not set
# CONFIG_ALIM7101_WDT is not set
# CONFIG_APM is not set
-# CONFIG_APRICOT is not set
# CONFIG_ARCH_HAS_ILOG2_U32 is not set
# CONFIG_ARCH_HAS_ILOG2_U64 is not set
CONFIG_ARCH_MAY_HAVE_PC_FDC=y
@@ -18,9 +15,7 @@ CONFIG_ARCH_POPULATES_NODE_MAP=y
CONFIG_ARCH_SELECT_MEMORY_MODEL=y
CONFIG_ARCH_SPARSEMEM_ENABLE=y
CONFIG_ARCH_SUPPORTS_MSI=y
-# CONFIG_AT1700 is not set
# CONFIG_ATM is not set
-# CONFIG_AX25 is not set
CONFIG_BACKLIGHT_CLASS_DEVICE=y
CONFIG_BACKLIGHT_LCD_SUPPORT=y
# CONFIG_BACKLIGHT_PROGEAR is not set
@@ -31,15 +26,10 @@ CONFIG_BATTERY_OLPC=y
CONFIG_BINFMT_MISC=y
CONFIG_BITREVERSE=y
CONFIG_BLK_DEV_CRYPTOLOOP=y
-CONFIG_BLK_DEV_GENERIC=y
-# CONFIG_BLK_DEV_HD is not set
-# CONFIG_BLK_DEV_HD_IDE is not set
-# CONFIG_BLK_DEV_HPT34X is not set
-# CONFIG_BLK_DEV_HPT366 is not set
-CONFIG_BLK_DEV_IDE=y
-CONFIG_BLK_DEV_IDEDISK=y
+CONFIG_BLK_DEV_GENERIC=m
+CONFIG_BLK_DEV_IDE=m
+CONFIG_BLK_DEV_IDEDISK=m
CONFIG_BLK_DEV_IDEDMA=y
-# CONFIG_BLK_DEV_IDEDMA_FORCED is not set
CONFIG_BLK_DEV_IDEDMA_PCI=y
CONFIG_BLK_DEV_IDEPCI=y
CONFIG_BLK_DEV_LOOP=y
@@ -48,12 +38,11 @@ CONFIG_BLK_DEV_RAM=y
CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024
CONFIG_BLK_DEV_RAM_COUNT=16
CONFIG_BLK_DEV_RAM_SIZE=4096
-CONFIG_BLK_DEV_SC1200=y
+CONFIG_BLK_DEV_SC1200=m
CONFIG_BLK_DEV_SD=y
CONFIG_BLK_DEV_SR=y
CONFIG_BLK_DEV_SR_VENDOR=y
-CONFIG_BLK_DEV_VIA82CXXX=y
-# CONFIG_BLK_DEV_XD is not set
+CONFIG_BLK_DEV_VIA82CXXX=m
# CONFIG_BONDING is not set
CONFIG_BOUNCE=y
# CONFIG_BRIDGE_NF_EBTABLES is not set
@@ -64,7 +53,6 @@ CONFIG_CHR_DEV_SG=y
CONFIG_CLOCKSOURCE_WATCHDOG=y
CONFIG_COMPAT_VDSO=y
# CONFIG_CPU5_WDT is not set
-# CONFIG_CPUSETS is not set
# CONFIG_CPU_FREQ is not set
# CONFIG_CRC_ITU_T is not set
# CONFIG_CRYPTO_AES is not set
@@ -99,11 +87,9 @@ CONFIG_CRYPTO_MANAGER=y
# CONFIG_CRYPTO_TWOFISH_586 is not set
# CONFIG_CRYPTO_WP512 is not set
# CONFIG_CS5535_GPIO is not set
-# CONFIG_CS89x0 is not set
# CONFIG_DCDBAS is not set
# CONFIG_DEBUG_BUGVERBOSE is not set
# CONFIG_DELL_RBU is not set
-# CONFIG_DEPCA is not set
CONFIG_DEVPORT=y
# CONFIG_DISABLE_CONSOLE_SUSPEND is not set
CONFIG_DISPLAY_SUPPORT=y
@@ -117,13 +103,7 @@ CONFIG_EARLY_PRINTK=y
# CONFIG_EDAC is not set
# CONFIG_EDD is not set
# CONFIG_EEPROM_93CX6 is not set
-# CONFIG_EISA is not set
-# CONFIG_EL1 is not set
-# CONFIG_EL16 is not set
-# CONFIG_EL2 is not set
-# CONFIG_EL3 is not set
CONFIG_ELF_CORE=y
-# CONFIG_ELPLUS is not set
# CONFIG_EUROTECH_WDT is not set
CONFIG_EXT2_FS=y
# CONFIG_EXT3_FS is not set
@@ -195,8 +175,8 @@ CONFIG_GENERIC_CLOCKEVENTS_BROADCAST=y
CONFIG_GENERIC_CMOS_UPDATE=y
CONFIG_GENERIC_IOMAP=y
CONFIG_GENERIC_ISA_DMA=y
-CONFIG_GENERIC_PENDING_IRQ=y
CONFIG_GEODE_MFGPT_TIMER=y
+# CONFIG_HAMRADIO is not set
# CONFIG_HANGCHECK_TIMER is not set
CONFIG_HAS_DMA=y
CONFIG_HAS_IOMEM=y
@@ -205,14 +185,12 @@ CONFIG_HAS_IOPORT=y
# CONFIG_HFSPLUS_FS is not set
# CONFIG_HFS_FS is not set
CONFIG_HIBERNATION=y
-CONFIG_HIBERNATION_SMP_POSSIBLE=y
+CONFIG_HIBERNATION_UP_POSSIBLE=y
CONFIG_HID=y
CONFIG_HID_SUPPORT=y
# CONFIG_HIGHMEM4G is not set
# CONFIG_HIGHMEM64G is not set
-# CONFIG_HIGH_RES_TIMERS is not set
# CONFIG_HOSTAP is not set
-CONFIG_HOTPLUG_CPU=y
# CONFIG_HPET_TIMER is not set
CONFIG_HT_IRQ=y
# CONFIG_HUGETLBFS is not set
@@ -230,14 +208,11 @@ CONFIG_I2C_BOARDINFO=y
# CONFIG_IB700_WDT is not set
# CONFIG_IBMASR is not set
# CONFIG_IBM_ASM is not set
-CONFIG_IDE=y
-# CONFIG_IDEDMA_IVB is not set
-# CONFIG_IDEDMA_ONLYDISK is not set
-CONFIG_IDEPCI_PCIBUS_ORDER=y
+CONFIG_IDE=m
+# CONFIG_IDEPCI_PCIBUS_ORDER is not set
CONFIG_IDEPCI_SHARE_IRQ=y
# CONFIG_IDE_ARM is not set
-# CONFIG_IDE_CHIPSETS is not set
-CONFIG_IDE_GENERIC=y
+CONFIG_IDE_GENERIC=m
# CONFIG_IDE_PROC_FS is not set
# CONFIG_IEEE80211 is not set
# CONFIG_INET6_TUNNEL is not set
@@ -283,9 +258,7 @@ CONFIG_INSTRUMENTATION=y
# CONFIG_IP_NF_TARGET_TOS is not set
# CONFIG_IP_NF_TARGET_TTL is not set
# CONFIG_IP_NF_TARGET_ULOG is not set
-CONFIG_IRQBALANCE=y
-CONFIG_ISA=y
-CONFIG_ISAPNP=y
+# CONFIG_ISA is not set
CONFIG_ISA_DMA_API=y
# CONFIG_ISDN is not set
# CONFIG_ISO9660_FS is not set
@@ -303,10 +276,8 @@ CONFIG_KMOD=y
# CONFIG_KPROBES is not set
CONFIG_KTIME_SCALAR=y
# CONFIG_KVM is not set
-# CONFIG_LANCE is not set
CONFIG_LCD_CLASS_DEVICE=y
CONFIG_LOCALVERSION_AUTO=y
-CONFIG_LOCK_KERNEL=y
# CONFIG_LOGO is not set
# CONFIG_M386 is not set
# CONFIG_M486 is not set
@@ -316,19 +287,17 @@ CONFIG_LOCK_KERNEL=y
# CONFIG_M686 is not set
# CONFIG_MACHZ_WDT is not set
# CONFIG_MACINTOSH_DRIVERS is not set
-CONFIG_MATH_EMULATION=y
+# CONFIG_MATH_EMULATION is not set
# CONFIG_MCA is not set
# CONFIG_MCORE2 is not set
# CONFIG_MCRUSOE is not set
# CONFIG_MCYRIXIII is not set
-# CONFIG_MDA_CONSOLE is not set
# CONFIG_MEFFICEON is not set
# CONFIG_MGEODEGX1 is not set
CONFIG_MGEODE_LX=y
CONFIG_MICROCODE=y
CONFIG_MICROCODE_OLD_INTERFACE=y
# CONFIG_MINIX_FS is not set
-# CONFIG_MIXCOMWD is not set
# CONFIG_MK6 is not set
# CONFIG_MK7 is not set
# CONFIG_MK8 is not set
@@ -383,14 +352,14 @@ CONFIG_MTD_MAP_BANK_WIDTH_4=y
# CONFIG_MTD_MAP_BANK_WIDTH_8 is not set
# CONFIG_MTD_MTDRAM is not set
CONFIG_MTD_NAND=y
-# CONFIG_MTD_NAND_CAFE is not set
+CONFIG_MTD_NAND_CAFE=y
# CONFIG_MTD_NAND_CS553X is not set
# CONFIG_MTD_NAND_DISKONCHIP is not set
# CONFIG_MTD_NAND_ECC_SMC is not set
CONFIG_MTD_NAND_IDS=y
# CONFIG_MTD_NAND_MUSEUM_IDS is not set
# CONFIG_MTD_NAND_NANDSIM is not set
-CONFIG_MTD_NAND_PLATFORM=y
+# CONFIG_MTD_NAND_PLATFORM is not set
# CONFIG_MTD_NAND_VERIFY_WRITE is not set
# CONFIG_MTD_ONENAND is not set
CONFIG_MTD_OOPS=y
@@ -404,7 +373,7 @@ CONFIG_MTD_PCI=y
# CONFIG_MTD_ROM is not set
# CONFIG_MTD_SLRAM is not set
# CONFIG_MTD_TS5500 is not set
-CONFIG_MTRR=y
+# CONFIG_MTRR is not set
# CONFIG_MVIAC3_2 is not set
# CONFIG_MVIAC7 is not set
# CONFIG_MWINCHIP2 is not set
@@ -449,8 +418,6 @@ CONFIG_NETDEV_1000=y
# CONFIG_NET_SCH_TBF is not set
# CONFIG_NET_SCH_TEQL is not set
CONFIG_NET_VENDOR_3COM=y
-# CONFIG_NET_VENDOR_RACAL is not set
-# CONFIG_NET_VENDOR_SMC is not set
# CONFIG_NFSD is not set
# CONFIG_NFS_FS is not set
# CONFIG_NF_CONNTRACK_AMANDA is not set
@@ -466,8 +433,6 @@ CONFIG_NET_VENDOR_3COM=y
# CONFIG_NF_NAT_SNMP_BASIC is not set
# CONFIG_NLS is not set
CONFIG_NOHIGHMEM=y
-# CONFIG_NO_HZ is not set
-CONFIG_NR_CPUS=8
CONFIG_NR_QUICK=1
CONFIG_NSC_GPIO=m
CONFIG_NVRAM=y
@@ -478,8 +443,6 @@ CONFIG_PAGE_OFFSET=0xC0000000
# CONFIG_PARAVIRT is not set
CONFIG_PC8736x_GPIO=m
# CONFIG_PC87413_WDT is not set
-CONFIG_PCCARD=m
-CONFIG_PCCARD_NONSTATIC=m
# CONFIG_PCIEPORTBUS is not set
# CONFIG_PCIPCWATCHDOG is not set
CONFIG_PCI_DIRECT=y
@@ -490,8 +453,6 @@ CONFIG_PCI_DIRECT=y
CONFIG_PCI_GOOLPC=y
# CONFIG_PCI_MSI is not set
CONFIG_PCI_OLPC=y
-CONFIG_PCMCIA_PROBE=y
-# CONFIG_PCWATCHDOG is not set
# CONFIG_PDA_POWER is not set
CONFIG_PHYSICAL_ALIGN=0x100000
CONFIG_PHYSICAL_START=0x100000
@@ -499,22 +460,20 @@ CONFIG_PM=y
CONFIG_PM_DEBUG=y
CONFIG_PM_LEGACY=y
CONFIG_PM_SLEEP=y
-CONFIG_PM_SLEEP_SMP=y
CONFIG_PM_STD_PARTITION=""
# CONFIG_PM_TRACE is not set
# CONFIG_PM_VERBOSE is not set
-CONFIG_PNP=y
-# CONFIG_PNPACPI is not set
-# CONFIG_PNPBIOS is not set
-# CONFIG_PNP_DEBUG is not set
CONFIG_POWER_SUPPLY=y
# CONFIG_POWER_SUPPLY_DEBUG is not set
# CONFIG_PPP_MPPE is not set
# CONFIG_PPP_SYNC_TTY is not set
-CONFIG_PREEMPT_BKL=y
+# CONFIG_PREEMPT_NONE is not set
+CONFIG_PREEMPT_VOLUNTARY=y
# CONFIG_PRISM54 is not set
# CONFIG_PROMFS_FS is not set
CONFIG_QUICKLIST=y
+CONFIG_REED_SOLOMON=y
+CONFIG_REED_SOLOMON_DEC16=y
CONFIG_RELAY=y
# CONFIG_RELOCATABLE is not set
CONFIG_RTC=y
@@ -523,19 +482,13 @@ CONFIG_RWSEM_XCHGADD_ALGORITHM=y
# CONFIG_SBC_EPX_C3_WATCHDOG is not set
# CONFIG_SC1200_WDT is not set
# CONFIG_SC520_WDT is not set
-CONFIG_SCHED_MC=y
-CONFIG_SCHED_SMT=y
CONFIG_SCSI=y
CONFIG_SCSI_WAIT_SCAN=m
-CONFIG_SCx200=y
-CONFIG_SCx200HR_TIMER=y
+# CONFIG_SCx200 is not set
# CONFIG_SCx200_ACB is not set
-# CONFIG_SCx200_GPIO is not set
-CONFIG_SCx200_WDT=m
CONFIG_SEMAPHORE_SLEEPERS=y
# CONFIG_SERIAL_8250_EXTENDED is not set
CONFIG_SERIAL_8250_PCI=y
-CONFIG_SERIAL_8250_PNP=y
CONFIG_SERIO=y
# CONFIG_SERIO_CT82C710 is not set
CONFIG_SERIO_I8042=y
@@ -543,24 +496,35 @@ CONFIG_SERIO_LIBPS2=y
# CONFIG_SERIO_PCIPS2 is not set
# CONFIG_SERIO_RAW is not set
CONFIG_SERIO_SERPORT=y
-CONFIG_SMP=y
+# CONFIG_SMP is not set
# CONFIG_SMSC37B787_WDT is not set
# CONFIG_SOFT_WATCHDOG is not set
# CONFIG_SONYPI is not set
# CONFIG_SOUND is not set
CONFIG_SPARSEMEM_STATIC=y
-CONFIG_STOP_MACHINE=y
CONFIG_SUSPEND=y
-CONFIG_SUSPEND_SMP_POSSIBLE=y
CONFIG_SYSVIPC_SYSCTL=y
# CONFIG_TELCLOCK is not set
-# CONFIG_TICK_ONESHOT is not set
+CONFIG_TICK_ONESHOT=y
# CONFIG_TOSHIBA is not set
# CONFIG_TUN is not set
# CONFIG_TYPHOON is not set
# CONFIG_UDF_FS is not set
CONFIG_UID16=y
-# CONFIG_USB is not set
+CONFIG_USB=y
+# CONFIG_USBPCWATCHDOG is not set
+CONFIG_USB_EHCI_HCD=y
+CONFIG_USB_EHCI_ROOT_HUB_TT=y
+CONFIG_USB_EHCI_SPLIT_ISO=y
+CONFIG_USB_EHCI_TT_NEWSCHED=y
+# CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set
+# CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set
+CONFIG_USB_OHCI_HCD=y
+# CONFIG_USB_PERSIST is not set
+# CONFIG_USB_R8A66597_HCD is not set
+CONFIG_USB_STORAGE=y
+# CONFIG_USB_SUSPEND is not set
+CONFIG_USB_UHCI_HCD=y
# CONFIG_USER_NS is not set
# CONFIG_VFAT_FS is not set
CONFIG_VGACON_SOFT_SCROLLBACK=y
@@ -584,7 +548,6 @@ CONFIG_VT=y
CONFIG_VT_CONSOLE=y
# CONFIG_VT_HW_CONSOLE_BINDING is not set
# CONFIG_WAFER_WDT is not set
-# CONFIG_WDT is not set
CONFIG_X86=y
CONFIG_X86_32=y
# CONFIG_X86_BIGSMP is not set
@@ -597,15 +560,12 @@ CONFIG_X86_CMPXCHG=y
CONFIG_X86_FIND_SMP_CONFIG=y
CONFIG_X86_GENERIC=y
# CONFIG_X86_GENERICARCH is not set
-CONFIG_X86_HT=y
CONFIG_X86_INTEL_USERCOPY=y
CONFIG_X86_INVLPG=y
CONFIG_X86_IO_APIC=y
CONFIG_X86_L1_CACHE_SHIFT=7
CONFIG_X86_LOCAL_APIC=y
-CONFIG_X86_MCE=y
-# CONFIG_X86_MCE_NONFATAL is not set
-# CONFIG_X86_MCE_P4THERMAL is not set
+# CONFIG_X86_MCE is not set
CONFIG_X86_MINIMUM_CPU_FAMILY=4
CONFIG_X86_MPPARSE=y
# CONFIG_X86_MSR is not set
@@ -614,10 +574,10 @@ CONFIG_X86_MPPARSE=y
CONFIG_X86_PC=y
CONFIG_X86_POPAD_OK=y
# CONFIG_X86_REBOOTFIXUPS is not set
-CONFIG_X86_SMP=y
# CONFIG_X86_SUMMIT is not set
-CONFIG_X86_TRAMPOLINE=y
CONFIG_X86_TSC=y
+CONFIG_X86_UP_APIC=y
+CONFIG_X86_UP_IOAPIC=y
CONFIG_X86_USE_3DNOW=y
CONFIG_X86_USE_PPRO_CHECKSUM=y
# CONFIG_X86_VISWS is not set
@@ -625,8 +585,3 @@ CONFIG_X86_USE_PPRO_CHECKSUM=y
CONFIG_X86_WP_WORKS_OK=y
CONFIG_X86_XADD=y
# CONFIG_XFS_FS is not set
-CONFIG_YENTA_ENE_TUNE=y
-CONFIG_YENTA_O2=y
-CONFIG_YENTA_RICOH=y
-CONFIG_YENTA_TI=y
-CONFIG_YENTA_TOSHIBA=y
diff --git a/target/linux/olpc/image/Config.in b/target/linux/olpc/image/Config.in
index 6252ae6..295f916 100644
--- a/target/linux/olpc/image/Config.in
+++ b/target/linux/olpc/image/Config.in
@@ -1,35 +1,23 @@
-config OLPC_GRUB_IMAGES
- bool "Build GRUB images"
+config OLPC_BOOTSCRIPT_IMAGES
+ bool "Build images with bootscript"
depends TARGET_olpc
depends TARGET_ROOTFS_EXT2FS || TARGET_ROOTFS_JFFS2 || TARGET_ROOTFS_SQUASHFS || TARGET_ROOTFS_ISO
- select PACKAGE_grub
default y
-config OLPC_GRUB_IMAGES_PAD
- bool "Pad GRUB images to filesystem size (for JFFS2)"
- depends OLPC_GRUB_IMAGES
+config OLPC_BOOTSCRIPT_IMAGES_PAD
+ bool "Pad bootscript images to filesystem size (for JFFS2)"
+ depends OLPC_BOOTSCRIPT_IMAGES
-config OLPC_GRUB_BAUDRATE
- int "Serial port baud rate"
- depends OLPC_GRUB_IMAGES
- default 38400
-
-config OLPC_GRUB_KERNELPART
+config OLPC_BOOTSCRIPT_KERNELPART
int "Kernel partition size (in MB)"
- depends OLPC_GRUB_IMAGES
+ depends OLPC_BOOTSCRIPT_IMAGES
default 4
-config OLPC_GRUB_ROOTPART
+config OLPC_BOOTSCRIPT_ROOTPART
string
- prompt "Root partition on target device" if OLPC_GRUB_IMAGES
+ prompt "Root partition on target device" if OLPC_BOOTSCRIPT_IMAGES
default "/dev/hda2"
help
The root partition on the final device. If you don't know,
you probably want the default (/dev/hda2).
-config OLPC_GRUB_BOOTOPTS
- string
- prompt "Extra kernel boot options" if OLPC_GRUB_IMAGES
- default ""
- help
- If you don't know, just leave it blank.
diff --git a/target/linux/olpc/image/Makefile b/target/linux/olpc/image/Makefile
index b6d9504..b433ac4 100644
--- a/target/linux/olpc/image/Makefile
+++ b/target/linux/olpc/image/Makefile
@@ -8,12 +8,11 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/image.mk
export PATH=$(TARGET_PATH):/sbin
-BOOTOPTS=$(strip $(subst ",, $(CONFIG_OLPC_GRUB_BOOTOPTS)))
-ROOTPART=$(strip $(subst ",, $(CONFIG_OLPC_GRUB_ROOTPART)))
+ROOTPART=$(strip $(subst ",, $(CONFIG_OLPC_BOOTSCRIPT_ROOTPART)))
#"))")) # fix vim's broken syntax highlighting
-ifeq ($(CONFIG_OLPC_GRUB_IMAGES),y)
+ifeq ($(CONFIG_OLPC_BOOTSCRIPT_IMAGES),y)
define Image/cmdline/squashfs
block2mtd.block2mtd=$(ROOTPART),65536,rootfs root=/dev/mtdblock0 rootfstype=squashfs init=/etc/preinit
endef
@@ -30,37 +29,18 @@ ifeq ($(CONFIG_OLPC_GRUB_IMAGES),y)
root=$(ROOTPART) rootfstype=ext2 init=/etc/preinit
endef
- define Image/Build/grub
+ define Image/Build/bootscript
# left here because the image builder doesnt need these
- $(INSTALL_DIR) $(KDIR)/root.grub/boot/grub
- $(CP) \
- $(KDIR)/*stage* \
- $(KDIR)/root.grub/boot/grub/
- $(CP) $(KDIR)/bzImage $(KDIR)/root.grub/boot/vmlinuz
- $(CP) ./olpc.fth $(KDIR)/root.grub/boot/olpc.fth
- sed \
- -e 's#@CMDLINE@#$(strip $(call Image/cmdline/$(1))) $(BOOTOPTS)#g' \
- -e 's#@BAUDRATE@#$(CONFIG_OLPC_GRUB_BAUDRATE)#g' \
- ./menu.lst > $(KDIR)/root.grub/boot/grub/menu.lst
- PADDING="$(CONFIG_OLPC_GRUB_IMAGES_PAD)" PATH="$(TARGET_PATH)" ./gen_image.sh $(BIN_DIR)/openwrt-$(BOARD)-$(1).image $(CONFIG_OLPC_GRUB_KERNELPART) $(KDIR)/root.grub $(CONFIG_TARGET_ROOTFS_FSPART) $(KDIR)/root.$(1)
- $(call Image/Build/grub/$(1))
- endef
-endif
-
-ifeq ($(CONFIG_OLPC_GRUB_IMAGES),y)
- define Image/Prepare/grub
- # for the image builder
- $(CP) \
- $(STAGING_DIR_HOST)/usr/lib/grub/i386-pc/stage1 \
- $(STAGING_DIR_HOST)/usr/lib/grub/i386-pc/stage2 \
- $(STAGING_DIR_HOST)/usr/lib/grub/i386-pc/e2fs_stage1_5 \
- $(KDIR)/
+ $(INSTALL_DIR) $(KDIR)/root.bootscript/boot
+ $(CP) $(KDIR)/bzImage $(KDIR)/root.bootscript/boot/vmlinuz
+ $(CP) ./olpc.fth $(KDIR)/root.bootscript/boot/olpc.fth
+ PADDING="$(CONFIG_OLPC_BOOTSCRIPT_IMAGES_PAD)" PATH="$(TARGET_PATH)" ./gen_image.sh $(BIN_DIR)/openwrt-$(BOARD)-$(1).image $(CONFIG_OLPC_BOOTSCRIPT_KERNELPART) $(KDIR)/root.bootscript $(CONFIG_TARGET_ROOTFS_FSPART) $(KDIR)/root.$(1)
endef
endif
define Image/Prepare
$(CP) $(LINUX_DIR)/arch/i386/boot/bzImage $(KDIR)/bzImage
- $(call Image/Prepare/grub)
+ $(call Image/Prepare/bootscript)
endef
define Image/Build/squashfs
@@ -73,7 +53,7 @@ endef
define Image/Build
$(call Image/Build/$(1))
- $(call Image/Build/grub,$(1))
+ $(call Image/Build/bootscript,$(1))
$(CP) $(KDIR)/root.$(1) $(BIN_DIR)/openwrt-$(BOARD)-$(1).fs
$(CP) $(KDIR)/bzImage $(BIN_DIR)/openwrt-$(BOARD)-vmlinuz
endef
diff --git a/target/linux/olpc/image/gen_image.sh b/target/linux/olpc/image/gen_image.sh
index d48e372..4fd6e37 100755
--- a/target/linux/olpc/image/gen_image.sh
+++ b/target/linux/olpc/image/gen_image.sh
@@ -1,5 +1,5 @@
#!/usr/bin/env bash
-# Copyright (C) 2006 OpenWrt.org
+# Copyright (C) 2006 - 2007 OpenWrt.org
set -x
[ $# == 5 ] || {
echo "SYNTAX: $0 <file> <kernel size> <kernel directory> <rootfs size> <rootfs image>"
@@ -33,13 +33,3 @@ dd if="$OUTPUT.kernel" of="$OUTPUT" bs=512 seek="$KERNELOFFSET" conv=notrunc
[ -n "$PADDING" ] && dd if=/dev/zero of="$OUTPUT" bs=512 seek="$ROOTFSOFFSET" conv=notrunc count="$ROOTFSSIZE"
dd if="$ROOTFSIMAGE" of="$OUTPUT" bs=512 seek="$ROOTFSOFFSET" conv=notrunc
#rm -f "$OUTPUT.kernel"
-
-which chpax >/dev/null && chpax -zp $(which grub)
-grub --batch --no-curses --no-floppy --device-map=/dev/null <<EOF
-device (hd0) $OUTPUT
-geometry (hd0) $cyl $head $sect
-root (hd0,0)
-setup (hd0)
-quit
-EOF
-
diff --git a/target/linux/olpc/image/menu.lst b/target/linux/olpc/image/menu.lst
deleted file mode 100644
index cb306cc..0000000
--- a/target/linux/olpc/image/menu.lst
+++ /dev/null
@@ -1,15 +0,0 @@
-serial --unit=0 --speed=@BAUDRATE@ --word=8 --parity=no --stop=1
-terminal --timeout=2 console serial
-
-default 0
-timeout 5
-
-title OpenWrt
-root (hd0,0)
-kernel /boot/vmlinuz @CMDLINE@ noinitrd console=tty0 console=ttyS0,@BAUDRATE@n8 reboot=bios
-boot
-
-title OpenWrt (failsafe)
-root (hd0,0)
-kernel /boot/vmlinuz failsafe=true @CMDLINE@ noinitrd console=tty0 console=ttyS0,@BAUDRATE@n8 reboot=bios
-boot
diff --git a/target/linux/olpc/image/olpc.fth b/target/linux/olpc/image/olpc.fth
index 02c9c2e..048ab88 100644
--- a/target/linux/olpc/image/olpc.fth
+++ b/target/linux/olpc/image/olpc.fth
@@ -1,4 +1,4 @@
\ Boot script
-" sd:\boot\vmlinuz" to boot-device
-" block2mtd.block2mtd=/dev/mmcblk0p2,65536,rootfs root=/dev/mtdblock0 rootfstype=squashfs init=/etc/preinit noinitrd console=tty0" to boot-file
+" u:\boot\vmlinuz" to boot-device
+" block2mtd.block2mtd=/dev/sda2,65536,rootfs root=/dev/mtdblock1 rootfstype=squashfs init=/etc/preinit rootdelay=5 noinitrd console=tty0" to boot-file
boot
diff --git a/target/linux/olpc/patches/300-block2mtd_init.patch b/target/linux/olpc/patches/300-block2mtd_init.patch
index 5d81f2f..5e73131 100644
--- a/target/linux/olpc/patches/300-block2mtd_init.patch
+++ b/target/linux/olpc/patches/300-block2mtd_init.patch
@@ -1,16 +1,17 @@
Index: linux-2.6.23/drivers/mtd/devices/block2mtd.c
===================================================================
---- linux-2.6.23.orig/drivers/mtd/devices/block2mtd.c 2007-10-25 21:43:40.854599193 +0200
-+++ linux-2.6.23/drivers/mtd/devices/block2mtd.c 2007-10-25 22:23:19.066125745 +0200
-@@ -20,6 +20,7 @@
+--- linux-2.6.23.orig/drivers/mtd/devices/block2mtd.c 2007-12-06 23:30:31.583285849 +0100
++++ linux-2.6.23/drivers/mtd/devices/block2mtd.c 2007-12-06 23:31:29.970613152 +0100
+@@ -20,6 +20,8 @@
#include <linux/buffer_head.h>
#include <linux/mutex.h>
#include <linux/mount.h>
+#include <linux/list.h>
++#include <linux/delay.h>
#define VERSION "$Revision: 1.30 $"
-@@ -27,6 +28,12 @@
+@@ -27,6 +29,12 @@
#define ERROR(fmt, args...) printk(KERN_ERR "block2mtd: " fmt "\n" , ## args)
#define INFO(fmt, args...) printk(KERN_INFO "block2mtd: " fmt "\n" , ## args)
@@ -23,7 +24,7 @@ Index: linux-2.6.23/drivers/mtd/devices/block2mtd.c
/* Info for the block device */
struct block2mtd_dev {
-@@ -38,10 +45,36 @@
+@@ -38,10 +46,36 @@
char devname[0];
};
@@ -60,7 +61,7 @@ Index: linux-2.6.23/drivers/mtd/devices/block2mtd.c
static struct page *page_read(struct address_space *mapping, int index)
{
-@@ -518,7 +551,10 @@
+@@ -518,7 +552,10 @@
if (token[2] && (strlen(token[2]) + 1 > 80))
parse_err("mtd device name too long");
@@ -72,7 +73,7 @@ Index: linux-2.6.23/drivers/mtd/devices/block2mtd.c
return 0;
}
-@@ -534,8 +570,11 @@
+@@ -534,8 +571,11 @@
and block2mtd_init() has already been called,
we can parse the argument now. */
@@ -87,8 +88,8 @@ Index: linux-2.6.23/drivers/mtd/devices/block2mtd.c
here. We must parse them later: if the param passed
Index: linux-2.6.23/init/do_mounts.c
===================================================================
---- linux-2.6.23.orig/init/do_mounts.c 2007-10-25 21:39:41.824977672 +0200
-+++ linux-2.6.23/init/do_mounts.c 2007-10-25 21:41:22.466712918 +0200
+--- linux-2.6.23.orig/init/do_mounts.c 2007-12-06 23:30:28.019082737 +0100
++++ linux-2.6.23/init/do_mounts.c 2007-12-06 23:30:32.459335774 +0100
@@ -241,16 +241,8 @@
return 1;
}
@@ -127,8 +128,8 @@ Index: linux-2.6.23/init/do_mounts.c
if (!strncmp(root_device_name, "mtd", 3)) {
Index: linux-2.6.23/init/main.c
===================================================================
---- linux-2.6.23.orig/init/main.c 2007-10-25 21:35:50.567799083 +0200
-+++ linux-2.6.23/init/main.c 2007-10-25 21:56:43.279187031 +0200
+--- linux-2.6.23.orig/init/main.c 2007-12-06 23:30:28.023082962 +0100
++++ linux-2.6.23/init/main.c 2007-12-06 23:30:32.463336000 +0100
@@ -65,6 +65,7 @@
#ifdef CONFIG_X86_LOCAL_APIC
#include <asm/smp.h>
@@ -198,8 +199,8 @@ Index: linux-2.6.23/init/main.c
Index: linux-2.6.23/arch/i386/kernel/vmlinux.lds.S
===================================================================
---- linux-2.6.23.orig/arch/i386/kernel/vmlinux.lds.S 2007-10-26 00:07:08.465118962 +0200
-+++ linux-2.6.23/arch/i386/kernel/vmlinux.lds.S 2007-10-26 00:10:15.259763782 +0200
+--- linux-2.6.23.orig/arch/i386/kernel/vmlinux.lds.S 2007-12-06 23:30:28.035083650 +0100
++++ linux-2.6.23/arch/i386/kernel/vmlinux.lds.S 2007-12-06 23:30:32.467336225 +0100
@@ -146,6 +146,11 @@
INITCALLS
__initcall_end = .;
@@ -214,8 +215,8 @@ Index: linux-2.6.23/arch/i386/kernel/vmlinux.lds.S
*(.con_initcall.init)
Index: linux-2.6.23/include/asm-generic/vmlinux.lds.h
===================================================================
---- linux-2.6.23.orig/include/asm-generic/vmlinux.lds.h 2007-10-26 00:08:46.558708993 +0200
-+++ linux-2.6.23/include/asm-generic/vmlinux.lds.h 2007-10-26 00:09:24.296859571 +0200
+--- linux-2.6.23.orig/include/asm-generic/vmlinux.lds.h 2007-12-06 23:30:28.043084102 +0100
++++ linux-2.6.23/include/asm-generic/vmlinux.lds.h 2007-12-06 23:30:32.467336225 +0100
@@ -243,12 +243,14 @@
*(.initcall4s.init) \
*(.initcall5.init) \