[qca-nss-sfe] SAWF related changes in SFE.
1. Adding sawf_metadata in SFE connection information
2. Addition of per cpu per service class stats DB as part of SFE.
Change-Id: I44e2a0d7b6144ee28a24fc5edd21fdc1cd439142
Signed-off-by: Parikshit Gune <quic_pgune@quicinc.com>
diff --git a/sfe_ipv6_udp.c b/sfe_ipv6_udp.c
index 3df6d51..08263bd 100644
--- a/sfe_ipv6_udp.c
+++ b/sfe_ipv6_udp.c
@@ -132,6 +132,7 @@
struct sfe_ipv6_addr *dest_ip;
__be16 src_port;
__be16 dest_port;
+ u32 service_class_id;
struct sfe_ipv6_connection_match *cm;
struct net_device *xmit_dev;
int ret;
@@ -529,6 +530,13 @@
*/
if (unlikely(cm->flags & SFE_IPV6_CONNECTION_MATCH_FLAG_MARK)) {
skb->mark = cm->mark;
+ /*
+ * Update service class stats if SAWF is valid.
+ */
+ if (likely(cm->sawf_valid)) {
+ service_class_id = SFE_GET_SAWF_SERVICE_CLASS(cm->mark);
+ sfe_ipv6_service_class_stats_inc(si, service_class_id, len);
+ }
}
/*