Platform

The main Radix cross Linux repository contains build scripts of the GNU/Linux distribution.

1000 Commits   6 Branches   3 Tags   |
Index: examples/hello/Makefile
===================================================================
--- examples/hello/Makefile	(revision 646)
+++ examples/hello/Makefile	(revision 647)
@@ -143,4 +143,4 @@
 	 echo "short_description=\"$(HELLO_PKG_SHORT_DESCRIPTION)\"" >> $(HELLO_PKG)/.PKGINFO ; \
 	 echo "url=$(HELLO_PKG_URL)"                                 >> $(HELLO_PKG)/.PKGINFO ; \
 	 echo "license=$(HELLO_PKG_LICENSE)"                         >> $(HELLO_PKG)/.PKGINFO
-	@$(FAKEROOT) sh -c "cd $(HELLO_PKG) && chown -R root:root . && $(MAKE_PACKAGE) --flavour=$(FLAVOUR) --linkadd yes .."
+	@$(PSEUDO) sh -c "cd $(HELLO_PKG) && chown -R root:root . && $(MAKE_PACKAGE) --flavour=$(FLAVOUR) --linkadd yes .."
Index: examples/hello-dll/Makefile
===================================================================
--- examples/hello-dll/Makefile	(revision 646)
+++ examples/hello-dll/Makefile	(revision 647)
@@ -9,7 +9,7 @@
 include ../../../build-system/constants.mk
 
 
-REQUIRES = libs/glibc/2.23
+REQUIRES = libs/glibc/2.24
 
 
 # ======= __END_OF_REQUIRES__ =======
@@ -150,4 +150,4 @@
 	 echo "short_description=\"$(HELLO_PKG_SHORT_DESCRIPTION)\"" >> $(HELLO_PKG)/.PKGINFO ; \
 	 echo "url=$(HELLO_PKG_URL)"                                 >> $(HELLO_PKG)/.PKGINFO ; \
 	 echo "license=$(HELLO_PKG_LICENSE)"                         >> $(HELLO_PKG)/.PKGINFO
-	@$(FAKEROOT) sh -c "cd $(HELLO_PKG) && chown -R root:root . && $(MAKE_PACKAGE) --flavour=$(FLAVOUR) --linkadd yes .."
+	@$(PSEUDO) sh -c "cd $(HELLO_PKG) && chown -R root:root . && $(MAKE_PACKAGE) --flavour=$(FLAVOUR) --linkadd yes .."
Index: examples/tiny/Makefile
===================================================================
--- examples/tiny/Makefile	(revision 646)
+++ examples/tiny/Makefile	(revision 647)
@@ -3,7 +3,6 @@
 COMPONENT_TARGETS += $(HARDWARE_CB1N)
 COMPONENT_TARGETS += $(HARDWARE_CB3N)
 COMPONENT_TARGETS += $(HARDWARE_AT91S)
-COMPONENT_TARGETS += $(HARDWARE_DM64N)
 COMPONENT_TARGETS += $(HARDWARE_L17UC)
 
 #
Index: init-devices/Makefile
===================================================================
--- init-devices/Makefile	(revision 646)
+++ init-devices/Makefile	(revision 647)
@@ -6,7 +6,14 @@
 COMPONENT_TARGETS += $(HARDWARE_CB3X)
 COMPONENT_TARGETS += $(HARDWARE_FFRK3288)
 COMPONENT_TARGETS += $(HARDWARE_M201)
-COMPONENT_TARGETS += $(HARDWARE_MXQ)
+COMPONENT_TARGETS += $(HARDWARE_MXV)
+COMPONENT_TARGETS += $(HARDWARE_P201)
+COMPONENT_TARGETS += $(HARDWARE_NEXBOX_A95X)
+COMPONENT_TARGETS += $(HARDWARE_ODROID_C2)
+COMPONENT_TARGETS += $(HARDWARE_P212)
+COMPONENT_TARGETS += $(HARDWARE_KHADAS_VIM)
+COMPONENT_TARGETS += $(HARDWARE_Q201)
+COMPONENT_TARGETS += $(HARDWARE_ENYBOX_X2)
 COMPONENT_TARGETS += $(HARDWARE_NIT6Q)
 COMPONENT_TARGETS += $(HARDWARE_OMAP5UEVM)
 COMPONENT_TARGETS += $(HARDWARE_DRA7XXEVM)
@@ -26,7 +33,7 @@
 PKG_GROUP = base
 
 INIT_DEV_PKG_NAME                = init-devices
-INIT_DEV_PKG_VERSION             = 1.2.1
+INIT_DEV_PKG_VERSION             = 1.2.2
 INIT_DEV_PKG_ARCH                = $(TOOLCHAIN)
 INIT_DEV_PKG_DISTRO_NAME         = $(DISTRO_NAME)
 INIT_DEV_PKG_DISTRO_VERSION      = $(DISTRO_VERSION)
@@ -83,115 +90,115 @@
 	 echo "short_description=\"$(INIT_DEV_PKG_SHORT_DESCRIPTION)\"" >> $(INIT_DEV_PKG)/.PKGINFO ; \
 	 echo "url=$(INIT_DEV_PKG_URL)"                                 >> $(INIT_DEV_PKG)/.PKGINFO ; \
 	 echo "license=$(INIT_DEV_PKG_LICENSE)"                         >> $(INIT_DEV_PKG)/.PKGINFO
-	@$(FAKEROOT) sh -c "cd $(INIT_DEV_PKG)   && \
-	                    chown -R root:root . && \
-	                    ( cd dev              ; \
-	                      mknod --mode=600 console       c    5 1   ; \
-	                      \
-	                      mknod --mode=660 ppp           c  108 0   ; \
-	                      mknod --mode=666 null          c    1 3   ; \
-	                      mknod --mode=666 random        c    1 8   ; \
-	                      mknod --mode=666 urandom       c    1 9   ; \
-	                      mknod --mode=666 zero          c    1 5   ; \
-	                      \
-	                      mknod --mode=660 fb0           c   29 0   ; \
-	                      mknod --mode=660 fb1           c   29 1   ; \
-	                      \
-	                      mknod --mode=660 apm_bios      c   10 134 ; \
-	                      \
-	                      mknod --mode=660 hda           b    3 0   ; \
-	                      mknod --mode=660 hda1          b    3 1   ; \
-	                      mknod --mode=660 hda2          b    3 2   ; \
-	                      mknod --mode=660 hda3          b    3 3   ; \
-	                      mknod --mode=660 hda4          b    3 4   ; \
-	                      \
-	                      mknod --mode=660 sda           b    8 0   ; \
-	                      mknod --mode=660 sda1          b    8 1   ; \
-	                      mknod --mode=660 sda2          b    8 2   ; \
-	                      mknod --mode=660 sda3          b    8 3   ; \
-	                      mknod --mode=660 sda4          b    8 4   ; \
-	                      \
-	                      mknod --mode=660 sdb           b    8 16  ; \
-	                      mknod --mode=660 sdb1          b    8 17  ; \
-	                      mknod --mode=660 sdb2          b    8 18  ; \
-	                      mknod --mode=660 sdb3          b    8 19  ; \
-	                      mknod --mode=660 sdb4          b    8 20  ; \
-	                      \
-	                      mknod --mode=640 mem           c    1 1   ; \
-	                      mknod --mode=640 kmem          c    1 2   ; \
-	                      mknod --mode=644 kmsg          c    1 11  ; \
-	                      mknod --mode=600 kvm           c   10 232 ; \
-	                      \
-	                      mknod --mode=660 mmcblk0       b  179 0   ; \
-	                      mknod --mode=660 mmcblk0p1     b  179 1   ; \
-	                      mknod --mode=660 mmcblk0p2     b  179 2   ; \
-	                      mknod --mode=660 mmcblk0p3     b  179 3   ; \
-	                      mknod --mode=660 mmcblk0p4     b  179 4   ; \
-	                      \
-	                      mknod --mode=660 mmcblk1       b  179 8   ; \
-	                      mknod --mode=660 mmcblk1p1     b  179 9   ; \
-	                      mknod --mode=660 mmcblk1p2     b  179 10  ; \
-	                      mknod --mode=660 mmcblk1p3     b  179 11  ; \
-	                      mknod --mode=660 mmcblk1p4     b  179 12  ; \
-	                      \
-	                      mknod --mode=660 mmcblk1boot0  b  179 16  ; \
-	                      mknod --mode=660 mmcblk1boot1  b  179 24  ; \
-	                      \
-	                      mknod --mode=660 mtd0          c   90 0   ; \
-	                      mknod --mode=660 mtd1          c   90 2   ; \
-	                      mknod --mode=660 mtd2          c   90 4   ; \
-	                      mknod --mode=660 mtd3          c   90 6   ; \
-	                      mknod --mode=660 mtd4          c   90 8   ; \
-	                      mknod --mode=660 mtd5          c   90 10  ; \
-	                      mknod --mode=660 mtd6          c   90 12  ; \
-	                      mknod --mode=660 mtd7          c   90 14  ; \
-	                      \
-	                      mknod --mode=640 mtdblock0     b   31 0   ; \
-	                      mknod --mode=640 mtdblock1     b   31 1   ; \
-	                      mknod --mode=640 mtdblock2     b   31 2   ; \
-	                      mknod --mode=640 mtdblock3     b   31 3   ; \
-	                      mknod --mode=640 mtdblock4     b   31 4   ; \
-	                      mknod --mode=640 mtdblock5     b   31 5   ; \
-	                      mknod --mode=640 mtdblock6     b   31 6   ; \
-	                      mknod --mode=640 mtdblock7     b   31 7   ; \
-	                      \
-	                      mknod --mode=640 ram0          b    1 0   ; \
-	                      mknod --mode=640 ram1          b    1 1   ; \
-	                      mknod --mode=640 ram2          b    1 2   ; \
-	                      mknod --mode=640 ram3          b    1 3   ; \
-	                      \
-	                      mknod --mode=666 tty           c    5 0   ; \
-	                      \
-	                      mknod --mode=660 ttyS0         c    4 64  ; \
-	                      mknod --mode=660 ttyS1         c    4 65  ; \
-	                      mknod --mode=660 ttyS2         c    4 66  ; \
-	                      mknod --mode=660 ttyS3         c    4 67  ; \
-	                      mknod --mode=660 ttyS4         c    4 68  ; \
-	                      mknod --mode=660 ttyS5         c    4 69  ; \
-	                      \
-	                      mknod --mode=640 ttySA0        c  204 5   ; \
-	                      mknod --mode=640 ttySA1        c  204 6   ; \
-	                      mknod --mode=640 ttySA2        c  204 7   ; \
-	                      \
-	                      mknod --mode=640 cusa0         c  205 5   ; \
-	                      mknod --mode=640 cusa1         c  205 6   ; \
-	                      mknod --mode=640 cusa2         c  205 7   ; \
-	                      \
-	                      mknod --mode=600 initctl p ; \
-	                      \
-	                      mkdir -p cgroup ; chmod 755 cgroup ; \
-	                      mkdir -p pts    ; chmod 755 pts    ; \
-	                      mkdir -p shm    ; chmod 755 shm    ; \
-	                      \
-	                      ln -sf null XOR ; \
-	                      \
-	                      chown 0:5   tty ttySA? cusa?    ; \
-	                      chown 0:16  ppp ttyS?           ; \
-	                      chown 0:0   cgroup pts shm null random urandom zero apm_bios initctl ; \
-	                      chown 0:18  fb0 fb1             ; \
-	                      chown 0:6   ram? hda* sda* sdb* ; \
-	                      chown 0:9   mem kmem            ; \
-	                      chown 0:0   kmsg kvm            ; \
-	                      chown 0:0   mtd? mtdblock? \
-	                    ) && \
-	                    $(MAKE_PACKAGE) --linkadd yes .."
+	@$(PSEUDO) sh -c "cd $(INIT_DEV_PKG)   && \
+	                  chown -R root:root . && \
+	                  ( cd dev              ; \
+	                    mknod --mode=600 console       c    5 1   ; \
+	                    \
+	                    mknod --mode=660 ppp           c  108 0   ; \
+	                    mknod --mode=666 null          c    1 3   ; \
+	                    mknod --mode=666 random        c    1 8   ; \
+	                    mknod --mode=666 urandom       c    1 9   ; \
+	                    mknod --mode=666 zero          c    1 5   ; \
+	                    \
+	                    mknod --mode=660 fb0           c   29 0   ; \
+	                    mknod --mode=660 fb1           c   29 1   ; \
+	                    \
+	                    mknod --mode=660 apm_bios      c   10 134 ; \
+	                    \
+	                    mknod --mode=660 hda           b    3 0   ; \
+	                    mknod --mode=660 hda1          b    3 1   ; \
+	                    mknod --mode=660 hda2          b    3 2   ; \
+	                    mknod --mode=660 hda3          b    3 3   ; \
+	                    mknod --mode=660 hda4          b    3 4   ; \
+	                    \
+	                    mknod --mode=660 sda           b    8 0   ; \
+	                    mknod --mode=660 sda1          b    8 1   ; \
+	                    mknod --mode=660 sda2          b    8 2   ; \
+	                    mknod --mode=660 sda3          b    8 3   ; \
+	                    mknod --mode=660 sda4          b    8 4   ; \
+	                    \
+	                    mknod --mode=660 sdb           b    8 16  ; \
+	                    mknod --mode=660 sdb1          b    8 17  ; \
+	                    mknod --mode=660 sdb2          b    8 18  ; \
+	                    mknod --mode=660 sdb3          b    8 19  ; \
+	                    mknod --mode=660 sdb4          b    8 20  ; \
+	                    \
+	                    mknod --mode=640 mem           c    1 1   ; \
+	                    mknod --mode=640 kmem          c    1 2   ; \
+	                    mknod --mode=644 kmsg          c    1 11  ; \
+	                    mknod --mode=600 kvm           c   10 232 ; \
+	                    \
+	                    mknod --mode=660 mmcblk0       b  179 0   ; \
+	                    mknod --mode=660 mmcblk0p1     b  179 1   ; \
+	                    mknod --mode=660 mmcblk0p2     b  179 2   ; \
+	                    mknod --mode=660 mmcblk0p3     b  179 3   ; \
+	                    mknod --mode=660 mmcblk0p4     b  179 4   ; \
+	                    \
+	                    mknod --mode=660 mmcblk1       b  179 8   ; \
+	                    mknod --mode=660 mmcblk1p1     b  179 9   ; \
+	                    mknod --mode=660 mmcblk1p2     b  179 10  ; \
+	                    mknod --mode=660 mmcblk1p3     b  179 11  ; \
+	                    mknod --mode=660 mmcblk1p4     b  179 12  ; \
+	                    \
+	                    mknod --mode=660 mmcblk1boot0  b  179 16  ; \
+	                    mknod --mode=660 mmcblk1boot1  b  179 24  ; \
+	                    \
+	                    mknod --mode=660 mtd0          c   90 0   ; \
+	                    mknod --mode=660 mtd1          c   90 2   ; \
+	                    mknod --mode=660 mtd2          c   90 4   ; \
+	                    mknod --mode=660 mtd3          c   90 6   ; \
+	                    mknod --mode=660 mtd4          c   90 8   ; \
+	                    mknod --mode=660 mtd5          c   90 10  ; \
+	                    mknod --mode=660 mtd6          c   90 12  ; \
+	                    mknod --mode=660 mtd7          c   90 14  ; \
+	                    \
+	                    mknod --mode=640 mtdblock0     b   31 0   ; \
+	                    mknod --mode=640 mtdblock1     b   31 1   ; \
+	                    mknod --mode=640 mtdblock2     b   31 2   ; \
+	                    mknod --mode=640 mtdblock3     b   31 3   ; \
+	                    mknod --mode=640 mtdblock4     b   31 4   ; \
+	                    mknod --mode=640 mtdblock5     b   31 5   ; \
+	                    mknod --mode=640 mtdblock6     b   31 6   ; \
+	                    mknod --mode=640 mtdblock7     b   31 7   ; \
+	                    \
+	                    mknod --mode=640 ram0          b    1 0   ; \
+	                    mknod --mode=640 ram1          b    1 1   ; \
+	                    mknod --mode=640 ram2          b    1 2   ; \
+	                    mknod --mode=640 ram3          b    1 3   ; \
+	                    \
+	                    mknod --mode=666 tty           c    5 0   ; \
+	                    \
+	                    mknod --mode=660 ttyS0         c    4 64  ; \
+	                    mknod --mode=660 ttyS1         c    4 65  ; \
+	                    mknod --mode=660 ttyS2         c    4 66  ; \
+	                    mknod --mode=660 ttyS3         c    4 67  ; \
+	                    mknod --mode=660 ttyS4         c    4 68  ; \
+	                    mknod --mode=660 ttyS5         c    4 69  ; \
+	                    \
+	                    mknod --mode=640 ttySA0        c  204 5   ; \
+	                    mknod --mode=640 ttySA1        c  204 6   ; \
+	                    mknod --mode=640 ttySA2        c  204 7   ; \
+	                    \
+	                    mknod --mode=640 cusa0         c  205 5   ; \
+	                    mknod --mode=640 cusa1         c  205 6   ; \
+	                    mknod --mode=640 cusa2         c  205 7   ; \
+	                    \
+	                    mknod --mode=600 initctl p ; \
+	                    \
+	                    mkdir -p cgroup ; chmod 755 cgroup ; \
+	                    mkdir -p pts    ; chmod 755 pts    ; \
+	                    mkdir -p shm    ; chmod 755 shm    ; \
+	                    \
+	                    ln -sf null XOR ; \
+	                    \
+	                    chown 0:5   tty ttySA? cusa?    ; \
+	                    chown 0:16  ppp ttyS?           ; \
+	                    chown 0:0   cgroup pts shm null random urandom zero apm_bios initctl ; \
+	                    chown 0:18  fb0 fb1             ; \
+	                    chown 0:6   ram? hda* sda* sdb* ; \
+	                    chown 0:9   mem kmem            ; \
+	                    chown 0:0   kmsg kvm            ; \
+	                    chown 0:0   mtd? mtdblock? \
+	                  ) && \
+	                  $(MAKE_PACKAGE) --linkadd yes .."
Index: install-tools/Makefile
===================================================================
--- install-tools/Makefile	(revision 646)
+++ install-tools/Makefile	(revision 647)
@@ -6,7 +6,14 @@
 COMPONENT_TARGETS += $(HARDWARE_CB3X)
 COMPONENT_TARGETS += $(HARDWARE_FFRK3288)
 COMPONENT_TARGETS += $(HARDWARE_M201)
