powkiddy-x55: new device (MR 4926)

This commit is contained in:
Vitaliy Ognev 2024-03-15 20:45:46 +02:00 committed by Ferass El Hafidi
parent 9740a785b3
commit df5f42fb0f
No known key found for this signature in database
GPG key ID: CAB5A5DBC11B967B
8 changed files with 9677 additions and 0 deletions

View file

@ -0,0 +1,47 @@
# Reference: <https://postmarketos.org/devicepkg>
# Maintainer: Vitaliy Ognev <vitaliy.ognev@gmail.com>
pkgname=device-powkiddy-x55
pkgdesc="Powkiddy X55"
pkgver=1
pkgrel=0
url="https://postmarketos.org"
license="MIT"
arch="aarch64"
options="!check !archcheck"
depends="
linux-firmware-rtl_bt
linux-firmware-rtw88
linux-powkiddy-x55
postmarketos-base
u-boot-powkiddy-x55
"
makedepends="devicepkg-dev"
source="
deviceinfo
rtw88.conf
cage-ui-powkiddy-x55-rotate.sh
"
subpackages="$pkgname-cage-ui-addons:cage_ui_addons:noarch"
build() {
devicepkg_build $startdir $pkgname
}
package() {
devicepkg_package $startdir $pkgname
install -Dm644 "$srcdir"/rtw88.conf -t "$pkgdir"/etc/modprobe.d/
}
cage_ui_addons() {
pkgdesc="Cage-UI addons for powkiddy x55"
install_if="$pkgname=$pkgver-r$pkgrel postmarketos-ui-cage"
install -Dm644 "$srcdir"/cage-ui-powkiddy-x55-rotate.sh -t "$subpkgdir"/etc/cage-ui/
}
sha512sums="
71efac86cba6e1982b0557636b08c050da9adcc98ecfa8d91ad96843994434d0e09a0af8094f103c88314a07a20962cad58f05c38109b887399b84b324cb05f1 deviceinfo
3765ba8da5c22965dbcbe199665d78af42187873b3dd0314b78f0e389e5703f40277f8b784566badbe21241a06074e3769a263ba5eb6099c01d6cda0bf024a75 rtw88.conf
a22986cab90dd8641956e19f8139e1cb7f24a349cb2907cadb0001b0f5ff9be67b7fa717502f3b078ea8db62eb0fdb8de20e35495b4e4db69c0940dcac04996d cage-ui-powkiddy-x55-rotate.sh
"

View file

@ -0,0 +1,3 @@
#!/bin/sh
wlr-randr --output DSI-1 --transform 90

View file

@ -0,0 +1,25 @@
# Reference: <https://postmarketos.org/deviceinfo>
# Please use double quotes only. You can source this file in shell
# scripts.
deviceinfo_format_version="0"
deviceinfo_name="Powkiddy X55"
deviceinfo_manufacturer="Powkiddy"
deviceinfo_codename="powkiddy-x55"
deviceinfo_year="2023"
deviceinfo_arch="aarch64"
# Device related
deviceinfo_chassis="tablet"
deviceinfo_keyboard="false"
deviceinfo_external_storage="true"
# Bootloader related
deviceinfo_flash_method="none"
deviceinfo_uboot_boardname="powkiddy-x55"
deviceinfo_dtb="rockchip/rk3566-powkiddy-x55"
deviceinfo_sd_embed_firmware="u-boot/powkiddy-x55/idbloader.img:64,u-boot/powkiddy-x55/u-boot.itb:16384"
deviceinfo_sd_embed_firmware_step_size="512"
deviceinfo_generate_extlinux_config="true"
deviceinfo_kernel_cmdline="earlycon quiet console=ttyS2,1500000 PMOS_FORCE_PARTITION_RESIZE"
deviceinfo_boot_part_start="32768"

View file

@ -0,0 +1 @@
options rtw88_core disable_lps_deep=Y

View file

