From 5f1119f7bb6f3b616196d1536b7d443ec310d7f9 Mon Sep 17 00:00:00 2001 From: "Sicelo A. Mhlongo" Date: Mon, 17 Mar 2025 18:01:59 +0200 Subject: [PATCH] wl1251-cal: extract nvs into pmos firmware search path This also allows us to not interfere with the upstream firmware, and thus the trigger is no longer needed. Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6333 [ci:skip-build]: already built successfully in CI --- device/community/wl1251-cal/APKBUILD | 5 ++--- device/community/wl1251-cal/calibrate-wl1251 | 8 ++++---- device/community/wl1251-cal/wl1251-cal.trigger | 5 ----- 3 files changed, 6 insertions(+), 12 deletions(-) delete mode 100644 device/community/wl1251-cal/wl1251-cal.trigger diff --git a/device/community/wl1251-cal/APKBUILD b/device/community/wl1251-cal/APKBUILD index 5f9c203b5..a21bcf9ab 100644 --- a/device/community/wl1251-cal/APKBUILD +++ b/device/community/wl1251-cal/APKBUILD @@ -1,14 +1,13 @@ # Maintainer: Dang Huynh pkgname=wl1251-cal pkgver=1.2 -pkgrel=3 +pkgrel=4 pkgdesc="Retrieve wl1251 calibration data from a CAL partition and feed it to the driver" url="https://github.com/maemo-leste/wl1251-cal" arch="armv7" license="LGPL-2.1-only" makedepends="linux-headers" subpackages="$pkgname-openrc" -triggers="$pkgname.trigger=/lib/firmware/ti-connectivity" source="$pkgname-$pkgver.tar.gz::https://github.com/maemo-leste/wl1251-cal/archive/refs/tags/$pkgver.tar.gz wl1251-cal.initd wl1251-blacklist @@ -35,5 +34,5 @@ sha512sums=" 1a402553fc98fa8f2d81d34a548f96be91d13bdcb77ec8e9d8373732b27a6e908895f6044aef8e88dbcd9fa6fa04f0a3d62bed877be91ba6207f68440c3ce758 wl1251-cal-1.2.tar.gz 39fec86cb13d34a605ad1a76eb3a6ae6e242a01427f477008a3ff066e0b59fb804f0d8379909f81d015aa053ccf9850505dbe3124062ed707a663ae5e2ccd9f1 wl1251-cal.initd d14fd2816a8d55592907f1cf1f702d86095c8d2581b336460eb7d5bfc6ab8cece37a53c0a181b9f75ef5050bc612ce7443992158d36fc03939b39010cd33de4c wl1251-blacklist -11341461c487b3d797728e5bd0883e659b8440a486d2f0bce008403da517582ba706f6ac89ee4a44217078a5e2d71c3a0b3d79c1189f83a431edc4069eddac10 calibrate-wl1251 +b6ee8ab642d2c70444851c6c57c4460f9712a423c8b655ea960563a143ea5609dc9f2bc2af5549b35c4a34ecae5597a382d0d6e4a829b72f0e76b77ab51edaf6 calibrate-wl1251 " diff --git a/device/community/wl1251-cal/calibrate-wl1251 b/device/community/wl1251-cal/calibrate-wl1251 index 336456ceb..c9527132a 100644 --- a/device/community/wl1251-cal/calibrate-wl1251 +++ b/device/community/wl1251-cal/calibrate-wl1251 @@ -5,10 +5,10 @@ if [ -e /in-pmbootstrap ]; then exit 0 fi -# Alpine now ships compressed versions of the firmware. In order for wl1251-cal -# to find the uncompressed file name, create it manually -touch /lib/firmware/ti-connectivity/wl1251-nvs.bin +# Store the firmware in the pmos firmware search path +mkdir -p /lib/firmware/postmarketos/ti-connectivity +touch /lib/firmware/postmarketos/ti-connectivity/wl1251-nvs.bin echo "Extracting and writing wl1251 calibration data.." -wl1251-cal --nvs-loading=/dev/null --nvs-push-data=/lib/firmware/ti-connectivity/wl1251-nvs.bin +wl1251-cal --nvs-loading=/dev/null --nvs-push-data=/lib/firmware/postmarketos/ti-connectivity/wl1251-nvs.bin echo "Done" diff --git a/device/community/wl1251-cal/wl1251-cal.trigger b/device/community/wl1251-cal/wl1251-cal.trigger deleted file mode 100644 index 2940508ed..000000000 --- a/device/community/wl1251-cal/wl1251-cal.trigger +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/sh - -[ -d /lib/firmware/ti-connectivity ] && calibrate-wl1251 - -exit 0