Search Linux Wireless

Re: Memory leak in ieee80211_rx_napi()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 4/9/21 2:31 PM, Johannes Berg wrote:
Hi Larry,

What setting or lack of, would cause ieee80211_rx_napi() to leak the skb that it
is given? The documentation states that once this call is made, mac80211 owns
this buffer. Does this mean that it will also be freed?

Eventually, yes. But it might go onto a NAPI GRO list, etc. Perhaps it
might even look like it's leaked if it's on such a list if you didn't
implement NAPI properly as polling, but just call ieee80211_rx_napi()
with a non-NULL napi struct pointer.

Hi Johannes,

There were two bugs in rtw88. The first, suggested by PK, was that the sequence between start/stop of NAPI and the enable/disable of interrupts were reversed. The second bug was in NAPI polling as you suggested. The poll routine was calling napi_schedule() rather than napi_reschedule().

With these two changes, my RTL8822CE handled 12 hours of flood ping with my router without leaking a single buffer.

Thanks for your help,

Larry



[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux