linux-motorola-panelli: store full kernel config (MR 3883)

Store the full kernel config instead of a fragment, so
"pmbootstrap kconfig check" can properly verify that all required kernel
options are there. Without this, it would fail an upcoming check for
BINFMT_ELF and BINFMT_SCRIPT:
https://lists.sr.ht/~postmarketos/pmbootstrap-devel/patches/38508

With the full config, pmbootstrap found that ANDROID_PARANOID_NETWORK
was enabled while it should be disabled, so disable it.

Fix the mediatek drvgen related build failure with
00_disable_drvgen.patch from linux-wiko-ufeel and including cust.dtsi:
https://wiki.postmarketos.org/wiki/Porting_to_a_new_device#Removing_python2_dependency

[ci:skip-build]: already built successfully in CI
This commit is contained in:
Oliver Smith 2023-02-19 14:35:54 +01:00 committed by Dylan Van Assche
parent ac9bff857c
commit fa292406df
No known key found for this signature in database
GPG key ID: 8642571587897EA1
4 changed files with 3639 additions and 66 deletions

View file

@ -0,0 +1,37 @@
diff --git a/Makefile b/Makefile
index 1ad63f5..af7a7c0 100644
--- a/Makefile
+++ b/Makefile
@@ -1494,13 +1494,13 @@ image_name:
@echo $(KBUILD_IMAGE)
# Clear a bunch of variables before executing the submake
-tools/: FORCE
- $(Q)mkdir -p $(objtree)/tools
- $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(filter --j% -j,$(MAKEFLAGS))" O=$(objtree) subdir=tools -C $(src)/tools/
+#tools/: FORCE
+# $(Q)mkdir -p $(objtree)/tools
+# $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(filter --j% -j,$(MAKEFLAGS))" O=$(objtree) subdir=tools -C $(src)/tools/
-tools/%: FORCE
- $(Q)mkdir -p $(objtree)/tools
- $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(filter --j% -j,$(MAKEFLAGS))" O=$(objtree) subdir=tools -C $(src)/tools/ $*
+#tools/%: FORCE
+# $(Q)mkdir -p $(objtree)/tools
+# $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(filter --j% -j,$(MAKEFLAGS))" O=$(objtree) subdir=tools -C $(src)/tools/ $*
# Single targets
# ---------------------------------------------------------------------------
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 2fe43be..845dcd1 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -300,7 +300,7 @@ MTK_PROJECT := $(CONFIG_ARCH_MTK_PROJECT:"%"=%)
export MTK_PLATFORM MTK_PROJECT MTK_TARGET_PROJECT
KBUILD_CPPFLAGS += -I$(srctree)/drivers/misc/mediatek/include/mt-plat/$(MTK_PLATFORM)/include
KBUILD_CPPFLAGS += -I$(srctree)/arch/arm/mach-mediatek/include/
--include $(srctree)/scripts/drvgen/drvgen.mk
+#-include $(srctree)/scripts/drvgen/drvgen.mk
archprepare: $(DRVGEN_FILE_LIST)
dtbs: $(DRVGEN_FILE_LIST)

View file

@ -3,7 +3,7 @@
pkgname=linux-motorola-panelli
pkgver=3.18.35
pkgrel=0
pkgrel=1
pkgdesc="Motorola Moto C Plus kernel fork"
arch="armv7"
_carch="arm"
@ -31,6 +31,8 @@ source="
gcc7-give-up-on-ilog2-const-optimizations.patch
gcc8-fix-put-user.patch
gcc10-extern_YYLOC_global_declaration.patch
00_disable_drvgen.patch
cust.dtsi
"
builddir="$srcdir/$_repository-$_commit"
_outdir="out"
@ -38,6 +40,7 @@ _outdir="out"
prepare() {
default_prepare
. downstreamkernel_prepare
cp "$srcdir"/cust.dtsi arch/arm/boot/dts/cust.dtsi
}
build() {
@ -53,8 +56,10 @@ package() {
sha512sums="
9532db50fed23cbe2452b6fba3051833e14eefeaa1a9c656e6e26a90a9f5a10c065286e5e42e08bd8ed04e323dd0ac64420e38e68bee483df3f115d55bf0540c linux-motorola-panelli-a06daea005dbbbb6b958bbd39a74fdd21cf092e2.tar.gz
714d1c4bd9a27e9b52d760d838cc4170f6bedde3973d180eb8d8abaa8ae87d92ef04b66ab1f1dea544751e5bdef99b86a7202dd6baf8a0c19bac4f26caf2a13c config-motorola-panelli.armv7
e1ada3692dbc45c978c7b60bd545f9108af10bc5ca239e57d1a51dc5d8f210590a17706c65947455a254c413b15870da222d442544acab8b2ab9b52cce1eafaf config-motorola-panelli.armv7
77eba606a71eafb36c32e9c5fe5e77f5e4746caac292440d9fb720763d766074a964db1c12bc76fe583c5d1a5c864219c59941f5e53adad182dbc70bf2bc14a7 gcc7-give-up-on-ilog2-const-optimizations.patch
197d40a214ada87fcb2dfc0ae4911704b9a93354b75179cd6b4aadbb627a37ec262cf516921c84a8b1806809b70a7b440cdc8310a4a55fca5d2c0baa988e3967 gcc8-fix-put-user.patch
2b48f1bf0e3f70703d2cdafc47d5e615cc7c56c70bec56b2e3297d3fa4a7a1321d649a8679614553dde8fe52ff1051dae38d5990e3744c9ca986d92187dcdbeb gcc10-extern_YYLOC_global_declaration.patch
8a04940e6f5424df67a3cc4c75dd19be1c9b560859e9db0ae67b766d52982a46156b601698afb80f90b9b99f63ef74e1f6147902b43ec97c25d2b75ba2f8d2b3 00_disable_drvgen.patch
6f32a4429faf97c1597264d9f42455cef7cab53d9f724baca9faab6af666421e48c1079fc4ae9f2b12415d0f5c749e2d015d1bc8302a25cc7dd7f775eee804f9 cust.dtsi
"

View file

@ -0,0 +1,312 @@
/*
* Generated by MTK SP Drv_CodeGen Version 03.13.6 for MT6735M. Copyright MediaTek Inc. (C) 2013.
* Sun Feb 19 13:59:47 2023
* Do Not Modify the File.
*/
#include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/interrupt-controller/arm-gic.h>
/*************************
* EINT DTSI File
*************************/
&nfc {
interrupt-parent = <&eintc>;
interrupts = <2 IRQ_TYPE_LEVEL_HIGH>;
debounce = <2 0>;
status = "okay";
};
&msdc1_ins {
interrupt-parent = <&eintc>;
interrupts = <5 IRQ_TYPE_LEVEL_LOW>;
debounce = <5 1000>;
status = "okay";
};
&accdet {
interrupt-parent = <&eintc>;
interrupts = <6 IRQ_TYPE_LEVEL_LOW>;
debounce = <6 256000>;
status = "okay";
};
&touch {
interrupt-parent = <&eintc>;
interrupts = <10 IRQ_TYPE_EDGE_FALLING>;
debounce = <10 0>;
status = "okay";
};
&als {
interrupt-parent = <&eintc>;
interrupts = <65 IRQ_TYPE_LEVEL_LOW>;
debounce = <65 0>;
status = "okay";
};
&gse_1 {
interrupt-parent = <&eintc>;
interrupts = <66 IRQ_TYPE_LEVEL_LOW>;
debounce = <66 0>;
status = "okay";
};
&gyro {
interrupt-parent = <&eintc>;
interrupts = <67 IRQ_TYPE_LEVEL_LOW>;
debounce = <67 0>;
status = "okay";
};
&ext_buck_oc {
interrupt-parent = <&eintc>;
interrupts = <78 IRQ_TYPE_LEVEL_HIGH>;
debounce = <78 0>;
status = "okay";
};
/********************
* GPIO USAGE MAPPING DTSI File
****************/
&gpio_usage_mapping {
GPIO_SIM1_HOT_PLUG = <8>;
GPIO_SIM2_HOT_PLUG = <9>;
GPIO_CMDAT1 = <43>;
GPIO_SIM2_SCLK = <160>;
GPIO_SIM2_SRST = <161>;
GPIO_SIM2_SIO = <162>;
GPIO_SIM1_SCLK = <163>;
GPIO_SIM1_SRST = <164>;
GPIO_SIM1_SIO = <165>;
};
&eintc {
MD1_SIM1_HOT_PLUG_EINT@0 {
compatible = "mediatek,MD1_SIM1_HOT_PLUG_EINT-eint";
interrupts = <0 4>;
debounce = <0 100000>;
dedicated = <0 0>;
src_pin = <0 1>;
sockettype=<0 0>;
status = "okay";
};
MD1_SIM2_HOT_PLUG_EINT@1 {
compatible = "mediatek,MD1_SIM2_HOT_PLUG_EINT-eint";
interrupts = <1 4>;
debounce = <1 100000>;
dedicated = <1 0>;
src_pin = <1 2>;
sockettype=<1 0>;
status = "okay";
};
};
/*************************
* PMIC DTSI File
*************************/
&mt_pmic_vcama_ldo_reg {
regulator-name = "vcama";
regulator-default-on = <0>; /* 0:skip, 1: off, 2:on */
status = "okay";
};
&mt_pmic_vsim1_ldo_reg {
regulator-name = "vsim1";
regulator-default-on = <0>; /* 0:skip, 1: off, 2:on */
status = "okay";
};
&mt_pmic_vsim2_ldo_reg {
regulator-name = "vsim2";
regulator-default-on = <0>; /* 0:skip, 1: off, 2:on */
status = "okay";
};
&mt_pmic_vcam_af_ldo_reg {
regulator-name = "vcamaf";
regulator-default-on = <0>; /* 0:skip, 1: off, 2:on */
status = "okay";
};
&mt_pmic_vgp1_ldo_reg {
regulator-name = "vgp1";
regulator-default-on = <0>; /* 0:skip, 1: off, 2:on */
status = "okay";
};
&mt_pmic_vibr_ldo_reg {
regulator-name = "vibr";
regulator-default-on = <0>; /* 0:skip, 1: off, 2:on */
status = "okay";
};
&mt_pmic_vcamd_ldo_reg {
regulator-name = "vcamd";
regulator-default-on = <0>; /* 0:skip, 1: off, 2:on */
status = "okay";
};
&mt_pmic_vcam_io_ldo_reg {
regulator-name = "vcamio";
regulator-default-on = <0>; /* 0:skip, 1: off, 2:on */
status = "okay";
};
&kd_camera_hw1 {
vcama-supply = <&mt_pmic_vcama_ldo_reg>;
vcama_main2-supply = <&mt_pmic_vcama_ldo_reg>;
vcama_sub-supply = <&mt_pmic_vcama_ldo_reg>;
vcamaf-supply = <&mt_pmic_vcam_af_ldo_reg>;
vcamaf_main2-supply = <&mt_pmic_vcam_af_ldo_reg>;
vcamaf_sub-supply = <&mt_pmic_vcam_af_ldo_reg>;
vcamd-supply = <&mt_pmic_vcamd_ldo_reg>;
vcamd_main2-supply = <&mt_pmic_vcamd_ldo_reg>;
vcamd_sub-supply = <&mt_pmic_vcamd_ldo_reg>;
vcamio-supply = <&mt_pmic_vcam_io_ldo_reg>;
vcamio_main2-supply = <&mt_pmic_vcam_io_ldo_reg>;
vcamio_sub-supply = <&mt_pmic_vcam_io_ldo_reg>;
status = "okay";
};
&touch {
vtouch-supply = <&mt_pmic_vgp1_ldo_reg>;
status = "okay";
};
/********************************************
*ADC DTSI File
********************************************/
&auxadc {
adc_channel@ {
compatible = "mediatek,adc_channel";
mediatek,temperature0 = <0>;
mediatek,temperature1 = <1>;
mediatek,adc_fdd_rf_params_dynamic_custom_ch = <12>;
status = "okay";
};
};
/**********************************************
*CLK_BUF DTSI File
********************************************/
&rf_clock_buffer_ctrl {
mediatek,clkbuf-quantity = <4>;
mediatek,clkbuf-config = <2 2 2 2>;
status = "okay";
};
/**********************************************
*Keypad DTSI File
********************************************/
&keypad{
mediatek,kpd-key-debounce = <1024>;
mediatek,kpd-sw-pwrkey = <116>;
mediatek,kpd-hw-pwrkey = <8>;
mediatek,kpd-sw-rstkey = <115>;
mediatek,kpd-hw-rstkey = <17>;
mediatek,kpd-use-extend-type = <0>;
/*HW Keycode [0~71] -> Linux Keycode*/
mediatek,kpd-hw-map-num = <72>;
mediatek,kpd-hw-init-map = <114 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 >;
mediatek,kpd-pwrkey-eint-gpio = <0>;
mediatek,kpd-pwkey-gpio-din = <0>;
mediatek,kpd-hw-dl-key0 = <17>;
mediatek,kpd-hw-dl-key1 = <0>;
mediatek,kpd-hw-dl-key2 = <8>;
mediatek,kpd-hw-recovery-key = <17>;
mediatek,kpd-hw-factory-key = <0>;
status = "okay";
};
/*************************
* I2C DTSI File
*************************/
&i2c0 {
#address-cells = <1>;
#size-cells = <0>;
camera_main@10 {
compatible = "mediatek,camera_main";
reg = <0x10>;
status = "okay";
};
camera_main_af@0c {
compatible = "mediatek,camera_main_af";
reg = <0x0c>;
status = "okay";
};
camera_sub@3c {
compatible = "mediatek,camera_sub";
reg = <0x3c>;
status = "okay";
};
};
&i2c1 {
#address-cells = <1>;
#size-cells = <0>;
cap_touch@5d {
compatible = "mediatek,cap_touch";
reg = <0x5d>;
status = "okay";
};
i2c_lcd_bias@3e {
compatible = "mediatek,i2c_lcd_bias";
reg = <0x3e>;
status = "okay";
};
};
&i2c2 {
#address-cells = <1>;
#size-cells = <0>;
msensor@0d {
compatible = "mediatek,msensor";
reg = <0x0d>;
status = "okay";
};
gyro@68 {
compatible = "mediatek,gyro";
reg = <0x68>;
status = "okay";
};
gsensor@0e {
compatible = "mediatek,gsensor";
reg = <0x0e>;
status = "okay";
};
alsps@60 {
compatible = "mediatek,alsps";
reg = <0x60>;
status = "okay";
};
nfc@28 {
compatible = "mediatek,nfc";
reg = <0x28>;
status = "okay";
};
strobe_main@63 {
compatible = "mediatek,strobe_main";
reg = <0x63>;
status = "okay";
};
};
&i2c3 {
#address-cells = <1>;
#size-cells = <0>;
ext_buck@6b {
compatible = "mediatek,ext_buck";
reg = <0x6b>;
status = "okay";
};
};