Commit Graph

165 Commits

Author SHA1 Message Date
Qosmio
931313931c nss-firmware: Allow selecting version 11.4/12.1
There is an issue with NSS firmware version 12.0/12.1 where NSS WIFI
mesh feature fails to bring up meshmgr.

Example of error:

Tue Feb 27 13:52:04 2024 kern.debug kernel: [10738.593826] nss_wifi_meshmgr_if_create_sync[1827]:ffffff8022a40000: Encap allocation failed.
Tue Feb 27 13:52:04 2024 kern.warn kernel: [10738.593858] ath11k c000000.wifi: failed to create meshmgr
Tue Feb 27 13:52:04 2024 kern.warn kernel: [10738.593880] ath11k c000000.wifi: failed to alloc and register mesh vap -22
Tue Feb 27 13:52:04 2024 kern.debug kernel: [10738.598335] nss_wifi_meshmgr_find_and_ref_inc[167]:ffffffc000be0500: Invalid mesh handle: -1
Tue Feb 27 13:52:04 2024 kern.debug kernel: [10738.598349] nss_wifi_meshmgr_if_destroy_sync[1728]:ffffffc000be0500: Mesh context is null
Tue Feb 27 13:52:04 2024 kern.warn kernel: [10738.598357] ath11k c000000.wifi: failed to free nss mesh object vdev nss_err:7
Tue Feb 27 13:52:04 2024 kern.warn kernel: [10738.605208] ath11k c000000.wifi: failed to create nss vdev -22
Tue Feb 27 13:52:04 2024 kern.debug kernel: [10738.616401] nss_wifi_meshmgr_if_create_sync[1827]:ffffff8022a40000: Encap allocation failed.
Tue Feb 27 13:52:04 2024 kern.warn kernel: [10738.616436] ath11k c000000.wifi: failed to create meshmgr
Tue Feb 27 13:52:04 2024 kern.warn kernel: [10738.618091] ath11k c000000.wifi: failed to alloc and register mesh vap -22
Tue Feb 27 13:52:04 2024 kern.debug kernel: [10738.623697] nss_wifi_meshmgr_find_and_ref_inc[167]:ffffffc000be0500: Invalid mesh handle: -1
Tue Feb 27 13:52:04 2024 kern.debug kernel: [10738.623715] nss_wifi_meshmgr_if_destroy_sync[1728]:ffffffc000be0500: Mesh context is null
Tue Feb 27 13:52:04 2024 kern.warn kernel: [10738.623723] ath11k c000000.wifi: failed to free nss mesh object vdev nss_err:7
Tue Feb 27 13:52:04 2024 kern.warn kernel: [10738.630541] ath11k c000000.wifi: failed to create nss vdev -22

The only version currently working is version 11.4. It is not
confirmed if this feature was removed in firmware > 11.4, or if the
issue if with the NSS driver package, or client package wifimgr. Looking
at the code changes between NHSS.QSDK.11.4 and 12.0.5 little was changed in
nss-drv/nss-clients related to the way mesh interfaces are brought up
(dynamic interfaces), much of the changes are related to stats.

To work around the issue, allow user selectable option to choose a
specific NSS firmware. The dependency is currently not enforced when
selecting NSS mesh offloading in ath11k. Users will need to switch
manually or disable the option altogether.
2024-02-27 13:36:16 -05:00
Qosmio
beb4b7f970 qca-nss-clients: Remove nss-ifb dependency 2024-02-27 01:10:01 -05:00
Qosmio
7080d89470 qca-nss-clients: add required wifili symbol 2024-02-19 03:01:56 -05:00
Qosmio
53162cdf9c qca-nss-clients: fix incorrectly defined exports include directory 2024-02-19 03:00:40 -05:00
Qosmio
3dfeff28b6 Revert "qca-nss-clients: fix incorrectly defined exports include directory"
This reverts commit 83b5ea1e6a.
2024-02-19 02:59:48 -05:00
Qosmio
83b5ea1e6a qca-nss-clients: fix incorrectly defined exports include directory 2024-02-19 02:58:17 -05:00
Qosmio
60c4bb0852 Revert "qca-nss-clients: fix incorrectly defined exports include directory"
This reverts commit 0c4e2ee764.
2024-02-19 02:55:22 -05:00
Qosmio
dc2090eb0b Revert "qca-nss-clients: add required legacy wifi symbol"
This reverts commit 5c43764e5d.
2024-02-19 02:54:43 -05:00
Qosmio
5c43764e5d qca-nss-clients: add required legacy wifi symbol 2024-02-19 02:40:24 -05:00
Qosmio
0c4e2ee764 qca-nss-clients: fix incorrectly defined exports include directory 2024-02-19 02:39:45 -05:00
Qosmio
9a35375fef nss-crypto: Require symbol NSS_DRV_CRYPTO_ENABLE 2024-02-19 02:24:12 -05:00
Qosmio
8d54d726c2 Move non-upstream NSS packages back into repo
To keep fork as closely synced with upstream, move NSS packages back
into repository. Not sure why they were moved out from my original fork.
* nss-firmware
* qca-nss-crypto
* qca-nss-cfi

