From nobody Sat Oct 9 19:52:04 2021 X-Original-To: threads@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id EE76417E187F for ; Sat, 9 Oct 2021 19:52:04 +0000 (UTC) (envelope-from bugzilla-noreply@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 4HRbLD6MTjz4Wfj for ; Sat, 9 Oct 2021 19:52:04 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (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 BB27320650 for ; Sat, 9 Oct 2021 19:52:04 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 199Jq4ol028634 for ; Sat, 9 Oct 2021 19:52:04 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 199Jq4cB028633 for threads@FreeBSD.org; Sat, 9 Oct 2021 19:52:04 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: threads@FreeBSD.org Subject: [Bug 254995] pthread_cond_timedwait() returns EDEADLK Date: Sat, 09 Oct 2021 19:52:04 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: threads X-Bugzilla-Version: 12.1-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: kib@FreeBSD.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: threads@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Threading List-Archive: https://lists.freebsd.org/archives/freebsd-threads List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-threads@freebsd.org X-BeenThere: freebsd-threads@freebsd.org MIME-Version: 1.0 X-ThisMailContainsUnwantedMimeParts: N https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D254995 --- Comment #10 from Konstantin Belousov --- (In reply to nkoch from comment #9) Perhaps try this. Still, since you are claiming that there is no stop sign= als, it should not matter. commit 98a2fa4a342983bee7f1700530fd721652ce27b5 Author: Konstantin Belousov Date: Sat Oct 9 22:46:08 2021 +0300 umtx: Do not return spurious failures on unlock after suspend for norma= l or PI mutexes diff --git a/sys/kern/kern_umtx.c b/sys/kern/kern_umtx.c index ea87259161c8..359318b3849e 100644 --- a/sys/kern/kern_umtx.c +++ b/sys/kern/kern_umtx.c @@ -1486,7 +1486,7 @@ do_unlock_normal(struct thread *td, struct umutex *m, uint32_t flags, bool rb) if (error =3D=3D -1) return (EFAULT); if (error =3D=3D 1) { - error =3D thread_check_susp(td, false); + error =3D thread_check_susp(td, true); if (error !=3D 0) return (error); goto again; @@ -1523,7 +1523,7 @@ do_unlock_normal(struct thread *td, struct umutex *m, uint32_t flags, bool rb) if (error =3D=3D 1) { if (old !=3D owner) return (EINVAL); - error =3D thread_check_susp(td, false); + error =3D thread_check_susp(td, true); if (error !=3D 0) return (error); goto again; @@ -2428,7 +2428,7 @@ do_unlock_pi(struct thread *td, struct umutex *m, uint32_t flags, bool rb) again: error =3D casueword32(&m->m_owner, owner, &old, new_owner); if (error =3D=3D 1) { - error =3D thread_check_susp(td, false); + error =3D thread_check_susp(td, true); if (error =3D=3D 0) goto again; } --=20 You are receiving this mail because: You are the assignee for the bug.=