From 5ed8b9d2fce147bc2676b3550f8f2c1c5bad3374 Mon Sep 17 00:00:00 2001 From: Danct12 <danct12@disroot.org> Date: Mon, 7 Mar 2022 11:47:27 +0700 Subject: [PATCH] linux-postmarketos-qcom-msm8998: enable sdcard and various config for pro1 --- .../linux-postmarketos-qcom-msm8998/APKBUILD | 10 +- .../aw9523-depend-on-regmap-i2c.patch | 11 ++ .../config-postmarketos-qcom-msm8998.aarch64 | 125 ++++++++++++++++-- .../fix-bf060y8m-aj0-error.patch | 11 ++ .../workaround-fxtec-keyboard.patch | 17 +++ 5 files changed, 161 insertions(+), 13 deletions(-) create mode 100644 device/testing/linux-postmarketos-qcom-msm8998/aw9523-depend-on-regmap-i2c.patch create mode 100644 device/testing/linux-postmarketos-qcom-msm8998/fix-bf060y8m-aj0-error.patch create mode 100644 device/testing/linux-postmarketos-qcom-msm8998/workaround-fxtec-keyboard.patch diff --git a/device/testing/linux-postmarketos-qcom-msm8998/APKBUILD b/device/testing/linux-postmarketos-qcom-msm8998/APKBUILD index d607afdbe55..72c2795fb9f 100644 --- a/device/testing/linux-postmarketos-qcom-msm8998/APKBUILD +++ b/device/testing/linux-postmarketos-qcom-msm8998/APKBUILD @@ -5,7 +5,7 @@ _flavor="postmarketos-qcom-msm8998" pkgname=linux-$_flavor pkgver=5.16.0_rc6 -pkgrel=1 +pkgrel=2 _commit="01325bd3a73b47a34b97c2757056b1cb9e4fdcc1" pkgdesc="Mainline Kernel fork for MSM8998 devices" arch="aarch64" @@ -36,6 +36,9 @@ makedepends=" source=" https://gitlab.com/msm8998-mainline/linux/-/archive/$_commit/linux-$_commit.tar.gz $_config + fix-bf060y8m-aj0-error.patch + aw9523-depend-on-regmap-i2c.patch + workaround-fxtec-keyboard.patch " builddir="$srcdir/linux-$_commit" @@ -67,5 +70,8 @@ package() { sha512sums=" 491be2124f8e843689c451e42cd6aef01c099632f3b53a0a2da0adc46401e66281159f5d356e85ec9a3a1361a05e146151b323409c15465b95b9c666b376ded5 linux-01325bd3a73b47a34b97c2757056b1cb9e4fdcc1.tar.gz -2cb89982099d17033e76219db1ca63754a9a269e01caaadb4f93a58c5f7685d0017063bcbb1560d7351350d6cf446853ddd1a5fd8d6bb298d8762e178da1d3a1 config-postmarketos-qcom-msm8998.aarch64 +e881a82c2cfe9909d498a6d2b2ed037845f74de7701d351c8d697e9cd0d2ef13d9011099af623abb629d53168599ff9b895cb6b26c5b9d4d1cb8e89b84cbbdd4 config-postmarketos-qcom-msm8998.aarch64 +f76cf96f50c859ea08c27ce15a165f4327896be327f780b5af60e34db153779a0b55fcdad2b62e76c9f2cae11d04557044994312b64d8720bfd9efe243693bdd fix-bf060y8m-aj0-error.patch +e13ab04085b6ba78fd516729df6530ce1f06a7a45012cb79bb35203fd75b917d10b0953122a93ead11fd96e89efee8c7d1f7006c6119ce7eb4dea35641bba9d6 aw9523-depend-on-regmap-i2c.patch +fbcc766db7e5410a4681f02fc53c9807d108d14889e71824d1d8d2bed4a367f4c743f31991af1018682b969afc834d06303e4943ad63e4d4cbbc83016fd599a6 workaround-fxtec-keyboard.patch " diff --git a/device/testing/linux-postmarketos-qcom-msm8998/aw9523-depend-on-regmap-i2c.patch b/device/testing/linux-postmarketos-qcom-msm8998/aw9523-depend-on-regmap-i2c.patch new file mode 100644 index 00000000000..f12cfd16ff4 --- /dev/null +++ b/device/testing/linux-postmarketos-qcom-msm8998/aw9523-depend-on-regmap-i2c.patch @@ -0,0 +1,11 @@ +--- a/drivers/pinctrl/Kconfig ++++ b/drivers/pinctrl/Kconfig +@@ -135,7 +135,7 @@ + select GENERIC_PINCONF + select GPIOLIB + select GPIOLIB_IRQCHIP +- select REGMAP ++ select REGMAP_I2C + help + The Awinic AW9523/AW9523B is a multi-function I2C GPIO + expander with PWM functionality. This driver bundles a diff --git a/device/testing/linux-postmarketos-qcom-msm8998/config-postmarketos-qcom-msm8998.aarch64 b/device/testing/linux-postmarketos-qcom-msm8998/config-postmarketos-qcom-msm8998.aarch64 index dd120345099..36865cbc4d6 100644 --- a/device/testing/linux-postmarketos-qcom-msm8998/config-postmarketos-qcom-msm8998.aarch64 +++ b/device/testing/linux-postmarketos-qcom-msm8998/config-postmarketos-qcom-msm8998.aarch64 @@ -2,14 +2,14 @@ # Automatically generated file; DO NOT EDIT. # Linux/arm64 5.16.0-rc5 Kernel Configuration # -CONFIG_CC_VERSION_TEXT="aarch64-alpine-linux-musl-gcc (Alpine 11.2.1_git20211128) 11.2.1 20211128" +CONFIG_CC_VERSION_TEXT="aarch64-alpine-linux-musl-gcc (Alpine 11.2.1_git20220219) 11.2.1 20220219" CONFIG_CC_IS_GCC=y CONFIG_GCC_VERSION=110201 CONFIG_CLANG_VERSION=0 CONFIG_AS_IS_GNU=y -CONFIG_AS_VERSION=23700 +CONFIG_AS_VERSION=23800 CONFIG_LD_IS_BFD=y -CONFIG_LD_VERSION=23700 +CONFIG_LD_VERSION=23800 CONFIG_LLD_VERSION=0 CONFIG_CC_HAS_ASM_GOTO=y CONFIG_CC_HAS_ASM_GOTO_OUTPUT=y @@ -1266,6 +1266,7 @@ CONFIG_BT_DEBUGFS=y # CONFIG_BT_QCA=m # CONFIG_BT_HCIBTUSB is not set +# CONFIG_BT_HCIBTSDIO is not set CONFIG_BT_HCIUART=m CONFIG_BT_HCIUART_SERDEV=y CONFIG_BT_HCIUART_H4=y @@ -1285,6 +1286,7 @@ CONFIG_BT_HCIUART_QCA=y # CONFIG_BT_HCIBFUSB is not set # CONFIG_BT_HCIVHCI is not set # CONFIG_BT_MRVL is not set +# CONFIG_BT_MTKSDIO is not set # CONFIG_BT_MTKUART is not set # CONFIG_BT_VIRTIO is not set # end of Bluetooth device drivers @@ -1388,7 +1390,7 @@ CONFIG_DEV_COREDUMP=y CONFIG_GENERIC_CPU_AUTOPROBE=y CONFIG_GENERIC_CPU_VULNERABILITIES=y CONFIG_REGMAP=y -CONFIG_REGMAP_I2C=m +CONFIG_REGMAP_I2C=y CONFIG_REGMAP_SLIMBUS=m CONFIG_REGMAP_SPMI=y CONFIG_REGMAP_MMIO=y @@ -1710,6 +1712,7 @@ CONFIG_WLAN_VENDOR_ATH=y # CONFIG_AR5523 is not set CONFIG_ATH10K=m CONFIG_ATH10K_CE=y +# CONFIG_ATH10K_SDIO is not set # CONFIG_ATH10K_USB is not set CONFIG_ATH10K_SNOC=m # CONFIG_ATH10K_DEBUG is not set @@ -1754,7 +1757,7 @@ CONFIG_INPUT=y CONFIG_INPUT_LEDS=m CONFIG_INPUT_FF_MEMLESS=m # CONFIG_INPUT_SPARSEKMAP is not set -# CONFIG_INPUT_MATRIXKMAP is not set +CONFIG_INPUT_MATRIXKMAP=y # # Userland interfaces @@ -1778,7 +1781,7 @@ CONFIG_INPUT_KEYBOARD=y # CONFIG_KEYBOARD_DLINK_DIR685 is not set # CONFIG_KEYBOARD_LKKBD is not set CONFIG_KEYBOARD_GPIO=y -# CONFIG_KEYBOARD_GPIO_FASTMATRIX is not set +CONFIG_KEYBOARD_GPIO_FASTMATRIX=y # CONFIG_KEYBOARD_GPIO_POLLED is not set # CONFIG_KEYBOARD_TCA6416 is not set # CONFIG_KEYBOARD_TCA8418 is not set @@ -1802,7 +1805,71 @@ CONFIG_KEYBOARD_GPIO=y # CONFIG_INPUT_MOUSE is not set # CONFIG_INPUT_JOYSTICK is not set # CONFIG_INPUT_TABLET is not set -# CONFIG_INPUT_TOUCHSCREEN is not set +CONFIG_INPUT_TOUCHSCREEN=y +# CONFIG_TOUCHSCREEN_AD7879 is not set +# CONFIG_TOUCHSCREEN_ADC is not set +# CONFIG_TOUCHSCREEN_AR1021_I2C is not set +# CONFIG_TOUCHSCREEN_ATMEL_MXT is not set +# CONFIG_TOUCHSCREEN_AUO_PIXCIR is not set +# CONFIG_TOUCHSCREEN_BU21013 is not set +# CONFIG_TOUCHSCREEN_BU21029 is not set +# CONFIG_TOUCHSCREEN_CHIPONE_ICN8318 is not set +# CONFIG_TOUCHSCREEN_CY8CTMA140 is not set +# CONFIG_TOUCHSCREEN_CY8CTMG110 is not set +# CONFIG_TOUCHSCREEN_CYTTSP_CORE is not set +# CONFIG_TOUCHSCREEN_CYTTSP4_CORE is not set +# CONFIG_TOUCHSCREEN_DYNAPRO is not set +# CONFIG_TOUCHSCREEN_HAMPSHIRE is not set +# CONFIG_TOUCHSCREEN_EETI is not set +# CONFIG_TOUCHSCREEN_EGALAX is not set +# CONFIG_TOUCHSCREEN_EGALAX_SERIAL is not set +# CONFIG_TOUCHSCREEN_EXC3000 is not set +# CONFIG_TOUCHSCREEN_FUJITSU is not set +CONFIG_TOUCHSCREEN_GOODIX=m +# CONFIG_TOUCHSCREEN_HIDEEP is not set +# CONFIG_TOUCHSCREEN_HYCON_HY46XX is not set +# CONFIG_TOUCHSCREEN_ILI210X is not set +# CONFIG_TOUCHSCREEN_ILITEK is not set +# CONFIG_TOUCHSCREEN_S6SY761 is not set +# CONFIG_TOUCHSCREEN_GUNZE is not set +# CONFIG_TOUCHSCREEN_EKTF2127 is not set +# CONFIG_TOUCHSCREEN_ELAN is not set +# CONFIG_TOUCHSCREEN_ELO is not set +# CONFIG_TOUCHSCREEN_WACOM_W8001 is not set +# CONFIG_TOUCHSCREEN_WACOM_I2C is not set +# CONFIG_TOUCHSCREEN_MAX11801 is not set +# CONFIG_TOUCHSCREEN_MCS5000 is not set +# CONFIG_TOUCHSCREEN_MMS114 is not set +# CONFIG_TOUCHSCREEN_MELFAS_MIP4 is not set +# CONFIG_TOUCHSCREEN_MSG2638 is not set +# CONFIG_TOUCHSCREEN_MTOUCH is not set +# CONFIG_TOUCHSCREEN_NT36XXX is not set +# CONFIG_TOUCHSCREEN_IMX6UL_TSC is not set +# CONFIG_TOUCHSCREEN_INEXIO is not set +# CONFIG_TOUCHSCREEN_MK712 is not set +# CONFIG_TOUCHSCREEN_PENMOUNT is not set +# CONFIG_TOUCHSCREEN_EDT_FT5X06 is not set +# CONFIG_TOUCHSCREEN_TOUCHRIGHT is not set +# CONFIG_TOUCHSCREEN_TOUCHWIN is not set +# CONFIG_TOUCHSCREEN_PIXCIR is not set +# CONFIG_TOUCHSCREEN_WDT87XX_I2C is not set +# CONFIG_TOUCHSCREEN_USB_COMPOSITE is not set +# CONFIG_TOUCHSCREEN_TOUCHIT213 is not set +# CONFIG_TOUCHSCREEN_TSC_SERIO is not set +# CONFIG_TOUCHSCREEN_TSC2004 is not set +# CONFIG_TOUCHSCREEN_TSC2007 is not set +# CONFIG_TOUCHSCREEN_RM_TS is not set +# CONFIG_TOUCHSCREEN_SILEAD is not set +# CONFIG_TOUCHSCREEN_SIS_I2C is not set +# CONFIG_TOUCHSCREEN_ST1232 is not set +# CONFIG_TOUCHSCREEN_STMFTS is not set +# CONFIG_TOUCHSCREEN_SX8654 is not set +# CONFIG_TOUCHSCREEN_TPS6507X is not set +# CONFIG_TOUCHSCREEN_ZET6223 is not set +# CONFIG_TOUCHSCREEN_ZFORCE is not set +# CONFIG_TOUCHSCREEN_ROHM_BU21023 is not set +# CONFIG_TOUCHSCREEN_IQS5XX is not set +# CONFIG_TOUCHSCREEN_ZINITIX is not set CONFIG_INPUT_MISC=y # CONFIG_INPUT_AD714X is not set # CONFIG_INPUT_ATMEL_CAPTOUCH is not set @@ -2025,7 +2092,7 @@ CONFIG_PINMUX=y CONFIG_PINCONF=y CONFIG_GENERIC_PINCONF=y # CONFIG_DEBUG_PINCTRL is not set -# CONFIG_PINCTRL_AW9523 is not set +CONFIG_PINCTRL_AW9523=y # CONFIG_PINCTRL_MCP23S08 is not set # CONFIG_PINCTRL_SINGLE is not set # CONFIG_PINCTRL_SX150X is not set @@ -2617,7 +2684,7 @@ CONFIG_DRM_PANEL=y # # CONFIG_DRM_PANEL_ARM_VERSATILE is not set # CONFIG_DRM_PANEL_ASUS_Z00T_TM5P5_NT35596 is not set -# CONFIG_DRM_PANEL_BOE_BF060Y8M_AJ0 is not set +CONFIG_DRM_PANEL_BOE_BF060Y8M_AJ0=m # CONFIG_DRM_PANEL_BOE_HIMAX8279D is not set # CONFIG_DRM_PANEL_BOE_TV101WUM_NL6 is not set # CONFIG_DRM_PANEL_DSI_CM is not set @@ -3395,7 +3462,40 @@ CONFIG_USB_FUNCTIONFS_GENERIC=y # CONFIG_TYPEC is not set CONFIG_USB_ROLE_SWITCH=y -# CONFIG_MMC is not set +CONFIG_MMC=y +CONFIG_PWRSEQ_EMMC=y +CONFIG_PWRSEQ_SIMPLE=y +CONFIG_MMC_BLOCK=y +CONFIG_MMC_BLOCK_MINORS=8 +# CONFIG_SDIO_UART is not set +# CONFIG_MMC_TEST is not set + +# +# MMC/SD/SDIO Host Controller Drivers +# +# CONFIG_MMC_DEBUG is not set +# CONFIG_MMC_ARMMMCI is not set +CONFIG_MMC_SDHCI=y +CONFIG_MMC_SDHCI_IO_ACCESSORS=y +CONFIG_MMC_SDHCI_PLTFM=y +# CONFIG_MMC_SDHCI_OF_ARASAN is not set +# CONFIG_MMC_SDHCI_OF_ASPEED is not set +# CONFIG_MMC_SDHCI_OF_AT91 is not set +# CONFIG_MMC_SDHCI_OF_DWCMSHC is not set +# CONFIG_MMC_SDHCI_CADENCE is not set +# CONFIG_MMC_SDHCI_F_SDH30 is not set +# CONFIG_MMC_SDHCI_MILBEAUT is not set +CONFIG_MMC_SDHCI_MSM=y +# CONFIG_MMC_DW is not set +# CONFIG_MMC_VUB300 is not set +# CONFIG_MMC_USHC is not set +# CONFIG_MMC_USDHI6ROL0 is not set +CONFIG_MMC_CQHCI=y +# CONFIG_MMC_HSQ is not set +# CONFIG_MMC_MTK is not set +# CONFIG_MMC_SDHCI_XENON is not set +# CONFIG_MMC_SDHCI_OMAP is not set +# CONFIG_MMC_SDHCI_AM654 is not set # CONFIG_MEMSTICK is not set CONFIG_NEW_LEDS=y CONFIG_LEDS_CLASS=m @@ -3641,6 +3741,7 @@ CONFIG_VIRTIO=y CONFIG_STAGING=y # CONFIG_PRISM2_USB is not set # CONFIG_RTLLIB is not set +# CONFIG_RTL8723BS is not set # CONFIG_R8712U is not set # CONFIG_R8188EU is not set # CONFIG_VT6656 is not set @@ -3707,8 +3808,10 @@ CONFIG_ASHMEM=y # CONFIG_GS_FPGABOOT is not set # CONFIG_UNISYSSPAR is not set # CONFIG_COMMON_CLK_XLNX_CLKWZRD is not set +# CONFIG_KS7010 is not set # CONFIG_XIL_AXIS_FIFO is not set # CONFIG_FIELDBUS_DEV is not set +# CONFIG_WFX is not set # CONFIG_GOLDFISH is not set # CONFIG_CHROME_PLATFORMS is not set # CONFIG_MELLANOX_PLATFORM is not set @@ -4003,7 +4106,7 @@ CONFIG_EXTCON=y # CONFIG_EXTCON_QCOM_SPMI_MISC is not set # CONFIG_EXTCON_RT8973A is not set # CONFIG_EXTCON_SM5502 is not set -CONFIG_EXTCON_USB_GPIO=m +CONFIG_EXTCON_USB_GPIO=y # CONFIG_EXTCON_USBC_TUSB320 is not set # CONFIG_MEMORY is not set CONFIG_IIO=y diff --git a/device/testing/linux-postmarketos-qcom-msm8998/fix-bf060y8m-aj0-error.patch b/device/testing/linux-postmarketos-qcom-msm8998/fix-bf060y8m-aj0-error.patch new file mode 100644 index 00000000000..e4d4370ca97 --- /dev/null +++ b/device/testing/linux-postmarketos-qcom-msm8998/fix-bf060y8m-aj0-error.patch @@ -0,0 +1,11 @@ +--- a/drivers/gpu/drm/panel/panel-boe-bf060y8m-aj0.c ++++ b/drivers/gpu/drm/panel/panel-boe-bf060y8m-aj0.c +@@ -386,7 +386,7 @@ + + dsi->lanes = 4; + dsi->format = MIPI_DSI_FMT_RGB888; +- dsi->mode_flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_EOT_PACKET | ++ dsi->mode_flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_NO_EOT_PACKET | + MIPI_DSI_MODE_VIDEO_SYNC_PULSE | + MIPI_DSI_CLOCK_NON_CONTINUOUS | + MIPI_DSI_MODE_LPM; diff --git a/device/testing/linux-postmarketos-qcom-msm8998/workaround-fxtec-keyboard.patch b/device/testing/linux-postmarketos-qcom-msm8998/workaround-fxtec-keyboard.patch new file mode 100644 index 00000000000..4ee1e2a071d --- /dev/null +++ b/device/testing/linux-postmarketos-qcom-msm8998/workaround-fxtec-keyboard.patch @@ -0,0 +1,17 @@ +This is a workaround for keyboard not working on Fxtec Pro1. + +genirq: Setting trigger mode 12 for irq 123 failed (aw9523_gpio_irq_type+0x0/0x20) +gpio-fastmatrix-keyboard gpio-keyboard: Cannot get IRQ for gpio302 + +--- a/drivers/pinctrl/pinctrl-aw9523.c ++++ b/drivers/pinctrl/pinctrl-aw9523.c +@@ -434,6 +434,9 @@ + switch (type) { + case IRQ_TYPE_NONE: + case IRQ_TYPE_EDGE_BOTH: ++ case IRQ_TYPE_LEVEL_MASK: ++ case IRQ_TYPE_LEVEL_HIGH: ++ case IRQ_TYPE_LEVEL_LOW: + return 0; + default: + return -EINVAL; -- GitLab