Removed the following:
* mhz (already available in packages repo)
* qrtr (unecessary, and has been broken for years)

Also moved packages out of `qca` and back into root directory.
2024-02-19 01:35:04 -05:00
Qosmio
441990caf1 qca-nss-drv: add required nss firmare dependency 2024-02-18 02:03:08 -05:00
Qosmio
14d6d1431c qca-nss-clients: add nss-ifb as dependency
It's required to get proper qdisc traffic shaping
2024-02-18 01:58:38 -05:00
Qosmio
07bfcd93d6 nss: fix warnings and dependencies
* nssinfo:
  - Fix warnings related string formatting
* qca-nss-ecm:
  - Remove unnecessary dependency on `CONFIG_NSS_DRV_WIFIOFFLOAD_ENABLE`
* qca-nss-clients(netlink):
  - Fix regression in enabling wifil. It was rename to 'CONFIG_NSS_DRV_WIFIOFFLOAD_ENABLE'
    in qca-nss-drv vs 'CONFIG_NSS_DRV_WIFI_ENABLE'
  - Modularize Makefile to only build nludp_st on platform ipq95xx/ipq50xx
* qca-nss-clients(qdisc/igs):
  - fix build igs
* qca-nss-drv:
  - Remove options to configure `CONFIG_NSS_DRV_DMA_ENABLE` and `CONFIG_NSS_DRV_EDMA_ENABLE`.
    These are always built and required on ipq807x, ipq60xx
2024-02-17 17:04:37 -05:00
Qosmio
1c4870f402 qca-nss-drv: fix build regression
restore required Makefile option NSS_DRV_IPV6_ENABLE

fixes the following:

../qca-nss-drv-2024-01-04-89cc01b5/nss_rps.c:289:24: error: 'nss_rps_ipv4_hash_bitmap_cfg' defined but not used [-Werror=unused-function]
  289 | static nss_tx_status_t nss_rps_ipv4_hash_bitmap_cfg(struct nss_ctx_instance *nss_ctx, int hash_bitmap)
      |                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
2024-02-16 19:53:46 -05:00
Qosmio
a6f3128889 qca-nss-drv: add option to configure NSS memory profile
Similar to how memory profile is assignable for ath11k, introduce a
config option to set NSS memory profile. Default was always set to
512MB in upstream for ipq807x even though the platform is available in
256MB/512MB/1GB.

This option primarily limits the default number of offloaded
connections, and for low memory profile, empty buffer pool size

Default number of connections for each IPv4 and IPv6
* NSS_MEM_PROFILE_HIGH    4096
* NSS_MEM_PROFILE_MEDIUM  2048
* NSS_MEM_PROFILE_LOW     512

MAX Connection shared between IPv4 and IPv6
* NSS_MEM_PROFILE_HIGH    8192
* NSS_MEM_PROFILE_MEDIUM  4096
* NSS_MEM_PROFILE_LOW     1024
2024-02-16 18:26:28 -05:00
Qosmio
5d30819182 qca-ssdk-shell: Resolve segmentation fault errors
Revert to using version `3.0.0` as version `3.1.0` results in a segmentation
fault whenever trying to run any command.
2024-02-11 16:43:40 -05:00
Qosmio
123f0c1272 qca-nss-drv: Avoid recreating debugfs entry virt_if
Everytime a virtual interface is created/destroyed, nss driver
tries to create a debugfs entry, without checking if it exists.
Prevent creation if it already exists. This will also prevent the
annoying kernel warning.

