From 3765454957b51e5aa908851d2558af8be1a936b7 Mon Sep 17 00:00:00 2001 From: iAboothahir Date: Sun, 20 Mar 2022 09:20:20 +0530 Subject: [PATCH] device-asus-x00td: initial support for mainline kernel in addition to downstream kernel (MR 2985) Signed-off-by: iAboothahir [ci:skip-build] Already built successfuly on CI in MR --- device/testing/device-asus-x00td/APKBUILD | 24 ++++++++++++++++++--- device/testing/device-asus-x00td/deviceinfo | 7 ++++-- 2 files changed, 26 insertions(+), 5 deletions(-) diff --git a/device/testing/device-asus-x00td/APKBUILD b/device/testing/device-asus-x00td/APKBUILD index 21bc130fc..d5055b6e9 100644 --- a/device/testing/device-asus-x00td/APKBUILD +++ b/device/testing/device-asus-x00td/APKBUILD @@ -1,14 +1,18 @@ # Reference: pkgname=device-asus-x00td pkgdesc="Asus ZenFone Max Pro M1" -pkgver=0.1 +pkgver=0.2 pkgrel=0 url="https://postmarketos.org" license="MIT" arch="aarch64" options="!check !archcheck" -depends="postmarketos-base linux-asus-x00td mkbootimg mesa-dri-gallium msm-fb-refresher" +depends="postmarketos-base mkbootimg" makedepends="devicepkg-dev" +subpackages=" + $pkgname-kernel-downstream:kernel_downstream + $pkgname-kernel-mainline:kernel_mainline +" source="deviceinfo" build() { @@ -19,4 +23,18 @@ package() { devicepkg_package $startdir $pkgname } -sha512sums="381b37d83afd97610527af7fe78058717d5a48f198c8d006b0f3461f5fc962c8c6de099d57430549d27fe17ce0a5b4848d870211066834bc49d5c468b26446f2 deviceinfo" +kernel_downstream() { + pkgdesc="LineageOS downstream kernel (recommended)" + depends="linux-asus-x00td mesa-dri-gallium msm-fb-refresher" + devicepkg_subpackage_kernel $startdir $pkgname $subpkgname +} + +kernel_mainline() { + pkgdesc="Close to mainline; for kernel development only (most features aren't working)" + depends="linux-postmarketos-qcom-sdm660 mesa-dri-gallium" + devicepkg_subpackage_kernel $startdir $pkgname $subpkgname +} + +sha512sums=" +c8f1d521e2f307e5b0a1134c59f172db6fb678b9a67d9ec9f76d3be7b18b4bff198a4fec284a61b0da92e7e45f0208c3595a69b6eb1c4c098c38dfcfa66d053b deviceinfo +" diff --git a/device/testing/device-asus-x00td/deviceinfo b/device/testing/device-asus-x00td/deviceinfo index 7bb7036b4..02c31acb2 100644 --- a/device/testing/device-asus-x00td/deviceinfo +++ b/device/testing/device-asus-x00td/deviceinfo @@ -6,9 +6,12 @@ deviceinfo_name="Asus ZenFone Max Pro M1" deviceinfo_manufacturer="Asus" deviceinfo_codename="asus-x00td" deviceinfo_year="2018" +deviceinfo_dtb_mainline="qcom/sdm636-asus-x00td" +deviceinfo_append_dtb_mainline="true" deviceinfo_arch="aarch64" # Device related +deviceinfo_chassis="handset" deviceinfo_keyboard="false" deviceinfo_external_storage="false" deviceinfo_screen_width="1080" @@ -16,7 +19,8 @@ deviceinfo_screen_height="2160" # Bootloader related deviceinfo_flash_method="fastboot" -deviceinfo_kernel_cmdline="console=ttyMSM0,115200,n8 androidboot.console=ttyMSM0 earlycon=msm_serial_dm,0xc170000 androidboot.hardware=qcom user_debug=31 msm_rtb.filter=0x37 ehci-hcd.park=3 lpm_levels.sleep_disabled=1 sched_enable_hmp=1 sched_enable_power_aware=1 service_locator.enable=1 swiotlb=1 firmware_class.path=/vendor/firmware_mnt/image loop.max_part=7 buildvariant=userdebug" +deviceinfo_kernel_cmdline_downstream="console=ttyMSM0,115200,n8 androidboot.console=ttyMSM0 earlycon=msm_serial_dm,0xc170000 androidboot.hardware=qcom user_debug=31 msm_rtb.filter=0x37 ehci-hcd.park=3 lpm_levels.sleep_disabled=1 sched_enable_hmp=1 sched_enable_power_aware=1 service_locator.enable=1 swiotlb=1 firmware_class.path=/vendor/firmware_mnt/image loop.max_part=7 buildvariant=userdebug" +deviceinfo_kernel_cmdline_mainline="PMOS_NO_OUTPUT_REDIRECT clk_ignore_unused" deviceinfo_generate_bootimg="true" deviceinfo_bootimg_qcdt="false" deviceinfo_bootimg_dtb_second="false" @@ -29,4 +33,3 @@ deviceinfo_flash_pagesize="4096" deviceinfo_flash_sparse=true deviceinfo_flash_fastboot_partition_vbmeta="vbmeta" deviceinfo_usb_rndis_function_downstream="rndis_bam.rndis" -deviceinfo_chassis="handset"