From nobody Sat Aug 20 17:34:54 2022 X-Original-To: dev-commits-src-main@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 4M95NZ42Fyz4Zpcw; Sat, 20 Aug 2022 17:34:54 +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 4M95NZ3Q6Pz3XRB; Sat, 20 Aug 2022 17:34:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1661016894; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AxRQsrp8lBcL9FNt3y182Kac0nwZVOmOU1zFP6OQxQE=; b=a06oV+4B3OvaA24X7zLIOTBV8E20k/veiQ2Hji13XJts9CPOoestOGS3xcEvicUIL/CENw ot0x3CU34J+OP7G64+9jiGgM4BgBjMfEu1MF2iYP/RgJyqsrVDoORhtT24GD26Rh4/adWq wFtMdFuR8HcdPq/TfBihpA5+jOgFMJTqKCm0J6vW+fHK+NsT4C6CuUr/EOprnz3uML97OI O6LSBDawQ0p3OJfmeG0gWbVc3st3up75hjS6Rq4BcYBzGAzlj7h/bzegEPqyS9DQKW0giV MBBmVe3sdKfIGSpr1ukeuFYkZmhdG9S2qctow9CISvXT6P6ZCc4YNPLr6GIOkA== 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 4M95NZ2W4rzgcM; Sat, 20 Aug 2022 17:34:54 +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 27KHYsah093344; Sat, 20 Aug 2022 17:34:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 27KHYsFE093343; Sat, 20 Aug 2022 17:34:54 GMT (envelope-from git) Date: Sat, 20 Aug 2022 17:34:54 GMT Message-Id: <202208201734.27KHYsFE093343@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Konstantin Belousov Subject: git: 30b16a6bcf01 - main - exit1(): update comment about thread_single() List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 30b16a6bcf01c17b52daef76bf2320749e84bd89 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1661016894; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=AxRQsrp8lBcL9FNt3y182Kac0nwZVOmOU1zFP6OQxQE=; b=o9wGpfHuq+XR+7BXxyMizw0Nyil2ydkvCOO45AscwT6aJLpGO9ROK61QvH2DWtfV4C9B1t bWwXY71EVo0r4ypipWAs7zu1IlLm/o5jKSxnzQXbSWl5WolcothgdA5+kyqW7wUyIneipX 0szRBOBLsgpCLn/suK7qzygnQXDmMfc2ZCX+bKTV9AIZUty4KGdTKh0QqzaYTdmRcb/4Rn 0a7p7i/XpW9wYmdxdORMMjvUHQ5UrWi5d4chCvYuEmzn6KygHXrjRJKXKf4D9iEE3shPdm t8VrxmFKnpd9fyq72+8/RtKqgVoGfENbfPb+HR6V8E5wxjAYqLbmrM1gVEyUAQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1661016894; a=rsa-sha256; cv=none; b=Wd6bf838u1prU86oPMr4tkMw/Cgf04lehFBpwWes76y5vysM3HDPFjSGVVXPkdKJZxGLY8 PY64qqz6Xy/vOpVPAwe2pUug6UH8dnVI9p3OaZzGlzwNhx7JvQ6VnGayD4lewKsei+B99s H8OPLFK7Xukg+T6fe3NcaAsRMfDC0vjccSMS4zAEQhKaaHfbU512QKe5y0wiw/itOqCWLi yTvepphKDa82bJVHgHIMl3S2lLWUozJx+HwzC7UCe6b0Irg0heOocRSkcbiEFtV/zKURj1 Kq+jlsXi6e2/0ng/Wo8bkxDbUQU1I5Lf7pq5d+xO5gizPaZcQS5QP7SBSgDWOg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=30b16a6bcf01c17b52daef76bf2320749e84bd89 commit 30b16a6bcf01c17b52daef76bf2320749e84bd89 Author: Konstantin Belousov AuthorDate: 2022-08-12 20:16:29 +0000 Commit: Konstantin Belousov CommitDate: 2022-08-20 17:33:17 +0000 exit1(): update comment about thread_single() We do not check single-threading conditions in trap, or when sleeping uninterruptible. Reviewed by: markj Sponsored by: The FreeBSD Foundation MFC after: 3 days Differential revision: https://reviews.freebsd.org/D36207 --- sys/kern/kern_exit.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/sys/kern/kern_exit.c b/sys/kern/kern_exit.c index c617bc73716d..68500c3b8721 100644 --- a/sys/kern/kern_exit.c +++ b/sys/kern/kern_exit.c @@ -276,16 +276,15 @@ exit1(struct thread *td, int rval, int signo) * Kill off the other threads. This requires * some co-operation from other parts of the kernel * so it may not be instantaneous. With this state set - * any thread entering the kernel from userspace will - * thread_exit() in trap(). Any thread attempting to + * any thread attempting to interruptibly * sleep will return immediately with EINTR or EWOULDBLOCK * which will hopefully force them to back out to userland * freeing resources as they go. Any thread attempting - * to return to userland will thread_exit() from userret(). + * to return to userland will thread_exit() from ast(). * thread_exit() will unsuspend us when the last of the * other threads exits. * If there is already a thread singler after resumption, - * calling thread_single will fail; in that case, we just + * calling thread_single() will fail; in that case, we just * re-check all suspension request, the thread should * either be suspended there or exit. */