'virt_if' in directory 'stats' already present!
2024-02-11 16:39:28 -05:00
Qosmio
1ce879e50f qca-nss-drv: assign empty_buf sos/queue to core 4 2024-02-11 16:24:01 -05:00
Qosmio
001d347392 qca-nss-drv: Fix wifi offload regression
The option for wifi offload is `NSS_DRV_WIFIOFFLOAD_ENABLE` but the
package Makefile was showing it as `NSS_DRV_WIFI_ENABLE` but then enabling the
flag as `NSS_DRV_WIFI_ENABLE`. Incorrectly assumed `NSS_DRV_WIFI_ENABLE`
was the global option. Reverted the change and updated the option to use
`NSS_DRV_WIFIOFFLOAD_ENABLE`.
2024-01-29 17:14:22 -05:00
Qosmio
7bdfc69b3d qca-nss-clients: Show titles for all packages
menuconfig doesn't show the title of packages if they are over a certain
length. Rewrite the titles to better describe what the package is as
well as show them in menuconfig without having to view the `HELP`
section.
2024-01-29 17:12:19 -05:00
Qosmio
32bdeb5192 qca-nss-clients: fix dependancies and capwapmgr
The following modules should all compile on ipq807x

kmod-qca-nss-drv-bridge-mgr
kmod-qca-nss-drv-capwapmgr
kmod-qca-nss-drv-clmapmgr
kmod-qca-nss-drv-dtlsmgr
kmod-qca-nss-drv-eogremgr
kmod-qca-nss-drv-gre
kmod-qca-nss-drv-igs
kmod-qca-nss-drv-ipsecmgr
kmod-qca-nss-drv-l2tpv2
kmod-qca-nss-drv-lag-mgr
kmod-qca-nss-drv-map-t
kmod-qca-nss-drv-match
kmod-qca-nss-drv-mirror
kmod-qca-nss-drv-netlink
kmod-qca-nss-drv-pppoe
kmod-qca-nss-drv-pptp
kmod-qca-nss-drv-pvxlanmgr
kmod-qca-nss-drv-qdisc
kmod-qca-nss-drv-tlsmgr
kmod-qca-nss-drv-tun6rd
kmod-qca-nss-drv-tunipip6
kmod-qca-nss-drv-vlan-mgr
kmod-qca-nss-drv-vxlanmgr
kmod-qca-nss-drv-wifi-meshmgr
2024-01-29 13:10:17 -05:00
Qosmio
3b822d5964 qca-nss-ecm: fix dependancy ppp_l2tp.ko 2024-01-29 13:07:08 -05:00
Qosmio
ebb069d7c6 libnl-nss: Revert removing dependancy on kmod-qca-nss-drv-netlink 2024-01-29 09:50:30 -05:00
Qosmio
468029840a qca-nss-drv/clients/userspace: Fix build of nssinfo/netlink 2024-01-28 11:41:25 -05:00
Qosmio
4454f4fd86 qca-nss-drv: Remove legacy wifi code
Mostly for ipq806x platform, reduces overall size by 30%
2024-01-28 00:19:18 -05:00
Qosmio
567b878120 qca-nss-drv: Mute verbose boot messages
Mostly noise, can be enabled with debug mode turned on
2024-01-28 00:18:03 -05:00
Qosmio
4de4f0b6bb qca-nss-drv: Remove legacy gmac stat
Used for ipq806x platform, remove it from showing up in debugfs
2024-01-27 18:47:10 -05:00
Qosmio
e862d14986 qca-nss-drv: Backport changes from 12.2
2024-01-02 - 89cc01b - Introduce new msg for pn error"

2024-01-02 - 8f31ae5 - Fix greredir stats partial copy issue
                       If the kernel passes smaller user buffer to copy stats
                       than required, copy the partial content from local buffer
                       and in the next call, copy the remaining content.

