qcacmn: Return gracefully if ingress device is NULL

If the ingress net device is NULL, return gracefully
from the API to check if the skb is from rmnet

Change-Id: I81b8cea7f311fe581e83f2310155b83b28f2fd32
CRs-Fixed: 3445050
This commit is contained in:
Pavankumar Nandeshwar
2023-03-30 00:36:27 -07:00
committed by Madan Koyyalamudi
parent ca023bedc9
commit 4df32b4c7a

View File

@@ -2007,6 +2007,9 @@ is_nbuf_frm_rmnet(qdf_nbuf_t nbuf, struct dp_tx_msdu_info_s *msdu_info)
ingress_dev = dev_get_by_index(dev_net(nbuf->dev), nbuf->skb_iif);
if (!ingress_dev)
return false;
if ((ingress_dev->priv_flags & IFF_PHONY_HEADROOM)) {
dev_put(ingress_dev);
frag = &(skb_shinfo(nbuf)->frags[0]);