@ -0,0 +1,71 @@
# Reference: <https://postmarketos.org/vendorkernel>
# Maintainer: Vitaliy Ognev <vitaliy.ognev@gmail.com>
_flavor="powkiddy-x55"
pkgname=linux-powkiddy-x55
pkgver=6.8.1
pkgrel=0
pkgdesc="Kernel for Powkiddy X55"
arch="aarch64"
url="https://kernel.org"
license="GPL-2.0-only"
options="!strip !check !tracedeps pmb:cross-native"
makedepends="
bash
bison
findutils
flex
gmp-dev
linux-headers
mpc1-dev
mpfr-dev
openssl-dev
perl
rsync
xz
"
_config="config-$_flavor.$arch"
case $pkgver in
*.*.*) _kernver=${pkgver%.0};;
*.*) _kernver=$pkgver;;
esac
source="
https://cdn.kernel.org/pub/linux/kernel/v${_kernver%%.*}.x/linux-$_kernver.tar.xz
$_config
"
builddir="$srcdir/linux-$_kernver"
prepare() {
default_prepare
cp "$srcdir/config-$_flavor.$arch" .config
make ARCH=arm64 olddefconfig
}
build() {
unset LDFLAGS
make ARCH=arm64 \
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-$_flavor"
}
package() {
install -Dm644 arch/arm64/boot/Image "$pkgdir/boot/vmlinuz"
make modules_install dtbs_install \
ARCH=arm64 \
INSTALL_MOD_STRIP=1 \
INSTALL_MOD_PATH="$pkgdir" \
INSTALL_DTBS_PATH="$pkgdir/boot/dtbs"
rm -f "$pkgdir"/lib/modules/*/build "$pkgdir"/lib/modules/*/source
install -D "$builddir"/include/config/kernel.release \
-t "$pkgdir"/usr/share/kernel/$_flavor/
}
sha512sums="
255921dd12f1043a4db38b5435b34773267c592f6712815c0851f1e0add71131fb00fd00746200eabdad29ba5b6e38a768da9c048da47fb5aa59d8eaef7d236e linux-6.8.1.tar.xz
34a9640e3195dd6fa972e8c9dde841cad51786791f59eae35b52ea8edf9eac189532cd3808c2cd5f627b9b61c1265ce87b868aa5179147a5b5beb10f4c094982 config-powkiddy-x55.aarch64
"

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,67 @@
# Maintainer: Vitaliy Ognev <vitaliy.ognev@gmail.com>
pkgname=u-boot-powkiddy-x55
pkgver=v2024.01_rc4
pkgrel=0
pkgdesc="U-Boot bootloader for the Powkiddy X55 (rk3566)"
url="https://source.denx.de/u-boot/u-boot.git"
arch="aarch64"
_carch="arm64"
license="GPL-2.0-or-later OFL-1.1 BSD-2-Clause BSD-3-Clause eCos-2.0 IBM-pibs
ISC LGPL-2.0-only LGPL-2.1-only X11"
options="!check"
makedepends="
bc
bison
flex
libfdt
make
openssl-dev
py3-elftools
py3-setuptools
python3-dev
swig
"
_uboot="27089f1e4d11fd7e0619097b59258d0428cde2ac"
_rkbin="a2a0b89b6c8c612dca5ed9ed8a68db8a07f68bc0"
builddir=$srcdir/u-boot-$_uboot
source="
uboot-$_uboot.tar.gz::https://github.com/u-boot/u-boot/archive/$_uboot.tar.gz
rkbin-$_rkbin.tar.gz::https://github.com/rockchip-linux/rkbin/archive/$_rkbin.tar.gz
powkiddy-x55.patch
"
build() {
cd $srcdir/rkbin-$_rkbin
./tools/boot_merger RKBOOT/RK3568MINIALL.ini
cd $builddir
make powkiddy-x55-rk3566_defconfig
export ROCKCHIP_TPL=$srcdir/rkbin-$_rkbin/bin/rk35/rk3566_ddr_1056MHz_v1.21.bin
export BL31=$srcdir/rkbin-$_rkbin/bin/rk35/rk3568_bl31_v1.44.elf
make spl/u-boot-spl.bin u-boot.dtb u-boot.img tools
make CONFIG_MKIMAGE_DTC_PATH="scripts/dtc/dtc"
tools/mkimage -n rk3568 -T rksd -d \
$ROCKCHIP_TPL:$srcdir/rkbin-$_rkbin/rk356x_spl_loader_v1.21.113.bin \
-C bzip2 idbloader.img
}
package() {
_installdir="$pkgdir/usr/share/u-boot/powkiddy-x55"
install -Dm644 u-boot.itb -t $_installdir
install -Dm644 idbloader.img -t $_installdir
}
sha512sums="
2727d6bd70b17a9235dd7296dddfc458a9632a62119a61a7ddaf91059844e8fe213dfeafe8126b0c9c1966e6614ead8c9b4710ab3dc636744533fbc7138e3ff5 uboot-27089f1e4d11fd7e0619097b59258d0428cde2ac.tar.gz
715253b5ef5c7fbcbce8478d4dea5ad3d1b4b738da437b5f0e9b31eed20f9bcb86cab082e4c04c69b42b6ffcc2cbb1a31079b33b968bb76826ff0dd4f83043e1 rkbin-a2a0b89b6c8c612dca5ed9ed8a68db8a07f68bc0.tar.gz
f9c6850267fc47ee14358df4cd10c46687c6f6223bba6de3aa6c6401c973ced7753ba7e81c7bf8315428a9cef50472aa257a1737ba9271482a2c13f69bcf29c1 powkiddy-x55.patch
"

File diff suppressed because it is too large Load diff