Commit Graph

15 Commits

Author SHA1 Message Date
Qosmio
bcc49b9aa7 nss-userspace: add new package and enable cfi 2022-09-16 08:20:27 -04:00
Qosmio
69febdb1da QSDK 12.1 backport + fixes
* qca-nss-drv: backport 12.1 (add more firmware checks)
    * qca-nss-ecm: backport 12.1
    * qca-nss-gmac: consolidate patches
2022-09-16 08:19:33 -04:00
Qosmio
476aeca1d4 revert again... 2022-09-12 10:55:16 -04:00
Qosmio
21b3164bf7 qca-nss-drv: refresh patch 2022-09-12 08:23:13 -04:00
Qosmio
85c1252f07 revert nss-core1 removal 2022-09-11 08:31:45 -04:00
Qosmio
58379681f6 Revert "Revert patch. Crashing on boot."
This reverts commit 0a333b208d.
2022-09-11 08:31:09 -04:00
Qosmio
693848253f fix compilation between 5.10-5.15 2022-09-11 04:02:31 -04:00
Qosmio
39e953886e nss-gmac: add timestamping feature and extra logging
requires an entry in dts:

example:

qcom,tstamp-enabled;

use ethtool to enable:
root@R7800 ~
➤ ethtool --set-priv-flags eth1 tstamp on
[Sat Sep 10 01:24:22 2022] ipq8064-mdio 37000000.mdio eth0: nss_gmac_ts_enable: Timestamp enabled
[Sat Sep 10 01:24:22 2022] ipq8064-mdio 37000000.mdio eth0: nss_gmac_set_priv_flags: Enabled 'Timestamp' flag (needed_headroom: 32)

root@R7800 ~
➤ cat /sys/devices/platform/soc/37000000.mdio/net/eth*/tstamp
sec:1084 nsec:752452290 time-of-day:   1662789199.391664
sec:1087 nsec:309864290 time-of-day:   1662789199.391799
2022-09-10 01:53:36 -04:00
Qosmio
66253b98ba nss-gmac: bugfix ethtool
When running 'ethtool' to set/get 'priv-flags' the output shows as

ethtool --show-priv-flags eth0
Before
Private flags for eth0:
���: off
���: off
���: off

