From: Sasha Levin <sashal@kernel.org>
To: linux-kernel@vger.kernel.org, stable@vger.kernel.org
Cc: David Howells <dhowells@redhat.com>,
Sasha Levin <sashal@kernel.org>,
marc.dionne@auristor.com, davem@davemloft.net,
edumazet@google.com, kuba@kernel.org, pabeni@redhat.com,
linux-afs@lists.infradead.org, netdev@vger.kernel.org
Subject: [PATCH AUTOSEL 5.4 03/12] rxrpc: Fix local destruction being repeated
Date: Wed, 14 Sep 2022 05:03:56 -0400 [thread overview]
Message-ID: <20220914090407.471328-3-sashal@kernel.org> (raw)
In-Reply-To: <20220914090407.471328-1-sashal@kernel.org>
From: David Howells <dhowells@redhat.com>
[ Upstream commit d3d863036d688313f8d566b87acd7d99daf82749 ]
If the local processor work item for the rxrpc local endpoint gets requeued
by an event (such as an incoming packet) between it getting scheduled for
destruction and the UDP socket being closed, the rxrpc_local_destroyer()
function can get run twice. The second time it can hang because it can end
up waiting for cleanup events that will never happen.
Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
net/rxrpc/local_object.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/net/rxrpc/local_object.c b/net/rxrpc/local_object.c
index 01135e54d95d2..fc784fcc3a947 100644
--- a/net/rxrpc/local_object.c
+++ b/net/rxrpc/local_object.c
@@ -448,6 +448,9 @@ static void rxrpc_local_processor(struct work_struct *work)
container_of(work, struct rxrpc_local, processor);
bool again;
+ if (local->dead)
+ return;
+
trace_rxrpc_local(local->debug_id, rxrpc_local_processing,
atomic_read(&local->usage), NULL);
--
2.35.1
next prev parent reply other threads:[~2022-09-14 9:09 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-14 9:03 [PATCH AUTOSEL 5.4 01/12] ASoC: nau8824: Fix semaphore unbalance at error paths Sasha Levin
2022-09-14 9:03 ` Sasha Levin
2022-09-14 9:03 ` [PATCH AUTOSEL 5.4 02/12] regulator: pfuze100: Fix the global-out-of-bounds access in pfuze100_regulator_probe() Sasha Levin
2022-09-14 9:03 ` Sasha Levin [this message]
2022-09-14 9:03 ` [PATCH AUTOSEL 5.4 04/12] rxrpc: Fix calc of resend age Sasha Levin
2022-09-14 9:03 ` [PATCH AUTOSEL 5.4 05/12] ALSA: hda/sigmatel: Keep power up while beep is enabled Sasha Levin
2022-09-14 9:03 ` Sasha Levin
2022-09-14 9:03 ` [PATCH AUTOSEL 5.4 06/12] ALSA: hda/tegra: Align BDL entry to 4KB boundary Sasha Levin
2022-09-14 9:03 ` Sasha Levin
2022-09-14 9:04 ` [PATCH AUTOSEL 5.4 07/12] ALSA: usb-audio: Fix an out-of-bounds bug in __snd_usb_parse_audio_interface() Sasha Levin
2022-09-14 9:04 ` Sasha Levin
2022-09-14 9:04 ` [PATCH AUTOSEL 5.4 08/12] net: usb: qmi_wwan: add Quectel RM520N Sasha Levin
2022-09-14 9:04 ` [PATCH AUTOSEL 5.4 09/12] afs: Return -EAGAIN, not -EREMOTEIO, when a file already locked Sasha Levin
2022-09-14 9:04 ` [PATCH AUTOSEL 5.4 10/12] scsi: mpt3sas: Fix use-after-free warning Sasha Levin
2022-09-14 9:04 ` [PATCH AUTOSEL 5.4 11/12] MIPS: OCTEON: irq: Fix octeon_irq_force_ciu_mapping() Sasha Levin
2022-09-14 9:04 ` [PATCH AUTOSEL 5.4 12/12] mksysmap: Fix the mismatch of 'L0' symbols in System.map Sasha Levin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220914090407.471328-3-sashal@kernel.org \
--to=sashal@kernel.org \
--cc=davem@davemloft.net \
--cc=dhowells@redhat.com \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=linux-afs@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=marc.dionne@auristor.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.