lkml.org 
[lkml]   [2019]   [Feb]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] xen-netback: fix occasional leak of grant ref mappings under memory pressure
From
Date
On 28/02/2019 11:21, Paul Durrant wrote:
>>> @@ -1153,6 +1152,10 @@ static int xenvif_tx_submit(struct xenvif_queue *queue)
>>> kfree_skb(skb);
>>> continue;
>>> }
>>> +
>>> + /* Copied all the bits from the frag list. */
>>> + skb_frag_list_init(skb);
>>> + kfree(nskb);
>>
>> I think you want kfree_skb here?
>
> No. nskb is the frag list... it is unlinked from skb by the call to skb_frag_list_init() and then it can be freed on its own. The skb is what we need to retain, because that now contains all the data.
>

Are you saying previous code in xenvif_handle_frag_list() incorrectly
called kfree_skb()?

Igor

\
 
 \ /
  Last update: 2019-02-28 12:43    [W:0.040 / U:6.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site