RE: [PATCH net v2 1/2] gianfar: Replace skb_realloc_headroom with skb_cow_head for PTP

Claudiu Manoil
2020-11-03T17:18:31Z

>-----Original Message-----
>From: Jakub Kicinski <kuba@kernel.org>
>Sent: Tuesday, November 3, 2020 6:31 PM
>To: Vladimir Oltean <olteanv@gmail.com>
>Cc: Claudiu Manoil <claudiu.manoil@nxp.com>; netdev@vger.kernel.org;
>David S . Miller <davem@davemloft.net>; james.jurack@ametek.com
>Subject: Re: [PATCH net v2 1/2] gianfar: Replace skb_realloc_headroom with
>skb_cow_head for PTP
>
>On Tue, 3 Nov 2020 18:13:19 +0200 Vladimir Oltean wrote:
>> [14538.046926] PC is at skb_release_data+0x6c/0x14c
>> [14538.051518] LR is at consume_skb+0x38/0xd8
>> [14538.055588] pc : [<c10e439c>] lr : [<c10e3fac>] psr: 200f0013
>> [14538.061817] sp : c28f1da8 ip : 00000000 fp : c265aa40
>> [14538.067010] r10: 00000000 r9 : 00000000 r8 : c2f98000
>> [14538.072204] r7 : c511d900 r6 : c3d3d900 r5 : c3d3d900 r4 : 00000000
>> [14538.078693] r3 : 000000d3 r2 : 00000001 r1 : 00000000 r0 : 00000000
>
>> [14538.263039] [<c10e439c>] (skb_release_data) from [<c10e3fac>]
>(consume_skb+0x38/0xd8)
>> [14538.270834] [<c10e3fac>] (consume_skb) from [<c0d529bc>]
>(gfar_start_xmit+0x704/0x784)
>> [14538.278714] [<c0d529bc>] (gfar_start_xmit) from [<c10fcdf8>]
>(dev_hard_start_xmit+0xfc/0x254)
>> [14538.287198] [<c10fcdf8>] (dev_hard_start_xmit) from [<c1158524>]
>(sch_direct_xmit+0x104/0x2e0)
>
>Looks like one of the error paths freeing a wonky skb.
>
>Could you decode these addresses to line numbers?

It's either the dev_kfree_skb_any from the dma mapping error path or the one
from skb_cow_head()'s error path. A confirmation would help indeed.