mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-13 08:07:32 -04:00
qcacmn: Always assert if TSO frag paddr is invalid
Always assert immediately in case of dma mapping error for TSO frags or whenever paddr is set to 0. This will assert closer to the point of failure in the future and point to the immediate operation causing this behavior. Change-Id: I8e3d58c1b4f18a8b7721b96686ea0ea4ff9c270b CRs-Fixed: 2777588
This commit is contained in:
parent
ca0cf99f1d
commit
91f3420b3d
1 changed files with 4 additions and 2 deletions
|
|
@ -3253,7 +3253,7 @@ uint32_t __qdf_nbuf_get_tso_info(qdf_device_t osdev, struct sk_buff *skb,
|
|||
if (unlikely(dma_mapping_error(osdev->dev,
|
||||
tso_frag_paddr))) {
|
||||
qdf_err("DMA mapping error!");
|
||||
qdf_assert(0);
|
||||
qdf_assert_always(0);
|
||||
return 0;
|
||||
}
|
||||
TSO_DEBUG("%s[%d] skb frag len %d tso frag len %d\n", __func__,
|
||||
|
|
@ -3302,6 +3302,8 @@ uint32_t __qdf_nbuf_get_tso_info(qdf_device_t osdev, struct sk_buff *skb,
|
|||
tso_cmn_info.tcp_seq_num += tso_frag_len;
|
||||
curr_seg->seg.tso_frags[i].paddr =
|
||||
tso_frag_paddr;
|
||||
|
||||
qdf_assert_always(curr_seg->seg.tso_frags[i].paddr);
|
||||
}
|
||||
|
||||
TSO_DEBUG("%s[%d] frag %d frag len %d total_len %u vaddr %pK\n",
|
||||
|
|
@ -3386,7 +3388,7 @@ uint32_t __qdf_nbuf_get_tso_info(qdf_device_t osdev, struct sk_buff *skb,
|
|||
if (unlikely(dma_mapping_error(osdev->dev,
|
||||
tso_frag_paddr))) {
|
||||
qdf_err("DMA mapping error!");
|
||||
qdf_assert(0);
|
||||
qdf_assert_always(0);
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue