mirror of
https://github.com/breeze303/nss-packages.git
synced 2025-12-16 16:57:29 +00:00
qca-nss-drv: update to 12.4
This commit is contained in:
parent
e6676102f1
commit
f91a55312f
@ -5,9 +5,9 @@ PKG_RELEASE:=$(AUTORELEASE)
|
||||
|
||||
PKG_SOURCE_URL:=https://git.codelinaro.org/clo/qsdk/oss/lklm/nss-drv.git
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_DATE:=2023-03-23
|
||||
PKG_SOURCE_VERSION:=5b395eb18d38754f4336cbf5e352c5a903d3ff38
|
||||
PKG_MIRROR_HASH:=86dff8ca03559ad6a428fdcdda86d271a6760bc0cc6d9431b314a448a5901263
|
||||
PKG_SOURCE_DATE:=2023-08-06
|
||||
PKG_SOURCE_VERSION:=1ab184034529539f61093184a67d4454cb3eb352
|
||||
PKG_MIRROR_HASH:=6aa081c0853d3e3b6d78eee588a0967e540b2317d15aef3c3f6f7129925653f7
|
||||
|
||||
PKG_BUILD_PARALLEL:=1
|
||||
PKG_FLAGS:=nonshared
|
||||
|
||||
@ -32,7 +32,7 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
goto out;
|
||||
--- a/nss_hal/ipq50xx/nss_hal_pvt.c
|
||||
+++ b/nss_hal/ipq50xx/nss_hal_pvt.c
|
||||
@@ -184,13 +184,13 @@ static struct nss_platform_data *__nss_h
|
||||
@@ -185,13 +185,13 @@ static struct nss_platform_data *__nss_h
|
||||
npd->nphys = res_nphys.start;
|
||||
npd->qgic_phys = res_qgic_phys.start;
|
||||
|
||||
@ -48,7 +48,7 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
if (!npd->qgic_map) {
|
||||
nss_info_always("%px: nss%d: ioremap() fail for qgic map\n", nss_ctx, nss_ctx->id);
|
||||
goto out;
|
||||
@@ -348,7 +348,7 @@ static int __nss_hal_common_reset(struct
|
||||
@@ -349,7 +349,7 @@ static int __nss_hal_common_reset(struct
|
||||
|
||||
of_node_put(cmn);
|
||||
|
||||
@ -59,7 +59,7 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
return -EFAULT;
|
||||
--- a/nss_hal/ipq60xx/nss_hal_pvt.c
|
||||
+++ b/nss_hal/ipq60xx/nss_hal_pvt.c
|
||||
@@ -207,13 +207,13 @@ static struct nss_platform_data *__nss_h
|
||||
@@ -208,13 +208,13 @@ static struct nss_platform_data *__nss_h
|
||||
npd->nphys = res_nphys.start;
|
||||
npd->qgic_phys = res_qgic_phys.start;
|
||||
|
||||
@ -75,7 +75,7 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
if (!npd->qgic_map) {
|
||||
nss_info_always("%px: nss%d: ioremap() fail for qgic map\n", nss_ctx, nss_ctx->id);
|
||||
goto out;
|
||||
@@ -433,13 +433,13 @@ static int __nss_hal_common_reset(struct
|
||||
@@ -434,13 +434,13 @@ static int __nss_hal_common_reset(struct
|
||||
|
||||
of_node_put(cmn);
|
||||
|
||||
@ -93,7 +93,7 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
return -EFAULT;
|
||||
--- a/nss_hal/ipq806x/nss_hal_pvt.c
|
||||
+++ b/nss_hal/ipq806x/nss_hal_pvt.c
|
||||
@@ -458,7 +458,7 @@ static struct nss_platform_data *__nss_h
|
||||
@@ -461,7 +461,7 @@ static struct nss_platform_data *__nss_h
|
||||
npd->nphys = res_nphys.start;
|
||||
npd->vphys = res_vphys.start;
|
||||
|
||||
@ -102,7 +102,7 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
if (!npd->nmap) {
|
||||
nss_info_always("%px: nss%d: ioremap() fail for nphys\n", nss_ctx, nss_ctx->id);
|
||||
goto out;
|
||||
@@ -711,7 +711,7 @@ static int __nss_hal_common_reset(struct
|
||||
@@ -714,7 +714,7 @@ static int __nss_hal_common_reset(struct
|
||||
}
|
||||
of_node_put(cmn);
|
||||
|
||||
@ -113,7 +113,7 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
return -EFAULT;
|
||||
--- a/nss_hal/ipq807x/nss_hal_pvt.c
|
||||
+++ b/nss_hal/ipq807x/nss_hal_pvt.c
|
||||
@@ -234,7 +234,7 @@ static struct nss_platform_data *__nss_h
|
||||
@@ -237,7 +237,7 @@ static struct nss_platform_data *__nss_h
|
||||
npd->vphys = res_vphys.start;
|
||||
npd->qgic_phys = res_qgic_phys.start;
|
||||
|
||||
@ -122,7 +122,7 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
if (!npd->nmap) {
|
||||
nss_info_always("%px: nss%d: ioremap() fail for nphys\n", nss_ctx, nss_ctx->id);
|
||||
goto out;
|
||||
@@ -247,7 +247,7 @@ static struct nss_platform_data *__nss_h
|
||||
@@ -250,7 +250,7 @@ static struct nss_platform_data *__nss_h
|
||||
goto out;
|
||||
}
|
||||
|
||||
@ -131,7 +131,7 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
if (!npd->qgic_map) {
|
||||
nss_info_always("%px: nss%d: ioremap() fail for qgic map\n", nss_ctx, nss_ctx->id);
|
||||
goto out;
|
||||
@@ -467,7 +467,7 @@ static int __nss_hal_common_reset(struct
|
||||
@@ -470,7 +470,7 @@ static int __nss_hal_common_reset(struct
|
||||
}
|
||||
of_node_put(cmn);
|
||||
|
||||
@ -185,7 +185,7 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
}
|
||||
--- a/nss_meminfo.c
|
||||
+++ b/nss_meminfo.c
|
||||
@@ -735,7 +735,7 @@ bool nss_meminfo_init(struct nss_ctx_ins
|
||||
@@ -736,7 +736,7 @@ bool nss_meminfo_init(struct nss_ctx_ins
|
||||
/*
|
||||
* meminfo_start is the label where the start address of meminfo map is stored.
|
||||
*/
|
||||
|
||||
@ -27,7 +27,7 @@ Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
|
||||
#error "Check skb recycle code in this file to match Linux version"
|
||||
#endif
|
||||
|
||||
@@ -2658,7 +2659,7 @@ static inline bool nss_core_skb_can_reus
|
||||
@@ -2658,7 +2660,7 @@ static inline bool nss_core_skb_can_reus
|
||||
if (unlikely(irqs_disabled()))
|
||||
return false;
|
||||
|
||||
|
||||
@ -17,7 +17,7 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
|
||||
--- a/nss_core.c
|
||||
+++ b/nss_core.c
|
||||
@@ -1659,7 +1659,7 @@ static int32_t nss_core_handle_cause_que
|
||||
@@ -1660,7 +1660,7 @@ static int32_t nss_core_handle_cause_que
|
||||
*
|
||||
*/
|
||||
if (unlikely((buffer_type == N2H_BUFFER_CRYPTO_RESP))) {
|
||||
@ -25,3 +25,4 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
+ dma_unmap_single(nss_ctx->dev, (desc->buffer + desc->payload_offs), desc->payload_len, DMA_FROM_DEVICE);
|
||||
goto consume;
|
||||
}
|
||||
|
||||
|
||||
@ -27,7 +27,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
|
||||
--- a/nss_core.c
|
||||
+++ b/nss_core.c
|
||||
@@ -1471,6 +1471,8 @@ static inline void nss_core_handle_empty
|
||||
@@ -1472,6 +1472,8 @@ static inline void nss_core_handle_empty
|
||||
uint32_t count, uint32_t hlos_index,
|
||||
uint16_t mask)
|
||||
{
|
||||
@ -36,7 +36,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
while (count) {
|
||||
/*
|
||||
* Since we only return the primary skb, we have no way to unmap
|
||||
@@ -1524,7 +1526,9 @@ next:
|
||||
@@ -1525,7 +1527,9 @@ next:
|
||||
n2h_desc_ring->hlos_index = hlos_index;
|
||||
if_map->n2h_hlos_index[NSS_IF_N2H_EMPTY_BUFFER_RETURN_QUEUE] = hlos_index;
|
||||
|
||||
@ -47,7 +47,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
NSS_CORE_DSB();
|
||||
}
|
||||
|
||||
@@ -1546,6 +1550,7 @@ static int32_t nss_core_handle_cause_que
|
||||
@@ -1547,6 +1551,7 @@ static int32_t nss_core_handle_cause_que
|
||||
struct nss_ctx_instance *nss_ctx = int_ctx->nss_ctx;
|
||||
struct nss_meminfo_ctx *mem_ctx = &nss_ctx->meminfo_ctx;
|
||||
struct nss_if_mem_map *if_map = mem_ctx->if_map;
|
||||
@ -55,7 +55,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
|
||||
qid = nss_core_cause_to_queue(cause);
|
||||
|
||||
@@ -1557,7 +1562,8 @@ static int32_t nss_core_handle_cause_que
|
||||
@@ -1558,7 +1563,8 @@ static int32_t nss_core_handle_cause_que
|
||||
n2h_desc_ring = &nss_ctx->n2h_desc_ring[qid];
|
||||
desc_if = &n2h_desc_ring->desc_ring;
|
||||
desc_ring = desc_if->desc;
|
||||
@ -65,7 +65,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
NSS_CORE_DSB();
|
||||
nss_index = if_map->n2h_nss_index[qid];
|
||||
|
||||
@@ -1586,13 +1592,23 @@ static int32_t nss_core_handle_cause_que
|
||||
@@ -1587,13 +1593,23 @@ static int32_t nss_core_handle_cause_que
|
||||
start = hlos_index;
|
||||
end = (hlos_index + count) & mask;
|
||||
if (end > start) {
|
||||
@ -92,7 +92,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -1721,7 +1737,8 @@ next:
|
||||
@@ -1722,7 +1738,8 @@ next:
|
||||
n2h_desc_ring->hlos_index = hlos_index;
|
||||
if_map->n2h_hlos_index[qid] = hlos_index;
|
||||
|
||||
@ -102,7 +102,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
NSS_CORE_DSB();
|
||||
|
||||
return count;
|
||||
@@ -1733,11 +1750,12 @@ next:
|
||||
@@ -1734,11 +1751,12 @@ next:
|
||||
*/
|
||||
static void nss_core_init_nss(struct nss_ctx_instance *nss_ctx, struct nss_if_mem_map *if_map)
|
||||
{
|
||||
@ -116,7 +116,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
NSS_CORE_DSB();
|
||||
|
||||
/*
|
||||
@@ -1834,6 +1852,7 @@ static void nss_core_alloc_paged_buffers
|
||||
@@ -1835,6 +1853,7 @@ static void nss_core_alloc_paged_buffers
|
||||
uint16_t count, int16_t mask, int32_t hlos_index, uint32_t alloc_fail_count,
|
||||
uint32_t buffer_type, uint32_t buffer_queue, uint32_t stats_index)
|
||||
{
|
||||
@ -124,7 +124,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
struct sk_buff *nbuf;
|
||||
struct page *npage;
|
||||
struct hlos_h2n_desc_rings *h2n_desc_ring = &nss_ctx->h2n_desc_rings[buffer_queue];
|
||||
@@ -1903,7 +1922,9 @@ static void nss_core_alloc_paged_buffers
|
||||
@@ -1904,7 +1923,9 @@ static void nss_core_alloc_paged_buffers
|
||||
/*
|
||||
* Flush the descriptor
|
||||
*/
|
||||
@ -135,7 +135,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
|
||||
hlos_index = (hlos_index + 1) & (mask);
|
||||
count--;
|
||||
@@ -1917,7 +1938,8 @@ static void nss_core_alloc_paged_buffers
|
||||
@@ -1918,7 +1939,8 @@ static void nss_core_alloc_paged_buffers
|
||||
h2n_desc_ring->hlos_index = hlos_index;
|
||||
if_map->h2n_hlos_index[buffer_queue] = hlos_index;
|
||||
|
||||
@ -145,7 +145,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
NSS_CORE_DSB();
|
||||
|
||||
NSS_PKT_STATS_INC(&nss_top->stats_drv[stats_index]);
|
||||
@@ -1930,7 +1952,7 @@ static void nss_core_alloc_paged_buffers
|
||||
@@ -1931,7 +1953,7 @@ static void nss_core_alloc_paged_buffers
|
||||
static void nss_core_alloc_jumbo_mru_buffers(struct nss_ctx_instance *nss_ctx, struct nss_if_mem_map *if_map,
|
||||
int jumbo_mru, uint16_t count, int16_t mask, int32_t hlos_index)
|
||||
{
|
||||
@ -154,7 +154,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
struct sk_buff *nbuf;
|
||||
struct hlos_h2n_desc_rings *h2n_desc_ring = &nss_ctx->h2n_desc_rings[NSS_IF_H2N_EMPTY_BUFFER_QUEUE];
|
||||
struct h2n_desc_if_instance *desc_if = &h2n_desc_ring->desc_ring;
|
||||
@@ -1977,7 +1999,9 @@ static void nss_core_alloc_jumbo_mru_buf
|
||||
@@ -1978,7 +2000,9 @@ static void nss_core_alloc_jumbo_mru_buf
|
||||
/*
|
||||
* Flush the descriptor
|
||||
*/
|
||||
@ -165,7 +165,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
|
||||
hlos_index = (hlos_index + 1) & (mask);
|
||||
count--;
|
||||
@@ -1991,7 +2015,8 @@ static void nss_core_alloc_jumbo_mru_buf
|
||||
@@ -1992,7 +2016,8 @@ static void nss_core_alloc_jumbo_mru_buf
|
||||
h2n_desc_ring->hlos_index = hlos_index;
|
||||
if_map->h2n_hlos_index[NSS_IF_H2N_EMPTY_BUFFER_QUEUE] = hlos_index;
|
||||
|
||||
@ -175,7 +175,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
NSS_CORE_DSB();
|
||||
|
||||
NSS_PKT_STATS_INC(&nss_top->stats_drv[NSS_DRV_STATS_TX_EMPTY]);
|
||||
@@ -2004,6 +2029,7 @@ static void nss_core_alloc_jumbo_mru_buf
|
||||
@@ -2005,6 +2030,7 @@ static void nss_core_alloc_jumbo_mru_buf
|
||||
static void nss_core_alloc_max_avail_size_buffers(struct nss_ctx_instance *nss_ctx, struct nss_if_mem_map *if_map,
|
||||
uint16_t max_buf_size, uint16_t count, int16_t mask, int32_t hlos_index)
|
||||
{
|
||||
@ -183,7 +183,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
struct hlos_h2n_desc_rings *h2n_desc_ring = &nss_ctx->h2n_desc_rings[NSS_IF_H2N_EMPTY_BUFFER_QUEUE];
|
||||
struct h2n_desc_if_instance *desc_if = &h2n_desc_ring->desc_ring;
|
||||
struct h2n_descriptor *desc_ring = desc_if->desc;
|
||||
@@ -2011,6 +2037,7 @@ static void nss_core_alloc_max_avail_siz
|
||||
@@ -2012,6 +2038,7 @@ static void nss_core_alloc_max_avail_siz
|
||||
uint16_t payload_len = max_buf_size + NET_SKB_PAD;
|
||||
uint16_t start = hlos_index;
|
||||
uint16_t prev_hlos_index;
|
||||
@ -191,7 +191,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
|
||||
while (count) {
|
||||
dma_addr_t buffer;
|
||||
@@ -2063,13 +2090,26 @@ static void nss_core_alloc_max_avail_siz
|
||||
@@ -2064,13 +2091,26 @@ static void nss_core_alloc_max_avail_siz
|
||||
* Flush the descriptors, including the descriptor at prev_hlos_index.
|
||||
*/
|
||||
if (prev_hlos_index > start) {
|
||||
@ -221,7 +221,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -2080,7 +2120,8 @@ static void nss_core_alloc_max_avail_siz
|
||||
@@ -2081,7 +2121,8 @@ static void nss_core_alloc_max_avail_siz
|
||||
h2n_desc_ring->hlos_index = hlos_index;
|
||||
if_map->h2n_hlos_index[NSS_IF_H2N_EMPTY_BUFFER_QUEUE] = hlos_index;
|
||||
|
||||
@ -231,7 +231,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
NSS_CORE_DSB();
|
||||
|
||||
NSS_PKT_STATS_INC(&nss_top->stats_drv[NSS_DRV_STATS_TX_EMPTY]);
|
||||
@@ -2093,6 +2134,7 @@ static void nss_core_alloc_max_avail_siz
|
||||
@@ -2094,6 +2135,7 @@ static void nss_core_alloc_max_avail_siz
|
||||
static inline void nss_core_handle_empty_buffer_sos(struct nss_ctx_instance *nss_ctx,
|
||||
struct nss_if_mem_map *if_map, uint16_t max_buf_size)
|
||||
{
|
||||
@ -239,7 +239,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
uint16_t count, size, mask;
|
||||
int32_t nss_index, hlos_index;
|
||||
struct hlos_h2n_desc_rings *h2n_desc_ring = &nss_ctx->h2n_desc_rings[NSS_IF_H2N_EMPTY_BUFFER_QUEUE];
|
||||
@@ -2103,7 +2145,8 @@ static inline void nss_core_handle_empty
|
||||
@@ -2104,7 +2146,8 @@ static inline void nss_core_handle_empty
|
||||
/*
|
||||
* Check how many empty buffers could be filled in queue
|
||||
*/
|
||||
@ -249,7 +249,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
NSS_CORE_DSB();
|
||||
nss_index = if_map->h2n_nss_index[NSS_IF_H2N_EMPTY_BUFFER_QUEUE];
|
||||
|
||||
@@ -2148,6 +2191,7 @@ static inline void nss_core_handle_empty
|
||||
@@ -2149,6 +2192,7 @@ static inline void nss_core_handle_empty
|
||||
static inline void nss_core_handle_paged_empty_buffer_sos(struct nss_ctx_instance *nss_ctx,
|
||||
struct nss_if_mem_map *if_map, uint16_t max_buf_size)
|
||||
{
|
||||
@ -257,7 +257,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
uint16_t count, size, mask;
|
||||
int32_t nss_index, hlos_index;
|
||||
struct hlos_h2n_desc_rings *h2n_desc_ring = &nss_ctx->h2n_desc_rings[NSS_IF_H2N_EMPTY_PAGED_BUFFER_QUEUE];
|
||||
@@ -2155,7 +2199,8 @@ static inline void nss_core_handle_paged
|
||||
@@ -2156,7 +2200,8 @@ static inline void nss_core_handle_paged
|
||||
/*
|
||||
* Check how many empty buffers could be filled in queue
|
||||
*/
|
||||
@ -267,7 +267,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
NSS_CORE_DSB();
|
||||
nss_index = if_map->h2n_nss_index[NSS_IF_H2N_EMPTY_PAGED_BUFFER_QUEUE];
|
||||
|
||||
@@ -2732,9 +2777,11 @@ void nss_skb_reuse(struct sk_buff *nbuf)
|
||||
@@ -2733,9 +2778,11 @@ void nss_skb_reuse(struct sk_buff *nbuf)
|
||||
* Sends one skb to NSS FW
|
||||
*/
|
||||
static inline int32_t nss_core_send_buffer_simple_skb(struct nss_ctx_instance *nss_ctx,
|
||||
@ -281,7 +281,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
struct h2n_descriptor *desc_ring = desc_if->desc;
|
||||
struct h2n_descriptor *desc;
|
||||
uint16_t bit_flags;
|
||||
@@ -2788,7 +2835,8 @@ static inline int32_t nss_core_send_buff
|
||||
@@ -2789,7 +2836,8 @@ static inline int32_t nss_core_send_buff
|
||||
(nss_ptr_t)nbuf, (uint16_t)(nbuf->data - nbuf->head), nbuf->len,
|
||||
sz, (uint32_t)nbuf->priority, mss, bit_flags);
|
||||
|
||||
@ -291,7 +291,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
|
||||
/*
|
||||
* We are done using the skb fields and can reuse it now
|
||||
@@ -2812,7 +2860,8 @@ no_reuse:
|
||||
@@ -2813,7 +2861,8 @@ no_reuse:
|
||||
(nss_ptr_t)nbuf, (uint16_t)(nbuf->data - nbuf->head), nbuf->len,
|
||||
(uint16_t)skb_end_offset(nbuf), (uint32_t)nbuf->priority, mss, bit_flags);
|
||||
|
||||
@ -301,7 +301,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
|
||||
NSS_PKT_STATS_INC(&nss_ctx->nss_top->stats_drv[NSS_DRV_STATS_TX_SIMPLE]);
|
||||
return 1;
|
||||
@@ -2826,9 +2875,11 @@ no_reuse:
|
||||
@@ -2827,9 +2876,11 @@ no_reuse:
|
||||
* Used to differentiate from FRAGLIST
|
||||
*/
|
||||
static inline int32_t nss_core_send_buffer_nr_frags(struct nss_ctx_instance *nss_ctx,
|
||||
@ -315,7 +315,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
struct h2n_descriptor *desc_ring = desc_if->desc;
|
||||
struct h2n_descriptor *desc;
|
||||
const skb_frag_t *frag;
|
||||
@@ -2868,7 +2919,8 @@ static inline int32_t nss_core_send_buff
|
||||
@@ -2869,7 +2920,8 @@ static inline int32_t nss_core_send_buff
|
||||
(nss_ptr_t)NULL, nbuf->data - nbuf->head, nbuf->len - nbuf->data_len,
|
||||
skb_end_offset(nbuf), (uint32_t)nbuf->priority, mss, bit_flags | H2N_BIT_FLAG_FIRST_SEGMENT);
|
||||
|
||||
@ -325,7 +325,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
|
||||
/*
|
||||
* Now handle rest of the fragments.
|
||||
@@ -2892,7 +2944,8 @@ static inline int32_t nss_core_send_buff
|
||||
@@ -2893,7 +2945,8 @@ static inline int32_t nss_core_send_buff
|
||||
(nss_ptr_t)NULL, 0, skb_frag_size(frag), skb_frag_size(frag),
|
||||
nbuf->priority, mss, bit_flags);
|
||||
|
||||
@ -335,7 +335,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -2908,7 +2961,8 @@ static inline int32_t nss_core_send_buff
|
||||
@@ -2909,7 +2962,8 @@ static inline int32_t nss_core_send_buff
|
||||
desc->bit_flags &= ~(H2N_BIT_FLAG_DISCARD);
|
||||
desc->opaque = (nss_ptr_t)nbuf;
|
||||
|
||||
@ -345,7 +345,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
|
||||
NSS_PKT_STATS_INC(&nss_ctx->nss_top->stats_drv[NSS_DRV_STATS_TX_NR_FRAGS]);
|
||||
return i+1;
|
||||
@@ -2922,9 +2976,11 @@ static inline int32_t nss_core_send_buff
|
||||
@@ -2923,9 +2977,11 @@ static inline int32_t nss_core_send_buff
|
||||
* Used to differentiate from FRAGS
|
||||
*/
|
||||
static inline int32_t nss_core_send_buffer_fraglist(struct nss_ctx_instance *nss_ctx,
|
||||
@ -359,7 +359,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
struct h2n_descriptor *desc_ring = desc_if->desc;
|
||||
struct h2n_descriptor *desc;
|
||||
dma_addr_t buffer;
|
||||
@@ -2963,7 +3019,8 @@ static inline int32_t nss_core_send_buff
|
||||
@@ -2964,7 +3020,8 @@ static inline int32_t nss_core_send_buff
|
||||
(nss_ptr_t)nbuf, nbuf->data - nbuf->head, nbuf->len - nbuf->data_len,
|
||||
skb_end_offset(nbuf), (uint32_t)nbuf->priority, mss, bit_flags | H2N_BIT_FLAG_FIRST_SEGMENT);
|
||||
|
||||
@ -369,7 +369,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
|
||||
/*
|
||||
* Walk the frag_list in nbuf
|
||||
@@ -3016,7 +3073,8 @@ static inline int32_t nss_core_send_buff
|
||||
@@ -3017,7 +3074,8 @@ static inline int32_t nss_core_send_buff
|
||||
(nss_ptr_t)iter, iter->data - iter->head, iter->len - iter->data_len,
|
||||
skb_end_offset(iter), iter->priority, mss, bit_flags);
|
||||
|
||||
@ -379,7 +379,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
|
||||
i++;
|
||||
}
|
||||
@@ -3035,7 +3093,8 @@ static inline int32_t nss_core_send_buff
|
||||
@@ -3036,7 +3094,8 @@ static inline int32_t nss_core_send_buff
|
||||
* Update bit flag for last descriptor.
|
||||
*/
|
||||
desc->bit_flags |= H2N_BIT_FLAG_LAST_SEGMENT;
|
||||
@ -389,7 +389,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
|
||||
NSS_PKT_STATS_INC(&nss_ctx->nss_top->stats_drv[NSS_DRV_STATS_TX_FRAGLIST]);
|
||||
return i+1;
|
||||
@@ -3114,8 +3173,10 @@ int32_t nss_core_send_buffer(struct nss_
|
||||
@@ -3115,8 +3174,10 @@ int32_t nss_core_send_buffer(struct nss_
|
||||
* We need to work out if there's sufficent space in our transmit descriptor
|
||||
* ring to place all the segments of a nbuf.
|
||||
*/
|
||||
@ -401,7 +401,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
nss_index = if_map->h2n_nss_index[qid];
|
||||
h2n_desc_ring->nss_index_local = nss_index;
|
||||
count = ((nss_index - hlos_index - 1) + size) & (mask);
|
||||
@@ -3180,13 +3241,13 @@ int32_t nss_core_send_buffer(struct nss_
|
||||
@@ -3181,13 +3242,13 @@ int32_t nss_core_send_buffer(struct nss_
|
||||
count = 0;
|
||||
if (likely((segments == 0) || is_bounce)) {
|
||||
count = nss_core_send_buffer_simple_skb(nss_ctx, desc_if, if_num,
|
||||
@ -418,7 +418,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
}
|
||||
|
||||
if (unlikely(count <= 0)) {
|
||||
@@ -3210,7 +3271,8 @@ int32_t nss_core_send_buffer(struct nss_
|
||||
@@ -3211,7 +3272,8 @@ int32_t nss_core_send_buffer(struct nss_
|
||||
h2n_desc_ring->hlos_index = hlos_index;
|
||||
if_map->h2n_hlos_index[qid] = hlos_index;
|
||||
|
||||
@ -484,7 +484,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
|
||||
--- a/nss_hal/ipq806x/nss_hal_pvt.c
|
||||
+++ b/nss_hal/ipq806x/nss_hal_pvt.c
|
||||
@@ -474,10 +474,9 @@ static struct nss_platform_data *__nss_h
|
||||
@@ -477,10 +477,9 @@ static struct nss_platform_data *__nss_h
|
||||
/*
|
||||
* Clear TCM memory used by this core
|
||||
*/
|
||||
@ -499,7 +499,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
/*
|
||||
--- a/nss_hal/ipq807x/nss_hal_pvt.c
|
||||
+++ b/nss_hal/ipq807x/nss_hal_pvt.c
|
||||
@@ -256,10 +256,9 @@ static struct nss_platform_data *__nss_h
|
||||
@@ -259,10 +259,9 @@ static struct nss_platform_data *__nss_h
|
||||
/*
|
||||
* Clear TCM memory used by this core
|
||||
*/
|
||||
@ -514,7 +514,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
/*
|
||||
--- a/nss_meminfo.c
|
||||
+++ b/nss_meminfo.c
|
||||
@@ -414,7 +414,6 @@ static bool nss_meminfo_init_block_lists
|
||||
@@ -415,7 +415,6 @@ static bool nss_meminfo_init_block_lists
|
||||
/*
|
||||
* Flush the updated meminfo request.
|
||||
*/
|
||||
@ -522,7 +522,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
NSS_CORE_DSB();
|
||||
|
||||
/*
|
||||
@@ -545,7 +544,7 @@ static bool nss_meminfo_configure_n2h_h2
|
||||
@@ -546,7 +545,7 @@ static bool nss_meminfo_configure_n2h_h2
|
||||
* Bring a fresh copy of if_map from memory in order to read it correctly.
|
||||
*/
|
||||
if_map = mem_ctx->if_map;
|
||||
@ -531,7 +531,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
NSS_CORE_DSB();
|
||||
|
||||
if_map->n2h_rings = NSS_N2H_RING_COUNT;
|
||||
@@ -583,7 +582,7 @@ static bool nss_meminfo_configure_n2h_h2
|
||||
@@ -584,7 +583,7 @@ static bool nss_meminfo_configure_n2h_h2
|
||||
/*
|
||||
* Flush the updated nss_if_mem_map.
|
||||
*/
|
||||
@ -542,7 +542,7 @@ Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
||||
return true;
|
||||
--- a/nss_profiler.c
|
||||
+++ b/nss_profiler.c
|
||||
@@ -202,11 +202,12 @@ EXPORT_SYMBOL(nss_profile_dma_deregister
|
||||
@@ -209,11 +209,12 @@ EXPORT_SYMBOL(nss_profile_dma_deregister
|
||||
struct nss_profile_sdma_ctrl *nss_profile_dma_get_ctrl(struct nss_ctx_instance *nss_ctx)
|
||||
{
|
||||
struct nss_profile_sdma_ctrl *ctrl = nss_ctx->meminfo_ctx.sdma_ctrl;
|
||||
|
||||
@ -30,7 +30,7 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
#include <nss_hal.h>
|
||||
#include <net/dst.h>
|
||||
#ifdef CONFIG_BRIDGE_NETFILTER
|
||||
@@ -491,50 +493,38 @@ static void nss_core_handle_crypto_pkt(s
|
||||
@@ -492,50 +494,38 @@ static void nss_core_handle_crypto_pkt(s
|
||||
*/
|
||||
static uint32_t nss_soc_mem_info(void)
|
||||
{
|
||||
@ -73,7 +73,7 @@ Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
- if (ppp) {
|
||||
- n_items /= sizeof(ppp[0]);
|
||||
- nss_msize = be32_to_cpup(ppp + addr_cells + size_cells - 1);
|
||||
- nss_info_always("addr/size storage words %d %d # words %d in DTS, ddr size %x\n",
|
||||
- nss_info("addr/size storage words %d %d # words %d in DTS, ddr size %x\n",
|
||||
- addr_cells, size_cells, n_items, nss_msize);
|
||||
+ struct device_node *common_node, *memory_node;
|
||||
+ struct resource r;
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
--- a/nss_hal/ipq807x/nss_hal_pvt.c
|
||||
+++ b/nss_hal/ipq807x/nss_hal_pvt.c
|
||||
@@ -656,62 +656,62 @@ static int __nss_hal_request_irq(struct
|
||||
@@ -659,62 +659,62 @@ static int __nss_hal_request_irq(struct
|
||||
irq_set_status_flags(irq, IRQ_DISABLE_UNLAZY);
|
||||
|
||||
if (irq_num == NSS_HAL_N2H_INTR_PURPOSE_EMPTY_BUFFER_SOS) {
|
||||
@ -72,3 +72,4 @@
|
||||
+ netif_napi_add_weight(&nss_ctx->napi_ndev, &int_ctx->napi, nss_core_handle_napi_sdma, NSS_DATA_COMMAND_BUFFER_PROCESSING_WEIGHT);
|
||||
err = request_irq(irq, nss_hal_handle_irq, 0, "nss_profile_dma", int_ctx);
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user