From owner-dev-commits-src-all@freebsd.org Wed Aug 11 02:34:26 2021 Return-Path: Delivered-To: dev-commits-src-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id CD1C8673722; Wed, 11 Aug 2021 02:34:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Gkv6B5N3Nz3j4X; Wed, 11 Aug 2021 02:34:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id A07A227301; Wed, 11 Aug 2021 02:34:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 17B2YQ4N033195; Wed, 11 Aug 2021 02:34:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 17B2YQBm033194; Wed, 11 Aug 2021 02:34:26 GMT (envelope-from git) Date: Wed, 11 Aug 2021 02:34:26 GMT Message-Id: <202108110234.17B2YQBm033194@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kevin Bowling Subject: git: ae51594c9794 - stable/12 - udp: Fix soroverflow SOCKBUF unlocking MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kbowling X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: ae51594c9794275073c955ad4c6fa7ad9fcc1614 Auto-Submitted: auto-generated X-BeenThere: dev-commits-src-all@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commit messages for all branches of the src repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 11 Aug 2021 02:34:26 -0000 The branch stable/12 has been updated by kbowling (ports committer): URL: https://cgit.FreeBSD.org/src/commit/?id=ae51594c9794275073c955ad4c6fa7ad9fcc1614 commit ae51594c9794275073c955ad4c6fa7ad9fcc1614 Author: Konstantin Kukushkin AuthorDate: 2021-08-01 14:41:38 +0000 Commit: Kevin Bowling CommitDate: 2021-08-11 02:00:09 +0000 udp: Fix soroverflow SOCKBUF unlocking We hold the SOCKBUF_LOCK so use soroverflow_locked here. This bug may manifest as a non-killable process stuck in [*so_rcv]. Approved by: scottl Reviewed by: Roy Marples Fixes: 7045b1603bdf MFC after: 10 days Differential Revision: https://reviews.freebsd.org/D31374 (cherry picked from commit a61c24ddb7d677337d6184ffcee34a6e902d72d7) --- sys/netinet/udp_usrreq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netinet/udp_usrreq.c b/sys/netinet/udp_usrreq.c index 2a5e8fdd25c2..f57a9059a7db 100644 --- a/sys/netinet/udp_usrreq.c +++ b/sys/netinet/udp_usrreq.c @@ -376,7 +376,7 @@ udp_append(struct inpcb *inp, struct ip *ip, struct mbuf *n, int off, so = inp->inp_socket; SOCKBUF_LOCK(&so->so_rcv); if (sbappendaddr_locked(&so->so_rcv, append_sa, n, opts) == 0) { - soroverflow(so); + soroverflow_locked(so); m_freem(n); if (opts) m_freem(opts);