From 785275ccb99d60da8abbbe0f80104f3d30ef4248 Mon Sep 17 00:00:00 2001 From: Chris Fiege Date: Mon, 3 Jul 2017 16:07:50 +0200 Subject: platform-v72: mx6: create own mx6 barebox defaultenv Using this change the barebox-mx6 package has its own defaultenv directory. Signed-off-by: Chris Fiege --- configs/platform-v7a/barebox-mx6-defaultenv/boot/9p | 10 ++++++++++ configs/platform-v7a/barebox-mx6-defaultenv/boot/bootchoser | 3 +++ configs/platform-v7a/barebox-mx6-defaultenv/init/bootsource | 13 +++++++++++++ .../barebox-mx6-defaultenv/nv/bootstate.system0.priority | 1 + .../barebox-mx6-defaultenv/nv/bootstate.system1.priority | 1 + .../barebox-mx6-defaultenv/nv/linux.bootargs.console | 1 + configs/platform-v7a/barebox-mx6.config | 2 +- 7 files changed, 30 insertions(+), 1 deletion(-) create mode 100644 configs/platform-v7a/barebox-mx6-defaultenv/boot/9p create mode 100644 configs/platform-v7a/barebox-mx6-defaultenv/boot/bootchoser create mode 100644 configs/platform-v7a/barebox-mx6-defaultenv/init/bootsource create mode 100644 configs/platform-v7a/barebox-mx6-defaultenv/nv/bootstate.system0.priority create mode 100644 configs/platform-v7a/barebox-mx6-defaultenv/nv/bootstate.system1.priority create mode 100644 configs/platform-v7a/barebox-mx6-defaultenv/nv/linux.bootargs.console diff --git a/configs/platform-v7a/barebox-mx6-defaultenv/boot/9p b/configs/platform-v7a/barebox-mx6-defaultenv/boot/9p new file mode 100644 index 0000000..264ffec --- /dev/null +++ b/configs/platform-v7a/barebox-mx6-defaultenv/boot/9p @@ -0,0 +1,10 @@ +#!/bin/sh + +addpart /dev/nor0 "8M@32M(kernel)" +addpart /dev/nor0 "512k@40M(dtb)" +global.bootm.image="/dev/nor0.kernel" +global.bootm.oftree="/dev/nor0.dtb" + +global linux.bootargs.base="console=ttyAMA0,115200 loglevel=5 ptxdist-devel" + +global linux.bootargs.root="root=/dev/root rootfstype=9p rootflags=trans=virtio" \ No newline at end of file diff --git a/configs/platform-v7a/barebox-mx6-defaultenv/boot/bootchoser b/configs/platform-v7a/barebox-mx6-defaultenv/boot/bootchoser new file mode 100644 index 0000000..3b2e19a --- /dev/null +++ b/configs/platform-v7a/barebox-mx6-defaultenv/boot/bootchoser @@ -0,0 +1,3 @@ +#!/bin/sh + +bootchoser -d diff --git a/configs/platform-v7a/barebox-mx6-defaultenv/init/bootsource b/configs/platform-v7a/barebox-mx6-defaultenv/init/bootsource new file mode 100644 index 0000000..4de7163 --- /dev/null +++ b/configs/platform-v7a/barebox-mx6-defaultenv/init/bootsource @@ -0,0 +1,13 @@ +#!/bin/sh + +if [ -n "$nv.boot.default" ]; then + exit +fi + +if [ $bootsource = mmc ]; then + global.boot.default="bootchooser net" +elif [ $bootsource = net ]; then + global.boot.default="net bootchooser" +else + global.boot.default="disk0.1 net" +fi diff --git a/configs/platform-v7a/barebox-mx6-defaultenv/nv/bootstate.system0.priority b/configs/platform-v7a/barebox-mx6-defaultenv/nv/bootstate.system0.priority new file mode 100644 index 0000000..f599e28 --- /dev/null +++ b/configs/platform-v7a/barebox-mx6-defaultenv/nv/bootstate.system0.priority @@ -0,0 +1 @@ +10 diff --git a/configs/platform-v7a/barebox-mx6-defaultenv/nv/bootstate.system1.priority b/configs/platform-v7a/barebox-mx6-defaultenv/nv/bootstate.system1.priority new file mode 100644 index 0000000..209e3ef --- /dev/null +++ b/configs/platform-v7a/barebox-mx6-defaultenv/nv/bootstate.system1.priority @@ -0,0 +1 @@ +20 diff --git a/configs/platform-v7a/barebox-mx6-defaultenv/nv/linux.bootargs.console b/configs/platform-v7a/barebox-mx6-defaultenv/nv/linux.bootargs.console new file mode 100644 index 0000000..705752c --- /dev/null +++ b/configs/platform-v7a/barebox-mx6-defaultenv/nv/linux.bootargs.console @@ -0,0 +1 @@ +loglevel=5 systemd.log_level=warning systemd.show_status=auto diff --git a/configs/platform-v7a/barebox-mx6.config b/configs/platform-v7a/barebox-mx6.config index 4362b87..c02914f 100644 --- a/configs/platform-v7a/barebox-mx6.config +++ b/configs/platform-v7a/barebox-mx6.config @@ -236,7 +236,7 @@ CONFIG_DEFAULT_COMPRESSION_NONE=y CONFIG_DEFAULT_ENVIRONMENT_GENERIC_NEW=y CONFIG_DEFAULT_ENVIRONMENT_GENERIC_NEW_MENU=y CONFIG_DEFAULT_ENVIRONMENT_GENERIC_NEW_DFU=y -CONFIG_DEFAULT_ENVIRONMENT_PATH="" +CONFIG_DEFAULT_ENVIRONMENT_PATH="${PTXDIST_PLATFORMCONFIGDIR}/barebox-mx6-defaultenv" # CONFIG_BAREBOXENV_TARGET is not set # CONFIG_BAREBOXCRC32_TARGET is not set CONFIG_POLLER=y -- cgit v1.2.3