ci: Build a cheza kernel.
authorEric Anholt <eric@anholt.net>
Mon, 6 Apr 2020 22:55:30 +0000 (15:55 -0700)
committerMarge Bot <eric+marge@anholt.net>
Fri, 29 May 2020 16:46:44 +0000 (16:46 +0000)
This is a set of kernel options I've come up with mostly cribbing from
chrome os's kernel config snippet.  We also build an lzma kernel, as
uncompressed kernel is big but lzma is the only compression supported by
the bootloader.  With that image, we have to pack it into a FIT formatted
image+dtb blob.

CONFIG_SUNRPC_DEBUG is added so that you can set "nfsrootdebug" to figure
out what's going wrong with your nfs mount (mine were "both the tcp and
nfsvers options were required, and don't try to use 'default' as the root
path to defer to DHCP's answer because otherwise you get
/tftpboot/default, just use an empty root path which doesn't prepend
/tftpboot.")

Reviewed-by: Kristian H. Kristensen <hoegsberg@google.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5247>

.gitlab-ci.yml
.gitlab-ci/arm64.config
.gitlab-ci/container/lava_arm.sh
.gitlab-ci/container/x86_cross_arm_test.sh

index d18e31bf2c8863e122ff7e92f135786f9af2248a..621c15b3be64405955367c2e9d0d30331ace42cc 100644 (file)
@@ -195,7 +195,7 @@ arm_build:
     - .fdo.container-build@debian@arm64v8
     - .container
   variables:
-    FDO_DISTRIBUTION_TAG: &arm_build "2020-05-28-cheza"
+    FDO_DISTRIBUTION_TAG: &arm_build "2020-05-28-cheza-2"
 
 .use-arm_build:
   variables:
@@ -208,7 +208,7 @@ arm_build:
 x86_cross_arm_test:
   extends: x86_build
   variables:
-    FDO_DISTRIBUTION_TAG: &x86_cross_arm_test "2020-05-28-cheza"
+    FDO_DISTRIBUTION_TAG: &x86_cross_arm_test "2020-05-28-cheza-2"
 
 .use-x86_cross_arm_test:
   variables:
index 1cf6ba96fd15746cb287cb53919ed23325c48c71..f98df8c6cefe5dc6cf72d38fd454d808a9c678b7 100644 (file)
@@ -29,6 +29,27 @@ CONFIG_TYPEC_FUSB302=y
 CONFIG_TYPEC=y
 CONFIG_TYPEC_TCPM=y
 
+# Cheza platform bits
+CONFIG_QCOM_RPMHPD=y
+CONFIG_SDM_GPUCC_845=y
+CONFIG_SDM_VIDEOCC_845=y
+CONFIG_SDM_DISPCC_845=y
+CONFIG_SDM_LPASSCC_845=y
+CONFIG_SDM_CAMCC_845=y
+CONFIG_RESET_QCOM_PDC=y
+CONFIG_DRM_TI_SN65DSI86=y
+CONFIG_I2C_QCOM_GENI=y
+CONFIG_SPI_QCOM_GENI=y
+CONFIG_PHY_QCOM_QUSB2=y
+CONFIG_PHY_QCOM_QMP=y
+CONFIG_QCOM_LLCC=y
+CONFIG_QCOM_SPMI_TEMP_ALARM=y
+CONFIG_POWER_RESET_QCOM_PON=y
+CONFIG_RTC_DRV_PM8XXX=y
+CONFIG_INTERCONNECT=y
+CONFIG_INTERCONNECT_QCOM_SDM845=y
+CONFIG_QCOM_WDT=y
+
 # db410c ethernet
 CONFIG_USB_RTL8152=y
 
@@ -70,7 +91,6 @@ CONFIG_ARCH_ZYNQMP=n
 # Strip out some stuff we don't need for graphics testing, to reduce
 # the build.
 CONFIG_CAN=n
-CONFIG_SPI=n
 CONFIG_WIRELESS=n
 CONFIG_RFKILL=n
 CONFIG_WLAN=n
@@ -95,3 +115,4 @@ CONFIG_DETECT_HUNG_TASK=y
 
 CONFIG_FW_LOADER_COMPRESS=y
 CONFIG_FW_LOADER_USER_HELPER=n
+CONFIG_SUNRPC_DEBUG=y
index fcaf905241848996b5f9c3c1654ce7fc93bf2896..ccebf1b823b126ef96f11b3e25864f4936c0d85e 100644 (file)
@@ -46,12 +46,27 @@ wget -qO- ${KERNEL_URL} | tar -xz --strip-components=1 -C kernel
 pushd kernel
 ./scripts/kconfig/merge_config.sh ${DEFCONFIG} ../.gitlab-ci/${KERNEL_ARCH}.config
 make ${KERNEL_IMAGE_NAME} dtbs
-cp arch/${KERNEL_ARCH}/boot/${KERNEL_IMAGE_NAME} /lava-files/.
+for image in ${KERNEL_IMAGE_NAME}; do
+    cp arch/${KERNEL_ARCH}/boot/${image} /lava-files/.
+done
 cp ${DEVICE_TREES} /lava-files/.
+
+
+if [[ ${DEBIAN_ARCH} = "arm64" ]] && which mkimage > /dev/null; then
+    make Image.lzma
+    mkimage \
+        -f auto \
+        -A arm \
+        -O linux \
+        -d arch/arm64/boot/Image.lzma \
+        -C lzma\
+        -b arch/arm64/boot/dts/qcom/sdm845-cheza-r3.dtb \
+        /lava-files/cheza-kernel
+fi
+
 popd
 rm -rf kernel
 
-
 ############### Create rootfs
 set +e
 debootstrap \
@@ -95,4 +110,10 @@ if [ ${DEBIAN_ARCH} = arm64 ]; then
 
     # Make a gzipped copy of the Image for db410c.
     gzip -k /lava-files/Image
+
+    # Add missing a630 firmware, added to debian packge in apr 2020
+    wget https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/plain/qcom/a630_gmu.bin \
+         -O /lava-files/rootfs-arm64/lib/firmware/qcom/a630_gmu.bin
+    wget https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/plain/qcom/a630_sqe.fw \
+         -O /lava-files/rootfs-arm64/lib/firmware/qcom/a630_sqe.fw
 fi
index 6ae96bf3708cfb4538712a8e64ec67d66d94fe96..5b50a89a12b671ba15887a0dff089e71bd1008bb 100644 (file)
@@ -38,6 +38,7 @@ apt-get install -y --no-remove \
         python3.7 \
         pkg-config \
         procps \
+        u-boot-tools \
         unzip
 
 # Cross-build test deps
@@ -86,7 +87,8 @@ apt-get purge -y \
         meson \
         pkg-config \
         python3-distutils \
-        procps
+        procps \
+        u-boot-tools
 
 for arch in $CROSS_ARCHITECTURES; do
     apt-get purge -y ".*:${arch}"