From 2c83ecbd26706dbdaaa7ea9405cf9f3f7703f5ee Mon Sep 17 00:00:00 2001 From: André Fabian Silva Delgado Date: Thu, 25 Feb 2016 03:23:06 -0300 Subject: rename uboot packages with Extlinux support to uboot4extlinux --- .../0001-parabola-arm-modifications.patch | 243 ---------------- libre/uboot-am335x_bone/PKGBUILD | 53 ---- libre/uboot-am335x_bone/extlinux.conf | 46 --- libre/uboot-am335x_bone/uEnv.txt | 1 - libre/uboot-am335x_bone/uboot-am335x_bone.install | 37 --- .../0001-parabola-arm-modifications.patch | 312 --------------------- libre/uboot-omap3_beagle/PKGBUILD | 51 ---- libre/uboot-omap3_beagle/extlinux.conf | 46 --- libre/uboot-omap3_beagle/uEnv.txt | 0 .../uboot-omap3_beagle/uboot-omap3_beagle.install | 11 - .../0001-parabola-arm-modifications.patch | 135 --------- libre/uboot-omap4_panda/PKGBUILD | 49 ---- libre/uboot-omap4_panda/extlinux.conf | 46 --- libre/uboot-omap4_panda/uEnv.txt | 2 - libre/uboot-omap4_panda/uboot-omap4_panda.install | 26 -- .../0001-parabola-arm-modifications.patch | 243 ++++++++++++++++ libre/uboot4extlinux-am335x_bone/PKGBUILD | 53 ++++ libre/uboot4extlinux-am335x_bone/extlinux.conf | 46 +++ libre/uboot4extlinux-am335x_bone/uEnv.txt | 1 + .../uboot4extlinux-am335x_bone.install | 37 +++ .../0001-parabola-arm-modifications.patch | 312 +++++++++++++++++++++ libre/uboot4extlinux-omap3_beagle/PKGBUILD | 51 ++++ libre/uboot4extlinux-omap3_beagle/extlinux.conf | 46 +++ libre/uboot4extlinux-omap3_beagle/uEnv.txt | 0 .../uboot4extlinux-omap3_beagle.install | 11 + .../0001-parabola-arm-modifications.patch | 135 +++++++++ libre/uboot4extlinux-omap4_panda/PKGBUILD | 49 ++++ libre/uboot4extlinux-omap4_panda/extlinux.conf | 46 +++ libre/uboot4extlinux-omap4_panda/uEnv.txt | 2 + .../uboot4extlinux-omap4_panda.install | 26 ++ 30 files changed, 1058 insertions(+), 1058 deletions(-) delete mode 100644 libre/uboot-am335x_bone/0001-parabola-arm-modifications.patch delete mode 100644 libre/uboot-am335x_bone/PKGBUILD delete mode 100644 libre/uboot-am335x_bone/extlinux.conf delete mode 100644 libre/uboot-am335x_bone/uEnv.txt delete mode 100644 libre/uboot-am335x_bone/uboot-am335x_bone.install delete mode 100644 libre/uboot-omap3_beagle/0001-parabola-arm-modifications.patch delete mode 100644 libre/uboot-omap3_beagle/PKGBUILD delete mode 100644 libre/uboot-omap3_beagle/extlinux.conf delete mode 100644 libre/uboot-omap3_beagle/uEnv.txt delete mode 100644 libre/uboot-omap3_beagle/uboot-omap3_beagle.install delete mode 100644 libre/uboot-omap4_panda/0001-parabola-arm-modifications.patch delete mode 100644 libre/uboot-omap4_panda/PKGBUILD delete mode 100644 libre/uboot-omap4_panda/extlinux.conf delete mode 100644 libre/uboot-omap4_panda/uEnv.txt delete mode 100644 libre/uboot-omap4_panda/uboot-omap4_panda.install create mode 100644 libre/uboot4extlinux-am335x_bone/0001-parabola-arm-modifications.patch create mode 100644 libre/uboot4extlinux-am335x_bone/PKGBUILD create mode 100644 libre/uboot4extlinux-am335x_bone/extlinux.conf create mode 100644 libre/uboot4extlinux-am335x_bone/uEnv.txt create mode 100644 libre/uboot4extlinux-am335x_bone/uboot4extlinux-am335x_bone.install create mode 100644 libre/uboot4extlinux-omap3_beagle/0001-parabola-arm-modifications.patch create mode 100644 libre/uboot4extlinux-omap3_beagle/PKGBUILD create mode 100644 libre/uboot4extlinux-omap3_beagle/extlinux.conf create mode 100644 libre/uboot4extlinux-omap3_beagle/uEnv.txt create mode 100644 libre/uboot4extlinux-omap3_beagle/uboot4extlinux-omap3_beagle.install create mode 100644 libre/uboot4extlinux-omap4_panda/0001-parabola-arm-modifications.patch create mode 100644 libre/uboot4extlinux-omap4_panda/PKGBUILD create mode 100644 libre/uboot4extlinux-omap4_panda/extlinux.conf create mode 100644 libre/uboot4extlinux-omap4_panda/uEnv.txt create mode 100644 libre/uboot4extlinux-omap4_panda/uboot4extlinux-omap4_panda.install (limited to 'libre') diff --git a/libre/uboot-am335x_bone/0001-parabola-arm-modifications.patch b/libre/uboot-am335x_bone/0001-parabola-arm-modifications.patch deleted file mode 100644 index 0f1c145da..000000000 --- a/libre/uboot-am335x_bone/0001-parabola-arm-modifications.patch +++ /dev/null @@ -1,243 +0,0 @@ -diff -Nur u-boot-2015.04.orig/configs/am335x_evm_defconfig u-boot-2015.04/configs/am335x_evm_defconfig ---- u-boot-2015.04.orig/configs/am335x_evm_defconfig 2015-04-13 11:53:03.000000000 -0300 -+++ u-boot-2015.04/configs/am335x_evm_defconfig 2016-02-24 12:05:57.627551576 -0300 -@@ -1,7 +1,6 @@ - CONFIG_SPL=y - CONFIG_SPL_STACK_R=y - CONFIG_SPL_STACK_R_ADDR=0x82000000 --CONFIG_SYS_EXTRA_OPTIONS="NAND" --CONFIG_CONS_INDEX=1 -+CONFIG_SYS_EXTRA_OPTIONS="SERIAL1,CONS_INDEX=1" - CONFIG_ARM=y - CONFIG_TARGET_AM335X_EVM=y -diff -Nur u-boot-2015.04.orig/include/configs/am335x_evm.h u-boot-2015.04/include/configs/am335x_evm.h ---- u-boot-2015.04.orig/include/configs/am335x_evm.h 2015-04-13 11:53:03.000000000 -0300 -+++ u-boot-2015.04/include/configs/am335x_evm.h 2016-02-24 12:09:41.983016704 -0300 -@@ -17,6 +17,7 @@ - #define __CONFIG_AM335X_EVM_H - - #include -+#define CONFIG_ENV_IS_NOWHERE - - #ifndef CONFIG_SPL_BUILD - #ifndef CONFIG_FIT -@@ -45,6 +46,9 @@ - /* Enhance our eMMC support / experience. */ - #define CONFIG_CMD_GPT - #define CONFIG_EFI_PARTITION -+#define CONFIG_CMD_PART -+#define CONFIG_PARTITION_UUIDS -+#define CONFIG_CMD_SETEXPR - - #ifdef CONFIG_NAND - #define NANDARGS \ -@@ -67,113 +71,90 @@ - - #define CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG - -+/* Enable Extlinux boot support */ -+#define CONFIG_CMD_PXE -+#define CONFIG_MENU -+#define BOOT_TARGET_DEVICES(func) -+#include -+ - #ifndef CONFIG_SPL_BUILD - #define CONFIG_EXTRA_ENV_SETTINGS \ -+ BOOTENV \ - DEFAULT_LINUX_BOOT_ENV \ -- "boot_fdt=try\0" \ -- "bootpart=0:2\0" \ -+ "bootpart=0:1\0" \ - "bootdir=/boot\0" \ -+ "fdtdir=/boot/dtbs\0" \ - "bootfile=zImage\0" \ - "fdtfile=undefined\0" \ -+ "rdfile=initramfs-linux.img\0" \ - "console=ttyO0,115200n8\0" \ - "partitions=" \ - "uuid_disk=${uuid_gpt_disk};" \ - "name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}\0" \ - "optargs=\0" \ -- "mmcdev=0\0" \ -- "mmcroot=/dev/mmcblk0p2 ro\0" \ -- "mmcrootfstype=ext4 rootwait\0" \ -- "rootpath=/export/rootfs\0" \ -- "nfsopts=nolock\0" \ -- "static_ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}:${hostname}" \ -- "::off\0" \ -- "ramroot=/dev/ram0 rw\0" \ -- "ramrootfstype=ext2\0" \ -+ "cape_disable=\0" \ -+ "cape_enable=\0" \ -+ "cmdline=\0" \ - "mmcargs=setenv bootargs console=${console} " \ - "${optargs} " \ -- "root=${mmcroot} " \ -- "rootfstype=${mmcrootfstype}\0" \ -- "spiroot=/dev/mtdblock4 rw\0" \ -- "spirootfstype=jffs2\0" \ -- "spisrcaddr=0xe0000\0" \ -- "spiimgsize=0x362000\0" \ -- "spibusno=0\0" \ -- "spiargs=setenv bootargs console=${console} " \ -- "${optargs} " \ -- "root=${spiroot} " \ -- "rootfstype=${spirootfstype}\0" \ -- "netargs=setenv bootargs console=${console} " \ -- "${optargs} " \ -- "root=/dev/nfs " \ -- "nfsroot=${serverip}:${rootpath},${nfsopts} rw " \ -- "ip=dhcp\0" \ -- "bootenv=uEnv.txt\0" \ -- "loadbootscript=load mmc ${mmcdev} ${loadaddr} boot.scr\0" \ -- "bootscript=echo Running bootscript from mmc${mmcdev} ...; " \ -- "source ${loadaddr}\0" \ -- "loadbootenv=load mmc ${mmcdev} ${loadaddr} ${bootenv}\0" \ -- "importbootenv=echo Importing environment from mmc ...; " \ -- "env import -t -r $loadaddr $filesize\0" \ -- "ramargs=setenv bootargs console=${console} " \ -- "${optargs} " \ -- "root=${ramroot} " \ -- "rootfstype=${ramrootfstype}\0" \ -- "loadramdisk=load mmc ${mmcdev} ${rdaddr} ramdisk.gz\0" \ -- "loadimage=load mmc ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \ -- "loadfdt=load mmc ${bootpart} ${fdtaddr} ${bootdir}/${fdtfile}\0" \ -- "mmcloados=run mmcargs; " \ -- "if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \ -- "if run loadfdt; then " \ -- "bootz ${loadaddr} - ${fdtaddr}; " \ -- "else " \ -- "if test ${boot_fdt} = try; then " \ -- "bootz; " \ -- "else " \ -- "echo WARN: Cannot load the DT; " \ -- "fi; " \ -- "fi; " \ -- "else " \ -- "bootz; " \ -- "fi;\0" \ -- "mmcboot=mmc dev ${mmcdev}; " \ -- "if mmc rescan; then " \ -- "echo SD/MMC found on device ${mmcdev};" \ -- "if run loadbootscript; then " \ -- "run bootscript;" \ -- "else " \ -- "if run loadbootenv; then " \ -- "echo Loaded environment from ${bootenv};" \ -- "run importbootenv;" \ -+ "${cape_disable} " \ -+ "${cape_enable} " \ -+ "root=${root} " \ -+ "${cmdline}\0" \ -+ "loadimage=load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \ -+ "loadrd=load ${devtype} ${bootpart} ${rdaddr} ${bootdir}/${rdfile}\0" \ -+ "loadfdt=echo loading ${fdtdir}/${fdtfile} ...; load ${devtype} ${bootpart} ${fdtaddr} ${fdtdir}/${fdtfile}\0" \ -+ "mmcboot=usb start;" \ -+ "for devtype in mmc usb; do " \ -+ "for devnum in 0 1; do " \ -+ "if ${devtype} dev ${devnum}; then " \ -+ "echo ${devtype} found on device ${devnum};" \ -+ "setenv bootpart ${devnum}:1;" \ -+ "part uuid ${devtype} ${bootpart} uuid;" \ -+ "setenv root PARTUUID=${uuid} rw rootwait fixrtc;" \ -+ "echo Checking for: ${bootdir}/uEnv.txt ...;" \ -+ "gpio set 54;" \ -+ "if test -e ${devtype} ${bootpart} ${bootdir}/uEnv.txt; then " \ -+ "load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/uEnv.txt;" \ -+ "env import -t ${loadaddr} ${filesize};" \ -+ "echo Loaded environment from ${bootdir}/uEnv.txt;" \ -+ "if test -n ${cape}; then " \ -+ "if test -e ${devtype} ${bootpart} ${fdtdir}/${fdtbase}-${cape}.dtb; then " \ -+ "setenv fdtfile ${fdtbase}-${cape}.dtb; " \ -+ "fi; " \ -+ "echo using: $fdtfile...; " \ -+ "fi; " \ -+ "echo Checking if uenvcmd is set ...;" \ -+ "if test -n ${uenvcmd}; then " \ -+ "echo Running uenvcmd ...;" \ -+ "run uenvcmd;" \ -+ "fi;" \ -+ "fi;" \ -+ "gpio set 55;" \ -+ "run scan_dev_for_boot;" \ -+ "if run loadimage; then " \ -+ "run mmcargs;" \ -+ "if run loadfdt; then " \ -+ "gpio set 56;" \ -+ "if run loadrd; then " \ -+ "bootz ${loadaddr} ${rdaddr}:${filesize} ${fdtaddr};" \ -+ "else " \ -+ "bootz ${loadaddr} - ${fdtaddr};" \ -+ "fi;" \ -+ "fi;" \ -+ "else " \ -+ "echo No kernel found;" \ -+ "fi;" \ -+ "gpio clear 54; gpio clear 55;" \ -+ "setexpr devnum ${devnum} + 1;" \ - "fi;" \ -- "if test -n $uenvcmd; then " \ -- "echo Running uenvcmd ...;" \ -- "run uenvcmd;" \ -- "fi;" \ -- "if run loadimage; then " \ -- "run mmcloados;" \ -- "fi;" \ -- "fi ;" \ -- "fi;\0" \ -- "spiboot=echo Booting from spi ...; " \ -- "run spiargs; " \ -- "sf probe ${spibusno}:0; " \ -- "sf read ${loadaddr} ${spisrcaddr} ${spiimgsize}; " \ -- "bootz ${loadaddr}\0" \ -- "netboot=echo Booting from network ...; " \ -- "setenv autoload no; " \ -- "dhcp; " \ -- "tftp ${loadaddr} ${bootfile}; " \ -- "tftp ${fdtaddr} ${fdtfile}; " \ -- "run netargs; " \ -- "bootz ${loadaddr} - ${fdtaddr}\0" \ -- "ramboot=echo Booting from ramdisk ...; " \ -- "run ramargs; " \ -- "bootz ${loadaddr} ${rdaddr} ${fdtaddr}\0" \ -+ "done;" \ -+ "done;\0" \ - "findfdt="\ - "if test $board_name = A335BONE; then " \ -- "setenv fdtfile am335x-bone.dtb; fi; " \ -+ "setenv fdtfile am335x-bone.dtb; setenv fdtbase am335x-bone; fi; " \ - "if test $board_name = A335BNLT; then " \ -- "setenv fdtfile am335x-boneblack.dtb; fi; " \ -+ "setenv fdtfile am335x-boneblack.dtb; setenv fdtbase am335x-boneblack; setenv umsmedia 1; fi; " \ - "if test $board_name = A33515BB; then " \ - "setenv fdtfile am335x-evm.dtb; fi; " \ - "if test $board_name = A335X_SK; then " \ -@@ -185,12 +166,11 @@ - #endif - - #define CONFIG_BOOTCOMMAND \ -- "run findfdt; " \ -- "run mmcboot;" \ -- "setenv mmcdev 1; " \ -- "setenv bootpart 1:2; " \ -+ "gpio set 53;" \ -+ "run findfdt;" \ - "run mmcboot;" \ -- "run nandboot;" -+ "gpio clear 54; gpio clear 55;" \ -+ "gpio set 56" - - /* NS16550 Configuration */ - #define CONFIG_SYS_NS16550_COM1 0x44e09000 /* Base EVM has UART0 */ -@@ -329,9 +309,8 @@ - #endif - - #ifdef CONFIG_MUSB_GADGET --#define CONFIG_USB_ETHER --#define CONFIG_USB_ETH_RNDIS --#define CONFIG_USBNET_HOST_ADDR "de:ad:be:af:00:00" -+#define CONFIG_CMD_USB_MASS_STORAGE -+#define CONFIG_USB_GADGET_MASS_STORAGE - - /* USB TI's IDs */ - #define CONFIG_G_DNL_VENDOR_NUM 0x0451 diff --git a/libre/uboot-am335x_bone/PKGBUILD b/libre/uboot-am335x_bone/PKGBUILD deleted file mode 100644 index 5b7051f91..000000000 --- a/libre/uboot-am335x_bone/PKGBUILD +++ /dev/null @@ -1,53 +0,0 @@ -# U-Boot: BeagleBone and BeagleBone Black -# Maintainer: André Silva -# Contributor: Jookia <166291@gmail.com> -# Contributor: Márcio Silva - -buildarch=4 - -pkgname=uboot-am335x_bone -pkgver=2015.04 -pkgrel=7 -pkgdesc="U-Boot for BeagleBone and BeagleBone Black" -arch=('armv7h') -url="http://git.denx.de/u-boot.git/" -replaces=('uboot-beaglebone-linux-libre' 'uboot-beaglebone-linux-libre-lts' - 'uboot-beaglebone-linux-libre-grsec' 'uboot-beaglebone-linux-libre-pck' - 'uboot-beaglebone') -conflicts=('uboot-beaglebone-linux-libre' 'uboot-beaglebone-linux-libre-lts' - 'uboot-beaglebone-linux-libre-grsec' 'uboot-beaglebone-linux-libre-pck' - 'uboot-beaglebone' 'uboot4grub-am335x_bone') -makedepends=('bc') -license=('GPL') -backup=(boot/extlinux/extlinux.conf) -install=${pkgname}.install -source=("ftp://ftp.denx.de/pub/u-boot/u-boot-${pkgver}.tar.bz2" - '0001-parabola-arm-modifications.patch' - 'extlinux.conf' - 'uEnv.txt') -md5sums=('570bdc2c47270c2a98ca60ff6c5c74cd' - '37784c8f8f52a615d65e775018d237fb' - '068f6b4e8047115e73f29af5f384889b' - 'ccb79775b81654e16fca18825c7f2506') - -prepare() { - cd u-boot-${pkgver} - patch -Np1 -i ../0001-parabola-arm-modifications.patch -} - -build() { - cd u-boot-${pkgver} - - unset CFLAGS CXXFLAGS LDFLAGS - - make distclean - make am335x_evm_config - make -} - -package() { - cd u-boot-${pkgver} - mkdir -p "${pkgdir}"/boot/extlinux - cp MLO u-boot.img "${srcdir}"/uEnv.txt "${pkgdir}"/boot - cp "${srcdir}"/extlinux.conf "${pkgdir}"/boot/extlinux -} diff --git a/libre/uboot-am335x_bone/extlinux.conf b/libre/uboot-am335x_bone/extlinux.conf deleted file mode 100644 index 52de94d49..000000000 --- a/libre/uboot-am335x_bone/extlinux.conf +++ /dev/null @@ -1,46 +0,0 @@ -menu title Welcome to U-Boot with Extlinux support! - -label Parabola GNU/Linux-libre, linux-libre kernel - kernel /boot/vmlinuz-linux-libre - append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 - fdtdir /boot/dtbs/linux-libre - -#label Parabola GNU/Linux-libre, linux-libre-lts kernel -# kernel /boot/vmlinuz-linux-libre-lts -# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 -# fdtdir /boot/dtbs/linux-libre-lts - -#label Parabola GNU/Linux-libre, linux-libre-knock kernel -# kernel /boot/vmlinuz-linux-libre-knock -# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 -# fdtdir /boot/dtbs/linux-libre-knock - -#label Parabola GNU/Linux-libre, linux-libre-lts-knock kernel -# kernel /boot/vmlinuz-linux-libre-lts-knock -# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 -# fdtdir /boot/dtbs/linux-libre-lts-knock - -#label Parabola GNU/Linux-libre, linux-libre-grsec kernel -# kernel /boot/vmlinuz-linux-libre-grsec -# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 -# fdtdir /boot/dtbs/linux-libre-grsec - -#label Parabola GNU/Linux-libre, linux-libre-grsec-knock kernel -# kernel /boot/vmlinuz-linux-libre-grsec-knock -# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 -# fdtdir /boot/dtbs/linux-libre-grsec-knock - -#label Parabola GNU/Linux-libre, linux-libre-audit kernel -# kernel /boot/vmlinuz-linux-libre-audit -# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 -# fdtdir /boot/dtbs/linux-libre-audit - -#label Parabola GNU/Linux-libre, linux-libre-pck kernel -# kernel /boot/vmlinuz-linux-libre-pck -# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 -# fdtdir /boot/dtbs/linux-libre-pck - -#label Parabola GNU/Linux-libre, linux-libre-rt kernel -# kernel /boot/vmlinuz-linux-libre-rt -# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 -# fdtdir /boot/dtbs/linux-libre-rt diff --git a/libre/uboot-am335x_bone/uEnv.txt b/libre/uboot-am335x_bone/uEnv.txt deleted file mode 100644 index f432efc6b..000000000 --- a/libre/uboot-am335x_bone/uEnv.txt +++ /dev/null @@ -1 +0,0 @@ -optargs=coherent_pool=1M diff --git a/libre/uboot-am335x_bone/uboot-am335x_bone.install b/libre/uboot-am335x_bone/uboot-am335x_bone.install deleted file mode 100644 index 4467c694e..000000000 --- a/libre/uboot-am335x_bone/uboot-am335x_bone.install +++ /dev/null @@ -1,37 +0,0 @@ -flash_instructions() { - echo "# dd if=/boot/MLO of=/dev/mmcblk0 count=1 seek=1 conv=notrunc bs=128k" - echo "# dd if=/boot/u-boot.img of=/dev/mmcblk0 count=2 seek=1 conv=notrunc bs=384k" -} - -extlinux_warning() { - echo "==> WARNING: U-Boot uses Extlinux support to boot up. For setting it up, edit /boot/extlinux/extlinux.conf" -} - -flash_uboot() { - root=$(mount | awk '/ on \/ / { print $1; }') - if [[ $root =~ ^/dev/mmcblk.*$ ]]; then - root=${root:0:12} - echo "A new U-Boot version needs to be flashed onto $root." - echo "Do this now? [y|N]" - read -r shouldwe - if [[ $shouldwe =~ ^([yY][eE][sS]|[yY])$ ]]; then - dd if=/boot/MLO of=$root count=1 seek=1 conv=notrunc bs=128k - dd if=/boot/u-boot.img of=$root count=2 seek=1 conv=notrunc bs=384k - else - echo "You can do this later by running:" - flash_instructions - fi - else - echo "Flash the new U-Boot version onto your boot device. For example:" - flash_instructions - fi - extlinux_warning -} - -post_install() { - flash_uboot -} - -post_upgrade() { - flash_uboot -} diff --git a/libre/uboot-omap3_beagle/0001-parabola-arm-modifications.patch b/libre/uboot-omap3_beagle/0001-parabola-arm-modifications.patch deleted file mode 100644 index c99cd89b8..000000000 --- a/libre/uboot-omap3_beagle/0001-parabola-arm-modifications.patch +++ /dev/null @@ -1,312 +0,0 @@ -diff -Nur u-boot-2016.01.orig/board/ti/beagle/beagle.c u-boot-2016.01/board/ti/beagle/beagle.c ---- u-boot-2016.01.orig/board/ti/beagle/beagle.c 2016-01-12 11:06:54.000000000 -0300 -+++ u-boot-2016.01/board/ti/beagle/beagle.c 2016-02-24 19:45:05.779336247 -0300 -@@ -56,6 +56,7 @@ - #define BBTOYS_WIFI 0x01000B00 - #define BBTOYS_VGA 0x02000B00 - #define BBTOYS_LCD 0x03000B00 -+#define BBTOYS_ULCD 0x04000B00 - #define BCT_BRETTL3 0x01000F00 - #define BCT_BRETTL4 0x02000F00 - #define LSR_COM6L_ADPT 0x01001300 -@@ -211,25 +212,25 @@ - * bus 1 for the availability of an AT24C01B serial EEPROM. - * returns the device_vendor field from the EEPROM - */ --static unsigned int get_expansion_id(void) -+static unsigned int get_expansion_id(int eeprom_address) - { - i2c_set_bus_num(EXPANSION_EEPROM_I2C_BUS); - - /* return BEAGLE_NO_EEPROM if eeprom doesn't respond */ -- if (i2c_probe(EXPANSION_EEPROM_I2C_ADDRESS) == 1) { -+ if (i2c_probe(eeprom_address) == 1) { - i2c_set_bus_num(TWL4030_I2C_BUS); - return BEAGLE_NO_EEPROM; - } - - /* read configuration data */ -- i2c_read(EXPANSION_EEPROM_I2C_ADDRESS, 0, 1, (u8 *)&expansion_config, -+ i2c_read(eeprom_address, 0, 1, (u8 *)&expansion_config, - sizeof(expansion_config)); - - /* retry reading configuration data with 16bit addressing */ - if ((expansion_config.device_vendor == 0xFFFFFF00) || - (expansion_config.device_vendor == 0xFFFFFFFF)) { - printf("EEPROM is blank or 8bit addressing failed: retrying with 16bit:\n"); -- i2c_read(EXPANSION_EEPROM_I2C_ADDRESS, 0, 2, (u8 *)&expansion_config, -+ i2c_read(eeprom_address, 0, 2, (u8 *)&expansion_config, - sizeof(expansion_config)); - } - -@@ -341,15 +342,18 @@ - case REVISION_AXBX: - printf("Beagle Rev Ax/Bx\n"); - setenv("beaglerev", "AxBx"); -+ setenv("musb", "musb_hdrc.fifo_mode=5"); - break; - case REVISION_CX: - printf("Beagle Rev C1/C2/C3\n"); - setenv("beaglerev", "Cx"); -+ setenv("musb", "musb_hdrc.fifo_mode=5"); - MUX_BEAGLE_C(); - break; - case REVISION_C4: - printf("Beagle Rev C4\n"); - setenv("beaglerev", "C4"); -+ setenv("musb", "musb_hdrc.fifo_mode=5"); - MUX_BEAGLE_C(); - /* Set VAUX2 to 1.8V for EHCI PHY */ - twl4030_pmrecv_vsel_cfg(TWL4030_PM_RECEIVER_VAUX2_DEDICATED, -@@ -390,7 +394,7 @@ - generate_fake_mac = true; - } - -- switch (get_expansion_id()) { -+ switch (get_expansion_id(EXPANSION_EEPROM_I2C_ADDRESS)) { - case TINCANTOOLS_ZIPPY: - printf("Recognized Tincantools Zippy board (rev %d %s)\n", - expansion_config.revision, -@@ -471,6 +475,30 @@ - } - - if (expansion_config.content == 1) -+ setenv(expansion_config.env_var, expansion_config.env_setting); -+ -+ /* Scan 0x51 as well for loop-thru boards */ -+ switch (get_expansion_id(EXPANSION_EEPROM_I2C_ADDRESS + 1)) { -+ case BBTOYS_ULCD: -+ printf("Recognized BeagleBoardToys uLCD-lite board\n"); -+ setenv("buddy2", "bbtoys-ulcd"); -+ setenv("defaultdisplay", "dvi"); -+ setenv("dvimode", "800x480MR-16@60"); -+ setenv("lcd1", "i2c mw 40 00 00; i2c mw 40 04 80; i2c mw 40 0d 05"); -+ setenv("lcdcmd", "i2c dev 1 ; run lcd1; i2c dev 0"); -+ setenv("kmsmode", "video=DVI-D-1:800x480"); -+ break; -+ case BEAGLE_NO_EEPROM: -+ printf("No EEPROM on expansion board\n"); -+ setenv("buddy2", "none"); -+ break; -+ default: -+ printf("Unrecognized expansion board: %x\n", -+ expansion_config.device_vendor); -+ setenv("buddy2", "unknown"); -+ } -+ -+ if (expansion_config.content == 1) - setenv(expansion_config.env_var, expansion_config.env_setting); - - twl4030_power_init(); -diff -Nur u-boot-2016.01.orig/include/configs/omap3_beagle.h u-boot-2016.01/include/configs/omap3_beagle.h ---- u-boot-2016.01.orig/include/configs/omap3_beagle.h 2016-01-12 11:06:54.000000000 -0300 -+++ u-boot-2016.01/include/configs/omap3_beagle.h 2016-02-24 19:50:25.959802093 -0300 -@@ -91,6 +91,12 @@ - #define CONFIG_USB_ETHER_MCS7830 - #define CONFIG_USB_ETHER_SMSC95XX - -+/* Parabola GNU/Linux-libre extras */ -+#define CONFIG_IDENT_STRING " Parabola GNU/Linux-libre" -+#define CONFIG_SUPPORT_RAW_INITRD -+#define CONFIG_CMD_PART -+#define CONFIG_PARTITION_UUIDS -+ - /* GPIO banks */ - #define CONFIG_OMAP3_GPIO_5 /* GPIO128..159 is in GPIO bank 5 */ - #define CONFIG_OMAP3_GPIO_6 /* GPIO160..191 is in GPIO bank 6 */ -@@ -124,51 +130,71 @@ - #define CONFIG_SYS_MAX_NAND_DEVICE 1 /* Max number of NAND */ - /* devices */ - -+/* Enable Extlinux boot support */ -+#define CONFIG_CMD_PXE -+#define CONFIG_MENU -+#define BOOT_TARGET_DEVICES(func) -+#include -+ - #define CONFIG_EXTRA_ENV_SETTINGS \ -- "loadaddr=0x80200000\0" \ -- "rdaddr=0x81000000\0" \ -+ BOOTENV \ -+ "loadaddr=0x82000000\0" \ -+ "rdaddr=0x88080000\0" \ - "fdt_high=0xffffffff\0" \ -- "fdtaddr=0x80f80000\0" \ -- "usbtty=cdc_acm\0" \ -- "bootfile=uImage\0" \ -- "ramdisk=ramdisk.gz\0" \ -- "bootdir=/boot\0" \ -- "bootpart=0:2\0" \ -+ "fdtaddr=0x88000000\0" \ - "console=ttyO2,115200n8\0" \ -- "mpurate=auto\0" \ -- "buddy=none\0" \ -- "optargs=\0" \ -- "camera=none\0" \ -- "vram=12M\0" \ -- "dvimode=640x480MR-16@60\0" \ -- "defaultdisplay=dvi\0" \ -+ "fdtfile=undefined\0" \ -+ "bootpart=0:1\0" \ -+ "bootdir=\0" \ -+ "fdtdir=/dtbs\0" \ -+ "bootfile=zImage\0" \ -+ "rdfile=initramfs-linux.img\0" \ - "mmcdev=0\0" \ -- "mmcroot=/dev/mmcblk0p2 rw\0" \ -- "mmcrootfstype=ext3 rootwait\0" \ -- "nandroot=ubi0:rootfs ubi.mtd=4\0" \ -- "nandrootfstype=ubifs\0" \ -- "ramroot=/dev/ram0 rw ramdisk_size=65536 initrd=0x81000000,64M\0" \ -- "ramrootfstype=ext2\0" \ -+ "optargs=\0" \ - "mmcargs=setenv bootargs console=${console} " \ - "${optargs} " \ -- "mpurate=${mpurate} " \ -- "buddy=${buddy} "\ -- "camera=${camera} "\ -- "vram=${vram} " \ -- "omapfb.mode=dvi:${dvimode} " \ -- "omapdss.def_disp=${defaultdisplay} " \ -- "root=${mmcroot} " \ -- "rootfstype=${mmcrootfstype}\0" \ -- "nandargs=setenv bootargs console=${console} " \ -- "${optargs} " \ -- "mpurate=${mpurate} " \ -- "buddy=${buddy} "\ -- "camera=${camera} "\ -- "vram=${vram} " \ -- "omapfb.mode=dvi:${dvimode} " \ -- "omapdss.def_disp=${defaultdisplay} " \ -- "root=${nandroot} " \ -- "rootfstype=${nandrootfstype}\0" \ -+ "root=${root} " \ -+ "${musb} " \ -+ "${cmdline}\0" \ -+ "loadimage=load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \ -+ "loadrd=load ${devtype} ${bootpart} ${rdaddr} ${bootdir}/${rdfile}\0" \ -+ "loadfdt=echo loading ${fdtdir}/${fdtfile} ...; load ${devtype} ${bootpart} ${fdtaddr} ${fdtdir}/${fdtfile}\0" \ -+ "mmcboot=usb start;" \ -+ "for devtype in mmc usb; do " \ -+ "setenv devnum 0;" \ -+ "while ${devtype} dev ${devnum}; do " \ -+ "echo ${devtype} found on device ${devnum};" \ -+ "setenv bootpart ${devnum}:1;" \ -+ "if test ${devtype} = mmc; then part uuid mmc ${devnum}:2 uuid; else part uuid ${devtype} ${devnum}:1 uuid; fi;" \ -+ "part uuid ${devtype} ${rootpart} uuid;" \ -+ "setenv root PARTUUID=${uuid} rw rootwait;" \ -+ "echo Checking for: ${bootdir}/uEnv.txt ...;" \ -+ "if test -e ${devtype} ${bootpart} ${bootdir}/uEnv.txt; then " \ -+ "load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/uEnv.txt;" \ -+ "env import -t ${loadaddr} ${filesize};" \ -+ "echo Loaded environment from ${bootdir}/uEnv.txt;" \ -+ "echo Checking if uenvcmd is set ...;" \ -+ "if test -n ${uenvcmd}; then " \ -+ "echo Running uenvcmd ...;" \ -+ "run uenvcmd;" \ -+ "fi;" \ -+ "fi;" \ -+ "run scan_dev_for_boot;" \ -+ "if run loadimage; then " \ -+ "run mmcargs;" \ -+ "if run loadfdt; then " \ -+ "if run loadrd; then " \ -+ "bootz ${loadaddr} ${rdaddr}:${filesize} ${fdtaddr};" \ -+ "else " \ -+ "bootz ${loadaddr} - ${fdtaddr};" \ -+ "fi;" \ -+ "fi;" \ -+ "else " \ -+ "echo No kernel found;" \ -+ "fi;" \ -+ "setexpr devnum ${devnum} + 1;" \ -+ "done;" \ -+ "done;\0" \ - "findfdt=" \ - "if test $beaglerev = AxBx; then " \ - "setenv fdtfile omap3-beagle.dtb; fi; " \ -@@ -181,81 +207,11 @@ - "if test $beaglerev = xMC; then " \ - "setenv fdtfile omap3-beagle-xm.dtb; fi; " \ - "if test $fdtfile = undefined; then " \ -- "echo WARNING: Could not determine device tree to use; fi; \0" \ -- "validatefdt=" \ -- "if test $beaglerev = xMAB; then " \ -- "if test ! -e mmc ${bootpart} ${bootdir}/${fdtfile}; then " \ -- "setenv fdtfile omap3-beagle-xm.dtb; " \ -- "fi; " \ -- "fi; \0" \ -- "bootenv=uEnv.txt\0" \ -- "loadbootenv=fatload mmc ${mmcdev} ${loadaddr} ${bootenv}\0" \ -- "importbootenv=echo Importing environment from mmc ...; " \ -- "env import -t -r $loadaddr $filesize\0" \ -- "ramargs=setenv bootargs console=${console} " \ -- "${optargs} " \ -- "mpurate=${mpurate} " \ -- "buddy=${buddy} "\ -- "vram=${vram} " \ -- "omapfb.mode=dvi:${dvimode} " \ -- "omapdss.def_disp=${defaultdisplay} " \ -- "root=${ramroot} " \ -- "rootfstype=${ramrootfstype}\0" \ -- "loadramdisk=load mmc ${bootpart} ${rdaddr} ${bootdir}/${ramdisk}\0" \ -- "loadimage=load mmc ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \ -- "loadbootscript=load mmc ${mmcdev} ${loadaddr} boot.scr\0" \ -- "bootscript=echo Running bootscript from mmc${mmcdev} ...; " \ -- "source ${loadaddr}\0" \ -- "loadfdt=run validatefdt; load mmc ${bootpart} ${fdtaddr} ${bootdir}/${fdtfile}\0" \ -- "mmcboot=echo Booting from mmc ...; " \ -- "run mmcargs; " \ -- "bootm ${loadaddr}\0" \ -- "mmcbootz=echo Booting with DT from mmc${mmcdev} ...; " \ -- "run mmcargs; " \ -- "bootz ${loadaddr} - ${fdtaddr}\0" \ -- "nandboot=echo Booting from nand ...; " \ -- "run nandargs; " \ -- "nand read ${loadaddr} 280000 400000; " \ -- "bootm ${loadaddr}\0" \ -- "ramboot=echo Booting from ramdisk ...; " \ -- "run ramargs; " \ -- "bootm ${loadaddr}\0" \ -- "userbutton=if gpio input 173; then run userbutton_xm; " \ -- "else run userbutton_nonxm; fi;\0" \ -- "userbutton_xm=gpio input 4;\0" \ -- "userbutton_nonxm=gpio input 7;\0" --/* "run userbutton" will return 1 (false) if pressed and 0 (true) if not */ -+ "echo WARNING: Could not determine device tree to use; fi; \0" -+ - #define CONFIG_BOOTCOMMAND \ - "run findfdt; " \ -- "mmc dev ${mmcdev}; if mmc rescan; then " \ -- "if run userbutton; then " \ -- "setenv bootenv uEnv.txt;" \ -- "else " \ -- "setenv bootenv user.txt;" \ -- "fi;" \ -- "echo SD/MMC found on device ${mmcdev};" \ -- "if run loadbootenv; then " \ -- "echo Loaded environment from ${bootenv};" \ -- "run importbootenv;" \ -- "fi;" \ -- "if test -n $uenvcmd; then " \ -- "echo Running uenvcmd ...;" \ -- "run uenvcmd;" \ -- "fi;" \ -- "if run loadbootscript; then " \ -- "run bootscript; " \ -- "else " \ -- "if run loadimage; then " \ -- "run mmcboot;" \ -- "fi;" \ -- "fi; " \ -- "fi;" \ -- "run nandboot;" \ -- "setenv bootfile zImage;" \ -- "if run loadimage; then " \ -- "run loadfdt;" \ -- "run mmcbootz; " \ -- "fi; " \ -+ "run mmcboot" - - /* - * OMAP3 has 12 GP timers, they can be driven by the system clock diff --git a/libre/uboot-omap3_beagle/PKGBUILD b/libre/uboot-omap3_beagle/PKGBUILD deleted file mode 100644 index 2b41eb15a..000000000 --- a/libre/uboot-omap3_beagle/PKGBUILD +++ /dev/null @@ -1,51 +0,0 @@ -# U-Boot: BeagleBoard and BeagleBoard-xM -# Maintainer: André Silva - -buildarch=4 - -pkgname=uboot-omap3_beagle -pkgver=2016.01 -pkgrel=2 -pkgdesc="U-Boot for BeagleBoard and BeagleBoard-xM" -arch=('armv7h') -url="http://git.denx.de/u-boot.git/" -license=('GPL') -replaces=('uboot-beagleboard-linux-libre' 'uboot-beagleboard-linux-libre-lts' - 'uboot-beagleboard-linux-libre-grsec' 'uboot-beagleboard-linux-libre-pck' - 'uboot-beagleboard') -conflicts=('uboot-beagleboard-linux-libre' 'uboot-beagleboard-linux-libre-lts' - 'uboot-beagleboard-linux-libre-grsec' 'uboot-beagleboard-linux-libre-pck' - 'uboot-beagleboard' 'uboot4grub-omap3_beagle') -makedepends=('bc') -backup=(boot/extlinux/extlinux.conf) -install=${pkgname}.install -source=("ftp://ftp.denx.de/pub/u-boot/u-boot-${pkgver}.tar.bz2" - '0001-parabola-arm-modifications.patch' - 'extlinux.conf' - 'uEnv.txt') -md5sums=('7d4f65fd43d4d706f5c5650e020d899d' - 'da3d52f785bce02602f88fb85f74de2f' - '5172c86fd491728aad8109ebb8a997f8' - 'd41d8cd98f00b204e9800998ecf8427e') - -prepare() { - cd u-boot-${pkgver} - patch -Np1 -i ../0001-parabola-arm-modifications.patch -} - -build() { - cd u-boot-${pkgver} - - unset LDFLAGS CFLAGS CXXFLAGS - - make distclean - make omap3_beagle_config - make -} - -package() { - cd u-boot-${pkgver} - mkdir -p "${pkgdir}"/boot/extlinux - cp MLO u-boot.img "${srcdir}"/uEnv.txt "${pkgdir}"/boot - cp "${srcdir}"/extlinux.conf "${pkgdir}"/boot/extlinux -} diff --git a/libre/uboot-omap3_beagle/extlinux.conf b/libre/uboot-omap3_beagle/extlinux.conf deleted file mode 100644 index 708bfcddb..000000000 --- a/libre/uboot-omap3_beagle/extlinux.conf +++ /dev/null @@ -1,46 +0,0 @@ -menu title Welcome to U-Boot with Extlinux support! - -label Parabola GNU/Linux-libre, linux-libre kernel - kernel /vmlinuz-linux-libre - append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 - fdtdir /dtbs/linux-libre - -#label Parabola GNU/Linux-libre, linux-libre-lts kernel -# kernel /vmlinuz-linux-libre-lts -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /dtbs/linux-libre-lts - -#label Parabola GNU/Linux-libre, linux-libre-knock kernel -# kernel /vmlinuz-linux-libre-knock -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /dtbs/linux-libre-knock - -#label Parabola GNU/Linux-libre, linux-libre-lts-knock kernel -# kernel /vmlinuz-linux-libre-lts-knock -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /dtbs/linux-libre-lts-knock - -#label Parabola GNU/Linux-libre, linux-libre-grsec kernel -# kernel /vmlinuz-linux-libre-grsec -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /dtbs/linux-libre-grsec - -#label Parabola GNU/Linux-libre, linux-libre-grsec-knock kernel -# kernel /vmlinuz-linux-libre-grsec-knock -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /dtbs/linux-libre-grsec-knock - -#label Parabola GNU/Linux-libre, linux-libre-audit kernel -# kernel /vmlinuz-linux-libre-audit -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /dtbs/linux-libre-audit - -#label Parabola GNU/Linux-libre, linux-libre-pck kernel -# kernel /vmlinuz-linux-libre-pck -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /dtbs/linux-libre-pck - -#label Parabola GNU/Linux-libre, linux-libre-rt kernel -# kernel /vmlinuz-linux-libre-rt -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /dtbs/linux-libre-rt diff --git a/libre/uboot-omap3_beagle/uEnv.txt b/libre/uboot-omap3_beagle/uEnv.txt deleted file mode 100644 index e69de29bb..000000000 diff --git a/libre/uboot-omap3_beagle/uboot-omap3_beagle.install b/libre/uboot-omap3_beagle/uboot-omap3_beagle.install deleted file mode 100644 index 8aff26699..000000000 --- a/libre/uboot-omap3_beagle/uboot-omap3_beagle.install +++ /dev/null @@ -1,11 +0,0 @@ -extlinux_warning() { - echo "==> WARNING: U-Boot uses Extlinux support to boot up. For setting it up, edit /boot/extlinux/extlinux.conf" -} - -post_install() { - extlinux_warning -} - -post_upgrade() { - extlinux_warning -} diff --git a/libre/uboot-omap4_panda/0001-parabola-arm-modifications.patch b/libre/uboot-omap4_panda/0001-parabola-arm-modifications.patch deleted file mode 100644 index 09aee7ce0..000000000 --- a/libre/uboot-omap4_panda/0001-parabola-arm-modifications.patch +++ /dev/null @@ -1,135 +0,0 @@ -diff -Nur u-boot-2016.01.orig/include/configs/ti_omap4_common.h u-boot-2016.01/include/configs/ti_omap4_common.h ---- u-boot-2016.01.orig/include/configs/ti_omap4_common.h 2016-01-12 11:06:54.000000000 -0300 -+++ u-boot-2016.01/include/configs/ti_omap4_common.h 2016-02-24 23:19:09.761629260 -0300 -@@ -46,7 +46,6 @@ - * the timings to use or use pre-determined timings (based on using the - * dynamic method. Default to the static timing infomation. - */ --#define CONFIG_SYS_EMIF_PRECALCULATED_TIMING_REGS - #ifndef CONFIG_SYS_EMIF_PRECALCULATED_TIMING_REGS - #define CONFIG_SYS_AUTOMATIC_SDRAM_DETECTION - #define CONFIG_SYS_DEFAULT_LPDDR2_TIMINGS -@@ -79,33 +78,74 @@ - #define CONFIG_USB_TTY 1 - #define CONFIG_SYS_CONSOLE_IS_IN_ENV 1 - -+/* Parabola GNU/Linux-libre extras */ -+#define CONFIG_IDENT_STRING " Parabola GNU/Linux-libre" -+ -+/* Enable Extlinux boot support */ -+#define CONFIG_CMD_PXE -+#define CONFIG_MENU -+#define BOOT_TARGET_DEVICES(func) -+#include -+ - /* - * Environment setup - */ - #define CONFIG_EXTRA_ENV_SETTINGS \ -+ BOOTENV \ - DEFAULT_LINUX_BOOT_ENV \ - DEFAULT_MMC_TI_ARGS \ - "console=ttyO2,115200n8\0" \ - "fdtfile=undefined\0" \ - "bootpart=0:2\0" \ - "bootdir=/boot\0" \ -+ "fdtdir=/boot/dtbs\0" \ - "bootfile=zImage\0" \ -+ "rdfile=initramfs-linux.img\0" \ - "usbtty=cdc_acm\0" \ - "vram=16M\0" \ -- "loadbootscript=load mmc ${mmcdev} ${loadaddr} boot.scr\0" \ -- "bootscript=echo Running bootscript from mmc${mmcdev} ...; " \ -- "source ${loadaddr}\0" \ -- "loadbootenv=load mmc ${mmcdev} ${loadaddr} uEnv.txt\0" \ -- "importbootenv=echo Importing environment from mmc${mmcdev} ...; " \ -- "env import -t ${loadaddr} ${filesize}\0" \ -- "loadimage=load mmc ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \ -- "loaduimage=load mmc ${mmcdev} ${loadaddr} uImage\0" \ -- "mmcboot=echo Booting from mmc${mmcdev} ...; " \ -- "run args_mmc; " \ -- "bootz ${loadaddr} - ${fdtaddr}\0" \ -- "uimageboot=echo Booting from mmc${mmcdev} ...; " \ -- "run args_mmc; " \ -- "bootm ${loadaddr}\0" \ -+ "optargs=\0" \ -+ "mmcargs=setenv bootargs console=${console} " \ -+ "vram=${vram} " \ -+ "root=${root} " \ -+ "${optargs}\0" \ -+ "loadimage=load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \ -+ "loadrd=load ${devtype} ${bootpart} ${rdaddr} ${bootdir}/${rdfile}\0" \ -+ "loadfdt=echo loading ${fdtdir}/${fdtfile} ...; load ${devtype} ${bootpart} ${fdtaddr} ${fdtdir}/${fdtfile}\0" \ -+ "mmcboot=usb start;" \ -+ "for devtype in mmc usb; do " \ -+ "setenv devnum 0;" \ -+ "while ${devtype} dev ${devnum}; do " \ -+ "echo ${devtype} found on device ${devnum};" \ -+ "setenv bootpart ${devnum}:1;" \ -+ "part uuid ${devtype} ${bootpart} uuid;" \ -+ "setenv root PARTUUID=${uuid} rw rootwait;" \ -+ "echo Checking for: ${bootdir}/uEnv.txt ...;" \ -+ "if test -e ${devtype} ${bootpart} ${bootdir}/uEnv.txt; then " \ -+ "load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/uEnv.txt;" \ -+ "env import -t ${loadaddr} ${filesize};" \ -+ "echo Loaded environment from ${bootdir}/uEnv.txt;" \ -+ "echo Checking if uenvcmd is set ...;" \ -+ "if test -n ${uenvcmd}; then " \ -+ "echo Running uenvcmd ...;" \ -+ "run uenvcmd;" \ -+ "fi;" \ -+ "fi;" \ -+ "run scan_dev_for_boot;" \ -+ "if run loadimage; then " \ -+ "run mmcargs;" \ -+ "if run loadfdt; then " \ -+ "if run loadrd; then " \ -+ "bootz ${loadaddr} ${rdaddr}:${filesize} ${fdtaddr};" \ -+ "else " \ -+ "bootz ${loadaddr} - ${fdtaddr};" \ -+ "fi;" \ -+ "fi;" \ -+ "else " \ -+ "echo No kernel found;" \ -+ "fi;" \ -+ "setexpr devnum ${devnum} + 1;" \ -+ "done;" \ -+ "done;\0" \ - "findfdt="\ - "if test $board_name = sdp4430; then " \ - "setenv fdtfile omap4-sdp.dtb; fi; " \ -@@ -118,32 +158,11 @@ - "if test $board_name = duovero; then " \ - "setenv fdtfile omap4-duovero-parlor.dtb; fi;" \ - "if test $fdtfile = undefined; then " \ -- "echo WARNING: Could not determine device tree to use; fi; \0" \ -- "loadfdt=load mmc ${bootpart} ${fdtaddr} ${bootdir}/${fdtfile}\0" \ -+ "echo WARNING: Could not determine device tree to use; fi; \0" - - #define CONFIG_BOOTCOMMAND \ - "run findfdt; " \ -- "mmc dev ${mmcdev}; if mmc rescan; then " \ -- "echo SD/MMC found on device ${mmcdev};" \ -- "if run loadbootscript; then " \ -- "run bootscript; " \ -- "else " \ -- "if run loadbootenv; then " \ -- "run importbootenv; " \ -- "fi;" \ -- "if test -n ${uenvcmd}; then " \ -- "echo Running uenvcmd ...;" \ -- "run uenvcmd;" \ -- "fi;" \ -- "fi;" \ -- "if run loadimage; then " \ -- "run loadfdt;" \ -- "run mmcboot; " \ -- "fi; " \ -- "if run loaduimage; then " \ -- "run uimageboot;" \ -- "fi; " \ -- "fi" -+ "run mmcboot" - - /* - * Defines for SPL diff --git a/libre/uboot-omap4_panda/PKGBUILD b/libre/uboot-omap4_panda/PKGBUILD deleted file mode 100644 index 6aaf94b60..000000000 --- a/libre/uboot-omap4_panda/PKGBUILD +++ /dev/null @@ -1,49 +0,0 @@ -# U-Boot: PandaBoard and PandaBoard ES -# Maintainer: André Silva - -buildarch=4 - -pkgname=uboot-omap4_panda -pkgver=2016.01 -pkgrel=2 -pkgdesc="U-Boot for PandaBoard and PandaBoard ES" -arch=('armv7h') -url="http://git.denx.de/u-boot.git/" -replaces=('uboot-pandaboard-linux-libre' 'uboot-pandaboard') -conflicts=('uboot-pandaboard-linux-libre' 'uboot-pandaboard' 'uboot4grub-omap4_panda') -makedepends=('bc') -license=('GPL') -install=${pkgname}.install -backup=('boot/extlinux/extlinux.conf' 'boot/uEnv.txt') -source=("ftp://ftp.denx.de/pub/u-boot/u-boot-${pkgver}.tar.bz2" - '0001-parabola-arm-modifications.patch' - 'extlinux.conf' - 'uEnv.txt') -md5sums=('7d4f65fd43d4d706f5c5650e020d899d' - 'b74e858feeed48acaba5ac0548d675ca' - '12c61073bb860f4c8d8ec59145c267ed' - '86004660f2912861a040e335c9c0e85b') - -prepare() { - cd u-boot-${pkgver} - - patch -Np1 -i ../0001-parabola-arm-modifications.patch -} - -build() { - cd u-boot-${pkgver} - - unset LDFLAGS - - make distclean - make omap4_panda_config - make -} - -package() { - cd u-boot-${pkgver} - - mkdir -p "${pkgdir}"/boot/extlinux - cp MLO u-boot.img "${srcdir}"/uEnv.txt "${pkgdir}"/boot - cp "${srcdir}"/extlinux.conf "${pkgdir}"/boot/extlinux -} diff --git a/libre/uboot-omap4_panda/extlinux.conf b/libre/uboot-omap4_panda/extlinux.conf deleted file mode 100644 index 725121811..000000000 --- a/libre/uboot-omap4_panda/extlinux.conf +++ /dev/null @@ -1,46 +0,0 @@ -menu title Welcome to U-Boot with Extlinux support! - -label Parabola GNU/Linux-libre, linux-libre kernel - kernel /boot/vmlinuz-linux-libre - append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 - fdtdir /boot/dtbs/linux-libre - -#label Parabola GNU/Linux-libre, linux-libre-lts kernel -# kernel /boot/vmlinuz-linux-libre-lts -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /boot/dtbs/linux-libre-lts - -#label Parabola GNU/Linux-libre, linux-libre-knock kernel -# kernel /boot/vmlinuz-linux-libre-knock -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /boot/dtbs/linux-libre-knock - -#label Parabola GNU/Linux-libre, linux-libre-lts-knock kernel -# kernel /boot/vmlinuz-linux-libre-lts-knock -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /boot/dtbs/linux-libre-lts-knock - -#label Parabola GNU/Linux-libre, linux-libre-grsec kernel -# kernel /boot/vmlinuz-linux-libre-grsec -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /boot/dtbs/linux-libre-grsec - -#label Parabola GNU/Linux-libre, linux-libre-grsec-knock kernel -# kernel /boot/vmlinuz-linux-libre-grsec-knock -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /boot/dtbs/linux-libre-grsec-knock - -#label Parabola GNU/Linux-libre, linux-libre-audit kernel -# kernel /boot/vmlinuz-linux-libre-audit -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /boot/dtbs/linux-libre-audit - -#label Parabola GNU/Linux-libre, linux-libre-pck kernel -# kernel /boot/vmlinuz-linux-libre-pck -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /boot/dtbs/linux-libre-pck - -#label Parabola GNU/Linux-libre, linux-libre-rt kernel -# kernel /boot/vmlinuz-linux-libre-rt -# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 -# fdtdir /boot/dtbs/linux-libre-rt diff --git a/libre/uboot-omap4_panda/uEnv.txt b/libre/uboot-omap4_panda/uEnv.txt deleted file mode 100644 index 55298e1a9..000000000 --- a/libre/uboot-omap4_panda/uEnv.txt +++ /dev/null @@ -1,2 +0,0 @@ -# Uncomment and add any additional kernel parameters to optargs -#optargs= diff --git a/libre/uboot-omap4_panda/uboot-omap4_panda.install b/libre/uboot-omap4_panda/uboot-omap4_panda.install deleted file mode 100644 index 771f1f0b3..000000000 --- a/libre/uboot-omap4_panda/uboot-omap4_panda.install +++ /dev/null @@ -1,26 +0,0 @@ -extlinux_warning() { - echo "==> WARNING: U-Boot uses Extlinux support to boot up. For setting it up, edit /boot/extlinux/extlinux.conf" -} - -flash_uboot() { - echo "A new U-Boot version needs to be flashed onto /dev/mmcblk0." - echo "Do this now? [y|N]" - read -r shouldwe - if [[ $shouldwe =~ ^([yY][eE][sS]|[yY])$ ]]; then - dd if=/boot/MLO of=/dev/mmcblk0 count=1 seek=1 conv=notrunc bs=128k - dd if=/boot/u-boot.img of=/dev/mmcblk0 count=2 seek=1 conv=notrunc bs=384k - else - echo "You can do this later by running:" - echo "# dd if=/boot/MLO of=/dev/mmcblk0 count=1 seek=1 conv=notrunc bs=128k" - echo "# dd if=/boot/u-boot.img of=/dev/mmcblk0 count=2 seek=1 conv=notrunc bs=384k" - fi - extlinux_warning -} - -post_install() { - flash_uboot -} - -post_upgrade() { - flash_uboot -} diff --git a/libre/uboot4extlinux-am335x_bone/0001-parabola-arm-modifications.patch b/libre/uboot4extlinux-am335x_bone/0001-parabola-arm-modifications.patch new file mode 100644 index 000000000..0f1c145da --- /dev/null +++ b/libre/uboot4extlinux-am335x_bone/0001-parabola-arm-modifications.patch @@ -0,0 +1,243 @@ +diff -Nur u-boot-2015.04.orig/configs/am335x_evm_defconfig u-boot-2015.04/configs/am335x_evm_defconfig +--- u-boot-2015.04.orig/configs/am335x_evm_defconfig 2015-04-13 11:53:03.000000000 -0300 ++++ u-boot-2015.04/configs/am335x_evm_defconfig 2016-02-24 12:05:57.627551576 -0300 +@@ -1,7 +1,6 @@ + CONFIG_SPL=y + CONFIG_SPL_STACK_R=y + CONFIG_SPL_STACK_R_ADDR=0x82000000 +-CONFIG_SYS_EXTRA_OPTIONS="NAND" +-CONFIG_CONS_INDEX=1 ++CONFIG_SYS_EXTRA_OPTIONS="SERIAL1,CONS_INDEX=1" + CONFIG_ARM=y + CONFIG_TARGET_AM335X_EVM=y +diff -Nur u-boot-2015.04.orig/include/configs/am335x_evm.h u-boot-2015.04/include/configs/am335x_evm.h +--- u-boot-2015.04.orig/include/configs/am335x_evm.h 2015-04-13 11:53:03.000000000 -0300 ++++ u-boot-2015.04/include/configs/am335x_evm.h 2016-02-24 12:09:41.983016704 -0300 +@@ -17,6 +17,7 @@ + #define __CONFIG_AM335X_EVM_H + + #include ++#define CONFIG_ENV_IS_NOWHERE + + #ifndef CONFIG_SPL_BUILD + #ifndef CONFIG_FIT +@@ -45,6 +46,9 @@ + /* Enhance our eMMC support / experience. */ + #define CONFIG_CMD_GPT + #define CONFIG_EFI_PARTITION ++#define CONFIG_CMD_PART ++#define CONFIG_PARTITION_UUIDS ++#define CONFIG_CMD_SETEXPR + + #ifdef CONFIG_NAND + #define NANDARGS \ +@@ -67,113 +71,90 @@ + + #define CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG + ++/* Enable Extlinux boot support */ ++#define CONFIG_CMD_PXE ++#define CONFIG_MENU ++#define BOOT_TARGET_DEVICES(func) ++#include ++ + #ifndef CONFIG_SPL_BUILD + #define CONFIG_EXTRA_ENV_SETTINGS \ ++ BOOTENV \ + DEFAULT_LINUX_BOOT_ENV \ +- "boot_fdt=try\0" \ +- "bootpart=0:2\0" \ ++ "bootpart=0:1\0" \ + "bootdir=/boot\0" \ ++ "fdtdir=/boot/dtbs\0" \ + "bootfile=zImage\0" \ + "fdtfile=undefined\0" \ ++ "rdfile=initramfs-linux.img\0" \ + "console=ttyO0,115200n8\0" \ + "partitions=" \ + "uuid_disk=${uuid_gpt_disk};" \ + "name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}\0" \ + "optargs=\0" \ +- "mmcdev=0\0" \ +- "mmcroot=/dev/mmcblk0p2 ro\0" \ +- "mmcrootfstype=ext4 rootwait\0" \ +- "rootpath=/export/rootfs\0" \ +- "nfsopts=nolock\0" \ +- "static_ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}:${hostname}" \ +- "::off\0" \ +- "ramroot=/dev/ram0 rw\0" \ +- "ramrootfstype=ext2\0" \ ++ "cape_disable=\0" \ ++ "cape_enable=\0" \ ++ "cmdline=\0" \ + "mmcargs=setenv bootargs console=${console} " \ + "${optargs} " \ +- "root=${mmcroot} " \ +- "rootfstype=${mmcrootfstype}\0" \ +- "spiroot=/dev/mtdblock4 rw\0" \ +- "spirootfstype=jffs2\0" \ +- "spisrcaddr=0xe0000\0" \ +- "spiimgsize=0x362000\0" \ +- "spibusno=0\0" \ +- "spiargs=setenv bootargs console=${console} " \ +- "${optargs} " \ +- "root=${spiroot} " \ +- "rootfstype=${spirootfstype}\0" \ +- "netargs=setenv bootargs console=${console} " \ +- "${optargs} " \ +- "root=/dev/nfs " \ +- "nfsroot=${serverip}:${rootpath},${nfsopts} rw " \ +- "ip=dhcp\0" \ +- "bootenv=uEnv.txt\0" \ +- "loadbootscript=load mmc ${mmcdev} ${loadaddr} boot.scr\0" \ +- "bootscript=echo Running bootscript from mmc${mmcdev} ...; " \ +- "source ${loadaddr}\0" \ +- "loadbootenv=load mmc ${mmcdev} ${loadaddr} ${bootenv}\0" \ +- "importbootenv=echo Importing environment from mmc ...; " \ +- "env import -t -r $loadaddr $filesize\0" \ +- "ramargs=setenv bootargs console=${console} " \ +- "${optargs} " \ +- "root=${ramroot} " \ +- "rootfstype=${ramrootfstype}\0" \ +- "loadramdisk=load mmc ${mmcdev} ${rdaddr} ramdisk.gz\0" \ +- "loadimage=load mmc ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \ +- "loadfdt=load mmc ${bootpart} ${fdtaddr} ${bootdir}/${fdtfile}\0" \ +- "mmcloados=run mmcargs; " \ +- "if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \ +- "if run loadfdt; then " \ +- "bootz ${loadaddr} - ${fdtaddr}; " \ +- "else " \ +- "if test ${boot_fdt} = try; then " \ +- "bootz; " \ +- "else " \ +- "echo WARN: Cannot load the DT; " \ +- "fi; " \ +- "fi; " \ +- "else " \ +- "bootz; " \ +- "fi;\0" \ +- "mmcboot=mmc dev ${mmcdev}; " \ +- "if mmc rescan; then " \ +- "echo SD/MMC found on device ${mmcdev};" \ +- "if run loadbootscript; then " \ +- "run bootscript;" \ +- "else " \ +- "if run loadbootenv; then " \ +- "echo Loaded environment from ${bootenv};" \ +- "run importbootenv;" \ ++ "${cape_disable} " \ ++ "${cape_enable} " \ ++ "root=${root} " \ ++ "${cmdline}\0" \ ++ "loadimage=load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \ ++ "loadrd=load ${devtype} ${bootpart} ${rdaddr} ${bootdir}/${rdfile}\0" \ ++ "loadfdt=echo loading ${fdtdir}/${fdtfile} ...; load ${devtype} ${bootpart} ${fdtaddr} ${fdtdir}/${fdtfile}\0" \ ++ "mmcboot=usb start;" \ ++ "for devtype in mmc usb; do " \ ++ "for devnum in 0 1; do " \ ++ "if ${devtype} dev ${devnum}; then " \ ++ "echo ${devtype} found on device ${devnum};" \ ++ "setenv bootpart ${devnum}:1;" \ ++ "part uuid ${devtype} ${bootpart} uuid;" \ ++ "setenv root PARTUUID=${uuid} rw rootwait fixrtc;" \ ++ "echo Checking for: ${bootdir}/uEnv.txt ...;" \ ++ "gpio set 54;" \ ++ "if test -e ${devtype} ${bootpart} ${bootdir}/uEnv.txt; then " \ ++ "load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/uEnv.txt;" \ ++ "env import -t ${loadaddr} ${filesize};" \ ++ "echo Loaded environment from ${bootdir}/uEnv.txt;" \ ++ "if test -n ${cape}; then " \ ++ "if test -e ${devtype} ${bootpart} ${fdtdir}/${fdtbase}-${cape}.dtb; then " \ ++ "setenv fdtfile ${fdtbase}-${cape}.dtb; " \ ++ "fi; " \ ++ "echo using: $fdtfile...; " \ ++ "fi; " \ ++ "echo Checking if uenvcmd is set ...;" \ ++ "if test -n ${uenvcmd}; then " \ ++ "echo Running uenvcmd ...;" \ ++ "run uenvcmd;" \ ++ "fi;" \ ++ "fi;" \ ++ "gpio set 55;" \ ++ "run scan_dev_for_boot;" \ ++ "if run loadimage; then " \ ++ "run mmcargs;" \ ++ "if run loadfdt; then " \ ++ "gpio set 56;" \ ++ "if run loadrd; then " \ ++ "bootz ${loadaddr} ${rdaddr}:${filesize} ${fdtaddr};" \ ++ "else " \ ++ "bootz ${loadaddr} - ${fdtaddr};" \ ++ "fi;" \ ++ "fi;" \ ++ "else " \ ++ "echo No kernel found;" \ ++ "fi;" \ ++ "gpio clear 54; gpio clear 55;" \ ++ "setexpr devnum ${devnum} + 1;" \ + "fi;" \ +- "if test -n $uenvcmd; then " \ +- "echo Running uenvcmd ...;" \ +- "run uenvcmd;" \ +- "fi;" \ +- "if run loadimage; then " \ +- "run mmcloados;" \ +- "fi;" \ +- "fi ;" \ +- "fi;\0" \ +- "spiboot=echo Booting from spi ...; " \ +- "run spiargs; " \ +- "sf probe ${spibusno}:0; " \ +- "sf read ${loadaddr} ${spisrcaddr} ${spiimgsize}; " \ +- "bootz ${loadaddr}\0" \ +- "netboot=echo Booting from network ...; " \ +- "setenv autoload no; " \ +- "dhcp; " \ +- "tftp ${loadaddr} ${bootfile}; " \ +- "tftp ${fdtaddr} ${fdtfile}; " \ +- "run netargs; " \ +- "bootz ${loadaddr} - ${fdtaddr}\0" \ +- "ramboot=echo Booting from ramdisk ...; " \ +- "run ramargs; " \ +- "bootz ${loadaddr} ${rdaddr} ${fdtaddr}\0" \ ++ "done;" \ ++ "done;\0" \ + "findfdt="\ + "if test $board_name = A335BONE; then " \ +- "setenv fdtfile am335x-bone.dtb; fi; " \ ++ "setenv fdtfile am335x-bone.dtb; setenv fdtbase am335x-bone; fi; " \ + "if test $board_name = A335BNLT; then " \ +- "setenv fdtfile am335x-boneblack.dtb; fi; " \ ++ "setenv fdtfile am335x-boneblack.dtb; setenv fdtbase am335x-boneblack; setenv umsmedia 1; fi; " \ + "if test $board_name = A33515BB; then " \ + "setenv fdtfile am335x-evm.dtb; fi; " \ + "if test $board_name = A335X_SK; then " \ +@@ -185,12 +166,11 @@ + #endif + + #define CONFIG_BOOTCOMMAND \ +- "run findfdt; " \ +- "run mmcboot;" \ +- "setenv mmcdev 1; " \ +- "setenv bootpart 1:2; " \ ++ "gpio set 53;" \ ++ "run findfdt;" \ + "run mmcboot;" \ +- "run nandboot;" ++ "gpio clear 54; gpio clear 55;" \ ++ "gpio set 56" + + /* NS16550 Configuration */ + #define CONFIG_SYS_NS16550_COM1 0x44e09000 /* Base EVM has UART0 */ +@@ -329,9 +309,8 @@ + #endif + + #ifdef CONFIG_MUSB_GADGET +-#define CONFIG_USB_ETHER +-#define CONFIG_USB_ETH_RNDIS +-#define CONFIG_USBNET_HOST_ADDR "de:ad:be:af:00:00" ++#define CONFIG_CMD_USB_MASS_STORAGE ++#define CONFIG_USB_GADGET_MASS_STORAGE + + /* USB TI's IDs */ + #define CONFIG_G_DNL_VENDOR_NUM 0x0451 diff --git a/libre/uboot4extlinux-am335x_bone/PKGBUILD b/libre/uboot4extlinux-am335x_bone/PKGBUILD new file mode 100644 index 000000000..f1436af02 --- /dev/null +++ b/libre/uboot4extlinux-am335x_bone/PKGBUILD @@ -0,0 +1,53 @@ +# U-Boot: BeagleBone and BeagleBone Black +# Maintainer: André Silva +# Contributor: Jookia <166291@gmail.com> +# Contributor: Márcio Silva + +buildarch=4 + +pkgname=uboot4extlinux-am335x_bone +pkgver=2015.04 +pkgrel=1 +pkgdesc="U-Boot with Extlinux support for BeagleBone and BeagleBone Black" +arch=('armv7h') +url="http://git.denx.de/u-boot.git/" +replaces=('uboot-beaglebone-linux-libre' 'uboot-beaglebone-linux-libre-lts' + 'uboot-beaglebone-linux-libre-grsec' 'uboot-beaglebone-linux-libre-pck' + 'uboot-beaglebone' 'uboot-am335x_bone') +conflicts=('uboot-beaglebone-linux-libre' 'uboot-beaglebone-linux-libre-lts' + 'uboot-beaglebone-linux-libre-grsec' 'uboot-beaglebone-linux-libre-pck' + 'uboot-beaglebone' 'uboot-am335x_bone' 'uboot4grub-am335x_bone') +makedepends=('bc') +license=('GPL') +backup=(boot/extlinux/extlinux.conf) +install=${pkgname}.install +source=("ftp://ftp.denx.de/pub/u-boot/u-boot-${pkgver}.tar.bz2" + '0001-parabola-arm-modifications.patch' + 'extlinux.conf' + 'uEnv.txt') +md5sums=('570bdc2c47270c2a98ca60ff6c5c74cd' + '37784c8f8f52a615d65e775018d237fb' + '068f6b4e8047115e73f29af5f384889b' + 'ccb79775b81654e16fca18825c7f2506') + +prepare() { + cd u-boot-${pkgver} + patch -Np1 -i ../0001-parabola-arm-modifications.patch +} + +build() { + cd u-boot-${pkgver} + + unset CFLAGS CXXFLAGS LDFLAGS + + make distclean + make am335x_evm_config + make +} + +package() { + cd u-boot-${pkgver} + mkdir -p "${pkgdir}"/boot/extlinux + cp MLO u-boot.img "${srcdir}"/uEnv.txt "${pkgdir}"/boot + cp "${srcdir}"/extlinux.conf "${pkgdir}"/boot/extlinux +} diff --git a/libre/uboot4extlinux-am335x_bone/extlinux.conf b/libre/uboot4extlinux-am335x_bone/extlinux.conf new file mode 100644 index 000000000..52de94d49 --- /dev/null +++ b/libre/uboot4extlinux-am335x_bone/extlinux.conf @@ -0,0 +1,46 @@ +menu title Welcome to U-Boot with Extlinux support! + +label Parabola GNU/Linux-libre, linux-libre kernel + kernel /boot/vmlinuz-linux-libre + append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 + fdtdir /boot/dtbs/linux-libre + +#label Parabola GNU/Linux-libre, linux-libre-lts kernel +# kernel /boot/vmlinuz-linux-libre-lts +# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 +# fdtdir /boot/dtbs/linux-libre-lts + +#label Parabola GNU/Linux-libre, linux-libre-knock kernel +# kernel /boot/vmlinuz-linux-libre-knock +# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 +# fdtdir /boot/dtbs/linux-libre-knock + +#label Parabola GNU/Linux-libre, linux-libre-lts-knock kernel +# kernel /boot/vmlinuz-linux-libre-lts-knock +# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 +# fdtdir /boot/dtbs/linux-libre-lts-knock + +#label Parabola GNU/Linux-libre, linux-libre-grsec kernel +# kernel /boot/vmlinuz-linux-libre-grsec +# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 +# fdtdir /boot/dtbs/linux-libre-grsec + +#label Parabola GNU/Linux-libre, linux-libre-grsec-knock kernel +# kernel /boot/vmlinuz-linux-libre-grsec-knock +# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 +# fdtdir /boot/dtbs/linux-libre-grsec-knock + +#label Parabola GNU/Linux-libre, linux-libre-audit kernel +# kernel /boot/vmlinuz-linux-libre-audit +# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 +# fdtdir /boot/dtbs/linux-libre-audit + +#label Parabola GNU/Linux-libre, linux-libre-pck kernel +# kernel /boot/vmlinuz-linux-libre-pck +# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 +# fdtdir /boot/dtbs/linux-libre-pck + +#label Parabola GNU/Linux-libre, linux-libre-rt kernel +# kernel /boot/vmlinuz-linux-libre-rt +# append root=/dev/mmcblk0p1 rw console=ttyO0,115200n8 +# fdtdir /boot/dtbs/linux-libre-rt diff --git a/libre/uboot4extlinux-am335x_bone/uEnv.txt b/libre/uboot4extlinux-am335x_bone/uEnv.txt new file mode 100644 index 000000000..f432efc6b --- /dev/null +++ b/libre/uboot4extlinux-am335x_bone/uEnv.txt @@ -0,0 +1 @@ +optargs=coherent_pool=1M diff --git a/libre/uboot4extlinux-am335x_bone/uboot4extlinux-am335x_bone.install b/libre/uboot4extlinux-am335x_bone/uboot4extlinux-am335x_bone.install new file mode 100644 index 000000000..4467c694e --- /dev/null +++ b/libre/uboot4extlinux-am335x_bone/uboot4extlinux-am335x_bone.install @@ -0,0 +1,37 @@ +flash_instructions() { + echo "# dd if=/boot/MLO of=/dev/mmcblk0 count=1 seek=1 conv=notrunc bs=128k" + echo "# dd if=/boot/u-boot.img of=/dev/mmcblk0 count=2 seek=1 conv=notrunc bs=384k" +} + +extlinux_warning() { + echo "==> WARNING: U-Boot uses Extlinux support to boot up. For setting it up, edit /boot/extlinux/extlinux.conf" +} + +flash_uboot() { + root=$(mount | awk '/ on \/ / { print $1; }') + if [[ $root =~ ^/dev/mmcblk.*$ ]]; then + root=${root:0:12} + echo "A new U-Boot version needs to be flashed onto $root." + echo "Do this now? [y|N]" + read -r shouldwe + if [[ $shouldwe =~ ^([yY][eE][sS]|[yY])$ ]]; then + dd if=/boot/MLO of=$root count=1 seek=1 conv=notrunc bs=128k + dd if=/boot/u-boot.img of=$root count=2 seek=1 conv=notrunc bs=384k + else + echo "You can do this later by running:" + flash_instructions + fi + else + echo "Flash the new U-Boot version onto your boot device. For example:" + flash_instructions + fi + extlinux_warning +} + +post_install() { + flash_uboot +} + +post_upgrade() { + flash_uboot +} diff --git a/libre/uboot4extlinux-omap3_beagle/0001-parabola-arm-modifications.patch b/libre/uboot4extlinux-omap3_beagle/0001-parabola-arm-modifications.patch new file mode 100644 index 000000000..c99cd89b8 --- /dev/null +++ b/libre/uboot4extlinux-omap3_beagle/0001-parabola-arm-modifications.patch @@ -0,0 +1,312 @@ +diff -Nur u-boot-2016.01.orig/board/ti/beagle/beagle.c u-boot-2016.01/board/ti/beagle/beagle.c +--- u-boot-2016.01.orig/board/ti/beagle/beagle.c 2016-01-12 11:06:54.000000000 -0300 ++++ u-boot-2016.01/board/ti/beagle/beagle.c 2016-02-24 19:45:05.779336247 -0300 +@@ -56,6 +56,7 @@ + #define BBTOYS_WIFI 0x01000B00 + #define BBTOYS_VGA 0x02000B00 + #define BBTOYS_LCD 0x03000B00 ++#define BBTOYS_ULCD 0x04000B00 + #define BCT_BRETTL3 0x01000F00 + #define BCT_BRETTL4 0x02000F00 + #define LSR_COM6L_ADPT 0x01001300 +@@ -211,25 +212,25 @@ + * bus 1 for the availability of an AT24C01B serial EEPROM. + * returns the device_vendor field from the EEPROM + */ +-static unsigned int get_expansion_id(void) ++static unsigned int get_expansion_id(int eeprom_address) + { + i2c_set_bus_num(EXPANSION_EEPROM_I2C_BUS); + + /* return BEAGLE_NO_EEPROM if eeprom doesn't respond */ +- if (i2c_probe(EXPANSION_EEPROM_I2C_ADDRESS) == 1) { ++ if (i2c_probe(eeprom_address) == 1) { + i2c_set_bus_num(TWL4030_I2C_BUS); + return BEAGLE_NO_EEPROM; + } + + /* read configuration data */ +- i2c_read(EXPANSION_EEPROM_I2C_ADDRESS, 0, 1, (u8 *)&expansion_config, ++ i2c_read(eeprom_address, 0, 1, (u8 *)&expansion_config, + sizeof(expansion_config)); + + /* retry reading configuration data with 16bit addressing */ + if ((expansion_config.device_vendor == 0xFFFFFF00) || + (expansion_config.device_vendor == 0xFFFFFFFF)) { + printf("EEPROM is blank or 8bit addressing failed: retrying with 16bit:\n"); +- i2c_read(EXPANSION_EEPROM_I2C_ADDRESS, 0, 2, (u8 *)&expansion_config, ++ i2c_read(eeprom_address, 0, 2, (u8 *)&expansion_config, + sizeof(expansion_config)); + } + +@@ -341,15 +342,18 @@ + case REVISION_AXBX: + printf("Beagle Rev Ax/Bx\n"); + setenv("beaglerev", "AxBx"); ++ setenv("musb", "musb_hdrc.fifo_mode=5"); + break; + case REVISION_CX: + printf("Beagle Rev C1/C2/C3\n"); + setenv("beaglerev", "Cx"); ++ setenv("musb", "musb_hdrc.fifo_mode=5"); + MUX_BEAGLE_C(); + break; + case REVISION_C4: + printf("Beagle Rev C4\n"); + setenv("beaglerev", "C4"); ++ setenv("musb", "musb_hdrc.fifo_mode=5"); + MUX_BEAGLE_C(); + /* Set VAUX2 to 1.8V for EHCI PHY */ + twl4030_pmrecv_vsel_cfg(TWL4030_PM_RECEIVER_VAUX2_DEDICATED, +@@ -390,7 +394,7 @@ + generate_fake_mac = true; + } + +- switch (get_expansion_id()) { ++ switch (get_expansion_id(EXPANSION_EEPROM_I2C_ADDRESS)) { + case TINCANTOOLS_ZIPPY: + printf("Recognized Tincantools Zippy board (rev %d %s)\n", + expansion_config.revision, +@@ -471,6 +475,30 @@ + } + + if (expansion_config.content == 1) ++ setenv(expansion_config.env_var, expansion_config.env_setting); ++ ++ /* Scan 0x51 as well for loop-thru boards */ ++ switch (get_expansion_id(EXPANSION_EEPROM_I2C_ADDRESS + 1)) { ++ case BBTOYS_ULCD: ++ printf("Recognized BeagleBoardToys uLCD-lite board\n"); ++ setenv("buddy2", "bbtoys-ulcd"); ++ setenv("defaultdisplay", "dvi"); ++ setenv("dvimode", "800x480MR-16@60"); ++ setenv("lcd1", "i2c mw 40 00 00; i2c mw 40 04 80; i2c mw 40 0d 05"); ++ setenv("lcdcmd", "i2c dev 1 ; run lcd1; i2c dev 0"); ++ setenv("kmsmode", "video=DVI-D-1:800x480"); ++ break; ++ case BEAGLE_NO_EEPROM: ++ printf("No EEPROM on expansion board\n"); ++ setenv("buddy2", "none"); ++ break; ++ default: ++ printf("Unrecognized expansion board: %x\n", ++ expansion_config.device_vendor); ++ setenv("buddy2", "unknown"); ++ } ++ ++ if (expansion_config.content == 1) + setenv(expansion_config.env_var, expansion_config.env_setting); + + twl4030_power_init(); +diff -Nur u-boot-2016.01.orig/include/configs/omap3_beagle.h u-boot-2016.01/include/configs/omap3_beagle.h +--- u-boot-2016.01.orig/include/configs/omap3_beagle.h 2016-01-12 11:06:54.000000000 -0300 ++++ u-boot-2016.01/include/configs/omap3_beagle.h 2016-02-24 19:50:25.959802093 -0300 +@@ -91,6 +91,12 @@ + #define CONFIG_USB_ETHER_MCS7830 + #define CONFIG_USB_ETHER_SMSC95XX + ++/* Parabola GNU/Linux-libre extras */ ++#define CONFIG_IDENT_STRING " Parabola GNU/Linux-libre" ++#define CONFIG_SUPPORT_RAW_INITRD ++#define CONFIG_CMD_PART ++#define CONFIG_PARTITION_UUIDS ++ + /* GPIO banks */ + #define CONFIG_OMAP3_GPIO_5 /* GPIO128..159 is in GPIO bank 5 */ + #define CONFIG_OMAP3_GPIO_6 /* GPIO160..191 is in GPIO bank 6 */ +@@ -124,51 +130,71 @@ + #define CONFIG_SYS_MAX_NAND_DEVICE 1 /* Max number of NAND */ + /* devices */ + ++/* Enable Extlinux boot support */ ++#define CONFIG_CMD_PXE ++#define CONFIG_MENU ++#define BOOT_TARGET_DEVICES(func) ++#include ++ + #define CONFIG_EXTRA_ENV_SETTINGS \ +- "loadaddr=0x80200000\0" \ +- "rdaddr=0x81000000\0" \ ++ BOOTENV \ ++ "loadaddr=0x82000000\0" \ ++ "rdaddr=0x88080000\0" \ + "fdt_high=0xffffffff\0" \ +- "fdtaddr=0x80f80000\0" \ +- "usbtty=cdc_acm\0" \ +- "bootfile=uImage\0" \ +- "ramdisk=ramdisk.gz\0" \ +- "bootdir=/boot\0" \ +- "bootpart=0:2\0" \ ++ "fdtaddr=0x88000000\0" \ + "console=ttyO2,115200n8\0" \ +- "mpurate=auto\0" \ +- "buddy=none\0" \ +- "optargs=\0" \ +- "camera=none\0" \ +- "vram=12M\0" \ +- "dvimode=640x480MR-16@60\0" \ +- "defaultdisplay=dvi\0" \ ++ "fdtfile=undefined\0" \ ++ "bootpart=0:1\0" \ ++ "bootdir=\0" \ ++ "fdtdir=/dtbs\0" \ ++ "bootfile=zImage\0" \ ++ "rdfile=initramfs-linux.img\0" \ + "mmcdev=0\0" \ +- "mmcroot=/dev/mmcblk0p2 rw\0" \ +- "mmcrootfstype=ext3 rootwait\0" \ +- "nandroot=ubi0:rootfs ubi.mtd=4\0" \ +- "nandrootfstype=ubifs\0" \ +- "ramroot=/dev/ram0 rw ramdisk_size=65536 initrd=0x81000000,64M\0" \ +- "ramrootfstype=ext2\0" \ ++ "optargs=\0" \ + "mmcargs=setenv bootargs console=${console} " \ + "${optargs} " \ +- "mpurate=${mpurate} " \ +- "buddy=${buddy} "\ +- "camera=${camera} "\ +- "vram=${vram} " \ +- "omapfb.mode=dvi:${dvimode} " \ +- "omapdss.def_disp=${defaultdisplay} " \ +- "root=${mmcroot} " \ +- "rootfstype=${mmcrootfstype}\0" \ +- "nandargs=setenv bootargs console=${console} " \ +- "${optargs} " \ +- "mpurate=${mpurate} " \ +- "buddy=${buddy} "\ +- "camera=${camera} "\ +- "vram=${vram} " \ +- "omapfb.mode=dvi:${dvimode} " \ +- "omapdss.def_disp=${defaultdisplay} " \ +- "root=${nandroot} " \ +- "rootfstype=${nandrootfstype}\0" \ ++ "root=${root} " \ ++ "${musb} " \ ++ "${cmdline}\0" \ ++ "loadimage=load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \ ++ "loadrd=load ${devtype} ${bootpart} ${rdaddr} ${bootdir}/${rdfile}\0" \ ++ "loadfdt=echo loading ${fdtdir}/${fdtfile} ...; load ${devtype} ${bootpart} ${fdtaddr} ${fdtdir}/${fdtfile}\0" \ ++ "mmcboot=usb start;" \ ++ "for devtype in mmc usb; do " \ ++ "setenv devnum 0;" \ ++ "while ${devtype} dev ${devnum}; do " \ ++ "echo ${devtype} found on device ${devnum};" \ ++ "setenv bootpart ${devnum}:1;" \ ++ "if test ${devtype} = mmc; then part uuid mmc ${devnum}:2 uuid; else part uuid ${devtype} ${devnum}:1 uuid; fi;" \ ++ "part uuid ${devtype} ${rootpart} uuid;" \ ++ "setenv root PARTUUID=${uuid} rw rootwait;" \ ++ "echo Checking for: ${bootdir}/uEnv.txt ...;" \ ++ "if test -e ${devtype} ${bootpart} ${bootdir}/uEnv.txt; then " \ ++ "load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/uEnv.txt;" \ ++ "env import -t ${loadaddr} ${filesize};" \ ++ "echo Loaded environment from ${bootdir}/uEnv.txt;" \ ++ "echo Checking if uenvcmd is set ...;" \ ++ "if test -n ${uenvcmd}; then " \ ++ "echo Running uenvcmd ...;" \ ++ "run uenvcmd;" \ ++ "fi;" \ ++ "fi;" \ ++ "run scan_dev_for_boot;" \ ++ "if run loadimage; then " \ ++ "run mmcargs;" \ ++ "if run loadfdt; then " \ ++ "if run loadrd; then " \ ++ "bootz ${loadaddr} ${rdaddr}:${filesize} ${fdtaddr};" \ ++ "else " \ ++ "bootz ${loadaddr} - ${fdtaddr};" \ ++ "fi;" \ ++ "fi;" \ ++ "else " \ ++ "echo No kernel found;" \ ++ "fi;" \ ++ "setexpr devnum ${devnum} + 1;" \ ++ "done;" \ ++ "done;\0" \ + "findfdt=" \ + "if test $beaglerev = AxBx; then " \ + "setenv fdtfile omap3-beagle.dtb; fi; " \ +@@ -181,81 +207,11 @@ + "if test $beaglerev = xMC; then " \ + "setenv fdtfile omap3-beagle-xm.dtb; fi; " \ + "if test $fdtfile = undefined; then " \ +- "echo WARNING: Could not determine device tree to use; fi; \0" \ +- "validatefdt=" \ +- "if test $beaglerev = xMAB; then " \ +- "if test ! -e mmc ${bootpart} ${bootdir}/${fdtfile}; then " \ +- "setenv fdtfile omap3-beagle-xm.dtb; " \ +- "fi; " \ +- "fi; \0" \ +- "bootenv=uEnv.txt\0" \ +- "loadbootenv=fatload mmc ${mmcdev} ${loadaddr} ${bootenv}\0" \ +- "importbootenv=echo Importing environment from mmc ...; " \ +- "env import -t -r $loadaddr $filesize\0" \ +- "ramargs=setenv bootargs console=${console} " \ +- "${optargs} " \ +- "mpurate=${mpurate} " \ +- "buddy=${buddy} "\ +- "vram=${vram} " \ +- "omapfb.mode=dvi:${dvimode} " \ +- "omapdss.def_disp=${defaultdisplay} " \ +- "root=${ramroot} " \ +- "rootfstype=${ramrootfstype}\0" \ +- "loadramdisk=load mmc ${bootpart} ${rdaddr} ${bootdir}/${ramdisk}\0" \ +- "loadimage=load mmc ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \ +- "loadbootscript=load mmc ${mmcdev} ${loadaddr} boot.scr\0" \ +- "bootscript=echo Running bootscript from mmc${mmcdev} ...; " \ +- "source ${loadaddr}\0" \ +- "loadfdt=run validatefdt; load mmc ${bootpart} ${fdtaddr} ${bootdir}/${fdtfile}\0" \ +- "mmcboot=echo Booting from mmc ...; " \ +- "run mmcargs; " \ +- "bootm ${loadaddr}\0" \ +- "mmcbootz=echo Booting with DT from mmc${mmcdev} ...; " \ +- "run mmcargs; " \ +- "bootz ${loadaddr} - ${fdtaddr}\0" \ +- "nandboot=echo Booting from nand ...; " \ +- "run nandargs; " \ +- "nand read ${loadaddr} 280000 400000; " \ +- "bootm ${loadaddr}\0" \ +- "ramboot=echo Booting from ramdisk ...; " \ +- "run ramargs; " \ +- "bootm ${loadaddr}\0" \ +- "userbutton=if gpio input 173; then run userbutton_xm; " \ +- "else run userbutton_nonxm; fi;\0" \ +- "userbutton_xm=gpio input 4;\0" \ +- "userbutton_nonxm=gpio input 7;\0" +-/* "run userbutton" will return 1 (false) if pressed and 0 (true) if not */ ++ "echo WARNING: Could not determine device tree to use; fi; \0" ++ + #define CONFIG_BOOTCOMMAND \ + "run findfdt; " \ +- "mmc dev ${mmcdev}; if mmc rescan; then " \ +- "if run userbutton; then " \ +- "setenv bootenv uEnv.txt;" \ +- "else " \ +- "setenv bootenv user.txt;" \ +- "fi;" \ +- "echo SD/MMC found on device ${mmcdev};" \ +- "if run loadbootenv; then " \ +- "echo Loaded environment from ${bootenv};" \ +- "run importbootenv;" \ +- "fi;" \ +- "if test -n $uenvcmd; then " \ +- "echo Running uenvcmd ...;" \ +- "run uenvcmd;" \ +- "fi;" \ +- "if run loadbootscript; then " \ +- "run bootscript; " \ +- "else " \ +- "if run loadimage; then " \ +- "run mmcboot;" \ +- "fi;" \ +- "fi; " \ +- "fi;" \ +- "run nandboot;" \ +- "setenv bootfile zImage;" \ +- "if run loadimage; then " \ +- "run loadfdt;" \ +- "run mmcbootz; " \ +- "fi; " \ ++ "run mmcboot" + + /* + * OMAP3 has 12 GP timers, they can be driven by the system clock diff --git a/libre/uboot4extlinux-omap3_beagle/PKGBUILD b/libre/uboot4extlinux-omap3_beagle/PKGBUILD new file mode 100644 index 000000000..a3c16f7cc --- /dev/null +++ b/libre/uboot4extlinux-omap3_beagle/PKGBUILD @@ -0,0 +1,51 @@ +# U-Boot: BeagleBoard and BeagleBoard-xM +# Maintainer: André Silva + +buildarch=4 + +pkgname=uboot4extlinux-omap3_beagle +pkgver=2016.01 +pkgrel=1 +pkgdesc="U-Boot with Extlinux support for BeagleBoard and BeagleBoard-xM" +arch=('armv7h') +url="http://git.denx.de/u-boot.git/" +license=('GPL') +replaces=('uboot-beagleboard-linux-libre' 'uboot-beagleboard-linux-libre-lts' + 'uboot-beagleboard-linux-libre-grsec' 'uboot-beagleboard-linux-libre-pck' + 'uboot-beagleboard' 'uboot-omap3_beagle') +conflicts=('uboot-beagleboard-linux-libre' 'uboot-beagleboard-linux-libre-lts' + 'uboot-beagleboard-linux-libre-grsec' 'uboot-beagleboard-linux-libre-pck' + 'uboot-beagleboard' 'uboot-omap3_beagle' 'uboot4grub-omap3_beagle') +makedepends=('bc') +backup=(boot/extlinux/extlinux.conf) +install=${pkgname}.install +source=("ftp://ftp.denx.de/pub/u-boot/u-boot-${pkgver}.tar.bz2" + '0001-parabola-arm-modifications.patch' + 'extlinux.conf' + 'uEnv.txt') +md5sums=('7d4f65fd43d4d706f5c5650e020d899d' + 'da3d52f785bce02602f88fb85f74de2f' + '5172c86fd491728aad8109ebb8a997f8' + 'd41d8cd98f00b204e9800998ecf8427e') + +prepare() { + cd u-boot-${pkgver} + patch -Np1 -i ../0001-parabola-arm-modifications.patch +} + +build() { + cd u-boot-${pkgver} + + unset LDFLAGS CFLAGS CXXFLAGS + + make distclean + make omap3_beagle_config + make +} + +package() { + cd u-boot-${pkgver} + mkdir -p "${pkgdir}"/boot/extlinux + cp MLO u-boot.img "${srcdir}"/uEnv.txt "${pkgdir}"/boot + cp "${srcdir}"/extlinux.conf "${pkgdir}"/boot/extlinux +} diff --git a/libre/uboot4extlinux-omap3_beagle/extlinux.conf b/libre/uboot4extlinux-omap3_beagle/extlinux.conf new file mode 100644 index 000000000..708bfcddb --- /dev/null +++ b/libre/uboot4extlinux-omap3_beagle/extlinux.conf @@ -0,0 +1,46 @@ +menu title Welcome to U-Boot with Extlinux support! + +label Parabola GNU/Linux-libre, linux-libre kernel + kernel /vmlinuz-linux-libre + append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 + fdtdir /dtbs/linux-libre + +#label Parabola GNU/Linux-libre, linux-libre-lts kernel +# kernel /vmlinuz-linux-libre-lts +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /dtbs/linux-libre-lts + +#label Parabola GNU/Linux-libre, linux-libre-knock kernel +# kernel /vmlinuz-linux-libre-knock +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /dtbs/linux-libre-knock + +#label Parabola GNU/Linux-libre, linux-libre-lts-knock kernel +# kernel /vmlinuz-linux-libre-lts-knock +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /dtbs/linux-libre-lts-knock + +#label Parabola GNU/Linux-libre, linux-libre-grsec kernel +# kernel /vmlinuz-linux-libre-grsec +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /dtbs/linux-libre-grsec + +#label Parabola GNU/Linux-libre, linux-libre-grsec-knock kernel +# kernel /vmlinuz-linux-libre-grsec-knock +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /dtbs/linux-libre-grsec-knock + +#label Parabola GNU/Linux-libre, linux-libre-audit kernel +# kernel /vmlinuz-linux-libre-audit +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /dtbs/linux-libre-audit + +#label Parabola GNU/Linux-libre, linux-libre-pck kernel +# kernel /vmlinuz-linux-libre-pck +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /dtbs/linux-libre-pck + +#label Parabola GNU/Linux-libre, linux-libre-rt kernel +# kernel /vmlinuz-linux-libre-rt +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /dtbs/linux-libre-rt diff --git a/libre/uboot4extlinux-omap3_beagle/uEnv.txt b/libre/uboot4extlinux-omap3_beagle/uEnv.txt new file mode 100644 index 000000000..e69de29bb diff --git a/libre/uboot4extlinux-omap3_beagle/uboot4extlinux-omap3_beagle.install b/libre/uboot4extlinux-omap3_beagle/uboot4extlinux-omap3_beagle.install new file mode 100644 index 000000000..8aff26699 --- /dev/null +++ b/libre/uboot4extlinux-omap3_beagle/uboot4extlinux-omap3_beagle.install @@ -0,0 +1,11 @@ +extlinux_warning() { + echo "==> WARNING: U-Boot uses Extlinux support to boot up. For setting it up, edit /boot/extlinux/extlinux.conf" +} + +post_install() { + extlinux_warning +} + +post_upgrade() { + extlinux_warning +} diff --git a/libre/uboot4extlinux-omap4_panda/0001-parabola-arm-modifications.patch b/libre/uboot4extlinux-omap4_panda/0001-parabola-arm-modifications.patch new file mode 100644 index 000000000..09aee7ce0 --- /dev/null +++ b/libre/uboot4extlinux-omap4_panda/0001-parabola-arm-modifications.patch @@ -0,0 +1,135 @@ +diff -Nur u-boot-2016.01.orig/include/configs/ti_omap4_common.h u-boot-2016.01/include/configs/ti_omap4_common.h +--- u-boot-2016.01.orig/include/configs/ti_omap4_common.h 2016-01-12 11:06:54.000000000 -0300 ++++ u-boot-2016.01/include/configs/ti_omap4_common.h 2016-02-24 23:19:09.761629260 -0300 +@@ -46,7 +46,6 @@ + * the timings to use or use pre-determined timings (based on using the + * dynamic method. Default to the static timing infomation. + */ +-#define CONFIG_SYS_EMIF_PRECALCULATED_TIMING_REGS + #ifndef CONFIG_SYS_EMIF_PRECALCULATED_TIMING_REGS + #define CONFIG_SYS_AUTOMATIC_SDRAM_DETECTION + #define CONFIG_SYS_DEFAULT_LPDDR2_TIMINGS +@@ -79,33 +78,74 @@ + #define CONFIG_USB_TTY 1 + #define CONFIG_SYS_CONSOLE_IS_IN_ENV 1 + ++/* Parabola GNU/Linux-libre extras */ ++#define CONFIG_IDENT_STRING " Parabola GNU/Linux-libre" ++ ++/* Enable Extlinux boot support */ ++#define CONFIG_CMD_PXE ++#define CONFIG_MENU ++#define BOOT_TARGET_DEVICES(func) ++#include ++ + /* + * Environment setup + */ + #define CONFIG_EXTRA_ENV_SETTINGS \ ++ BOOTENV \ + DEFAULT_LINUX_BOOT_ENV \ + DEFAULT_MMC_TI_ARGS \ + "console=ttyO2,115200n8\0" \ + "fdtfile=undefined\0" \ + "bootpart=0:2\0" \ + "bootdir=/boot\0" \ ++ "fdtdir=/boot/dtbs\0" \ + "bootfile=zImage\0" \ ++ "rdfile=initramfs-linux.img\0" \ + "usbtty=cdc_acm\0" \ + "vram=16M\0" \ +- "loadbootscript=load mmc ${mmcdev} ${loadaddr} boot.scr\0" \ +- "bootscript=echo Running bootscript from mmc${mmcdev} ...; " \ +- "source ${loadaddr}\0" \ +- "loadbootenv=load mmc ${mmcdev} ${loadaddr} uEnv.txt\0" \ +- "importbootenv=echo Importing environment from mmc${mmcdev} ...; " \ +- "env import -t ${loadaddr} ${filesize}\0" \ +- "loadimage=load mmc ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \ +- "loaduimage=load mmc ${mmcdev} ${loadaddr} uImage\0" \ +- "mmcboot=echo Booting from mmc${mmcdev} ...; " \ +- "run args_mmc; " \ +- "bootz ${loadaddr} - ${fdtaddr}\0" \ +- "uimageboot=echo Booting from mmc${mmcdev} ...; " \ +- "run args_mmc; " \ +- "bootm ${loadaddr}\0" \ ++ "optargs=\0" \ ++ "mmcargs=setenv bootargs console=${console} " \ ++ "vram=${vram} " \ ++ "root=${root} " \ ++ "${optargs}\0" \ ++ "loadimage=load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \ ++ "loadrd=load ${devtype} ${bootpart} ${rdaddr} ${bootdir}/${rdfile}\0" \ ++ "loadfdt=echo loading ${fdtdir}/${fdtfile} ...; load ${devtype} ${bootpart} ${fdtaddr} ${fdtdir}/${fdtfile}\0" \ ++ "mmcboot=usb start;" \ ++ "for devtype in mmc usb; do " \ ++ "setenv devnum 0;" \ ++ "while ${devtype} dev ${devnum}; do " \ ++ "echo ${devtype} found on device ${devnum};" \ ++ "setenv bootpart ${devnum}:1;" \ ++ "part uuid ${devtype} ${bootpart} uuid;" \ ++ "setenv root PARTUUID=${uuid} rw rootwait;" \ ++ "echo Checking for: ${bootdir}/uEnv.txt ...;" \ ++ "if test -e ${devtype} ${bootpart} ${bootdir}/uEnv.txt; then " \ ++ "load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/uEnv.txt;" \ ++ "env import -t ${loadaddr} ${filesize};" \ ++ "echo Loaded environment from ${bootdir}/uEnv.txt;" \ ++ "echo Checking if uenvcmd is set ...;" \ ++ "if test -n ${uenvcmd}; then " \ ++ "echo Running uenvcmd ...;" \ ++ "run uenvcmd;" \ ++ "fi;" \ ++ "fi;" \ ++ "run scan_dev_for_boot;" \ ++ "if run loadimage; then " \ ++ "run mmcargs;" \ ++ "if run loadfdt; then " \ ++ "if run loadrd; then " \ ++ "bootz ${loadaddr} ${rdaddr}:${filesize} ${fdtaddr};" \ ++ "else " \ ++ "bootz ${loadaddr} - ${fdtaddr};" \ ++ "fi;" \ ++ "fi;" \ ++ "else " \ ++ "echo No kernel found;" \ ++ "fi;" \ ++ "setexpr devnum ${devnum} + 1;" \ ++ "done;" \ ++ "done;\0" \ + "findfdt="\ + "if test $board_name = sdp4430; then " \ + "setenv fdtfile omap4-sdp.dtb; fi; " \ +@@ -118,32 +158,11 @@ + "if test $board_name = duovero; then " \ + "setenv fdtfile omap4-duovero-parlor.dtb; fi;" \ + "if test $fdtfile = undefined; then " \ +- "echo WARNING: Could not determine device tree to use; fi; \0" \ +- "loadfdt=load mmc ${bootpart} ${fdtaddr} ${bootdir}/${fdtfile}\0" \ ++ "echo WARNING: Could not determine device tree to use; fi; \0" + + #define CONFIG_BOOTCOMMAND \ + "run findfdt; " \ +- "mmc dev ${mmcdev}; if mmc rescan; then " \ +- "echo SD/MMC found on device ${mmcdev};" \ +- "if run loadbootscript; then " \ +- "run bootscript; " \ +- "else " \ +- "if run loadbootenv; then " \ +- "run importbootenv; " \ +- "fi;" \ +- "if test -n ${uenvcmd}; then " \ +- "echo Running uenvcmd ...;" \ +- "run uenvcmd;" \ +- "fi;" \ +- "fi;" \ +- "if run loadimage; then " \ +- "run loadfdt;" \ +- "run mmcboot; " \ +- "fi; " \ +- "if run loaduimage; then " \ +- "run uimageboot;" \ +- "fi; " \ +- "fi" ++ "run mmcboot" + + /* + * Defines for SPL diff --git a/libre/uboot4extlinux-omap4_panda/PKGBUILD b/libre/uboot4extlinux-omap4_panda/PKGBUILD new file mode 100644 index 000000000..cf9132074 --- /dev/null +++ b/libre/uboot4extlinux-omap4_panda/PKGBUILD @@ -0,0 +1,49 @@ +# U-Boot: PandaBoard and PandaBoard ES +# Maintainer: André Silva + +buildarch=4 + +pkgname=uboot4extlinux-omap4_panda +pkgver=2016.01 +pkgrel=1 +pkgdesc="U-Boot with Extlinux support for PandaBoard and PandaBoard ES" +arch=('armv7h') +url="http://git.denx.de/u-boot.git/" +replaces=('uboot-pandaboard-linux-libre' 'uboot-pandaboard' 'uboot-omap4_panda') +conflicts=('uboot-pandaboard-linux-libre' 'uboot-pandaboard' 'uboot-omap4_panda' 'uboot4grub-omap4_panda') +makedepends=('bc') +license=('GPL') +install=${pkgname}.install +backup=('boot/extlinux/extlinux.conf' 'boot/uEnv.txt') +source=("ftp://ftp.denx.de/pub/u-boot/u-boot-${pkgver}.tar.bz2" + '0001-parabola-arm-modifications.patch' + 'extlinux.conf' + 'uEnv.txt') +md5sums=('7d4f65fd43d4d706f5c5650e020d899d' + 'b74e858feeed48acaba5ac0548d675ca' + '12c61073bb860f4c8d8ec59145c267ed' + '86004660f2912861a040e335c9c0e85b') + +prepare() { + cd u-boot-${pkgver} + + patch -Np1 -i ../0001-parabola-arm-modifications.patch +} + +build() { + cd u-boot-${pkgver} + + unset LDFLAGS + + make distclean + make omap4_panda_config + make +} + +package() { + cd u-boot-${pkgver} + + mkdir -p "${pkgdir}"/boot/extlinux + cp MLO u-boot.img "${srcdir}"/uEnv.txt "${pkgdir}"/boot + cp "${srcdir}"/extlinux.conf "${pkgdir}"/boot/extlinux +} diff --git a/libre/uboot4extlinux-omap4_panda/extlinux.conf b/libre/uboot4extlinux-omap4_panda/extlinux.conf new file mode 100644 index 000000000..725121811 --- /dev/null +++ b/libre/uboot4extlinux-omap4_panda/extlinux.conf @@ -0,0 +1,46 @@ +menu title Welcome to U-Boot with Extlinux support! + +label Parabola GNU/Linux-libre, linux-libre kernel + kernel /boot/vmlinuz-linux-libre + append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 + fdtdir /boot/dtbs/linux-libre + +#label Parabola GNU/Linux-libre, linux-libre-lts kernel +# kernel /boot/vmlinuz-linux-libre-lts +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /boot/dtbs/linux-libre-lts + +#label Parabola GNU/Linux-libre, linux-libre-knock kernel +# kernel /boot/vmlinuz-linux-libre-knock +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /boot/dtbs/linux-libre-knock + +#label Parabola GNU/Linux-libre, linux-libre-lts-knock kernel +# kernel /boot/vmlinuz-linux-libre-lts-knock +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /boot/dtbs/linux-libre-lts-knock + +#label Parabola GNU/Linux-libre, linux-libre-grsec kernel +# kernel /boot/vmlinuz-linux-libre-grsec +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /boot/dtbs/linux-libre-grsec + +#label Parabola GNU/Linux-libre, linux-libre-grsec-knock kernel +# kernel /boot/vmlinuz-linux-libre-grsec-knock +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /boot/dtbs/linux-libre-grsec-knock + +#label Parabola GNU/Linux-libre, linux-libre-audit kernel +# kernel /boot/vmlinuz-linux-libre-audit +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /boot/dtbs/linux-libre-audit + +#label Parabola GNU/Linux-libre, linux-libre-pck kernel +# kernel /boot/vmlinuz-linux-libre-pck +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /boot/dtbs/linux-libre-pck + +#label Parabola GNU/Linux-libre, linux-libre-rt kernel +# kernel /boot/vmlinuz-linux-libre-rt +# append root=/dev/mmcblk0p1 rw console=ttyO2,115200n8 +# fdtdir /boot/dtbs/linux-libre-rt diff --git a/libre/uboot4extlinux-omap4_panda/uEnv.txt b/libre/uboot4extlinux-omap4_panda/uEnv.txt new file mode 100644 index 000000000..55298e1a9 --- /dev/null +++ b/libre/uboot4extlinux-omap4_panda/uEnv.txt @@ -0,0 +1,2 @@ +# Uncomment and add any additional kernel parameters to optargs +#optargs= diff --git a/libre/uboot4extlinux-omap4_panda/uboot4extlinux-omap4_panda.install b/libre/uboot4extlinux-omap4_panda/uboot4extlinux-omap4_panda.install new file mode 100644 index 000000000..771f1f0b3 --- /dev/null +++ b/libre/uboot4extlinux-omap4_panda/uboot4extlinux-omap4_panda.install @@ -0,0 +1,26 @@ +extlinux_warning() { + echo "==> WARNING: U-Boot uses Extlinux support to boot up. For setting it up, edit /boot/extlinux/extlinux.conf" +} + +flash_uboot() { + echo "A new U-Boot version needs to be flashed onto /dev/mmcblk0." + echo "Do this now? [y|N]" + read -r shouldwe + if [[ $shouldwe =~ ^([yY][eE][sS]|[yY])$ ]]; then + dd if=/boot/MLO of=/dev/mmcblk0 count=1 seek=1 conv=notrunc bs=128k + dd if=/boot/u-boot.img of=/dev/mmcblk0 count=2 seek=1 conv=notrunc bs=384k + else + echo "You can do this later by running:" + echo "# dd if=/boot/MLO of=/dev/mmcblk0 count=1 seek=1 conv=notrunc bs=128k" + echo "# dd if=/boot/u-boot.img of=/dev/mmcblk0 count=2 seek=1 conv=notrunc bs=384k" + fi + extlinux_warning +} + +post_install() { + flash_uboot +} + +post_upgrade() { + flash_uboot +} -- cgit v1.2.3