From bbd601b9f62646a4d79387af6f0632c74551b337 Mon Sep 17 00:00:00 2001
From: David Bauer <mail@david-bauer.net>
Date: Thu, 11 Jan 2024 23:06:53 +0100
Subject: [PATCH] ath79-generic: add support for Ubiquiti UniFi Swiss Army
 Knife Ultra (#3149)

(cherry picked from commit 10721f6e23184a1ca501ba35173e49cd90b1bfd3)
---
 docs/user/supported_devices.rst                          | 1 +
 package/gluon-core/luasrc/usr/lib/lua/gluon/platform.lua | 1 +
 targets/ath79-generic                                    | 6 ++++++
 3 files changed, 8 insertions(+)

diff --git a/docs/user/supported_devices.rst b/docs/user/supported_devices.rst
index 30576777..0f1da2e1 100644
--- a/docs/user/supported_devices.rst
+++ b/docs/user/supported_devices.rst
@@ -154,6 +154,7 @@ ath79-generic
   - UniFi AP LR
   - UniFi AP Outdoor+
   - UniFi AP PRO
+  - UniFi Swiss Army Knife Ultra
 
 ath79-mikrotik
 --------------
diff --git a/package/gluon-core/luasrc/usr/lib/lua/gluon/platform.lua b/package/gluon-core/luasrc/usr/lib/lua/gluon/platform.lua
index 7ba3103f..014e516c 100644
--- a/package/gluon-core/luasrc/usr/lib/lua/gluon/platform.lua
+++ b/package/gluon-core/luasrc/usr/lib/lua/gluon/platform.lua
@@ -41,6 +41,7 @@ function M.is_outdoor_device()
 		'tplink,wbs210-v1',
 		'tplink,wbs210-v2',
 		'tplink,wbs510-v1',
+		'ubnt,uk-ultra',
 		'ubnt,unifi-ap-outdoor-plus',
 		'ubnt,unifiac-mesh',
 		'ubnt,unifiac-mesh-pro',
diff --git a/targets/ath79-generic b/targets/ath79-generic
index 626b6520..af23bf6a 100644
--- a/targets/ath79-generic
+++ b/targets/ath79-generic
@@ -604,3 +604,9 @@ device('ubiquiti-unifi-ap-outdoor+', 'ubnt_unifi-ap-outdoor-plus', {
 })
 
 device('ubiquiti-unifi-ap-pro', 'ubnt_unifi-ap-pro')
+
+
+device('ubiquiti-unifi-swiss-army-knife-ultra', 'ubnt_uk-ultra', {
+	factory = false,
+	packages = ATH10K_PACKAGES_QCA9880,
+})
-- 
GitLab