-COMPONENT_TARGETS += $(HARDWARE_MXQ)
+COMPONENT_TARGETS += $(HARDWARE_MXV)
+COMPONENT_TARGETS += $(HARDWARE_P201)
+COMPONENT_TARGETS += $(HARDWARE_NEXBOX_A95X)
+COMPONENT_TARGETS += $(HARDWARE_ODROID_C2)
+COMPONENT_TARGETS += $(HARDWARE_P212)
+COMPONENT_TARGETS += $(HARDWARE_KHADAS_VIM)
+COMPONENT_TARGETS += $(HARDWARE_Q201)
+COMPONENT_TARGETS += $(HARDWARE_ENYBOX_X2)
 COMPONENT_TARGETS += $(HARDWARE_NIT6Q)
 COMPONENT_TARGETS += $(HARDWARE_OMAP5UEVM)
 COMPONENT_TARGETS += $(HARDWARE_DRA7XXEVM)
@@ -41,7 +48,7 @@
 PKG_GROUP = base
 
 SETUP_DEV_PKG_NAME                = install-tools
-SETUP_DEV_PKG_VERSION             = 1.2.1
+SETUP_DEV_PKG_VERSION             = 1.2.2
 SETUP_DEV_PKG_ARCH                = $(TOOLCHAIN)
 SETUP_DEV_PKG_DISTRO_NAME         = $(DISTRO_NAME)
 SETUP_DEV_PKG_DISTRO_VERSION      = $(DISTRO_VERSION)
