[qca-nss-sfe] initialise l2_info fields
Change-Id: I965a5a89be0cb50e308e4d873adcf627ec1f0787
Signed-off-by: Nitin Shetty <quic_nitinsj@quicinc.com>
diff --git a/sfe_ipv4.c b/sfe_ipv4.c
index 2b440eb..ce6f1f9 100644
--- a/sfe_ipv4.c
+++ b/sfe_ipv4.c
@@ -2474,8 +2474,7 @@
*/
static unsigned int sfe_ipv4_local_out(void *priv, struct sk_buff *skb, const struct nf_hook_state *nhs)
{
- struct sfe_l2_info l2_info;
- l2_info.parse_flags = 0;
+ struct sfe_l2_info l2_info = {0};
DEBUG_TRACE("%px: sfe: sfe_ipv4_local_out hook called.\n", skb);
diff --git a/sfe_ipv6.c b/sfe_ipv6.c
index 5d1cbf8..a4ba6b1 100644
--- a/sfe_ipv6.c
+++ b/sfe_ipv6.c
@@ -2429,10 +2429,12 @@
struct sk_buff *skb,
const struct nf_hook_state *nhs)
{
+ struct sfe_l2_info l2_info = {0};
+
DEBUG_TRACE("sfe: sfe_ipv6_local_out hook called.\n");
if (likely(skb->skb_iif)) {
- return sfe_ipv6_recv(skb->dev, skb, NULL, true) ? NF_STOLEN : NF_ACCEPT;
+ return sfe_ipv6_recv(skb->dev, skb, &l2_info, true) ? NF_STOLEN : NF_ACCEPT;
}
return NF_ACCEPT;