scripts: Move DB410C to QCOM and add ROOTFS_PARTLABEL

We are adding DB845c board and the customize script for QCOM boards
is likely the same in all QCOM boards only differs on ROOTFS_PARTLABEL
so move DB410c into QCOM and remove the specific board customize
script.

Change-Id: I9e18345edea35c2d8c27232941e3a5e13cc66991
Signed-off-by: Aníbal Limón <anibal.limon@linaro.org>
diff --git a/class/DB410C.var b/class/DB410C.var
index 1331fce..0d7c40a 100644
--- a/class/DB410C.var
+++ b/class/DB410C.var
@@ -1,2 +1,3 @@
 KVERS=4.14.0-qcomlt-arm64
 fdtfile=qcom/apq8016-sbc.dtb
+ROOTFS_PARTLABEL=rootfs
diff --git a/class/DB600C.var b/class/DB600C.var
index da75b47..1abc980 100644
--- a/class/DB600C.var
+++ b/class/DB600C.var
@@ -1,2 +1,3 @@
 KVERS=4.14.0-qcomlt-arm
 fdtfile=qcom-apq8064-arrow-sd-600eval.dtb
+ROOTFS_PARTLABEL=userdata
diff --git a/class/DB820C.var b/class/DB820C.var
index be45c34..5acb68f 100644
--- a/class/DB820C.var
+++ b/class/DB820C.var
@@ -1,2 +1,3 @@
 KVERS=4.14.0-qcomlt-arm64
 fdtfile=qcom/apq8096-db820c.dtb
+ROOTFS_PARTLABEL=rootfs
diff --git a/class/DB845C.var b/class/DB845C.var
index 05d49d0..ce313f6 100644
--- a/class/DB845C.var
+++ b/class/DB845C.var
@@ -1,2 +1,3 @@
 KVERS=5.1.0-qcomlt-arm64
 fdtfile=qcom/sdm845-db845c.dtb
+ROOTFS_PARTLABEL=userdata
diff --git a/scripts/DB600C/21-customize b/scripts/DB600C/21-customize
deleted file mode 100755
index 97af710..0000000
--- a/scripts/DB600C/21-customize
+++ /dev/null
@@ -1,18 +0,0 @@
-#!/bin/bash
-set -e
-
-# In case initrd doesn't exist, create it, else update
-if [ -f $target/boot/initrd.img-${KVERS} ]
-then
-    chroot $target /usr/sbin/update-initramfs -u -k ${KVERS}
-else
-    chroot $target /usr/sbin/update-initramfs -c -k ${KVERS}
-fi
-
-OUT=$FAI/out
-mkdir -p $OUT
-cp $target/boot/vmlinuz-${KVERS} $OUT/
-cp $target/usr/lib/linux-image-${KVERS}/$fdtfile $OUT/
-cp $target/boot/initrd.img-${KVERS} $OUT/
-cp $target/boot/config-${KVERS} $OUT/
-cp $target/boot/System.map-${KVERS} $OUT/
diff --git a/scripts/DB820C/21-customize b/scripts/DB820C/21-customize
deleted file mode 100755
index 6355ae7..0000000
--- a/scripts/DB820C/21-customize
+++ /dev/null
@@ -1,27 +0,0 @@
-#!/bin/bash
-set -e
-
-cat << EOF > $target/etc/fstab
-/dev/disk/by-partlabel/userdata / ext4   rw,relatime,data=ordered 0 1
-EOF
-
-# In case initrd doesn't exist, create it, else update
-if [ -f $target/boot/initrd.img-${KVERS} ]
-then
-    chroot $target /usr/sbin/update-initramfs -u -k ${KVERS}
-else
-    chroot $target /usr/sbin/update-initramfs -c -k ${KVERS}
-fi
-
-# Hold the kernel package to avoid kernel upgrade
-# This is a workaround to avoid upgrade the kernel (hence the modules in /lib/modules)
-# without updating the boot image
-$ROOTCMD apt-mark hold linux-image-${KVERS}
-
-OUT=$FAI/out
-mkdir -p $OUT
-cp $target/boot/vmlinuz-${KVERS} $OUT/
-cp $target/usr/lib/linux-image-${KVERS}/$fdtfile $OUT/
-cp $target/boot/initrd.img-${KVERS} $OUT/
-cp $target/boot/config-${KVERS} $OUT/
-cp $target/boot/System.map-${KVERS} $OUT/
diff --git a/scripts/DB410C/21-customize b/scripts/QCOM/21-customize
similarity index 92%
rename from scripts/DB410C/21-customize
rename to scripts/QCOM/21-customize
index 497b6dc..5d9fe3f 100755
--- a/scripts/DB410C/21-customize
+++ b/scripts/QCOM/21-customize
@@ -2,7 +2,7 @@
 set -e
 
 cat << EOF > $target/etc/fstab
-/dev/disk/by-partlabel/rootfs / ext4   rw,relatime,data=ordered 0 1
+/dev/disk/by-partlabel/${ROOTFS_PARTLABEL} / ext4   rw,relatime,data=ordered 0 1
 EOF
 
 if ifclass INSTALLER; then