@@ -146,4 +153,4 @@
 	 echo "short_description=\"$(SETUP_DEV_PKG_SHORT_DESCRIPTION)\"" >> $(SETUP_DEV_PKG)/.PKGINFO ; \
 	 echo "url=$(SETUP_DEV_PKG_URL)"                                 >> $(SETUP_DEV_PKG)/.PKGINFO ; \
 	 echo "license=$(SETUP_DEV_PKG_LICENSE)"                         >> $(SETUP_DEV_PKG)/.PKGINFO
-	@$(FAKEROOT) sh -c "cd $(SETUP_DEV_PKG) && chown -R root:root . && $(MAKE_PACKAGE) --linkadd yes .."
+	@$(PSEUDO) sh -c "cd $(SETUP_DEV_PKG) && chown -R root:root . && $(MAKE_PACKAGE) --linkadd yes .."
Index: pkgtool/Makefile
===================================================================
--- pkgtool/Makefile	(revision 646)
+++ pkgtool/Makefile	(revision 647)
@@ -6,7 +6,14 @@
 COMPONENT_TARGETS += $(HARDWARE_CB3X)
 COMPONENT_TARGETS += $(HARDWARE_FFRK3288)
 COMPONENT_TARGETS += $(HARDWARE_M201)
-COMPONENT_TARGETS += $(HARDWARE_MXQ)
+COMPONENT_TARGETS += $(HARDWARE_MXV)
+COMPONENT_TARGETS += $(HARDWARE_P201)
+COMPONENT_TARGETS += $(HARDWARE_NEXBOX_A95X)
+COMPONENT_TARGETS += $(HARDWARE_ODROID_C2)
+COMPONENT_TARGETS += $(HARDWARE_P212)
+COMPONENT_TARGETS += $(HARDWARE_KHADAS_VIM)
+COMPONENT_TARGETS += $(HARDWARE_Q201)
+COMPONENT_TARGETS += $(HARDWARE_ENYBOX_X2)
 COMPONENT_TARGETS += $(HARDWARE_NIT6Q)
 COMPONENT_TARGETS += $(HARDWARE_OMAP5UEVM)
 COMPONENT_TARGETS += $(HARDWARE_DRA7XXEVM)
@@ -29,7 +36,7 @@
 PKG_GROUP = base
 
 PKGTOOL_BIN_PKG_NAME                = pkgtool
-PKGTOOL_BIN_PKG_VERSION             = 1.2.1
+PKGTOOL_BIN_PKG_VERSION             = 1.2.2
 PKGTOOL_BIN_PKG_ARCH                = $(TOOLCHAIN)
 PKGTOOL_BIN_PKG_DISTRO_NAME         = $(DISTRO_NAME)
 PKGTOOL_BIN_PKG_DISTRO_VERSION      = $(DISTRO_VERSION)
@@ -105,4 +112,4 @@
 	 echo "short_description=\"$(PKGTOOL_BIN_PKG_SHORT_DESCRIPTION)\"" >> $(PKGTOOL_BIN_PKG)/.PKGINFO ; \
 	 echo "url=$(PKGTOOL_BIN_PKG_URL)"                                 >> $(PKGTOOL_BIN_PKG)/.PKGINFO ; \
 	 echo "license=$(PKGTOOL_BIN_PKG_LICENSE)"                         >> $(PKGTOOL_BIN_PKG)/.PKGINFO
-	@$(FAKEROOT) sh -c "cd $(PKGTOOL_BIN_PKG) && chown -R root:root . && $(MAKE_PACKAGE) --linkadd yes .."
+	@$(PSEUDO) sh -c "cd $(PKGTOOL_BIN_PKG) && chown -R root:root . && $(MAKE_PACKAGE) --linkadd yes .."
Index: radix-system/Makefile
===================================================================
--- radix-system/Makefile	(revision 646)
+++ radix-system/Makefile	(revision 647)
@@ -6,7 +6,14 @@
 COMPONENT_TARGETS += $(HARDWARE_CB3X)
 COMPONENT_TARGETS += $(HARDWARE_FFRK3288)
 COMPONENT_TARGETS += $(HARDWARE_M201)
-COMPONENT_TARGETS += $(HARDWARE_MXQ)
+COMPONENT_TARGETS += $(HARDWARE_MXV)
+COMPONENT_TARGETS += $(HARDWARE_P201)
+COMPONENT_TARGETS += $(HARDWARE_NEXBOX_A95X)
+COMPONENT_TARGETS += $(HARDWARE_ODROID_C2)
+COMPONENT_TARGETS += $(HARDWARE_P212)
+COMPONENT_TARGETS += $(HARDWARE_KHADAS_VIM)
+COMPONENT_TARGETS += $(HARDWARE_Q201)
+COMPONENT_TARGETS += $(HARDWARE_ENYBOX_X2)
 COMPONENT_TARGETS += $(HARDWARE_NIT6Q)
 COMPONENT_TARGETS += $(HARDWARE_OMAP5UEVM)
 COMPONENT_TARGETS += $(HARDWARE_DRA7XXEVM)
@@ -31,7 +38,7 @@
 PKG_GROUP = base
 
 SYSINIT_BIN_PKG_NAME                = radix-system
-SYSINIT_BIN_PKG_VERSION             = 1.2.1
+SYSINIT_BIN_PKG_VERSION             = 1.2.2
 SYSINIT_BIN_PKG_ARCH                = $(TOOLCHAIN)
 SYSINIT_BIN_PKG_DISTRO_NAME         = $(DISTRO_NAME)
 SYSINIT_BIN_PKG_DISTRO_VERSION      = $(DISTRO_VERSION)
