From 49c6f0ce39c3c12586d1638d53c12dd5615fa172 Mon Sep 17 00:00:00 2001 From: Raymond Hackley Date: Tue, 1 Mar 2022 20:14:40 +0900 Subject: [PATCH] samsung-fortunaltezt: new device (MR 3026) --- .../device-samsung-fortunaltezt/APKBUILD | 51 +++++++++++++++++++ .../device-samsung-fortunaltezt/deviceinfo | 33 ++++++++++++ .../device-samsung-fortunaltezt/phoc.ini | 2 + .../firmware-samsung-fortunaltezt/APKBUILD | 32 ++++++++++++ 4 files changed, 118 insertions(+) create mode 100644 device/testing/device-samsung-fortunaltezt/APKBUILD create mode 100644 device/testing/device-samsung-fortunaltezt/deviceinfo create mode 100644 device/testing/device-samsung-fortunaltezt/phoc.ini create mode 100644 device/testing/firmware-samsung-fortunaltezt/APKBUILD diff --git a/device/testing/device-samsung-fortunaltezt/APKBUILD b/device/testing/device-samsung-fortunaltezt/APKBUILD new file mode 100644 index 000000000..388ba5875 --- /dev/null +++ b/device/testing/device-samsung-fortunaltezt/APKBUILD @@ -0,0 +1,51 @@ +# Reference: +pkgname=device-samsung-fortunaltezt +pkgdesc="Samsung Galaxy Grand Prime (SM-G530Y)" +pkgver=1 +pkgrel=0 +url="https://postmarketos.org" +license="MIT" +arch="armv7" +options="!check !archcheck" +depends=" + postmarketos-base + mkbootimg + linux-postmarketos-qcom-msm8916 + soc-qcom-msm8916 + soc-qcom-msm8916-rproc +" +makedepends="devicepkg-dev" +source=" + deviceinfo + phoc.ini +" +subpackages=" + $pkgname-nonfree-firmware:nonfree_firmware + $pkgname-phosh +" +_pmb_select="soc-qcom-msm8916-rproc" + +build() { + devicepkg_build $startdir $pkgname +} + +package() { + devicepkg_package $startdir $pkgname +} + +nonfree_firmware() { + pkgdesc="GPU/WiFi/BT/Modem/Video firmware" + depends="firmware-qcom-adreno-a300 msm-firmware-loader firmware-samsung-fortunaltezt-wcnss-nv" + mkdir "$subpkgdir" +} + +phosh() { + install_if="$pkgname postmarketos-ui-phosh" + install -Dm644 "$srcdir"/phoc.ini \ + "$subpkgdir"/etc/phosh/phoc.ini +} + +sha512sums=" +d2a5ff7f9bd85107388aca5c921ee0352b9c4d4725bef0a810f2c736a1715bb619922a2cf24124554dcbe8f57ebf20c6bcbc2d4e46939d37a109cf32169275d7 deviceinfo +dbc8422fc00c757963dd016f26dd45d8c05c8c46b7e60cd11dd154550e166568cfdcee60678ee3542d27c2f8c373b71a1c3ec33da0260509fe4133ecd06a27bc phoc.ini +" diff --git a/device/testing/device-samsung-fortunaltezt/deviceinfo b/device/testing/device-samsung-fortunaltezt/deviceinfo new file mode 100644 index 000000000..8a6d3d574 --- /dev/null +++ b/device/testing/device-samsung-fortunaltezt/deviceinfo @@ -0,0 +1,33 @@ +# Reference: +# Please use double quotes only. You can source this file in shell scripts. + +deviceinfo_format_version="0" +deviceinfo_name="Samsung Galaxy Grand Prime (SM-G530Y)" +deviceinfo_manufacturer="Samsung" +deviceinfo_codename="samsung-fortunaltezt" +deviceinfo_year="2014" +deviceinfo_dtb="qcom-msm8916-samsung-fortunaltezt" +deviceinfo_append_dtb="true" +deviceinfo_modules_initfs="panel-samsung-hx8389c-gh9607501a msm zinitix" +deviceinfo_arch="armv7" + +# Device related +deviceinfo_gpu_accelerated="true" +deviceinfo_chassis="handset" +deviceinfo_keyboard="false" +deviceinfo_external_storage="true" +deviceinfo_screen_width="540" +deviceinfo_screen_height="960" +deviceinfo_getty="ttyMSM0;115200" + +# Bootloader related +deviceinfo_flash_method="fastboot" +deviceinfo_kernel_cmdline="earlycon console=ttyMSM0,115200 PMOS_NO_OUTPUT_REDIRECT" +deviceinfo_generate_bootimg="true" +deviceinfo_flash_offset_base="0x80000000" +deviceinfo_flash_offset_kernel="0x00080000" +deviceinfo_flash_offset_ramdisk="0x02000000" +deviceinfo_flash_offset_second="0x00f00000" +deviceinfo_flash_offset_tags="0x01e00000" +deviceinfo_flash_pagesize="2048" +deviceinfo_flash_sparse="true" diff --git a/device/testing/device-samsung-fortunaltezt/phoc.ini b/device/testing/device-samsung-fortunaltezt/phoc.ini new file mode 100644 index 000000000..21546afe3 --- /dev/null +++ b/device/testing/device-samsung-fortunaltezt/phoc.ini @@ -0,0 +1,2 @@ +[output:DSI-1] +scale = 1.5 diff --git a/device/testing/firmware-samsung-fortunaltezt/APKBUILD b/device/testing/firmware-samsung-fortunaltezt/APKBUILD new file mode 100644 index 000000000..15c8335e4 --- /dev/null +++ b/device/testing/firmware-samsung-fortunaltezt/APKBUILD @@ -0,0 +1,32 @@ +pkgname=firmware-samsung-fortunaltezt +pkgver=1 +pkgrel=0 +_name="Samsung Galaxy Grand Prime (SM-G530Y)" +pkgdesc="Firmware for $_name" +url="https://postmarketos.org" +subpackages="$pkgname-wcnss-nv:wcnss_nv" +arch="armv7" +license="proprietary" +options="!check !strip !archcheck !tracedeps pmb:cross-native" +source="$pkgname-WCNSS_qcom_wlan_nv.bin.base64::https://pastebin.com/raw/s25mBaen" + +_fwdir="/lib/firmware/postmarketos" + +unpack() { + default_unpack + base64 -d $pkgname-WCNSS_qcom_wlan_nv.bin.base64 > WCNSS_qcom_wlan_nv.bin +} + +package() { + # parent package is empty + mkdir -p "$pkgdir" +} + +wcnss_nv() { + pkgdesc="$_name WiFi/BT firmware configuration" + install -Dm644 "$srcdir"/WCNSS_qcom_wlan_nv.bin -t "$subpkgdir/$_fwdir"/wlan/prima +} + +sha512sums=" +0a34532a0c5bbf69bb6a81ec850951b47c9e059a3ea2ab269dac1dfe19de49a51f98d018d899db2517e95f0ac737f82ff0c46df9bfd3e990b44b7b03062cba2e firmware-samsung-fortunaltezt-WCNSS_qcom_wlan_nv.bin.base64 +"