2023-12-27 - bd89094 - qca-nss-drv: Introduce new msg for pn error
2024-01-27 18:27:37 -05:00
Qosmio
ffdc908e7b qca-nss-drv: add affinity function to set last match
Since NSS IRQs use the same name for each core, the current function
assigns all matching names to the same CPU core. Add function
'set_affinity_last' to specify that only the 'last' matching irq ID be set
to the specified CPU core.
2024-01-27 18:18:36 -05:00
Qosmio
757783ae22 qca-nss-drv: fix up affinity script
Each NSS irq has two interrupts, distribute them evenly.
2024-01-26 19:20:29 -05:00
Qosmio
9e669af42a qca-ssdk-shell: Bump version to 12.4.5.r3 2024-01-26 16:46:28 -05:00
Qosmio
8af2a3e75b qca-nss-drv: Use smp_affinity logic from base-files
Using the framework that's provided in base-files 'smp_affinity' init
script for better readability.
2024-01-26 16:43:03 -05:00
Qosmio
71c2bda76b qca-nss-clients: Rework dependancies and align with upstream
Refactored to better align with QSDK's upstream Makefile, and to track
dependancies with qca-nss-drv.
2024-01-26 16:41:01 -05:00
Qosmio
a95d14a92c qca-nss-clients: wifi-meshmgr fix unintiallized warnings 2024-01-26 16:39:59 -05:00
Qosmio
0a50fb78b3 qca-nss-drv: Include options to ignore QVPN,LSO_RX,MAPT,CAPWAP,UDP_ST
NSS drivers were being built unconditionally for QVPN, LSO_RX, MAPT,
CAPWAP, and UDP_ST when it was not required. Include options to disable
them manually, as well as expose them to be built should any client
in 'qca-nss-clients' require them.
2024-01-26 16:33:08 -05:00
Qosmio
8b57fec8d7 qca-nss-ecm: Reduce required dependancies
No longer required to build with the following kernel modules:
  * ppp
  * pptp
  * pppoe
  * bonding
  * vxlan

Instead, the dependancies will only be required if one of the
nss-clients requireing it is needed. This reduces the number of modules
needed at build time thus, a smaller overall build.

Note: If any of the above are built as optional modules "<m>" then
qca-nss-ecm is switched from built-in "<y>" to "<m>".
2024-01-26 16:26:14 -05:00
Qosmio
76469f3cba qca-mcs: Bump version NHSS 12.4.5.r3 2024-01-20 05:38:36 -05:00
Qosmio
30b3db203d qca-nss-ecm: rearrange defs since SCS isnt required 2024-01-13 20:40:35 -05:00
Qosmio
404761a6b5 qca-nss-clients: improve debugging meshgr
it's really difficult to see where meshmgr is failing when the same generic
message is used by some 28 functions. include the function being called
as mart of the message.
2024-01-13 20:38:01 -05:00
Qosmio
688ce344a9 qca-nss-drv: Revert changing path sizes 2024-01-13 20:37:15 -05:00
Qosmio
d9b3558640 qca-nss: Build parallel 2024-01-11 05:40:28 -05:00
Qosmio
a1aea433bb qca-nss: Fix dependency selection 2024-01-11 05:39:36 -05:00
Qosmio
fbf5654611 qca-nss-clients: fix ipsecmgr + bugfixes
Disabled the following broken packages.
  * qca-nss-drv-mscs
  * qca-nss-drv-ovpn-link
  * qca-nss-drv-ovpn-mgr
  * qca-nss-ipsec-klips (PLUGIN)

Moved everyting to 'SUBMENU:=Network Devices'
2024-01-11 05:34:51 -05:00
Qosmio
a161057d03 qca-nss-macsec: add new MACSEC driver
will require DTS update.
--- a/arch/arm64/boot/dts/qcom/ipq8074-nss.dtsi	2024-01-08 16:04:51.957322224 -0500
+++ b/arch/arm64/boot/dts/qcom/ipq8074-nss.dtsi	2024-01-08 16:09:29.079630738 -0500
@@ -268,4 +268,10 @@
 			};
 		};
 	};
+	nss-macsec1 {
+		compatible = "qcom,nss-macsec";
+		phy_addr = <0x1c>;
+		phy_access_mode = <0x00>;
+		mdiobus = <&mdio>;
+	};
 };
2024-01-08 17:47:00 -05:00
Qosmio
5656e7a050 qca-nss-clients: fix old debug warnings 2024-01-08 17:46:05 -05:00
Qosmio
2c9ffba363 qca-nss-ecm: properly setup firewall, init, defaults for 6.1 2024-01-08 17:44:47 -05:00
Qosmio
a74fe1cfa1 qca-nss-drv: Properly display dyn virt interfaces
cat /sys/kernel/debug/qca-nss-drv/stats/dynamic_if/type_names
2024-01-08 17:43:16 -05:00
Qosmio
09fde351bb nss-udp-st: Add experimental UDP speedtest 2024-01-07 18:07:58 -05:00