@@ -71,6 +78,15 @@
 NOCLEAR_FIRST_TTY = --noclear
 endif
 
+ifneq ($(filter $(HARDWARE),$(HARDWARE_P201) $(HARDWARE_NEXBOX_A95X) \
+                            $(HARDWARE_P212) $(HARDWARE_KHADAS_VIM)  \
+                            $(HARDWARE_Q201) $(HARDWARE_ENYBOX_X2)),)
+FB_BPP = 24
+else
+FB_BPP = 32
+endif
+
+
 $(build):
 	@mkdir -p $(SYSINIT_BIN_PKG)/dev/{cgroup,pts,shm}
 	@mkdir -p $(SYSINIT_BIN_PKG)/etc/{X11,rc.d,profile.d,skel}
@@ -112,9 +128,17 @@
 	   mv rc.keymap   rc.keymap.new  ; \
 	   mv rc.modules  rc.modules.new ; \
 	 )
-ifneq ($(filter $(HARDWARE),$(HARDWARE_M201) $(HARDWARE_MXQ)),)
-	@cat $(scripts)/rc.mesonfb >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.fbset.new
+ifneq ($(filter $(HARDWARE),$(HARDWARE_M201) $(HARDWARE_MXV)),)
+	@cat $(scripts)/rc.meson8fb >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.fbset.new
 endif
+ifneq ($(filter $(HARDWARE),$(HARDWARE_P201) $(HARDWARE_NEXBOX_A95X) \
+                            $(HARDWARE_P212) $(HARDWARE_KHADAS_VIM)  \
+                            $(HARDWARE_Q201) $(HARDWARE_ENYBOX_X2)),)
+	@cat $(scripts)/rc.meson64fb >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.fbset.new
+endif
+ifneq ($(filter $(HARDWARE),$(HARDWARE_ODROID_C2)),)
+	@cat $(scripts)/rc.odroidc2 >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.fbset.new
+endif
 ifneq ($(filter $(HARDWARE),$(HARDWARE_CB1X)),)
 	@echo "# Ethernet:"                    >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.modules.new
 	@echo "/sbin/modprobe sunxi_gmac"      >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.modules.new
@@ -148,6 +172,10 @@
 	@echo "# PowerVR:"                     >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.modules.new
 	@echo "/sbin/modprobe bc_example"      >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.modules.new
 endif
+ifneq ($(filter $(HARDWARE),$(HARDWARE_BT1)),)
+	@echo "# HW Random:"                   >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.modules.new
+	@echo "/sbin/modprobe rng-core"        >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.modules.new
+endif
 ifneq ($(filter $(HARDWARE),$(HARDWARE_OMAP5UEVM)),)
 	@cat $(modprobes)/modprobe.$(HARDWARE) >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.modules.new
 endif
@@ -160,6 +188,12 @@
 	@echo "# Additional stuff:"            >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.modules.new
 	@echo "/sbin/modprobe udl"             >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.modules.new
 endif
+ifneq ($(filter $(HARDWARE),$(HARDWARE_KHADAS_VIM) \
+                            $(HARDWARE_ENYBOX_X2)),)
+	@echo "# Wi-Fi/Bluetooth:"             >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.modules.new
+	@echo "/sbin/modprobe dhd"             >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.modules.new
+	@echo "/sbin/modprobe bcmdhd"          >> $(SYSINIT_BIN_PKG)/etc/rc.d/rc.modules.new
+endif
 	@chmod a+x $(SYSINIT_BIN_PKG)/etc/rc.d/rc.{fbset.new,font.new,gpm.new,keymap.new,modules.new}
 	# ======= etc/inittab =======
 	@cat $(source_etc)/inittab.in | \
@@ -173,12 +207,13 @@
 ifneq ($(filter $(HARDWARE),$(HARDWARE_CB3X)),)
 	@echo "s1:12345:respawn:/sbin/agetty -L ttyS0 115200 vt100" >> $(SYSINIT_BIN_PKG)/etc/inittab.new
 endif
-ifneq ($(filter $(HARDWARE),$(HARDWARE_M201)),)
+ifneq ($(filter $(HARDWARE),$(HARDWARE_M201) $(HARDWARE_MXV)         \
+                            $(HARDWARE_P201) $(HARDWARE_NEXBOX_A95X) \
+                                             $(HARDWARE_ODROID_C2)   \
+                            $(HARDWARE_P212) $(HARDWARE_KHADAS_VIM)  \
+                            $(HARDWARE_Q201) $(HARDWARE_ENYBOX_X2)),)
 	@echo "s1:12345:respawn:/sbin/agetty -L ttyS0 115200 vt100" >> $(SYSINIT_BIN_PKG)/etc/inittab.new
 endif
-ifneq ($(filter $(HARDWARE),$(HARDWARE_MXQ)),)
-	@echo "s1:12345:respawn:/sbin/agetty -L ttyS0 115200 vt100" >> $(SYSINIT_BIN_PKG)/etc/inittab.new
-endif
 ifneq ($(filter $(HARDWARE),$(HARDWARE_CI20)),)
 	@echo "s1:12345:respawn:/sbin/agetty -L ttyS4 115200 vt100" >> $(SYSINIT_BIN_PKG)/etc/inittab.new
 endif
@@ -191,6 +226,9 @@
 ifneq ($(filter $(HARDWARE),$(HARDWARE_DRA7XXEVM)),)
 	@echo "s1:12345:respawn:/sbin/agetty -L ttyS0 115200 vt100" >> $(SYSINIT_BIN_PKG)/etc/inittab.new
 endif
+ifneq ($(filter $(HARDWARE),$(HARDWARE_BT1)),)
+	@echo "s1:12345:respawn:/sbin/agetty -L ttyS0 115200 vt100" >> $(SYSINIT_BIN_PKG)/etc/inittab.new
+endif
 	@echo ""                                                    >> $(SYSINIT_BIN_PKG)/etc/inittab.new
 	@echo "# End of /etc/inittab"                               >> $(SYSINIT_BIN_PKG)/etc/inittab.new
 	# ======= etc/fstab =======
@@ -214,7 +252,8 @@
 	@chmod a+x $(SYSINIT_BIN_PKG)/etc/rc.d/rc.{4.new,6.new,K.new,M.new,S.new}
 	# ======= etc/profile.d =======
 	@cat $(source_etc)/X11/xorg.conf.fbdev.in | \
-	     sed 's,@HARDWARE_SPEC@,$(HW_SPEC),'  > $(SYSINIT_BIN_PKG)/etc/X11/xorg.conf.fbdev
+	     sed 's,@HARDWARE_SPEC@,$(HW_SPEC),'  | \
+	     sed 's,@DEFAULT_FB_BPP@,$(FB_BPP),'  > $(SYSINIT_BIN_PKG)/etc/X11/xorg.conf.fbdev
 	@cat $(source_etc)/HOSTNAME.in | \
 	     sed 's,@HARDWARE@,$(HARDWARE),' > $(SYSINIT_BIN_PKG)/etc/HOSTNAME.new
 	@cat $(source_etc)/hosts.in | \
@@ -257,7 +296,7 @@
 	 echo "short_description=\"$(SYSINIT_BIN_PKG_SHORT_DESCRIPTION)\"" >> $(SYSINIT_BIN_PKG)/.PKGINFO ; \
 	 echo "url=$(SYSINIT_BIN_PKG_URL)"                                 >> $(SYSINIT_BIN_PKG)/.PKGINFO ; \
 	 echo "license=$(SYSINIT_BIN_PKG_LICENSE)"                         >> $(SYSINIT_BIN_PKG)/.PKGINFO
-	@$(FAKEROOT) sh -c "cd $(SYSINIT_BIN_PKG)  && \
-	                    chown -R 0:0 .       && \
-	                    chown -R 0:22 var/log/wtmp var/run/utmp && \
-	                    $(MAKE_PACKAGE) --linkadd yes .."
+	@$(PSEUDO) sh -c "cd $(SYSINIT_BIN_PKG)  && \
+	                  chown -R 0:0 .       && \
+	                  chown -R 0:22 var/log/wtmp var/run/utmp && \
+	                  $(MAKE_PACKAGE) --linkadd yes .."
Index: radix-system/etc/X11/xorg.conf.fbdev.in
===================================================================
--- radix-system/etc/X11/xorg.conf.fbdev.in	(revision 646)
+++ radix-system/etc/X11/xorg.conf.fbdev.in	(revision 647)
@@ -14,5 +14,5 @@
     Identifier      "Screen0"
     Monitor         "Monitor"
     Device          "Device0"
-    DefaultFbBpp    32
+    DefaultFbBpp    @DEFAULT_FB_BPP@
 EndSection
