diff --git a/device/testing/device-samsung-gt510/APKBUILD b/device/testing/device-samsung-gt510/APKBUILD new file mode 100644 index 000000000..0691d2e71 --- /dev/null +++ b/device/testing/device-samsung-gt510/APKBUILD @@ -0,0 +1,64 @@ +# Reference: +# Maintainer: Nikita Travkin +pkgname=device-samsung-gt510 +pkgdesc="Samsung Galaxy Tab A 9.7 (2015)" +pkgver=1 +pkgrel=0 +url="https://postmarketos.org" +license="MIT" +arch="aarch64" +options="!check !archcheck" +depends="postmarketos-base mkbootimg soc-qcom-msm8916" +makedepends="devicepkg-dev" +source=" + deviceinfo + pointercal + rootston.ini +" +subpackages=" + $pkgname-kernel-mainline:kernel_mainline + $pkgname-kernel-mainline-modem-lte:kernel_mainline_modem_lte + $pkgname-nonfree-firmware:nonfree_firmware + $pkgname-phosh +" + +build() { + devicepkg_build $startdir $pkgname +} + +package() { + devicepkg_package $startdir $pkgname + + install -D -m644 "$srcdir"/pointercal \ + "$pkgdir"/etc/pointercal +} + +kernel_mainline() { + pkgdesc="Close to mainline kernel (no modem, audio routed directly, use for all variants)" + depends="linux-postmarketos-qcom-msm8916" + devicepkg_subpackage_kernel $startdir $pkgname $subpkgname +} + +kernel_mainline_modem_lte() { + pkgdesc="Close to mainline kernel (non-free modem, audio routed through ADSP, for LTE variant)" + depends="linux-postmarketos-qcom-msm8916 soc-qcom-msm8916-modem" + devicepkg_subpackage_kernel $startdir $pkgname $subpkgname +} + +nonfree_firmware() { + pkgdesc="GPU/WiFi/BT/Video(/Modem) firmware" + depends="linux-firmware-qcom msm-firmware-loader firmware-samsung-gt510-wcnss-nv" + mkdir "$subpkgdir" +} + +phosh() { + install_if="$pkgname postmarketos-ui-phosh" + install -Dm644 "$srcdir"/rootston.ini \ + "$subpkgdir"/etc/phosh/rootston.ini +} + +sha512sums=" +e441a875457ee6dc8822df7a89cd08522af0b03c2dc8f9adc1f9d969297a0507f96defae425899c1248c659e7be418afd677c16a171a836ecda551b3c2148955 deviceinfo +6aedd5eeac4d21356678f5399f3f0946392c9a7477ac21d39b8e761133dc8ed67adb4966647314f71d5263483ab68cad92847dacff95ffa45eabfc33c9f405b5 pointercal +bc620d2031027405f70eea68854744799b460db0d787e2c844556f437120eea0fc857689c6894dd485a5cd3794c7fb5281b901e9e10da1b550c637a852445180 rootston.ini +" diff --git a/device/testing/device-samsung-gt510wifi/deviceinfo b/device/testing/device-samsung-gt510/deviceinfo similarity index 74% rename from device/testing/device-samsung-gt510wifi/deviceinfo rename to device/testing/device-samsung-gt510/deviceinfo index 1e7f34edc..b6cdecad8 100644 --- a/device/testing/device-samsung-gt510wifi/deviceinfo +++ b/device/testing/device-samsung-gt510/deviceinfo @@ -2,12 +2,14 @@ # Please use double quotes only. You can source this file in shell scripts. deviceinfo_format_version="0" -deviceinfo_name="Samsung Galaxy Tab A 9.7 Wifi (2015) (SM-T550)" +deviceinfo_name="Samsung Galaxy Tab A 9.7 (2015)" deviceinfo_manufacturer="Samsung" -deviceinfo_codename="samsung-gt510wifi" +deviceinfo_codename="samsung-gt510" deviceinfo_year="2015" -deviceinfo_dtb="qcom/msm8916-samsung-gt510" +deviceinfo_dtb_mainline="qcom/msm8916-samsung-gt510" +deviceinfo_dtb_mainline_modem_lte="qcom/msm8916-samsung-gt510lte-modem" deviceinfo_append_dtb="true" +deviceinfo_modules_initfs="panel-samsung-s6d7aa0-ltl101at01 msm atmel_mxt_ts" deviceinfo_arch="aarch64" # Device related @@ -17,9 +19,7 @@ deviceinfo_external_storage="true" deviceinfo_screen_width="768" deviceinfo_screen_height="1024" deviceinfo_getty="ttyMSM0;115200" - -# MSM DRM cannot take over the framebuffer from the bootloader at the moment -deviceinfo_no_framebuffer="true" +deviceinfo_gpu_accelerated="true" # Bootloader related deviceinfo_flash_method="fastboot" diff --git a/device/testing/device-samsung-gt510/pointercal b/device/testing/device-samsung-gt510/pointercal new file mode 100644 index 000000000..01cbfdc3f --- /dev/null +++ b/device/testing/device-samsung-gt510/pointercal @@ -0,0 +1 @@ +12288 0 0 0 16384 0 65536 768 1024 0 diff --git a/device/testing/device-samsung-gt510/rootston.ini b/device/testing/device-samsung-gt510/rootston.ini new file mode 100644 index 000000000..fcc28cac2 --- /dev/null +++ b/device/testing/device-samsung-gt510/rootston.ini @@ -0,0 +1,6 @@ +[cursor:seat0] +map-to-output:DSI-1 + +[output:DSI-1] +scale = 1 + diff --git a/device/testing/device-samsung-gt510wifi/APKBUILD b/device/testing/device-samsung-gt510wifi/APKBUILD deleted file mode 100644 index b63356359..000000000 --- a/device/testing/device-samsung-gt510wifi/APKBUILD +++ /dev/null @@ -1,32 +0,0 @@ -# Reference: -pkgname=device-samsung-gt510wifi -pkgdesc="Samsung Galaxy Tab A 9.7 WiFi (2015) (SM-T550)" -pkgver=3 -pkgrel=3 -url="https://postmarketos.org" -license="MIT" -arch="aarch64" -options="!check !archcheck" -depends="postmarketos-base mkbootimg linux-postmarketos-qcom-msm8916 soc-qcom-msm8916" -makedepends="devicepkg-dev" -source="deviceinfo modprobe.conf" -subpackages="$pkgname-nonfree-firmware:nonfree_firmware" - -build() { - devicepkg_build $startdir $pkgname -} - -package() { - devicepkg_package $startdir $pkgname -} - -nonfree_firmware() { - pkgdesc="GPU/WiFi/BT/Video firmware" - depends="linux-firmware-qcom firmware-samsung-gt510wifi-venus firmware-samsung-gt510wifi-wcnss" - mkdir "$subpkgdir" -} - -sha512sums=" -9280ec6d1d32ba37d496d40f47a317008401f3cf5c0a7abc695fc307bcdf4ef21e6da70ad5fc8ef7522510d473b91b8df9db1f646208c2f3535f9786f0b09d02 deviceinfo -8e589824aa6f2a63e37efc4b4daed6eb0dce5771803f8a5321c9513f413e719c72caa7a952671b9657e3e340bc4bd653bffe3d4685d07f4ec83d7be16e9ddab5 modprobe.conf -" diff --git a/device/testing/device-samsung-gt510wifi/modprobe.conf b/device/testing/device-samsung-gt510wifi/modprobe.conf deleted file mode 100644 index fbe89933e..000000000 --- a/device/testing/device-samsung-gt510wifi/modprobe.conf +++ /dev/null @@ -1,20 +0,0 @@ -# -# There is a weird probe issue if both MSM DRM and the panel driver are built -# as modules: When MSM DRM is loaded it registers the DSI bus for the panel. -# At this point the panel is not loaded yet, so the kernel sends an uevent -# to userspace to load the necessary panel module. -# -# This causes some delay until the panel module is loaded, so MSM DRM fails to -# probe temporarily and returns -EPROBE_DEFER (to request probing again later). -# Unfortunately this will also unregister the DSI bus for the panel, and the -# kernel will not try probing MSM DRM + panel again until some other (slow) -# driver loads after MSM DRM. -# -# Usually WCNSS (WiFi/BT) fits that criteria, allowing the display to work. -# But this does not work if the user decides to exclude proprietary firmware. -# -# To avoid this problem we add an explicit soft dependency for MSM DRM -# on the panel module, so modprobe loads the panel module first and MSM DRM -# will immediately find the panel it is looking for. -# -softdep msm pre: panel-samsung-s6d7aa0-ltl101at01 diff --git a/device/testing/firmware-samsung-gt510/APKBUILD b/device/testing/firmware-samsung-gt510/APKBUILD new file mode 100644 index 000000000..7be6093a8 --- /dev/null +++ b/device/testing/firmware-samsung-gt510/APKBUILD @@ -0,0 +1,33 @@ +pkgname=firmware-samsung-gt510 +pkgver=1 +pkgrel=0 +_name="Samsung Galaxy Tab A 9.7 (2015)" +pkgdesc="Firmware for $_name" +url="https://postmarketos.org" +subpackages="$pkgname-wcnss-nv:wcnss_nv" +arch="aarch64" +license="proprietary" +options="!check !strip !archcheck !tracedeps pmb:cross-native" +source="$pkgname-WCNSS_qcom_wlan_nv.bin.base64::https://pastebin.com/raw/vi1vz9ES" + +_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=" +0708fde555d49c7cad49613af764921a906c6de00638b766b6adbfdcf8848fad630264c9234f804dbfcba9f91dde941a1f594673c1789b6ad48145e8039cde71 firmware-samsung-gt510-WCNSS_qcom_wlan_nv.bin.base64 +" diff --git a/device/testing/firmware-samsung-gt510wifi/APKBUILD b/device/testing/firmware-samsung-gt510wifi/APKBUILD deleted file mode 100644 index a4ed06a39..000000000 --- a/device/testing/firmware-samsung-gt510wifi/APKBUILD +++ /dev/null @@ -1,38 +0,0 @@ -pkgname=firmware-samsung-gt510wifi -pkgver=2 -pkgrel=0 -pkgdesc="Firmware for Samsung Galaxy Tab A 9.7 WiFi (2015) (SM-T550)" -url="https://rizzotherat.gitlab.io/firmware/" -subpackages="$pkgname-modem $pkgname-venus $pkgname-wcnss" -arch="aarch64" -license="proprietary" -options="!check !strip !archcheck !tracedeps pmb:cross-native" -source="https://rizzotherat.gitlab.io/firmware/SM-T550.tar.xz" - -_fwdir="/lib/firmware/postmarketos" - -package() { - # parent package is empty - mkdir -p "$pkgdir" -} - -modem() { - pkgdesc="Samsung Galaxy Tab A 9.7 WiFi (2015) (SM-T550) modem firmware" - install -Dm644 "$srcdir"/mba.mbn -t "$subpkgdir/$_fwdir" - install -Dm644 "$srcdir"/modem.* -t "$subpkgdir/$_fwdir" -} - -venus() { - pkgdesc="Samsung Galaxy Tab A 9.7 WiFi (2015) (SM-T550) video firmware" - install -Dm644 "$srcdir"/venus.* -t "$subpkgdir/$_fwdir"/qcom/venus-1.8 -} - -wcnss() { - pkgdesc="Samsung Galaxy Tab A 9.7 WiFi (2015) (SM-T550) WiFi/BT firmware" - cd "$srcdir" - install -Dm644 wcnss.* -t "$subpkgdir/$_fwdir" - install -Dm644 WCNSS_* -t "$subpkgdir/$_fwdir"/wlan/prima -} - - -sha512sums="ad1e0ec6eb0f23c1cca1e0657176d6ecf536489fb9c64a53ab5e63dd980e0df67e257dc2ae0808c50885476960448bf8d1713c43a9c6225d22c0e854fa67f923 SM-T550.tar.xz"