No description
  • C 98.2%
  • Assembly 1%
  • Makefile 0.3%
  • Shell 0.2%
  • Python 0.1%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Robert Hancock ba0d7beec2 net: macb: Fix lost RX packet wakeup race in NAPI receive
commit 0bf476fc3624e3a72af4ba7340d430a91c18cd67 upstream.

There is an oddity in the way the RSR register flags propagate to the
ISR register (and the actual interrupt output) on this hardware: it
appears that RSR register bits only result in ISR being asserted if the
interrupt was actually enabled at the time, so enabling interrupts with
RSR bits already set doesn't trigger an interrupt to be raised. There
was already a partial fix for this race in the macb_poll function where
it checked for RSR bits being set and re-triggered NAPI receive.
However, there was a still a race window between checking RSR and
actually enabling interrupts, where a lost wakeup could happen. It's
necessary to check again after enabling interrupts to see if RSR was set
just prior to the interrupt being enabled, and re-trigger receive in that
case.

This issue was noticed in a point-to-point UDP request-response protocol
which periodically saw timeouts or abnormally high response times due to
received packets not being processed in a timely fashion. In many
applications, more packets arriving, including TCP retransmissions, would
cause the original packet to be processed, thus masking the issue.

Fixes: 02f7a34f34 ("net: macb: Re-enable RX interrupt only when RX is done")
Cc: stable@vger.kernel.org
Co-developed-by: Scott McNutt <scott.mcnutt@siriusxm.com>
Signed-off-by: Scott McNutt <scott.mcnutt@siriusxm.com>
Signed-off-by: Robert Hancock <robert.hancock@calian.com>
Tested-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-03-16 13:21:47 +01:00
arch ARM: Spectre-BHB: provide empty stub for non-config 2022-03-16 13:21:47 +01:00
block block: Fix fsync always failed if once failed 2022-03-08 19:07:47 +01:00
certs
crypto
Documentation x86/speculation: Update link to AMD speculation whitepaper 2022-03-11 11:22:37 +01:00
drivers net: macb: Fix lost RX packet wakeup race in NAPI receive 2022-03-16 13:21:47 +01:00
fs fuse: fix pipe buffer lifetime for direct_io 2022-03-16 13:21:47 +01:00
include net/mlx5: Fix size field in bufferx_reg struct 2022-03-16 13:21:46 +01:00
init bpf: Add kconfig knob for disabling unpriv bpf by default 2022-02-16 12:52:49 +01:00
ipc
kernel tracing: Ensure trace buffer is at least 4096 bytes large 2022-03-16 13:21:47 +01:00
lib lib/iov_iter: initialize "flags" in new pipe_buffer 2022-02-23 11:59:59 +01:00
LICENSES
mm memfd: fix F_SEAL_WRITE after shmem huge page allocated 2022-03-08 19:07:49 +01:00
net ipv6: prevent a possible race condition with lifetimes 2022-03-16 13:21:47 +01:00
samples
scripts kconfig: fix failing to generate auto.conf 2022-02-23 12:00:01 +01:00
security ima: Do not print policy rule with inactive LSM labels 2022-02-16 12:52:47 +01:00
sound ASoC: cs4265: Fix the duplicated control name 2022-03-08 19:07:49 +01:00
tools selftests/memfd: clean up mapping in mfd_fail_write 2022-03-16 13:21:47 +01:00
usr
virt
.clang-format
.cocciconfig
.get_maintainer.ignore
.gitattributes
.gitignore
.mailmap
COPYING
CREDITS
Kbuild
Kconfig
MAINTAINERS
Makefile Linux 5.4.184 2022-03-11 11:22:39 +01:00
README

Linux kernel
============

There are several guides for kernel developers and users. These guides can
be rendered in a number of formats, like HTML and PDF. Please read
Documentation/admin-guide/README.rst first.

In order to build the documentation, use ``make htmldocs`` or
``make pdfdocs``.  The formatted documentation can also be read online at:

    https://www.kernel.org/doc/html/latest/

There are various text files in the Documentation/ subdirectory,
several of them using the Restructured Text markup notation.

Please read the Documentation/process/changes.rst file, as it contains the
requirements for building and running the kernel, and information about
the problems which may result by upgrading your kernel.