Index: radix-system/scripts/rc.mesonfb
===================================================================
--- radix-system/scripts/rc.mesonfb	(revision 646)
+++ radix-system/scripts/rc.mesonfb	(nonexistent)
@@ -1,124 +0,0 @@
-#
-# rc.mesonfb - initial set up meson framebuffer
-#
-hdmimode=720p
-
-# Parse command line arguments
-for arg in $(cat /proc/cmdline); do
-  case $arg in
-    hdmimode=*)
-      hdmimode="${arg#*=}"
-      ;;
-  esac
-done
-
-outputmode=$hdmimode
-
-/bin/echo $outputmode > /sys/class/display/mode
-
-# Enable framebuffer device
-/bin/echo 0 > /sys/class/graphics/fb0/blank
-
-# Blank fb1 to prevent static noise
-/bin/echo 1 > /sys/class/graphics/fb1/blank
-
-# Disable framebuffer scaling
-/bin/echo 0 > /sys/class/graphics/fb0/free_scale
-/bin/echo 0 > /sys/class/graphics/fb1/free_scale
-
-
-/bin/echo 1 > /sys/class/graphics/fb0/freescale_mode
-
-case $outputmode in
-  480*)
-    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/free_scale_axis
-    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/window_axis
-    ;;
-
-  576*)
-    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/free_scale_axis
-    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/window_axis
-    ;;
-
-  720*)
-    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/free_scale_axis
-    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/window_axis
-    ;;
-
-  1080*)
-    /bin/echo 0 0 1919 1079 > /sys/class/graphics/fb0/free_scale_axis
-    /bin/echo 0 0 1919 1079 > /sys/class/graphics/fb0/window_axis
-    ;;
-
-  4k2k*)
-    /bin/echo 0 0 1919 1079 > /sys/class/graphics/fb0/free_scale_axis
-    /bin/echo 0 0 1919 1079 > /sys/class/graphics/fb0/window_axis
-    ;;
-
-  *)
-    # outputmode = 720p
-    /bin/echo 720p > /sys/class/display/mode
-    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/free_scale_axis
-    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/window_axis
-    ;;
-esac
-
-
-# Set framebuffer geometry to match the resolution
-case "$hdmimode" in
-  720*)
-    /usr/sbin/fbset -fb /dev/fb0 -a -g 1280 720 1280 1440 32
-    ;;
-  1080*)
-    /usr/sbin/fbset -fb /dev/fb0 -a -g 1920 1080 1920 3240 32
-    ;;
-esac
-/usr/sbin/fbset -fb /dev/fb1 -g 32 32 32 32 32
-
-# Include deinterlacer into default VFM map
-/bin/echo rm default > /sys/class/vfm/map
-/bin/echo add default decoder ppmgr deinterlace amvideo > /sys/class/vfm/map
-
-################################################################
-#
-# If HDMI cable is connected during kernel start and the new
-# outputmode is equal to current hdmimode then the screen is
-# black.
-#
-# To wake up the monitor, we must reset outputmode.
-# Only in this case, the driver will wake the display up.
-#
-# Instead we will have to reconnect hdmi cable.
-#
-outputmode=$(cat /sys/class/display/mode)
-hpdstate=$(cat /sys/class/amhdmitx/amhdmitx0/hpd_state)
-
-if [ "$hpdstate" = "1" ]; then
-  # Blank fb0 to prevent static noise
-  /bin/echo 1 > /sys/class/graphics/fb0/blank
-    case $outputmode in
-      720*)
-        /bin/echo 1080p > /sys/class/display/mode
-        /bin/echo $outputmode > /sys/class/display/mode
-        ;;
-
-      1080*)
-        /bin/echo 720p > /sys/class/display/mode
-        /bin/echo $outputmode > /sys/class/display/mode
-        ;;
-      *)
-        # probably nobody asks 480cvbs
-        /bin/echo 480cvbs > /sys/class/display/mode
-        /bin/echo $outputmode > /sys/class/display/mode
-        ;;
-    esac
-  # Enable framebuffer device
-  /bin/echo 0 > /sys/class/graphics/fb0/blank
-fi
-#
-# End of HDMI cable reconnect trick.
-#
-################################################################
-
-echo 0x10001 > /sys/class/graphics/fb0/free_scale
-echo 0 > /sys/class/graphics/fb1/free_scale
Index: radix-system/scripts/rc.meson64fb
===================================================================
--- radix-system/scripts/rc.meson64fb	(nonexistent)
+++ radix-system/scripts/rc.meson64fb	(revision 647)
@@ -0,0 +1,124 @@
+#
+# rc.mesonfb - initial set up meson framebuffer
+#
+hdmimode=1080p60hz
+
+# Parse command line arguments
+for arg in $(cat /proc/cmdline); do
+  case $arg in
+    hdmimode=*)
+      hdmimode="${arg#*=}"
+      ;;
+  esac
+done
+
+outputmode=$hdmimode
+
+/bin/echo $outputmode > /sys/class/display/mode
+
+# Enable framebuffer device
+/bin/echo 0 > /sys/class/graphics/fb0/blank
+
+# Blank fb1 to prevent static noise
+/bin/echo 1 > /sys/class/graphics/fb1/blank
+
+# Disable framebuffer scaling
+/bin/echo 0 > /sys/class/graphics/fb0/free_scale
+/bin/echo 0 > /sys/class/graphics/fb1/free_scale
+
+
+/bin/echo 1 > /sys/class/graphics/fb0/freescale_mode
+
+case $outputmode in
+  480*)
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/free_scale_axis
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/window_axis
+    ;;
+
+  576*)
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/free_scale_axis
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/window_axis
+    ;;
+
+  720*)
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/free_scale_axis
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/window_axis
+    ;;
+
+  1080*)
+    /bin/echo 0 0 1919 1079 > /sys/class/graphics/fb0/free_scale_axis
+    /bin/echo 0 0 1919 1079 > /sys/class/graphics/fb0/window_axis
+    ;;
+
+  4k2k*)
+    /bin/echo 0 0 1919 1079 > /sys/class/graphics/fb0/free_scale_axis
+    /bin/echo 0 0 1919 1079 > /sys/class/graphics/fb0/window_axis
+    ;;
+
+  *)
+    # outputmode = 720p
+    /bin/echo 720p > /sys/class/display/mode
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/free_scale_axis
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/window_axis
+    ;;
+esac
+
+
+# Set framebuffer geometry to match the resolution
+case "$hdmimode" in
+  720*)
+    /usr/sbin/fbset -fb /dev/fb0 -a -g 1280 720 1280 1440 32
+    ;;
+  1080*)
+    /usr/sbin/fbset -fb /dev/fb0 -a -g 1920 1080 1920 3240 32
+    ;;
+esac
+/usr/sbin/fbset -fb /dev/fb1 -g 32 32 32 32 32
+
+# Include deinterlacer into default VFM map
+/bin/echo rm default > /sys/class/vfm/map
+/bin/echo add default decoder ppmgr deinterlace amvideo > /sys/class/vfm/map
+
+################################################################
+#
+# If HDMI cable is connected during kernel start and the new
+# outputmode is equal to current hdmimode then the screen is
+# black.
+#
+# To wake up the monitor, we must reset outputmode.
+# Only in this case, the driver will wake the display up.
+#
+# Instead we will have to reconnect hdmi cable.
+#
+outputmode=$(cat /sys/class/display/mode)
+hpdstate=$(cat /sys/class/amhdmitx/amhdmitx0/hpd_state)
+
+if [ "$hpdstate" = "1" ]; then
+  # Blank fb0 to prevent static noise
+  /bin/echo 1 > /sys/class/graphics/fb0/blank
+    case $outputmode in
+      720*)
+        /bin/echo 1080p60hz > /sys/class/display/mode
+        /bin/echo $outputmode > /sys/class/display/mode
+        ;;
+
+      1080*)
+        /bin/echo 720p60hz > /sys/class/display/mode
+        /bin/echo $outputmode > /sys/class/display/mode
+        ;;
+      *)
+        # probably nobody asks 480cvbs
+        /bin/echo 480cvbs > /sys/class/display/mode
+        /bin/echo $outputmode > /sys/class/display/mode
+        ;;
+    esac
+  # Enable framebuffer device
+  /bin/echo 0 > /sys/class/graphics/fb0/blank
+fi
+#
+# End of HDMI cable reconnect trick.
+#
+################################################################
+
+echo 0x10001 > /sys/class/graphics/fb0/free_scale
+echo 0 > /sys/class/graphics/fb1/free_scale
Index: radix-system/scripts/rc.meson8fb
===================================================================
--- radix-system/scripts/rc.meson8fb	(nonexistent)
+++ radix-system/scripts/rc.meson8fb	(revision 647)
@@ -0,0 +1,124 @@
+#
+# rc.mesonfb - initial set up meson framebuffer
+#
+hdmimode=720p
+
+# Parse command line arguments
+for arg in $(cat /proc/cmdline); do
+  case $arg in
+    hdmimode=*)
+      hdmimode="${arg#*=}"
+      ;;
+  esac
+done
+
+outputmode=$hdmimode
+
+/bin/echo $outputmode > /sys/class/display/mode
+
+# Enable framebuffer device
+/bin/echo 0 > /sys/class/graphics/fb0/blank
+
+# Blank fb1 to prevent static noise
+/bin/echo 1 > /sys/class/graphics/fb1/blank
+
+# Disable framebuffer scaling
+/bin/echo 0 > /sys/class/graphics/fb0/free_scale
+/bin/echo 0 > /sys/class/graphics/fb1/free_scale
+
+
+/bin/echo 1 > /sys/class/graphics/fb0/freescale_mode
+
+case $outputmode in
+  480*)
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/free_scale_axis
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/window_axis
+    ;;
+
+  576*)
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/free_scale_axis
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/window_axis
+    ;;
+
+  720*)
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/free_scale_axis
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/window_axis
+    ;;
+
+  1080*)
+    /bin/echo 0 0 1919 1079 > /sys/class/graphics/fb0/free_scale_axis
+    /bin/echo 0 0 1919 1079 > /sys/class/graphics/fb0/window_axis
+    ;;
+
+  4k2k*)
+    /bin/echo 0 0 1919 1079 > /sys/class/graphics/fb0/free_scale_axis
+    /bin/echo 0 0 1919 1079 > /sys/class/graphics/fb0/window_axis
+    ;;
+
+  *)
+    # outputmode = 720p
+    /bin/echo 720p > /sys/class/display/mode
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/free_scale_axis
+    /bin/echo 0 0 1279 719 > /sys/class/graphics/fb0/window_axis
+    ;;
+esac
+
+
+# Set framebuffer geometry to match the resolution
+case "$hdmimode" in
+  720*)
+    /usr/sbin/fbset -fb /dev/fb0 -a -g 1280 720 1280 1440 32
+    ;;
+  1080*)
+    /usr/sbin/fbset -fb /dev/fb0 -a -g 1920 1080 1920 3240 32
+    ;;
+esac
+/usr/sbin/fbset -fb /dev/fb1 -g 32 32 32 32 32
+
+# Include deinterlacer into default VFM map
+/bin/echo rm default > /sys/class/vfm/map
+/bin/echo add default decoder ppmgr deinterlace amvideo > /sys/class/vfm/map
+
+################################################################
+#
+# If HDMI cable is connected during kernel start and the new
+# outputmode is equal to current hdmimode then the screen is
+# black.
+#
+# To wake up the monitor, we must reset outputmode.
+# Only in this case, the driver will wake the display up.
+#
+# Instead we will have to reconnect hdmi cable.
+#
+outputmode=$(cat /sys/class/display/mode)
+hpdstate=$(cat /sys/class/amhdmitx/amhdmitx0/hpd_state)
+
+if [ "$hpdstate" = "1" ]; then
+  # Blank fb0 to prevent static noise
+  /bin/echo 1 > /sys/class/graphics/fb0/blank
+    case $outputmode in
+      720*)
+        /bin/echo 1080p > /sys/class/display/mode
+        /bin/echo $outputmode > /sys/class/display/mode
+        ;;
+
+      1080*)
+        /bin/echo 720p > /sys/class/display/mode
+        /bin/echo $outputmode > /sys/class/display/mode
+        ;;
+      *)
+        # probably nobody asks 480cvbs
+        /bin/echo 480cvbs > /sys/class/display/mode
+        /bin/echo $outputmode > /sys/class/display/mode
+        ;;
+    esac
+  # Enable framebuffer device
+  /bin/echo 0 > /sys/class/graphics/fb0/blank
+fi
+#
+# End of HDMI cable reconnect trick.
+#
+################################################################
+
+echo 0x10001 > /sys/class/graphics/fb0/free_scale
+echo 0 > /sys/class/graphics/fb1/free_scale
Index: radix-system/scripts/rc.odroidc2
===================================================================
--- radix-system/scripts/rc.odroidc2	(nonexistent)
+++ radix-system/scripts/rc.odroidc2	(revision 647)
@@ -0,0 +1,149 @@
+#
+# rc.odroidc2 - initial set up ODROID C2 framebuffer
+#
+
+for x in $(cat /proc/cmdline); do
+  case ${x} in
+    m_bpp=*) export bpp=${x#*=} ;;
+    hdmimode=*) export mode=${x#*=} ;;
+    modeline=*) export modeline=${x#*=} ;;
+  esac
+done
+
+HPD_STATE=/sys/class/amhdmitx/amhdmitx0/hpd_state
+DISP_CAP=/sys/class/amhdmitx/amhdmitx0/disp_cap
+DISP_MODE=/sys/class/display/mode
+
+# if setenv nographics "1" in boot.ini then this needs to fail
+if [ ! -f $DISP_MODE ]; then
+  exit 0
+fi
+
+echo $mode > $DISP_MODE
+
+common_display_setup() {
+  M="0 0 $(($X - 1)) $(($Y - 1))"
+  Y_VIRT=$(($Y * 2))
+  fbset -fb /dev/fb0 -g $X $Y $X $Y_VIRT $bpp
+  echo $mode > /sys/class/display/mode
+  echo 0 > /sys/class/graphics/fb0/free_scale
+  echo 1 > /sys/class/graphics/fb0/freescale_mode
+  echo $M > /sys/class/graphics/fb0/free_scale_axis
+  echo $M > /sys/class/graphics/fb0/window_axis
+
+  echo 0 > /sys/class/graphics/fb1/free_scale
+  echo 1 > /sys/class/graphics/fb1/freescale_mode
+}
+
+case $mode in
+  custombuilt*)
+    export X=`echo $modeline | cut -f1 -d","`
+    export Y=`echo $modeline | cut -f2 -d","`
+    ;;
+  480*) 
+    export X=720 
+    export Y=480 
+    ;;
+  576*)
+    export X=720
+    export Y=576
+    ;;
+  720p*)
+    export X=1280
+    export Y=720
+    ;;
+  1080*)
+    export X=1920
+    export Y=1080
+    ;;
+  2160p*)
+    export X=3840
+    export Y=2160
+    ;;
+  smpte24hz*)
+    export X=3840
+    export Y=2160
+    ;;
+  640x480p60hz*)
+    export X=640
+    export Y=480
+    ;;
+  800x480p60hz*)
+    export X=800
+    export Y=480
+    ;;
+  800x600p60hz*)
+    export X=800
+    export Y=600
+    ;;
+  1024x600p60hz*)
+    export X=1024
+    export Y=600
+    ;;
+  1024x768p60hz*)
+    export X=1024
+    export Y=768
+    ;;
+  1280x800p60hz*)
+    export X=1280
+    export Y=800
+    ;;
+  1280x1024p60hz*)
+    export X=1280
+    export Y=1024
+    ;;
+  1360x768p60hz*)
+    export X=1360
+    export Y=768
+    ;;
+  1440x900p60hz*)
+    export X=1440
+    export Y=900
+    ;;
+  1600x900p60hz*)
+    export X=1600
+    export Y=900
+    ;;
+  1680x1050p60hz*)
+    export X=1680
+    export Y=1050
+    ;;
+  1600x1200p60hz*)
+    export X=1600
+    export Y=1200
+    ;;
+  1920x1200p60hz*)
+    export X=1920
+    export Y=1200
+    ;;
+  2560x1080p60hz*)
+    export X=2560
+    export Y=1080
+    ;;
+  2560x1440p60hz*)
+    export X=2560
+    export Y=1440
+    ;;
+  2560x1600p60hz*)
+    export X=2560
+    export Y=1600
+    ;;
+  3440x1440p60hz*)
+    export X=3440
+    export Y=1440
+    ;;
+esac
+
+common_display_setup
+
+# Console unblack
+case $mode in
+  *cvbs*|480i*|576i*|1080i*)
+    echo 0 > /sys/class/graphics/fb0/blank
+    echo 1 > /sys/class/graphics/fb1/blank
+    ;;
+  *)
+    echo 0 > /sys/class/graphics/fb0/blank
+    echo 0 > /sys/class/graphics/fb1/blank
+    ;;
+esac