Merge pull request #21 from hkfuertes/zram

zram + CI/CD consolidation
This commit is contained in:
Miguel Fuertes authored and GitHub committed 2026-02-21 18:10:03 +01:00
commit dfbe0339c3
12 files changed
+79 -242

No files matched your search

@@ -1,18 +1,22 @@
name: OpenWrt Builder (M9S)
name: OpenWrt Builder (All Devices)
on:
repository_dispatch:
workflow_dispatch:
env:
UPLOAD_BIN_DIR: true
UPLOAD_FIRMWARE: true
UPLOAD_RELEASE: false
TZ: Europe/Madrid
jobs:
build:
runs-on: ubuntu-22.04
strategy:
fail-fast: false
matrix:
device: [uz801, m9s, mf68e, uf02]
steps:
- name: Checkout
uses: actions/checkout@v4
@@ -29,19 +33,17 @@ jobs:
sudo -E apt-get -qq clean
sudo timedatectl set-timezone "$TZ"
- name: "Clone OpenWrt source code"
- name: Clone OpenWrt source code
run: |
df -hT $PWD
git clone --depth=1 --branch "main" https://git.openwrt.org/openwrt/openwrt.git openwrt
git clone https://git.openwrt.org/openwrt/openwrt.git openwrt
git -C openwrt checkout 00ceb1ed1763f7479df6edf92ffada948f0e7d45
- name: Load msm89xx target and packages
run: |
git apply --unsafe-paths enable_wcn36xx_mac80211.patch
mv msm89xx openwrt/target/linux/msm89xx
mv packages openwrt/package/uz801
if [ "${{ inputs.openwrt_version }}" == "openwrt-24.10" ]; then
sed -i '/^KERNEL_PATCHVER/c\KERNEL_PATCHVER:=6.6' openwrt/target/linux/msm89xx/Makefile
fi
- name: Update and install feeds
run: |
@@ -50,9 +52,11 @@ jobs:
./scripts/feeds update -a
./scripts/feeds install -a
- name: "Load diffconfig"
- name: Load diffconfig
run: |
[ -f diffconfig_m9s ] && mv diffconfig_m9s openwrt/.config
DEVICE="${{ matrix.device }}"
DIFFCONFIG=$([ "$DEVICE" = "uz801" ] && echo "diffconfig" || echo "diffconfig_${DEVICE}")
[ -f "$DIFFCONFIG" ] && mv "$DIFFCONFIG" openwrt/.config
- name: Download package
id: package
@@ -89,9 +93,9 @@ jobs:
with:
name: openwrt_firmware_${{ env.DEVICE_NAME }}_${{ env.FILE_DATE }}
path: |
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-m9s-squashfs-gpt_both0.bin
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-m9s-squashfs-boot.img
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-m9s-squashfs-system.img
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-m9s.manifest
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-m9s-flash.sh
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-m9s-firmware.zip
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-${{ env.DEVICE_NAME }}-squashfs-gpt_both0.bin
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-${{ env.DEVICE_NAME }}-squashfs-boot.img
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-${{ env.DEVICE_NAME }}-squashfs-system.img
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-${{ env.DEVICE_NAME }}.manifest
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-${{ env.DEVICE_NAME }}-flash.sh
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-${{ env.DEVICE_NAME }}-firmware.zip
@@ -1,12 +1,22 @@
name: OpenWrt Builder (MF68E)
name: OpenWrt Builder
on:
repository_dispatch:
workflow_dispatch:
inputs:
device:
description: 'Target device'
required: true
type: choice
default: uz801
options:
- uz801
- m9s
- mf68e
- uf02
env:
UPLOAD_BIN_DIR: true
UPLOAD_FIRMWARE: true
UPLOAD_RELEASE: false
TZ: Europe/Madrid
jobs:
@@ -29,19 +39,17 @@ jobs:
sudo -E apt-get -qq clean
sudo timedatectl set-timezone "$TZ"
- name: "Clone OpenWrt source code"
- name: Clone OpenWrt source code
run: |
df -hT $PWD
git clone --depth=1 --branch "main" https://git.openwrt.org/openwrt/openwrt.git openwrt
git clone https://git.openwrt.org/openwrt/openwrt.git openwrt
git -C openwrt checkout 00ceb1ed1763f7479df6edf92ffada948f0e7d45
- name: Load msm89xx target and packages
run: |
git apply --unsafe-paths enable_wcn36xx_mac80211.patch
mv msm89xx openwrt/target/linux/msm89xx
mv packages openwrt/package/uz801
if [ "${{ inputs.openwrt_version }}" == "openwrt-24.10" ]; then
sed -i '/^KERNEL_PATCHVER/c\KERNEL_PATCHVER:=6.6' openwrt/target/linux/msm89xx/Makefile
fi
- name: Update and install feeds
run: |
@@ -50,9 +58,11 @@ jobs:
./scripts/feeds update -a
./scripts/feeds install -a
- name: "Load diffconfig"
- name: Load diffconfig
run: |
[ -f diffconfig_mf68e ] && mv diffconfig_mf68e openwrt/.config
DEVICE="${{ inputs.device || 'uz801' }}"
DIFFCONFIG=$([ "$DEVICE" = "uz801" ] && echo "diffconfig" || echo "diffconfig_${DEVICE}")
[ -f "$DIFFCONFIG" ] && mv "$DIFFCONFIG" openwrt/.config
- name: Download package
id: package
@@ -89,9 +99,9 @@ jobs:
with:
name: openwrt_firmware_${{ env.DEVICE_NAME }}_${{ env.FILE_DATE }}
path: |
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-mf68e-squashfs-gpt_both0.bin
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-mf68e-squashfs-boot.img
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-mf68e-squashfs-system.img
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-mf68e.manifest
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-mf68e-flash.sh
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-mf68e-firmware.zip
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-${{ env.DEVICE_NAME }}-squashfs-gpt_both0.bin
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-${{ env.DEVICE_NAME }}-squashfs-boot.img
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-${{ env.DEVICE_NAME }}-squashfs-system.img
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-${{ env.DEVICE_NAME }}.manifest
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-${{ env.DEVICE_NAME }}-flash.sh
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-${{ env.DEVICE_NAME }}-firmware.zip
-97
View File
@@ -1,97 +0,0 @@
name: OpenWrt Builder (UF02)
on:
repository_dispatch:
workflow_dispatch:
env:
UPLOAD_BIN_DIR: true
UPLOAD_FIRMWARE: true
UPLOAD_RELEASE: false
TZ: Europe/Madrid
jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Initialization environment
env:
DEBIAN_FRONTEND: noninteractive
run: |
sudo rm -rf /etc/apt/sources.list.d/* /usr/share/dotnet /usr/local/lib/android /opt/ghc /opt/hostedtoolcache/CodeQL
sudo docker image prune --all --force
sudo -E apt-get -qq update
sudo -E ./devenv/dependencies.sh
sudo -E apt-get -qq autoremove --purge
sudo -E apt-get -qq clean
sudo timedatectl set-timezone "$TZ"
- name: "Clone OpenWrt source code"
run: |
df -hT $PWD
git clone --depth=1 --branch "main" https://git.openwrt.org/openwrt/openwrt.git openwrt
- name: Load msm89xx target and packages
run: |
git apply --unsafe-paths enable_wcn36xx_mac80211.patch
mv msm89xx openwrt/target/linux/msm89xx
mv packages openwrt/package/uz801
if [ "${{ inputs.openwrt_version }}" == "openwrt-24.10" ]; then
sed -i '/^KERNEL_PATCHVER/c\KERNEL_PATCHVER:=6.6' openwrt/target/linux/msm89xx/Makefile
fi
- name: Update and install feeds
run: |
cd openwrt
rm -rf tmp
./scripts/feeds update -a
./scripts/feeds install -a
- name: "Load diffconfig"
run: |
[ -f diffconfig_uf02 ] && mv diffconfig_uf02 openwrt/.config
- name: Download package
id: package
run: |
cd openwrt
make defconfig
make download -j8
find dl -size -1024c -exec ls -l {} \; || true
find dl -size -1024c -exec rm -f {} \; || true
- name: Compile the firmware
id: compile
run: |
cd openwrt
echo -e "$(nproc) thread compile"
make -j$(nproc) || make -j1 || make -j1 V=s
echo "status=success" >> $GITHUB_OUTPUT
grep '^CONFIG_TARGET.*DEVICE.*=y' .config | sed -r 's/.*DEVICE_(.*)=y/\1/' > DEVICE_NAME
[ -s DEVICE_NAME ] && echo "DEVICE_NAME=$(cat DEVICE_NAME)" >> $GITHUB_ENV
echo "FILE_DATE=$(date +"%Y%m%d%H%M")" >> $GITHUB_ENV
- name: Organize files
id: organize
if: env.UPLOAD_FIRMWARE == 'true' && !cancelled()
run: |
cd openwrt/bin/targets/*/*
rm -rf packages
echo "FIRMWARE=$PWD" >> $GITHUB_ENV
echo "status=success" >> $GITHUB_OUTPUT
- name: Upload firmware
uses: actions/upload-artifact@v4
if: steps.organize.outputs.status == 'success' && !cancelled()
with:
name: openwrt_firmware_${{ env.DEVICE_NAME }}_${{ env.FILE_DATE }}
path: |
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-uf02-squashfs-gpt_both0.bin
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-uf02-squashfs-boot.img
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-uf02-squashfs-system.img
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-uf02.manifest
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-uf02-flash.sh
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-generic-uf02-firmware.zip
-97
View File
@@ -1,97 +0,0 @@
name: OpenWrt Builder (UZ801)
on:
repository_dispatch:
workflow_dispatch:
env:
UPLOAD_BIN_DIR: true
UPLOAD_FIRMWARE: true
UPLOAD_RELEASE: false
TZ: Europe/Madrid
jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Initialization environment
env:
DEBIAN_FRONTEND: noninteractive
run: |
sudo rm -rf /etc/apt/sources.list.d/* /usr/share/dotnet /usr/local/lib/android /opt/ghc /opt/hostedtoolcache/CodeQL
sudo docker image prune --all --force
sudo -E apt-get -qq update
sudo -E ./devenv/dependencies.sh
sudo -E apt-get -qq autoremove --purge
sudo -E apt-get -qq clean
sudo timedatectl set-timezone "$TZ"
- name: "Clone OpenWrt source code"
run: |
df -hT $PWD
git clone --depth=1 --branch "main" https://git.openwrt.org/openwrt/openwrt.git openwrt
- name: Load msm89xx target and packages
run: |
git apply --unsafe-paths enable_wcn36xx_mac80211.patch
mv msm89xx openwrt/target/linux/msm89xx
mv packages openwrt/package/uz801
if [ "${{ inputs.openwrt_version }}" == "openwrt-24.10" ]; then
sed -i '/^KERNEL_PATCHVER/c\KERNEL_PATCHVER:=6.6' openwrt/target/linux/msm89xx/Makefile
fi
- name: Update and install feeds
run: |
cd openwrt
rm -rf tmp
./scripts/feeds update -a
./scripts/feeds install -a
- name: "Load diffconfig"
run: |
[ -f diffconfig ] && mv diffconfig openwrt/.config
- name: Download package
id: package
run: |
cd openwrt
make defconfig
make download -j8
find dl -size -1024c -exec ls -l {} \; || true
find dl -size -1024c -exec rm -f {} \; || true
- name: Compile the firmware
id: compile
run: |
cd openwrt
echo -e "$(nproc) thread compile"
make -j$(nproc) || make -j1 || make -j1 V=s
echo "status=success" >> $GITHUB_OUTPUT
grep '^CONFIG_TARGET.*DEVICE.*=y' .config | sed -r 's/.*DEVICE_(.*)=y/\1/' > DEVICE_NAME
[ -s DEVICE_NAME ] && echo "DEVICE_NAME=$(cat DEVICE_NAME)" >> $GITHUB_ENV
echo "FILE_DATE=$(date +"%Y%m%d%H%M")" >> $GITHUB_ENV
- name: Organize files
id: organize
if: env.UPLOAD_FIRMWARE == 'true' && !cancelled()
run: |
cd openwrt/bin/targets/*/*
rm -rf packages
echo "FIRMWARE=$PWD" >> $GITHUB_ENV
echo "status=success" >> $GITHUB_OUTPUT
- name: Upload firmware
uses: actions/upload-artifact@v4
if: steps.organize.outputs.status == 'success' && !cancelled()
with:
name: openwrt_firmware_${{ env.DEVICE_NAME }}_${{ env.FILE_DATE }}
path: |
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-yiming-uz801v3-squashfs-gpt_both0.bin
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-yiming-uz801v3-squashfs-boot.img
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-yiming-uz801v3-squashfs-system.img
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-yiming-uz801v3.manifest
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-yiming-uz801v3-flash.sh
${{ env.FIRMWARE }}/openwrt-msm89xx-msm8916-yiming-uz801v3-firmware.zip
+1
View File
@@ -1 +1,2 @@
bin
pr_description.md
+2 -1
View File
@@ -20,7 +20,8 @@ FROM base AS openwrt
ENV BRANCH=main
# Clone OpenWrt repository
RUN git clone --depth=1 -b ${BRANCH} https://git.openwrt.org/openwrt/openwrt.git openwrt
RUN git clone https://git.openwrt.org/openwrt/openwrt.git openwrt && \
git -C openwrt checkout 00ceb1ed1763f7479df6edf92ffada948f0e7d45
# Apply patch inside openwrt directory
COPY enable_wcn36xx_mac80211.patch .
+2
View File
@@ -89,4 +89,6 @@ CONFIG_PACKAGE_ucode-mod-math=y
CONFIG_PACKAGE_uhttpd=y
CONFIG_PACKAGE_uhttpd-mod-ubus=y
CONFIG_PACKAGE_wireguard-tools=y
CONFIG_PACKAGE_kmod-zram=y
CONFIG_PACKAGE_zram-swap=y
# CONFIG_TARGET_ROOTFS_EXT4FS is not set
+2
View File
@@ -91,4 +91,6 @@ CONFIG_PACKAGE_ucode-mod-math=y
CONFIG_PACKAGE_uhttpd=y
CONFIG_PACKAGE_uhttpd-mod-ubus=y
CONFIG_PACKAGE_wireguard-tools=y
CONFIG_PACKAGE_kmod-zram=y
CONFIG_PACKAGE_zram-swap=y
# CONFIG_TARGET_ROOTFS_EXT4FS is not set
+2
View File
@@ -91,4 +91,6 @@ CONFIG_PACKAGE_ucode-mod-math=y
CONFIG_PACKAGE_uhttpd=y
CONFIG_PACKAGE_uhttpd-mod-ubus=y
CONFIG_PACKAGE_wireguard-tools=y
CONFIG_PACKAGE_kmod-zram=y
CONFIG_PACKAGE_zram-swap=y
# CONFIG_TARGET_ROOTFS_EXT4FS is not set
+2
View File
@@ -92,4 +92,6 @@ CONFIG_PACKAGE_ucode-mod-math=y
CONFIG_PACKAGE_uhttpd=y
CONFIG_PACKAGE_uhttpd-mod-ubus=y
CONFIG_PACKAGE_wireguard-tools=y
CONFIG_PACKAGE_kmod-zram=y
CONFIG_PACKAGE_zram-swap=y
# CONFIG_TARGET_ROOTFS_EXT4FS is not set
+21 -14
View File
@@ -1,18 +1,16 @@
diff --git a/oopenwrt/package/kernel/mac80211/ath.mk b/openwrt/package/kernel/mac80211/ath.mk
index 5b13b6a..f8c5edf 100644
diff --git a/openwrt/package/kernel/mac80211/ath.mk b/openwrt/package/kernel/mac80211/ath.mk
--- a/openwrt/package/kernel/mac80211/ath.mk
+++ b/openwrt/package/kernel/mac80211/ath.mk
@@ -1,6 +1,7 @@
@@ -1,6 +1,6 @@
PKG_DRIVERS += \
- ath ath5k ath6kl ath6kl-sdio ath6kl-usb ath9k ath9k-common ath9k-htc ath10k ath10k-smallbuffers \
- ath11k ath11k-ahb ath11k-pci ath12k carl9170 owl-loader ar5523 wil6210 qcom-qmi-helpers
+ ath ath5k ath6kl ath6kl-sdio ath6kl-usb ath9k ath9k-common ath9k-htc ath10k ath10k-sdio ath10k-smallbuffers \
+ ath11k ath11k-ahb ath11k-pci ath12k carl9170 owl-loader ar5523 wil6210 wcn36xx qcom-qmi-helpers
+
PKG_CONFIG_DEPENDS += \
CONFIG_PACKAGE_ATH_DEBUG \
@@ -25,7 +26,8 @@ ifdef CONFIG_PACKAGE_MAC80211_DEBUGFS
@@ -25,7 +25,8 @@
CARL9170_DEBUGFS \
ATH5K_DEBUG \
ATH6KL_DEBUG \
@@ -22,7 +20,7 @@ index 5b13b6a..f8c5edf 100644
endif
ifdef CONFIG_PACKAGE_MAC80211_TRACING
@@ -40,7 +42,7 @@ ifdef CONFIG_PACKAGE_MAC80211_TRACING
@@ -40,7 +41,7 @@
endif
config-$(call config_package,qcom-qmi-helpers) += QCOM_QMI_HELPERS
@@ -31,7 +29,7 @@ index 5b13b6a..f8c5edf 100644
config-$(CONFIG_PACKAGE_ATH_DEBUG) += ATH_DEBUG ATH10K_DEBUG ATH11K_DEBUG ATH12K_DEBUG ATH9K_STATION_STATISTICS
config-$(CONFIG_PACKAGE_ATH_DFS) += ATH9K_DFS_CERTIFIED ATH10K_DFS_CERTIFIED
config-$(CONFIG_PACKAGE_ATH_SPECTRAL) += ATH9K_COMMON_SPECTRAL ATH10K_SPECTRAL ATH11K_SPECTRAL
@@ -50,6 +52,7 @@ config-$(call config_package,ath9k-common) += ATH9K_COMMON
@@ -50,6 +51,7 @@
config-$(call config_package,owl-loader) += ATH9K_PCI_NO_EEPROM
config-$(CONFIG_TARGET_ath79) += ATH9K_AHB
config-$(CONFIG_TARGET_ipq40xx) += ATH10K_AHB
@@ -39,7 +37,7 @@ index 5b13b6a..f8c5edf 100644
config-$(CONFIG_PCI) += ATH9K_PCI
config-$(CONFIG_ATH_USER_REGD) += ATH_USER_REGD ATH_REG_DYNAMIC_USER_REG_HINTS
config-$(CONFIG_ATH9K_HWRNG) += ATH9K_HWRNG
@@ -62,6 +65,7 @@ config-$(CONFIG_ATH11K_THERMAL) += ATH11K_THERMAL
@@ -62,6 +64,7 @@
config-$(call config_package,ath9k-htc) += ATH9K_HTC
config-$(call config_package,ath10k,regular) += ATH10K ATH10K_PCI
@@ -47,7 +45,7 @@ index 5b13b6a..f8c5edf 100644
config-$(call config_package,ath10k-smallbuffers,smallbuffers) += ATH10K ATH10K_PCI ATH10K_SMALLBUFFERS
config-$(call config_package,ath11k) += ATH11K
config-$(call config_package,ath11k-ahb) += ATH11K_AHB
@@ -140,7 +144,7 @@ endef
@@ -140,7 +143,7 @@
define KernelPackage/ath
$(call KernelPackage/mac80211/Default)
TITLE:=Atheros common driver part
@@ -56,7 +54,12 @@ index 5b13b6a..f8c5edf 100644
FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath.ko
MENU:=1
endef
@@ -294,10 +298,30 @@ define KernelPackage/ath10k/config
@@ -295,11 +298,12 @@
config ATH10K_LEDS
bool "Enable LED support"
default y
- depends on PACKAGE_kmod-ath10k || PACKAGE_kmod-ath10k-smallbuffers
+ depends on PACKAGE_kmod-ath10k || PACKAGE_kmod-ath10k-sdio || PACKAGE_kmod-ath10k-smallbuffers
config ATH10K_THERMAL
bool "Enable thermal sensors and throttling support"
@@ -66,6 +69,10 @@ index 5b13b6a..f8c5edf 100644
endef
@@ -310,6 +314,25 @@
PROVIDES:=@kmod-ath10k-any
endef
+define KernelPackage/ath10k-sdio
+ $(call KernelPackage/mac80211/Default)
+ TITLE:=Atheros 802.11ac SDIO wireless cards support
@@ -85,10 +92,10 @@ index 5b13b6a..f8c5edf 100644
+Atheros IEEE 802.11ac family of chipsets with SDIO bus.
+endef
+
define KernelPackage/ath10k-smallbuffers
$(call KernelPackage/ath10k)
TITLE+= (small buffers for low-RAM devices)
@@ -356,6 +380,20 @@ This module adds support for Qualcomm Technologies 802.11ax family of
define KernelPackage/ath11k
$(call KernelPackage/mac80211/Default)
TITLE:=Qualcomm 802.11ax wireless chipset support (common code)
@@ -362,6 +385,20 @@
chipsets with PCI bus.
endef
+1 -1
View File
@@ -215,7 +215,7 @@ The modem requires region-specific MCFG configuration files.
- Note: Target-specific modules may require building from source via `make menuconfig`
- Removed feed: `https://downloads.openwrt.org/snapshots/targets/msm89xx/msm8916/packages/packages.adb`
- [ ] Investigate `lpac` for eSIM support
- [ ] Memory expansion: swap/zram configuration
- [x] Memory expansion: `kmod-zram` + `zram-swap` enabled on all devices
## Credits