• Alessandro Rubini's avatar
    kernel/wr-nic: fix a memory leakage under heavy load · ce7eb8a2
    Alessandro Rubini authored
    When the switch is loaded, some PTP outgoing frames get discarded, so we
    never get back the timestamp interrupt.  By round-robin'ing the slots,
    we get back to the "busy" one, which holds an skb structure that must be
    released.
    
    Without this freeing, the skb remains in the output queue of the
    socket, and after a while we get EAGAIN in send() because the buffer
    is full (400 frames, more or less). And the ptp port is stuck until we
    reopen the socket.
    
    This diagnosis exposed the fact that it's not an overflow of pending
    descriptors, so I change the message from
    
      descriptor overflow: tx timestamp pending
    
    to
    
      discarding tx frame that got no timestamp
    
    Finally, this is pr_warn, not pr_err as we now know it's expected.
    Signed-off-by: Alessandro Rubini's avatarAlessandro Rubini <rubini@gnudd.com>
    ce7eb8a2
Name
Last commit
Last update
binaries Loading commit data...
build Loading commit data...
configs Loading commit data...
doc Loading commit data...
hwinfo-sdb Loading commit data...
kernel Loading commit data...
patches Loading commit data...
robustness/coding Loading commit data...
scripts Loading commit data...
usb-loader Loading commit data...
userspace Loading commit data...
.gitignore Loading commit data...
.gitmodules Loading commit data...
COPYING Loading commit data...
Kconfig Loading commit data...
Makefile Loading commit data...
Makefile.kconfig Loading commit data...
README Loading commit data...