linux-postmarketos-mediatek-mt8173: new aport (MR 3505)
This commit is contained in:
parent
b016cef0b2
commit
c5443e33fd
5 changed files with 8260 additions and 0 deletions
79
device/testing/linux-postmarketos-mediatek-mt8173/APKBUILD
Normal file
79
device/testing/linux-postmarketos-mediatek-mt8173/APKBUILD
Normal file
|
@ -0,0 +1,79 @@
|
||||||
|
# Maintainer: Jenneron <jenneron@protonmail.com>
|
||||||
|
pkgname=linux-postmarketos-mediatek-mt8173
|
||||||
|
pkgver=6.0
|
||||||
|
pkgrel=0
|
||||||
|
pkgdesc="Mainline kernel fork for Mediatek MT8173 devices"
|
||||||
|
arch="aarch64"
|
||||||
|
_carch="arm64"
|
||||||
|
_flavor="${pkgname#linux-}"
|
||||||
|
url="https://kernel.org"
|
||||||
|
license="GPL-2.0-only"
|
||||||
|
options="!strip !check !tracedeps
|
||||||
|
pmb:cross-native
|
||||||
|
pmb:kconfigcheck-anbox
|
||||||
|
pmb:kconfigcheck-containers
|
||||||
|
pmb:kconfigcheck-iwd
|
||||||
|
pmb:kconfigcheck-nftables
|
||||||
|
pmb:kconfigcheck-zram
|
||||||
|
"
|
||||||
|
makedepends="
|
||||||
|
bash
|
||||||
|
bison
|
||||||
|
findutils
|
||||||
|
flex
|
||||||
|
installkernel
|
||||||
|
openssl-dev
|
||||||
|
perl
|
||||||
|
gmp-dev
|
||||||
|
mpc1-dev
|
||||||
|
mpfr-dev
|
||||||
|
xz
|
||||||
|
"
|
||||||
|
|
||||||
|
# Source
|
||||||
|
_config="config-$_flavor.$arch"
|
||||||
|
case $pkgver in
|
||||||
|
*.*.*) _kernver=${pkgver%.0};;
|
||||||
|
*.*) _kernver=$pkgver;;
|
||||||
|
esac
|
||||||
|
source="
|
||||||
|
https://cdn.kernel.org/pub/linux/kernel/v6.x/linux-${pkgver//_/-}.tar.xz
|
||||||
|
$_config
|
||||||
|
fix-mmc1-speed.patch
|
||||||
|
fix-mmc-order.patch
|
||||||
|
fix-spi-nor-max-frequency.patch
|
||||||
|
"
|
||||||
|
builddir="$srcdir/linux-${_kernver//_/-}"
|
||||||
|
|
||||||
|
prepare() {
|
||||||
|
default_prepare
|
||||||
|
cp "$srcdir/config-$_flavor.$CARCH" .config
|
||||||
|
}
|
||||||
|
|
||||||
|
build() {
|
||||||
|
unset LDFLAGS
|
||||||
|
make ARCH="$_carch" CC="${CC:-gcc}" \
|
||||||
|
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-postmarketOS"
|
||||||
|
}
|
||||||
|
|
||||||
|
package() {
|
||||||
|
mkdir -p "$pkgdir"/boot
|
||||||
|
make zinstall modules_install dtbs_install \
|
||||||
|
ARCH="$_carch" \
|
||||||
|
INSTALL_PATH="$pkgdir"/boot \
|
||||||
|
INSTALL_MOD_PATH="$pkgdir" \
|
||||||
|
INSTALL_MOD_STRIP=1 \
|
||||||
|
INSTALL_DTBS_PATH="$pkgdir/boot/dtbs"
|
||||||
|
rm -f "$pkgdir"/lib/modules/*/build "$pkgdir"/lib/modules/*/source
|
||||||
|
|
||||||
|
install -D "$builddir"/include/config/kernel.release \
|
||||||
|
"$pkgdir"/usr/share/kernel/$_flavor/kernel.release
|
||||||
|
}
|
||||||
|
|
||||||
|
sha512sums="
|
||||||
|
bac41a7aeb6e809616cee2f13dcd1c45e829dfd1ccf60aee1dc4c46b1e28532f4485c7d819a32940de84fdfbf89db80a4e919bce8a74b2948c5a01551771b714 linux-6.0.tar.xz
|
||||||
|
9568c0bac5c4a5ce7fd1cafe01927c2f47017f64077f3539dc0d4d57cc6f3cf2a904c074b882be2692bacd519996274c5f613b12bfc4de709b5678ef827865b4 config-postmarketos-mediatek-mt8173.aarch64
|
||||||
|
4b499c1fbf53631cffd6fa7299643dc744e0e2187f71804664b02f05296162b42e3f76aa0d8c688cecb43a8bcd41ec92991c98287951292260237b828dcca710 fix-mmc1-speed.patch
|
||||||
|
c86f8dfc32165a32381d45a4c8b6811ebf43f01b5d8a48fbe227cf5084cfefe24b32264c1c150cb49115db4759a2d21ad48b37dcaac78367d226e9cc2a5ba849 fix-mmc-order.patch
|
||||||
|
caf48ac0f77661153ee94c7de4931baca135a69a97e93f01ad8f276b4a9944e077d7214c117450943cca07990c773661f79718cb0c2ff7c5789c93d37afb26de fix-spi-nor-max-frequency.patch
|
||||||
|
"
|
File diff suppressed because it is too large
Load diff
|
@ -0,0 +1,14 @@
|
||||||
|
Link: https://git.alpinelinux.org/aports/tree/testing/linux-elm?h=master
|
||||||
|
|
||||||
|
--- a/arch/arm64/boot/dts/mediatek/mt8173.dtsi 2020-12-13 22:41:30.000000000 +0000
|
||||||
|
+++ a/arch/arm64/boot/dts/mediatek/mt8173.dtsi 2021-01-06 19:57:33.225047779 +0000
|
||||||
|
@@ -55,6 +55,9 @@
|
||||||
|
serial1 = &uart1;
|
||||||
|
serial2 = &uart2;
|
||||||
|
serial3 = &uart3;
|
||||||
|
+ mmc0 = &mmc0;
|
||||||
|
+ mmc1 = &mmc1;
|
||||||
|
+ mmc2 = &mmc2;
|
||||||
|
};
|
||||||
|
|
||||||
|
cluster0_opp: opp_table0 {
|
|
@ -0,0 +1,15 @@
|
||||||
|
cut max-frequency to half because at full speed mmc is buggy
|
||||||
|
|
||||||
|
Link: https://git.alpinelinux.org/aports/tree/testing/linux-elm?h=master
|
||||||
|
|
||||||
|
--- a/arch/arm64/boot/dts/mediatek/mt8173-elm.dtsi 2020-12-28 21:22:16.614538427 +0000
|
||||||
|
+++ b/arch/arm64/boot/dts/mediatek/mt8173-elm.dtsi 2020-12-28 21:23:59.702157398 +0000
|
||||||
|
@@ -381,7 +381,7 @@
|
||||||
|
pinctrl-0 = <&mmc1_pins_default>;
|
||||||
|
pinctrl-1 = <&mmc1_pins_uhs>;
|
||||||
|
bus-width = <4>;
|
||||||
|
- max-frequency = <200000000>;
|
||||||
|
+ max-frequency = <100000000>;
|
||||||
|
cap-sd-highspeed;
|
||||||
|
sd-uhs-sdr50;
|
||||||
|
sd-uhs-sdr104;
|
|
@ -0,0 +1,13 @@
|
||||||
|
Link: https://git.alpinelinux.org/aports/tree/testing/linux-elm?h=master
|
||||||
|
|
||||||
|
--- a/arch/arm64/boot/dts/mediatek/mt8173-elm.dtsi 2021-01-03 10:20:26.482347785 +0000
|
||||||
|
+++ b/arch/arm64/boot/dts/mediatek/mt8173-elm.dtsi 2021-01-03 11:36:43.321775391 +0000
|
||||||
|
@@ -437,7 +437,7 @@
|
||||||
|
flash@0 {
|
||||||
|
compatible = "jedec,spi-nor";
|
||||||
|
reg = <0>;
|
||||||
|
- spi-max-frequency = <50000000>;
|
||||||
|
+ spi-max-frequency = <109200000>;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
Loading…
Reference in a new issue