After:
Private flags for eth0:
linkpoll          : off
tstamp            : off
ignore_rx_csum_err: off
2022-09-09 07:52:00 -04:00
Qosmio
0a333b208d Revert patch. Crashing on boot.
[    6.641556] **********************************************************
[    6.717592] nss_driver - fw of size 544712  bytes copied to load addr: 40000000, nss_id : 0
[    6.718132] nss_driver - Turbo Support 1
[    6.724747] Supported Frequencies -
[    6.724752] 800Mhz
[    6.729002] 800Mhz
[    6.732469] 800Mhz
[    6.734292]
[    6.738739] bf2187c0: meminfo init succeed
[    6.750187] nss_driver - fw of size 218860  bytes copied to load addr: 40800000, nss_id : 1
[    6.750431] bf21d100: meminfo init succeed
[    6.757404] debugfs: Directory 'dynamic_if' with parent 'stats' already present!
[    6.761581] debugfs: File 'n2h' in directory 'strings' already present!
[    6.769160] debugfs: File 'drv' in directory 'strings' already present!
[    6.769616] node size 1 # items 2
[    6.775412] debugfs: File 'c2c_tx' in directory 'strings' already present!
[    6.775420] debugfs: File 'c2c_rx' in directory 'strings' already present!
[    6.778169] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    6.782022] memory: 0 0 (avl 609472512) items 2 active_cores 2
[    6.789819] SCSI subsystem initialized
[    6.792378] addr/size storage words 1 1 # words 2 in DTS, ddr size 1000000
[    6.811447] bf2187c0: nss core 0 booted successfully
[    6.817251] ahci 29000000.sata: supply ahci not found, using dummy regulator
[    6.822609] node size 1 # items 2
[    6.827240] ahci 29000000.sata: supply phy not found, using dummy regulator
[    6.834238] memory: 0 0 (avl 609472512) items 2 active_cores 2
[    6.837537] ahci 29000000.sata: supply target not found, using dummy regulator
[    6.844200] addr/size storage words 1 1 # words 2 in DTS, ddr size 1000000
[    6.850505] ahci 29000000.sata: forcing port_map 0x0 -> 0x1
[    6.857274] bf21d100: nss core 1 booted successfully
[    6.864189] ahci 29000000.sata: AHCI 0001.0300 32 slots 1 ports 6 Gbps 0x1 impl platform mode
[    6.864200] ahci 29000000.sata: flags: ncq sntf pm led clo only pmp pio slum part ccc apst
[    6.870067] NSS core 1 signal COREDUMP COMPLETE 4000
[    6.877628] scsi host0: ahci
[    6.883292] bf21d100: Starting NSS-FW logbuffer dump for core 1
[    6.891643] ata1: SATA max UDMA/133 mmio [mem 0x29000000-0x2900017f] port 0x100 irq 32
[    6.899598] NSS core 0 signal COREDUMP COMPLETE 4000
[    6.913151] bf2187c0: Starting NSS-FW logbuffer dump for core 0
[    6.918196] Kernel panic - not syncing: NSS FW coredump: bringing system down
[    6.923842] CPU1: stopping
[    6.931124] CPU: 1 PID: 0 Comm: swapper/1 Not tainted 5.15.67 #0
[    6.933731] Hardware name: Generic DT based system
[    6.939900] [<c031198c>] (unwind_backtrace) from [<c030c4e4>] (show_stack+0x1c/0x28)
[    6.944500] [<c030c4e4>] (show_stack) from [<c0658fdc>] (dump_stack_lvl+0x40/0x4c)
[    6.952400] [<c0658fdc>] (dump_stack_lvl) from [<c030fd44>] (do_handle_IPI+0x2a8/0x324)
[    6.959776] [<c030fd44>] (do_handle_IPI) from [<c030fde0>] (ipi_handler+0x20/0x34)
[    6.967675] [<c030fde0>] (ipi_handler) from [<c03803e8>] (handle_percpu_devid_irq+0x98/0x220)
[    6.975316] [<c03803e8>] (handle_percpu_devid_irq) from [<c03796f0>] (handle_domain_irq+0x6c/0xa0)
[    6.983910] [<c03796f0>] (handle_domain_irq) from [<c06731c8>] (gic_handle_irq+0x88/0xbc)
[    6.992763] [<c06731c8>] (gic_handle_irq) from [<c0300b7c>] (__irq_svc+0x5c/0x78)
[    7.001008] Exception stack(0xc2515f18 to 0xc2515f60)
[    7.008472] 5f00:                                                       00000000 00000001
[    7.013511] 5f20: 1bbca000 dda13500 00000000 c3939040 9cb163c0 00000000 dda12770 00000001
[    7.021671] 5f40: 00000000 9c57d940 000576c0 c2515f68 c081c2c8 c081c2e8 60000013 ffffffff
[    7.029830] [<c0300b7c>] (__irq_svc) from [<c081c2e8>] (cpuidle_enter_state+0x1ac/0x42c)
[    7.037990] [<c081c2e8>] (cpuidle_enter_state) from [<c081c5c8>] (cpuidle_enter+0x44/0x64)
[    7.046147] [<c081c5c8>] (cpuidle_enter) from [<c035a620>] (do_idle+0x204/0x294)
[    7.054222] [<c035a620>] (do_idle) from [<c035a9d8>] (cpu_startup_entry+0x24/0x28)
[    7.061772] [<c035a9d8>] (cpu_startup_entry) from [<42301610>] (0x42301610)
[    7.272882] Rebooting in 1 seconds..
2022-09-09 06:35:01 -04:00
Qosmio
6446dd0d5b Update README 2022-09-09 05:59:11 -04:00
Qosmio
fbab415223 Modularize driver build 2022-09-09 05:21:03 -04:00
Ansuel Smith
8afb0d4951 nss-drv: rework NSS_CORE_DMA_CACHE_MAINT ops
Rework NSS_CORE_DMA_CACHE_MAINT ops to use standard dma sync ops instead
of using the direct arch function. This permit to skip any hack/patch
needed for nss-drv to correctly compile on upstream kernel.

We drop any NSS_CORE_DMA_CACHE_MAINT use in nss_core and we correctly
use the dma_sync_single_for_device we correctly dma addr using the new
DMA helper.
We drop sync for IOREMAP addr and we just leave a memory block.
We hope the nss_profiler is correctly ported.
We finally drop the NSS_CORE_DMA_CACHE_MAINT jus in case someone wants
to use it.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2022-09-09 04:38:34 -04:00
Qosmio
61c338cbc3 QSDK 11.2 + 11.4-12 backports
* kernel: 5.4 to 5.15
  * nss-clients: NHSS.QSDK.11.2
  * nss-drv: NHSS.QSDK.11.2
    * firmware: NHSS.QSDK.11.0 (NSS.AK.K.CS1-1-R)
  * nss-ecm: NHSS.QSDK.11.4
  * nss-crypto: NHSS.QSDK.11.4
  * nss-cfi: NHSS.QSDK.11.2
  * nss-gmac: NHSS.QSDK.12.0
  * qca-mcs: NHSS.QSDK.12.0
2022-09-09 01:21:15 -04:00
qosmio
7fb7de5434
Initial commit 2022-09-08 20:02:29 -04:00