From nobody Wed Nov 20 03:35:49 2024 X-Original-To: dev-commits-src-all@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 4XtRpY6Sxkz5d8PX; Wed, 20 Nov 2024 03:35:49 +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 "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4XtRpY4Z2kz44Jp; Wed, 20 Nov 2024 03:35:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1732073749; 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=ld/c6/zxFtcNqOxVzTnSF266ZoSJFejETR3LZ8gUB2k=; b=bF+v6/RbJigdQDRGhwkeTVlJ7uAVyHpNEz7n6TlksJcPAHP/fRrmLz8rGS4n7dmmTqhSk1 yGPCtz9yogIUlOeI67uelG4BDBTec6ttR2TZtt8Kra8Lm4zvJ0hsRZTOqfriYaxZo/nADm l1wn8G15cyhZ4IFjlBK5Zma6jqRNe1AeHu3UVAM9Le2zx1qaFw0hCSt7d6NZwquOsM5b3W ij4L/n6/N4fmApRVgYlHf2Esc6hCr1hvJ0jfR0oHMhNKg6NgerVp9Dih1WQ8XazFn9N1b4 kZUwM3F1qEjc8O88fDvOvEA6jdGTidY2pPLq9L06FSMkSgzHHs2F3w3qNmt1rw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1732073749; 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=ld/c6/zxFtcNqOxVzTnSF266ZoSJFejETR3LZ8gUB2k=; b=ZGxDuR0KffB/1f56dFwwbo9TNukUGeOFrQnIOKzYImKGbXR0+lC6g4CJq17MDKXZZJgotJ jEFdCYRGsCC+UpW16ncoCkm70Dtnzahi9Xfmww3qWaNKm9Q8szULJoOFV7k8eTRWytewsw p+GY111TN6rzQoRbfNCQ/6ZYXYi9lFD82WxyuoDXNzZbXxzoifYcxFKLbnNlLK7rhcNJBU k5zJSSL/tHK1JzJOvRJ+P7ZpCoMjvBpbmkyaERqS4UVlOSQSUyhdJbTW/7RN7tb9ETPlx4 a0lLP/ZJXcvkePzz5zdYkWPS/u90P1N6eoWduy8RSCj+8f24Q+BBLlJ+a3/OYg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1732073749; a=rsa-sha256; cv=none; b=ILFi5DtOmOAQzYFvU6ZO6GbZIdT669oDrllmqPrkfd0TV8em0c2ap4FF4Ra7yaq1YL5+Ib +hxd+JPwlAeBUkqKTOLfkEYYtKe3ulsJtd8vRthByiIIaF/Ae04+CgYlLkM2rh4uQSh2cI kM1aAjW3VrsX+DGhvZEvgwRh5kr/GbCP6PVqWkixxaXSQBy8v19T6DUmrS3qbAUvGWbAXQ 70a5RhI5AER6QZCdSuSR4QcoqVTRx9P3ea48WdTAT9oDrUilEPvNErcC6hHZv0Pe94dfxr +/E1A347k48afBkcP+rjZTp+9wBqxuO/uePKjKgsFMh5TvzRbVUJSbUn3cHUgg== 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 4XtRpY3s45zdDt; Wed, 20 Nov 2024 03:35:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 4AK3Zn9c099507; Wed, 20 Nov 2024 03:35:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4AK3ZnVU099504; Wed, 20 Nov 2024 03:35:49 GMT (envelope-from git) Date: Wed, 20 Nov 2024 03:35:49 GMT Message-Id: <202411200335.4AK3ZnVU099504@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: c29cba408d19 - main - stand: Narrow the 'signal emulation' we provide List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c29cba408d197ed2c267d0605e4225bb54153e01 Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=c29cba408d197ed2c267d0605e4225bb54153e01 commit c29cba408d197ed2c267d0605e4225bb54153e01 Author: Warner Losh AuthorDate: 2024-11-20 03:05:11 +0000 Commit: Warner Losh CommitDate: 2024-11-20 03:24:41 +0000 stand: Narrow the 'signal emulation' we provide We only need to provide sig_atomic_t in emulation. However, including machine/signal.h brings in too much namespace pollution related to signals. Instead, define sig_atomic_t as long. Setting long is async atomic on all platforms (though powerpc64 defines it to an int), though that doesn't matter since the boot loader doesn't use signals. Sponsored by: Netflix --- stand/libsa/stand.h | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/stand/libsa/stand.h b/stand/libsa/stand.h index 260defa3a33d..e1188fb73a26 100644 --- a/stand/libsa/stand.h +++ b/stand/libsa/stand.h @@ -82,8 +82,13 @@ #define EOFFSET (ELAST+8) /* relative seek not supported */ #define ESALAST (ELAST+8) /* */ -/* Partial signal emulation for sig_atomic_t */ -#include +/* + * LUA needs sig_atomic_t. This is defined to be long or int on all our + * platforms. On all but powerpc, these are all the same thing as long. 64-bit + * powerpc defines this as int, but long can also be accessed atomically. It's + * also OK because we don't have signal handlers in the boot loader. + */ +typedef long sig_atomic_t; __BEGIN_DECLS