Commit Graph

37 Commits

Author SHA1 Message Date
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
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
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
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
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
688ce344a9 qca-nss-drv: Revert changing path sizes 2024-01-13 20:37:15 -05:00
Qosmio
a1aea433bb qca-nss: Fix dependency selection 2024-01-11 05:39:36 -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
60e4d29068 qca-nss-drv: align path_flags sizes 2024-01-07 18:06:17 -05:00
Qosmio
eb19331d72 qca-nss-drv: load firmware without fallback to sysfs warning 2024-01-07 18:01:20 -05:00
Qosmio
93743e3123 qca-nss-drv: optimize smp_affinity for nss cores 2024-01-07 18:00:37 -05:00
dimfish
f91a55312f qca-nss-drv: update to 12.4 2023-11-09 16:15:17 +03:00
bitthief
5156673ca9 nss: rename ipq807x target to qualcommax
Now that qualcommax exists as a target and dependencies have been updated,
move ipq807x support to subtarget of qualcommax.

Signed-off-by: bitthief <bitthief@protonmail.ch>
2023-07-27 07:06:45 +03:00
bitthief
baa4a04f1f qca-nss-drv: add support for kernel 6.1
Signed-off-by: bitthief <bitthief@protonmail.ch>
2023-07-27 07:06:45 +03:00
bitthief
08daa5dfaa qca-nss-drv: update to 12.4.r1
Signed-off-by: bitthief <bitthief@protonmail.ch>
2023-07-27 07:06:45 +03:00
bitthief
7798c20353 qca-nss-drv: fix compilation with GCC 13 2023-05-08 19:17:18 +03:00
bitthief
bffc154981 qca-nss-drv: update to 12.3.r2 2023-02-24 02:46:44 +02:00
Ansuel Smith
d442d1328e
qca-nss-drv: disable additional module not used
Add patch to permit more modularization and disable
additional module not used. PPPOE is disabled by default.
Will be enabled later if PPPOE offload will be reintroduced.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2022-05-17 21:40:05 +02:00
Ansuel Smith
9324002719 qca-nss-drv: fix use of custom skb_skip_tc_classify
Use standard skb_skip_tc_classify instead of using custom api
and bit.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2022-05-15 21:44:46 +02:00
Ansuel Smith
8d6d7b6fe1 qca-nss-drv: fix use of dmac_{inv/clean}_range with standard api
Drop use of dmac_{inv/clean}_range and use generic dma sync api.
This should permit us to compile nss-drv without adding additional
patch to the upstream kernel.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2022-05-15 21:44:46 +02:00
Ansuel Smith
f04e4036c0 nss-drv: update to QSDK 12.0
Update nss-drv to QSDK 12.0

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2022-05-15 21:44:46 +02:00
Ansuel Smith
ea5a395dc2 nss-drv: add support for kernel 5.15
Add support for kernel 5.15 for nss-drv

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2022-05-15 21:44:46 +02:00
Robert Marko
1f3addc3a2 treewide: update GIT source URL-s
Codeaurora is now in archive-only mode as everything has been moved to the
Gitlab based git.codelinaro.org

So, update all of the source URL-s as well as update to the latest 11.4
commit if there is a newer one.

Refresh patches as well if any have offsets or fuzzes.

Signed-off-by: Robert Marko <robimarko@gmail.com>
2022-04-04 13:11:12 +02:00
Robert Marko
7833eff264 nss-drv: enable crypto
This enables the crypto code required by nss-crypto.

Also, disable erroring out on unused variables.

Signed-off-by: Robert Marko <robimarko@gmail.com>
2022-03-13 15:47:47 +01:00
Ansuel Smith
dff684e695 nss-drv: remove mismatched NSS FW support
There is no need for the mismatched 11.3 FW support on 11.4
SPF drivers, so drop the support.

This reverts commit f806309bbe.

Signed-off-by: Robert Marko <robimarko@gmail.com>
2021-09-16 18:25:20 +02:00
Robert Marko
4667f4acb4 nss-drv: fix NSS FW coredump
DMA functions used for NSS FW coredump are called
with NULL being passed instead of device pointer.
This will obviously cause a NULL pointer exception
and crash the kernel.

So, fix it by passing proper device structure pointer.

Signed-off-by: Robert Marko <robimarko@gmail.com>
2021-06-09 12:09:49 +02:00
Ansuel Smith
f806309bbe
Add Initial support for mismatched NSS firmware version
Permit to use mismatched NSS firmware version with higher QSDK version.
As we currently have 11.3 public NSS firmware, set this version by default.
This can be expanded later to support previous NSS version or to use newer
QSDK version if they are still compatible with basic NSS firmware loading
and handling.
Tested feature and working for now are basic ipv4 and ipv6 handling, virt_if
and wifili (wifi offload).

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2021-05-30 19:03:03 +02:00
Robert Marko
4ae9a73646 Add 11.4 NSS-DRV
Add NSS-DRV from QSDK11.4.

NSS-DRV is the core NSS driver providing NSS firmware
loading and communication between NSS cores and
other NSS offloading drivers.

It includes patches to it in order to work under kernel 5.10.
Made for and tested on IPQ807x.

Signed-off-by: Robert Marko <robimarko@gmail.com>
2021-05-30 18:19:16 +02:00