From nobody Mon Dec 9 03:28:33 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 4Y66lQ0CxTz5g7kr; Mon, 09 Dec 2024 03:28:34 +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 4Y66lP6nNqz44Tt; Mon, 9 Dec 2024 03:28:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733714914; 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=yw+7iYDDkWoxp7bpEySZbIawHfUBl6tOfquMTA7AupA=; b=ZAevO8SJeDPioTLMmSyE3TFxkoFoAb+MBQZm4Zqd392XRn8vNyFQIiSMVHbSPhOnotoQCK 5s7SQRFoym/1Nj7OWYO3hNzkOcUFzNKZrqvnjOIHCAD0X1n/hv/hWHdWtRX5jTfGu3Nno4 IgUid/Iwc5WD7U3sumL6UmuYFNJRTSy6OoW1a0Rg8gSK1xs85tM9wx74NwQQY61h4xd7Tx 9kTIEGd94SVBImbjyrqDrF+QJogUjLCghC8mjrv6mYfDhzRTgBwEnBWPJ8SOvSETDaesC3 4ONYzG+CDTfODwPWD4fUk1M9bOPNh2sjZnKPhSpT/RsOUj3pwNEVqSgmJl2J9A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733714914; 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=yw+7iYDDkWoxp7bpEySZbIawHfUBl6tOfquMTA7AupA=; b=yDSPb5EiGO4NMUC9ZFDnPID+cDJXn868c3tuPTMdn4CN1sNvTRC0fWkwZsyhLQ4y8S74mT gDUWXeWJEIDwiAR7swS8zU6JsJf3EMPwzkn+EC9e3DzuxO5noSMMaQ16BXBSP1yLK+1ciS zBvwybHR06jr6a3+ZczNOAGGr2S/pUEVJkaQfWKKUvAE6wf8S9Y2hS8Gv4Z5kYMaPdVxrb S+OmeT2Ozc+ctw1IEHQWM67eRWPJyYmgnVXuyJ/7QLk4VbLR6c+StPTO6SBwxK43NujqOF 7BapkL/NSz+Uyfpj4LjIR+FD0yuk70oFQKjCAPxPbb//s66xot8ly8pmAt+1PQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733714914; a=rsa-sha256; cv=none; b=psLHDuUnomwo9n+dZfiFXQ3/FwpDBl6bQ0ZBO6CjR1iVxA0VMzJc2r7DwLt+yBGL0m+Oqj g5E2o5UTeyW9k1Dy0/5PsJHNFXelGOWMCyEYN8FmsX+KJx1idLLDeGCwkUmkE1n9vfMUcc 24A7mtdprE0t9eAtiAfGactBcd0Wtje/jsihandWjyzboXjGbfgDPY6+PHEjVXekvosjBy l+bZzqE/I3ZHIWjZgWsqvFthYEq3tq9SnFdxnaT5SCvQikEhJ9xYUZuWw0WQRRIwyVXrbv xjG2MPfLvg41jutlPoRg9lHXPUl8sIWD2ybBsuTTCtJBajsWXXAUEn+IigkRkA== 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 4Y66lP6FhWzLTD; Mon, 9 Dec 2024 03:28:33 +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 4B93SXUg083710; Mon, 9 Dec 2024 03:28:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B93SXxd083707; Mon, 9 Dec 2024 03:28:33 GMT (envelope-from git) Date: Mon, 9 Dec 2024 03:28:33 GMT Message-Id: <202412090328.4B93SXxd083707@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: 6ed68e6f5d47 - main - vm_map: overlap system map mutex and user man sx 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6ed68e6f5d47ca30716d4e06c1452e68530970db Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=6ed68e6f5d47ca30716d4e06c1452e68530970db commit 6ed68e6f5d47ca30716d4e06c1452e68530970db Author: Konstantin Belousov AuthorDate: 2024-12-05 22:44:08 +0000 Commit: Konstantin Belousov CommitDate: 2024-12-09 03:27:44 +0000 vm_map: overlap system map mutex and user man sx This saves 616-584 = 32 bytes per struct vmspace on amd64, which allows to pack 7 vmspaces per page vs. 6 for non-overlapping layout. I used anonymous union member feature to avoid too much churn. Reviewed by: alc, markj Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D47934 --- sys/vm/vm_kern.c | 3 +-- sys/vm/vm_map.c | 18 +++++++++++------- sys/vm/vm_map.h | 7 +++++-- 3 files changed, 17 insertions(+), 11 deletions(-) diff --git a/sys/vm/vm_kern.c b/sys/vm/vm_kern.c index a748a6c57d65..29a64a0fe6d8 100644 --- a/sys/vm/vm_kern.c +++ b/sys/vm/vm_kern.c @@ -830,8 +830,7 @@ kmem_init(vm_offset_t start, vm_offset_t end) vm_size_t quantum; int domain; - vm_map_init(kernel_map, kernel_pmap, VM_MIN_KERNEL_ADDRESS, end); - kernel_map->system_map = 1; + vm_map_init_system(kernel_map, kernel_pmap, VM_MIN_KERNEL_ADDRESS, end); vm_map_lock(kernel_map); /* N.B.: cannot use kgdb to debug, starting with this assignment ... */ (void)vm_map_insert(kernel_map, NULL, 0, diff --git a/sys/vm/vm_map.c b/sys/vm/vm_map.c index 910ebfb6dc4e..c3aa499e0dc7 100644 --- a/sys/vm/vm_map.c +++ b/sys/vm/vm_map.c @@ -292,9 +292,7 @@ vmspace_zinit(void *mem, int size, int flags) vm = (struct vmspace *)mem; map = &vm->vm_map; - memset(map, 0, sizeof(*map)); - mtx_init(&map->system_mtx, "vm map (system)", NULL, - MTX_DEF | MTX_DUPOK); + memset(map, 0, sizeof(*map)); /* set map->system_map = false */ sx_init(&map->lock, "vm map (user)"); PMAP_LOCK_INIT(vmspace_pmap(vm)); return (0); @@ -890,7 +888,6 @@ _vm_map_init(vm_map_t map, pmap_t pmap, vm_offset_t min, vm_offset_t max) map->header.eflags = MAP_ENTRY_HEADER; map->needs_wakeup = FALSE; - map->system_map = 0; map->pmap = pmap; map->header.end = min; map->header.start = max; @@ -908,13 +905,20 @@ _vm_map_init(vm_map_t map, pmap_t pmap, vm_offset_t min, vm_offset_t max) void vm_map_init(vm_map_t map, pmap_t pmap, vm_offset_t min, vm_offset_t max) { - _vm_map_init(map, pmap, min, max); - mtx_init(&map->system_mtx, "vm map (system)", NULL, - MTX_DEF | MTX_DUPOK); + map->system_map = false; sx_init(&map->lock, "vm map (user)"); } +void +vm_map_init_system(vm_map_t map, pmap_t pmap, vm_offset_t min, vm_offset_t max) +{ + _vm_map_init(map, pmap, min, max); + map->system_map = true; + mtx_init(&map->system_mtx, "vm map (system)", NULL, MTX_DEF | + MTX_DUPOK); +} + /* * vm_map_entry_dispose: [ internal use only ] * diff --git a/sys/vm/vm_map.h b/sys/vm/vm_map.h index d0b4bb52968e..5ecec0531e1c 100644 --- a/sys/vm/vm_map.h +++ b/sys/vm/vm_map.h @@ -203,8 +203,10 @@ vm_map_entry_system_wired_count(vm_map_entry_t entry) */ struct vm_map { struct vm_map_entry header; /* List of entries */ - struct sx lock; /* Lock for map data */ - struct mtx system_mtx; + union { + struct sx lock; /* Lock for map data */ + struct mtx system_mtx; + }; int nentries; /* Number of entries */ vm_size_t size; /* virtual size */ u_int timestamp; /* Version number */ @@ -484,6 +486,7 @@ int vm_map_fixed(vm_map_t, vm_object_t, vm_ooffset_t, vm_offset_t, vm_size_t, vm_offset_t vm_map_findspace(vm_map_t, vm_offset_t, vm_size_t); int vm_map_inherit (vm_map_t, vm_offset_t, vm_offset_t, vm_inherit_t); void vm_map_init(vm_map_t, pmap_t, vm_offset_t, vm_offset_t); +void vm_map_init_system(vm_map_t, pmap_t, vm_offset_t, vm_offset_t); int vm_map_insert (vm_map_t, vm_object_t, vm_ooffset_t, vm_offset_t, vm_offset_t, vm_prot_t, vm_prot_t, int); int vm_map_lookup (vm_map_t *, vm_offset_t, vm_prot_t, vm_map_entry_t *, vm_object_t *, vm_pindex_t *, vm_prot_t *, boolean_t *); From nobody Mon Dec 9 03:28:34 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 4Y66lR3Lz3z5g7fv; Mon, 09 Dec 2024 03:28:35 +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 4Y66lR2lW0z44nx; Mon, 9 Dec 2024 03:28:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733714915; 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=HiJDa3RNVajpJQnYNkg6HFTI0ZFZWigmRoxq+deS2SM=; b=Gcx8rwfr7oz7uoQfH07WsZwQIo0Hcy3RGIQ4SK/i/oeGT7pbxFpnU9K0r+rLI8ZAmpkWYj AkgNhxqocPuvaYa2kyp7QoV0Tf8+KlJsbP3NJiCWJEESKCgk0J6mfVX39sAAZ1GfhHVDhm 3n8/OPRGbREMYIGOSb8W4d+UCySYu7urWad3AuKGW6pN5gbfFEjP21kRgSEhqFxiQ5fSg5 U1cEV8IdLRny6ck/0E8PbwqYfdethTBJMvITYkZLDg8TbrmGM2eGPwjrqaYMuRnThZdZMy DNcTwz65W5oaa6SF/sJgV/nftO8RFRu69YE11FkdunfEd+XJ5Psyw+rj3thixw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733714915; 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=HiJDa3RNVajpJQnYNkg6HFTI0ZFZWigmRoxq+deS2SM=; b=johnbBPKELHd9Di7prChG6kOGgziWPOoEGyhPape8cppyQujjf59dzP0ENRJu9HqbgBmAy Vg1V4XPWISzzjtHbBWzEoc2zJzKFW9ggh8Ffs+9bVVKKQ4/nPJlUo+ZyASv5s4wd+3ZDDT eAnaRFIFB5+DMEJBsk8dpgM8cuhk6grK4QlCG6akq71jL9/xCNUGWaJB8Eur8+06073dYe bHXfUWZGtfaTBspY8yfz+gzbuGskY8/g9BpMFrsOLB3g9mONHA5lQ4qLz7fUXxXViAHsdj m3l02m+a3MdhpaEGmY49nAcjmWEAeOGX5ta7NbZ/g4H9fLppLVSmMVdThSilJw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733714915; a=rsa-sha256; cv=none; b=ZAkKdHfLQX3+NrI9fr3DMfPmHnmyr8ciJHkmLsgWqMQesTz0W4PBu6LBx2l4zCjmUzBTIy 6MHha13GZikrvRoBz2N1W1wyTIjldVlHCpF7oeaVDTyAOrrgOSYS5Kw2M4hwWbDfpLqNCq TXX47OfIzxOnokJNHzIHQIRPR2QpNP6BitwpyaSJ4pDhv3aJ2fFyvkzzYY4Ww89MWvL8wC Lu1Gyuz/x5Gt0hdTBNMzsKGUuq9CRjF1svQUzXVPifrVtdwEf0FdkdyQlYCsAy2v6hGXvN jzkU4h5xoJyf87Vn4CB48x7h1QXNF6Q6zpqgYHKMVAYrbuQ6sXFyZnRcU0VAMg== 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 4Y66lR0TpszKwx; Mon, 9 Dec 2024 03:28:35 +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 4B93SYvP083764; Mon, 9 Dec 2024 03:28:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B93SYHh083761; Mon, 9 Dec 2024 03:28:34 GMT (envelope-from git) Date: Mon, 9 Dec 2024 03:28:34 GMT Message-Id: <202412090328.4B93SYHh083761@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: c5b19cef3609 - main - vm_map: wrap map->system_map checks into wrapper 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c5b19cef3609211e692d6b21abcddef877c94af7 Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=c5b19cef3609211e692d6b21abcddef877c94af7 commit c5b19cef3609211e692d6b21abcddef877c94af7 Author: Konstantin Belousov AuthorDate: 2024-12-06 23:51:08 +0000 Commit: Konstantin Belousov CommitDate: 2024-12-09 03:27:44 +0000 vm_map: wrap map->system_map checks into wrapper Reviewed by: alc Sponsored by: The FreeBSD Foundation Differential revision: https://reviews.freebsd.org/D47934 --- sys/vm/vm_fault.c | 2 +- sys/vm/vm_map.c | 49 ++++++++++++++++++++++++------------------------- sys/vm/vm_map.h | 6 ++++++ sys/vm/vm_pageout.c | 2 +- 4 files changed, 32 insertions(+), 27 deletions(-) diff --git a/sys/vm/vm_fault.c b/sys/vm/vm_fault.c index 6e0415b30600..8c7fe9e37af1 100644 --- a/sys/vm/vm_fault.c +++ b/sys/vm/vm_fault.c @@ -1355,7 +1355,7 @@ vm_fault_getpages(struct faultstate *fs, int *behindp, int *aheadp) MPASS(status == FAULT_CONTINUE || status == FAULT_RESTART); if (status == FAULT_RESTART) return (status); - KASSERT(fs->vp == NULL || !fs->map->system_map, + KASSERT(fs->vp == NULL || !vm_map_is_system(fs->map), ("vm_fault: vnode-backed object mapped by system map")); /* diff --git a/sys/vm/vm_map.c b/sys/vm/vm_map.c index c3aa499e0dc7..f7847a244586 100644 --- a/sys/vm/vm_map.c +++ b/sys/vm/vm_map.c @@ -523,7 +523,7 @@ void _vm_map_lock(vm_map_t map, const char *file, int line) { - if (map->system_map) + if (vm_map_is_system(map)) mtx_lock_flags_(&map->system_mtx, 0, file, line); else sx_xlock_(&map->lock, file, line); @@ -614,7 +614,7 @@ static void _vm_map_assert_locked(vm_map_t map, const char *file, int line) { - if (map->system_map) + if (vm_map_is_system(map)) mtx_assert_(&map->system_mtx, MA_OWNED, file, line); else sx_assert_(&map->lock, SA_XLOCKED, file, line); @@ -657,7 +657,7 @@ _vm_map_unlock(vm_map_t map, const char *file, int line) { VM_MAP_UNLOCK_CONSISTENT(map); - if (map->system_map) { + if (vm_map_is_system(map)) { #ifndef UMA_USE_DMAP if (map == kernel_map && (map->flags & MAP_REPLENISH) != 0) { uma_prealloc(kmapentzone, 1); @@ -675,7 +675,7 @@ void _vm_map_lock_read(vm_map_t map, const char *file, int line) { - if (map->system_map) + if (vm_map_is_system(map)) mtx_lock_flags_(&map->system_mtx, 0, file, line); else sx_slock_(&map->lock, file, line); @@ -685,7 +685,7 @@ void _vm_map_unlock_read(vm_map_t map, const char *file, int line) { - if (map->system_map) { + if (vm_map_is_system(map)) { KASSERT((map->flags & MAP_REPLENISH) == 0, ("%s: MAP_REPLENISH leaked", __func__)); mtx_unlock_flags_(&map->system_mtx, 0, file, line); @@ -700,7 +700,7 @@ _vm_map_trylock(vm_map_t map, const char *file, int line) { int error; - error = map->system_map ? + error = vm_map_is_system(map) ? !mtx_trylock_flags_(&map->system_mtx, 0, file, line) : !sx_try_xlock_(&map->lock, file, line); if (error == 0) @@ -713,7 +713,7 @@ _vm_map_trylock_read(vm_map_t map, const char *file, int line) { int error; - error = map->system_map ? + error = vm_map_is_system(map) ? !mtx_trylock_flags_(&map->system_mtx, 0, file, line) : !sx_try_slock_(&map->lock, file, line); return (error == 0); @@ -734,7 +734,7 @@ _vm_map_lock_upgrade(vm_map_t map, const char *file, int line) { unsigned int last_timestamp; - if (map->system_map) { + if (vm_map_is_system(map)) { mtx_assert_(&map->system_mtx, MA_OWNED, file, line); } else { if (!sx_try_upgrade_(&map->lock, file, line)) { @@ -760,7 +760,7 @@ void _vm_map_lock_downgrade(vm_map_t map, const char *file, int line) { - if (map->system_map) { + if (vm_map_is_system(map)) { KASSERT((map->flags & MAP_REPLENISH) == 0, ("%s: MAP_REPLENISH leaked", __func__)); mtx_assert_(&map->system_mtx, MA_OWNED, file, line); @@ -780,10 +780,9 @@ int vm_map_locked(vm_map_t map) { - if (map->system_map) + if (vm_map_is_system(map)) return (mtx_owned(&map->system_mtx)); - else - return (sx_xlocked(&map->lock)); + return (sx_xlocked(&map->lock)); } /* @@ -806,7 +805,7 @@ _vm_map_unlock_and_wait(vm_map_t map, int timo, const char *file, int line) VM_MAP_UNLOCK_CONSISTENT(map); mtx_lock(&map_sleep_mtx); - if (map->system_map) { + if (vm_map_is_system(map)) { KASSERT((map->flags & MAP_REPLENISH) == 0, ("%s: MAP_REPLENISH leaked", __func__)); mtx_unlock_flags_(&map->system_mtx, 0, file, line); @@ -864,7 +863,7 @@ vm_map_wait_busy(vm_map_t map) VM_MAP_ASSERT_LOCKED(map); while (map->busy) { vm_map_modflags(map, MAP_BUSY_WAKEUP, 0); - if (map->system_map) + if (vm_map_is_system(map)) msleep(&map->busy, &map->system_mtx, 0, "mbusy", 0); else sx_sleep(&map->busy, &map->lock, 0, "mbusy", 0); @@ -927,7 +926,7 @@ vm_map_init_system(vm_map_t map, pmap_t pmap, vm_offset_t min, vm_offset_t max) static void vm_map_entry_dispose(vm_map_t map, vm_map_entry_t entry) { - uma_zfree(map->system_map ? kmapentzone : mapentzone, entry); + uma_zfree(vm_map_is_system(map) ? kmapentzone : mapentzone, entry); } /* @@ -961,7 +960,7 @@ vm_map_entry_create(vm_map_t map) } } else #endif - if (map->system_map) { + if (vm_map_is_system(map)) { new_entry = uma_zalloc(kmapentzone, M_NOWAIT); } else { new_entry = uma_zalloc(mapentzone, M_WAITOK); @@ -2428,7 +2427,7 @@ vm_map_entry_charge_object(vm_map_t map, vm_map_entry_t entry) VM_MAP_ASSERT_LOCKED(map); KASSERT((entry->eflags & MAP_ENTRY_IS_SUB_MAP) == 0, ("map entry %p is a submap", entry)); - if (entry->object.vm_object == NULL && !map->system_map && + if (entry->object.vm_object == NULL && !vm_map_is_system(map) && (entry->eflags & MAP_ENTRY_GUARD) == 0) vm_map_entry_back(entry); else if (entry->object.vm_object != NULL && @@ -2493,7 +2492,7 @@ vm_map_clip_start(vm_map_t map, vm_map_entry_t entry, vm_offset_t startaddr) vm_map_entry_t new_entry; int bdry_idx; - if (!map->system_map) + if (!vm_map_is_system(map)) WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, NULL, "%s: map %p entry %p start 0x%jx", __func__, map, entry, (uintmax_t)startaddr); @@ -2536,7 +2535,7 @@ vm_map_lookup_clip_start(vm_map_t map, vm_offset_t start, vm_map_entry_t entry; int rv; - if (!map->system_map) + if (!vm_map_is_system(map)) WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, NULL, "%s: map %p start 0x%jx prev %p", __func__, map, (uintmax_t)start, prev_entry); @@ -2566,7 +2565,7 @@ vm_map_clip_end(vm_map_t map, vm_map_entry_t entry, vm_offset_t endaddr) vm_map_entry_t new_entry; int bdry_idx; - if (!map->system_map) + if (!vm_map_is_system(map)) WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, NULL, "%s: map %p entry %p end 0x%jx", __func__, map, entry, (uintmax_t)endaddr); @@ -3936,7 +3935,7 @@ vm_map_entry_delete(vm_map_t map, vm_map_entry_t entry) MPASS(entry->cred == NULL); MPASS((entry->eflags & MAP_ENTRY_IS_SUB_MAP) == 0); MPASS(object == NULL); - vm_map_entry_deallocate(entry, map->system_map); + vm_map_entry_deallocate(entry, vm_map_is_system(map)); return; } @@ -3987,7 +3986,7 @@ vm_map_entry_delete(vm_map_t map, vm_map_entry_t entry) } VM_OBJECT_WUNLOCK(object); } - if (map->system_map) + if (vm_map_is_system(map)) vm_map_entry_deallocate(entry, TRUE); else { entry->defer_next = curthread->td_map_def_user; @@ -4710,7 +4709,7 @@ vm_map_growstack(vm_map_t map, vm_offset_t addr, vm_map_entry_t gap_entry) p->p_textvp == NULL)) return (KERN_FAILURE); - MPASS(!map->system_map); + MPASS(!vm_map_is_system(map)); lmemlim = lim_cur(curthread, RLIMIT_MEMLOCK); stacklim = lim_cur(curthread, RLIMIT_STACK); @@ -5118,7 +5117,7 @@ RetryLookupLocked: /* * Create an object if necessary. */ - if (entry->object.vm_object == NULL && !map->system_map) { + if (entry->object.vm_object == NULL && !vm_map_is_system(map)) { if (vm_map_lock_upgrade(map)) goto RetryLookup; entry->object.vm_object = vm_object_allocate_anon(atop(size), @@ -5206,7 +5205,7 @@ vm_map_lookup_locked(vm_map_t *var_map, /* IN/OUT */ /* * Fail if an object should be created. */ - if (entry->object.vm_object == NULL && !map->system_map) + if (entry->object.vm_object == NULL && !vm_map_is_system(map)) return (KERN_FAILURE); /* diff --git a/sys/vm/vm_map.h b/sys/vm/vm_map.h index 5ecec0531e1c..ed1106734951 100644 --- a/sys/vm/vm_map.h +++ b/sys/vm/vm_map.h @@ -278,6 +278,12 @@ vm_map_range_valid(vm_map_t map, vm_offset_t start, vm_offset_t end) return (true); } +static inline bool +vm_map_is_system(vm_map_t map) +{ + return ((map->system_map)); +} + #endif /* KLD_MODULE */ #endif /* _KERNEL */ diff --git a/sys/vm/vm_pageout.c b/sys/vm/vm_pageout.c index f6c5e6291692..28a54a83fd49 100644 --- a/sys/vm/vm_pageout.c +++ b/sys/vm/vm_pageout.c @@ -1844,7 +1844,7 @@ vm_pageout_oom_pagecount(struct vmspace *vmspace) long res; map = &vmspace->vm_map; - KASSERT(!map->system_map, ("system map")); + KASSERT(!vm_map_is_system(map), ("system map")); sx_assert(&map->lock, SA_LOCKED); res = 0; VM_MAP_ENTRY_FOREACH(entry, map) { From nobody Mon Dec 9 03:28:37 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 4Y66lT5cJBz5g7c4; Mon, 09 Dec 2024 03:28:37 +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 4Y66lT3cgbz44jy; Mon, 9 Dec 2024 03:28:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733714917; 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=uZIn5HbBTPa+zOlMQz5/NqTvFnDmi4N5j2zfcIxy03o=; b=ySWsV+w5hQHbib4Q2Z33zRZvbZ4/AbMDyKfq0lD8XNihT/P9wX1acI1JaLIwLL4wRfcMtN tORSdfxahAOPst9pE4ltfQfkfHGJRIwNCJFma/DhJUKvCBgPP4ArpUpdCDmCByXca39Ttc 57Cs3GVMiXKDdsW7483Qy/Y36ZQwtXWfTOqbeYARWyS5hTfUUasAAOeXYBR+s/ekXcXbaR CKPk7lZa7QanmlE9KPZ5/nwuVdZYwiyF3v+Wysr0NZ442Hl431zPZ5kAeqmcSSXHa5enxa bHsYH8WWON4O1ATEnyZTKyrfvyDf1Dauz0rSrS9Z5JdxHvyQrNlfW/E2Bx+Vqw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733714917; 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=uZIn5HbBTPa+zOlMQz5/NqTvFnDmi4N5j2zfcIxy03o=; b=o/OFsqb9mH0qvt1hnHSUqlWgy5POcz4ZdOyREdtBmc+lBzf3eo7g88SBaUVQuAQ/esOeS8 IxEd8PhVBNrI0wX6LH+UjCN3QFsnBwO5VgblkUe7FKK8gey3FPEURcZ3htcCMj46ZyMaSo aBoBS1k78VO2cZspyQPgDZqHTxQ69jkJs7uEhqwpZAm94Qf7czEMkpUqq2sdoPRHhBAXRu /MaTQsnK8J3t3UHzTtU8yIfr2jhZzz2dyB0ghn251sBmL6nmtAfxKqwAWoL8efGx2inF5y ilDwyozBqf2tCb6lq9hiOQxTdeKhQv4j4FCConm3zEWDx+RoyxluNid3wgUCtw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733714917; a=rsa-sha256; cv=none; b=StzHzYDjITP5xYmYQAoq/mmg9aArfFYOnHArOCCSsLfGLLQBqw/SebQ+BLyRZKYA54xoZe BmSm+JXli8jzXLClGeH7yj2ms8R+RJNOenyOyisrK8oEmhLPDAhQi/k9Kych5rI9WsRGlU 3nFCov+6Hmuov8H3dMl39+L7/inpdAI086mfbR3pVaO4N1F8d/UP+LDGAlIyHCb4IBkW3/ TQhI5ji9s6u/7riZhMwsYDQXDs+dmIclppB82roAuPWwdivZUniQSJHXQw0xhBF6t1VwZC igSqL42LZe/OyWiUfH/rA6lrnXR+Uq49MLnPhDDBCZy0l+5YLl1UD68C5HeXmw== 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 4Y66lT1qGtzLTF; Mon, 9 Dec 2024 03:28:37 +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 4B93SbTp083872; Mon, 9 Dec 2024 03:28:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B93Sbdt083869; Mon, 9 Dec 2024 03:28:37 GMT (envelope-from git) Date: Mon, 9 Dec 2024 03:28:37 GMT Message-Id: <202412090328.4B93Sbdt083869@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: d939fd2d4512 - main - vm_map: convert several bool members into flags 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d939fd2d4512c9811246834a19946f69350764e0 Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=d939fd2d4512c9811246834a19946f69350764e0 commit d939fd2d4512c9811246834a19946f69350764e0 Author: Konstantin Belousov AuthorDate: 2024-12-06 23:52:25 +0000 Commit: Konstantin Belousov CommitDate: 2024-12-09 03:27:44 +0000 vm_map: convert several bool members into flags Extend flags to u_int. Move system_map and needs_wakeup bools into flags. Reviewed by: alc Sponsored by: The FreeBSD Foundation Differential revision: https://reviews.freebsd.org/D47934 --- sys/vm/vm_kern.c | 6 +++--- sys/vm/vm_map.c | 6 ++---- sys/vm/vm_map.h | 12 ++++++------ 3 files changed, 11 insertions(+), 13 deletions(-) diff --git a/sys/vm/vm_kern.c b/sys/vm/vm_kern.c index 29a64a0fe6d8..86ab2529e27f 100644 --- a/sys/vm/vm_kern.c +++ b/sys/vm/vm_kern.c @@ -724,7 +724,7 @@ kmap_alloc_wait(vm_map_t map, vm_size_t size) swap_release(size); return (0); } - map->needs_wakeup = TRUE; + vm_map_modflags(map, MAP_NEEDS_WAKEUP, 0); vm_map_unlock_and_wait(map, 0); } vm_map_insert(map, NULL, 0, addr, addr + size, VM_PROT_RW, VM_PROT_RW, @@ -745,8 +745,8 @@ kmap_free_wakeup(vm_map_t map, vm_offset_t addr, vm_size_t size) vm_map_lock(map); (void) vm_map_delete(map, trunc_page(addr), round_page(addr + size)); - if (map->needs_wakeup) { - map->needs_wakeup = FALSE; + if ((map->flags & MAP_NEEDS_WAKEUP) != 0) { + vm_map_modflags(map, 0, MAP_NEEDS_WAKEUP); vm_map_wakeup(map); } vm_map_unlock(map); diff --git a/sys/vm/vm_map.c b/sys/vm/vm_map.c index f7847a244586..564ef59950e4 100644 --- a/sys/vm/vm_map.c +++ b/sys/vm/vm_map.c @@ -292,7 +292,7 @@ vmspace_zinit(void *mem, int size, int flags) vm = (struct vmspace *)mem; map = &vm->vm_map; - memset(map, 0, sizeof(*map)); /* set map->system_map = false */ + memset(map, 0, sizeof(*map)); /* set MAP_SYSTEM_MAP to false */ sx_init(&map->lock, "vm map (user)"); PMAP_LOCK_INIT(vmspace_pmap(vm)); return (0); @@ -886,7 +886,6 @@ _vm_map_init(vm_map_t map, pmap_t pmap, vm_offset_t min, vm_offset_t max) { map->header.eflags = MAP_ENTRY_HEADER; - map->needs_wakeup = FALSE; map->pmap = pmap; map->header.end = min; map->header.start = max; @@ -905,7 +904,6 @@ void vm_map_init(vm_map_t map, pmap_t pmap, vm_offset_t min, vm_offset_t max) { _vm_map_init(map, pmap, min, max); - map->system_map = false; sx_init(&map->lock, "vm map (user)"); } @@ -913,7 +911,7 @@ void vm_map_init_system(vm_map_t map, pmap_t pmap, vm_offset_t min, vm_offset_t max) { _vm_map_init(map, pmap, min, max); - map->system_map = true; + vm_map_modflags(map, MAP_SYSTEM_MAP, 0); mtx_init(&map->system_mtx, "vm map (system)", NULL, MTX_DEF | MTX_DUPOK); } diff --git a/sys/vm/vm_map.h b/sys/vm/vm_map.h index caed29bd23cf..9645ae1a0527 100644 --- a/sys/vm/vm_map.h +++ b/sys/vm/vm_map.h @@ -210,9 +210,7 @@ struct vm_map { int nentries; /* Number of entries */ vm_size_t size; /* virtual size */ u_int timestamp; /* Version number */ - u_char needs_wakeup; - u_char system_map; /* (c) Am I a system map? */ - vm_flags_t flags; /* flags for this vm_map */ + u_int flags; /* flags for this vm_map */ vm_map_entry_t root; /* Root of a binary search tree */ pmap_t pmap; /* (c) Physical map */ vm_offset_t anon_loc; @@ -223,7 +221,7 @@ struct vm_map { }; /* - * vm_flags_t values + * vm_map flags values */ #define MAP_WIREFUTURE 0x00000001 /* wire all future pages */ #define MAP_BUSY_WAKEUP 0x00000002 /* thread(s) waiting on busy @@ -236,6 +234,8 @@ struct vm_map { #define MAP_WXORX 0x00000040 /* enforce W^X */ #define MAP_ASLR_STACK 0x00000080 /* stack location is randomized */ +#define MAP_NEEDS_WAKEUP 0x40000000 +#define MAP_SYSTEM_MAP 0x80000000 #ifdef _KERNEL #if defined(KLD_MODULE) && !defined(KLD_TIED) @@ -266,7 +266,7 @@ vm_map_pmap(vm_map_t map) } static __inline void -vm_map_modflags(vm_map_t map, vm_flags_t set, vm_flags_t clear) +vm_map_modflags(vm_map_t map, u_int set, u_int clear) { map->flags = (map->flags | set) & ~clear; } @@ -284,7 +284,7 @@ vm_map_range_valid(vm_map_t map, vm_offset_t start, vm_offset_t end) static inline bool vm_map_is_system(vm_map_t map) { - return ((map->system_map)); + return ((map->flags & MAP_SYSTEM_MAP) != 0); } #endif /* KLD_MODULE */ From nobody Mon Dec 9 03:28:36 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 4Y66lT0482z5g7hp; Mon, 09 Dec 2024 03:28:37 +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 4Y66lS4YyHz44lM; Mon, 9 Dec 2024 03:28:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733714916; 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=f7GJAEu+0fKJhLDlt8MZA3+IvGR0UM1oTSk/xUUxy3g=; b=QEDtcVVN9oqGiNDvItkWVZu+Au6iORa826W1yP4PV8lq7C2BoTeHOZphJIUUoTXuqMzBE4 Jc25HHsxWJDDCPLJ6iqb/12S5pE+jCRpabtZ+B/cG3e8OTGpywQesC3BiXJIdU4wpaFoBH zyzORr1ylMZAWBI5O0+9pIksbqy24fMcOHCEzvifhMQaoDBUGfJSBNQ/asm0w23fEusBtJ w8frwO53WFQXE7CTF952NXF1JmYkSg6J8YkCENfB4F6Utc7kWpWl5AvIiJ3udPcbAqfOx8 Z3PJb/BY1HumoGVd/dsUBtDKubC9Vi/ZjzcczDl77z1WMm2dyWod3EyEHSEQLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733714916; 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=f7GJAEu+0fKJhLDlt8MZA3+IvGR0UM1oTSk/xUUxy3g=; b=Mhg96EcO1ZOxlckKksmV/TKUPL4bnP9juL7gfuvECxDhPS+8a1ZY7gYauIx6eh85zXgJTE ey1VUgyfVYpoghWhh/RuWLZK82Qjlbvwe9rHeaAOGzJLrKswUFzZAAX62xSUD6fO7iAqcX d3cQn8QZjtjUd1Zwj/NGfNElNtL4sc9veOdkK0D7V37NxK8d4QT8nSX5O90qtMfLkg8oHS Ch6bSsV2003CxsJ0lRUr4NoB4TjVIWMRkE9q7nu5Fdc/sPun1j5otXc6NZz6WbDazuQf4l joLS/vHeVlvGKva+VV6R95n5E88B1C3fW1OqiDuLqjLyAzHezK8+3imzr/OJIA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733714916; a=rsa-sha256; cv=none; b=IdVwFQXyd4FjCrNXDBxDgFxURdoNoJbXrc10r0N024sP2iwshVGnVg2JxSrHNOJ+ccomDE 0nSOJd29i+6zCJH0v3CUtopr0g+aKElUdxwt9trRhax2wTCMaVuNufv/ujtr1ZF2ukE8Ge twHzDYO+9HDCj0qWa8khESxixdn1yLmIx3sLV8om1BYQEKG1cLKLek1NJdCVs9lb1kiTfu rODgODIL/E0WBEmL/W9xBa4WIRHwmblpkM4rX+NgyQAlEDm8ocr+y3TUZ8ZT03snvGwerm 6wOco9b3S6MK0Zrjoc+nUdtLC8wf0jP86z5VMIa5LIiXKFJrXZ9S1QEfe1YRzw== 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 4Y66lS2d8FzLFk; Mon, 9 Dec 2024 03:28:36 +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 4B93SaAI083824; Mon, 9 Dec 2024 03:28:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B93Sa6Y083821; Mon, 9 Dec 2024 03:28:36 GMT (envelope-from git) Date: Mon, 9 Dec 2024 03:28:36 GMT Message-Id: <202412090328.4B93Sa6Y083821@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: b4431e95542a - main - vm/vm_map.h: extend number of digits in vm_map flags definitions 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b4431e95542a4edddf8c677ec275201dfde71a2f Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=b4431e95542a4edddf8c677ec275201dfde71a2f commit b4431e95542a4edddf8c677ec275201dfde71a2f Author: Konstantin Belousov AuthorDate: 2024-12-07 23:58:35 +0000 Commit: Konstantin Belousov CommitDate: 2024-12-09 03:27:44 +0000 vm/vm_map.h: extend number of digits in vm_map flags definitions Reviewed by: alc Sponsored by: The FreeBSD Foundation Differential revision: https://reviews.freebsd.org/D47934 --- sys/vm/vm_map.h | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/sys/vm/vm_map.h b/sys/vm/vm_map.h index ed1106734951..caed29bd23cf 100644 --- a/sys/vm/vm_map.h +++ b/sys/vm/vm_map.h @@ -225,14 +225,17 @@ struct vm_map { /* * vm_flags_t values */ -#define MAP_WIREFUTURE 0x01 /* wire all future pages */ -#define MAP_BUSY_WAKEUP 0x02 /* thread(s) waiting on busy state */ -#define MAP_IS_SUB_MAP 0x04 /* has parent */ -#define MAP_ASLR 0x08 /* enabled ASLR */ -#define MAP_ASLR_IGNSTART 0x10 /* ASLR ignores data segment */ -#define MAP_REPLENISH 0x20 /* kmapent zone needs to be refilled */ -#define MAP_WXORX 0x40 /* enforce W^X */ -#define MAP_ASLR_STACK 0x80 /* stack location is randomized */ +#define MAP_WIREFUTURE 0x00000001 /* wire all future pages */ +#define MAP_BUSY_WAKEUP 0x00000002 /* thread(s) waiting on busy + state */ +#define MAP_IS_SUB_MAP 0x00000004 /* has parent */ +#define MAP_ASLR 0x00000008 /* enabled ASLR */ +#define MAP_ASLR_IGNSTART 0x00000010 /* ASLR ignores data segment */ +#define MAP_REPLENISH 0x00000020 /* kmapent zone needs to be + refilled */ +#define MAP_WXORX 0x00000040 /* enforce W^X */ +#define MAP_ASLR_STACK 0x00000080 /* stack location is + randomized */ #ifdef _KERNEL #if defined(KLD_MODULE) && !defined(KLD_TIED) From nobody Mon Dec 9 03:28:38 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 4Y66lV6LT5z5g7Hg; Mon, 09 Dec 2024 03:28:38 +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 4Y66lV3qRNz44rp; Mon, 9 Dec 2024 03:28:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733714918; 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=cwUoRSaRpuOEDCZNOHNvdUWXytvxwWnFYasD+eGKbow=; b=oRMBSFXYAU99J+j4bwBgjAUZZ2kfbRBlXEOpn2CDYpFknzFW6CUx8Q7inb+Rce1930ZANl Rk6zNGyac4JFyJ2XPkNy/eCIlO49VduTRNZIZk2O6oipoxub2pO8GbXA29LAD2/qvr1KWs 31xQu4HS4bOhjG+OfHtQLisf6Y4N+60N6CtWY2gG6dDdyPX3jTuNHXfp8vnSgY/hkuIHw5 eBDbAmIuu2kg+du1KOt6muxSU0kCkOTZn9ox7M9SCoGKzjFDpZjOhhrKWFmkTr2MJ1Qmqe PuK7OBmX17goX1xse/s36UFpHEqgOMqYBHUhC6i+kiuMwqipOf12af3r5pFDqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733714918; 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=cwUoRSaRpuOEDCZNOHNvdUWXytvxwWnFYasD+eGKbow=; b=WKTDs5/1/c3UVQQ1/4nTvvuvNex4nqFhbF+CO6JBhBaw5tDSJIxxpiZw4fq2o3dwZKdTwW 6cdeJ/tQb9XqyU8MODOfFqEtiHF0v4Th9dzmg9Ujx8q+fLz/d53Rl8QYL7dLRMW42uEyuu V91vuqDJG75q739WMsPNpejKaB59dSBFO8KzQbHCT981Y7VNUT3i2K5CHRigBvO0eph9b7 IuZwm5WPwxKjcynuMWembSiAdqj+FDQQOCvCz0T0LBbWVoJqfyDm7zgxxP677QuNNNTxsi Rly3TLYfj66ZkYTDjR9kVmK4lT828mQJeqsW2b3Lr90uwg0ccnO1PtavFp5uYg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733714918; a=rsa-sha256; cv=none; b=ujJ94fZfk1p2pbDYsJ1uZBXfHG7QyYsx22waehaWp9/GH1CzX0cFLbsBohRmpZQaAPHVAG 2RoFsyCyxyjCVs4zj276ouLmttjY0kNWjIKJzN0lGs3CT2jYGYkp4ZxDBh2rPKa0pNg3W5 UjJssBWrX8qh9//hIZpQ398h0TjLQAQ9xbF7PobPo+TLkGl5kHgqEDzAl2FRZbxlIdvSuD 7sgEFfyWp+zeRMD5bMabte7uFFciyT8TMHrwzs3eCfE2y50DM0N66NnnAbcohGuZG2oIPd nDkYLonE6ZxQENF9nvpXogUGSZ7fKI7C+pFCWH3X0MOfI43ABy6eKU/9zajKWw== 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 4Y66lV35H9zKwy; Mon, 9 Dec 2024 03:28:38 +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 4B93Scrv083908; Mon, 9 Dec 2024 03:28:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B93SchT083905; Mon, 9 Dec 2024 03:28:38 GMT (envelope-from git) Date: Mon, 9 Dec 2024 03:28:38 GMT Message-Id: <202412090328.4B93SchT083905@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: fae0cc5fd82d - main - vm/vm_map.h: drop vm_flags_t 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: fae0cc5fd82dce009f06c29e0d9cf5232f03136a Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=fae0cc5fd82dce009f06c29e0d9cf5232f03136a commit fae0cc5fd82dce009f06c29e0d9cf5232f03136a Author: Konstantin Belousov AuthorDate: 2024-12-07 23:09:57 +0000 Commit: Konstantin Belousov CommitDate: 2024-12-09 03:27:44 +0000 vm/vm_map.h: drop vm_flags_t Suggested by: alc Reviewed by: alc Sponsored by: The FreeBSD Foundation Differential revision: https://reviews.freebsd.org/D47934 --- sys/vm/vm_map.h | 1 - 1 file changed, 1 deletion(-) diff --git a/sys/vm/vm_map.h b/sys/vm/vm_map.h index 9645ae1a0527..6af3dba42685 100644 --- a/sys/vm/vm_map.h +++ b/sys/vm/vm_map.h @@ -75,7 +75,6 @@ * vm_map_entry_t an entry in an address map. */ -typedef u_char vm_flags_t; typedef u_int vm_eflags_t; /* From nobody Mon Dec 9 03:28:39 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 4Y66lW6cpqz5g7c7; Mon, 09 Dec 2024 03:28:39 +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 4Y66lW58Z2z44kS; Mon, 9 Dec 2024 03:28:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733714919; 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=ePJsuYKhlfxilkbB4qQ2w4+Ernab+Jzb3hw7bgaD4lQ=; b=JPK9e/QVfFTxJ2aLGs6m+gtkNRw4fYjbjwwmdN3pFp+ZedyNHBit8j/19Lhl0bEYxXMcat +zbOPUk0MDmUZPoQCTJ+el32ilNyaKO9z3IzqR3iejc+H68Q+MpxyZGckSiVFpu2hgP/vj tPikdM/jXmkYnNMZhPB/U5NJg0cRPYxu3OGqHVu7ZOjvoKCMaiqceI9zNGiJOtTUA+38pK Vrm3fY47QNUddXYWDjSzgrT4sBnIJZYQYvU8qnnMSlMrva9n+Jbvt+6g3LK+4FKdpTLzW3 pZaaobMCBqXy7KatVFzo45KjYZdOh/2fOJSx1F6DoJSh0FlPrNU0VrDj965Kvw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733714919; 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=ePJsuYKhlfxilkbB4qQ2w4+Ernab+Jzb3hw7bgaD4lQ=; b=bFiAjEs0/Sw3G2rGPRB5m0h3moXr9cPKkK6ifLATCVtuyiKX6Ec04RKZzgJCUc+UxxweBB wB156M5pe202j4X5iFhFNiya+cId5AXgC7ULHZU5UWg5FYKBCK6pztHpPHI3ChFPyFdufV 4YkNTsWUfxSP3tiZVlTjofkLYJ0IzKdpLZvkHP3rILPszATbCF7VNddAi6TWRU9e+9cuKd wLGVCL2aVls9K9tGZzU8B1iNY5orTRamXD3NtSvUCLxz2po1Apa9svGsj4lKstUQm00/1X sZZzVSdaWqMdLQR4M7gauTkMdHlNbkc+JITF9JxUXFMMejQQZDbp3cy5wfLjdQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733714919; a=rsa-sha256; cv=none; b=pcvmKtdj+Y2T7qqh1zCH+a7MSvIkoHt6JCGVeZgReVPpgsRFOeDBnMttf2yxhrkqWnWfBI miax9Q+h5GXOUmHv7/XdBwiNmBuzqYEu7oeja9IlBEVrxXi7sEkcE3lEphkGvVuEU/GKww bGqJEj9IZilG+hTI/h1moBJb1fw9dCHC+mePdZ1+3V8TtmTDotQbAJpKM0zZ0E0OqwGD8F SRuZSXMmgvKJmzgplxQvxO3sLTH1lgwT3Fl30g35iWX2ZqL55iIaodtLQ/A8EQ/v7eoUUp VNDmN0o8mHiokIO+SlGfBn/4AT2YnQU0unDV6UD4teIbbslwRz/1y+rBqtNy9w== 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 4Y66lW445WzLV2; Mon, 9 Dec 2024 03:28:39 +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 4B93Sde5083945; Mon, 9 Dec 2024 03:28:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B93Sd4d083942; Mon, 9 Dec 2024 03:28:39 GMT (envelope-from git) Date: Mon, 9 Dec 2024 03:28:39 GMT Message-Id: <202412090328.4B93Sd4d083942@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: 32873ecb20ae - main - vm_map(9): some refresh 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 32873ecb20aebc5117a849dc9f2a11bd9b364a6b Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=32873ecb20aebc5117a849dc9f2a11bd9b364a6b commit 32873ecb20aebc5117a849dc9f2a11bd9b364a6b Author: Konstantin Belousov AuthorDate: 2024-12-07 23:10:52 +0000 Commit: Konstantin Belousov CommitDate: 2024-12-09 03:27:44 +0000 vm_map(9): some refresh Reviewed by: alc Sponsored by: The FreeBSD Foundation Differential revision: https://reviews.freebsd.org/D47934 --- share/man/man9/vm_map.9 | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/share/man/man9/vm_map.9 b/share/man/man9/vm_map.9 index 81379a5c347d..39242dd6b2b8 100644 --- a/share/man/man9/vm_map.9 +++ b/share/man/man9/vm_map.9 @@ -49,15 +49,15 @@ subordinate maps, created using the function. .Bd -literal -offset indent struct vm_map { - struct vm_map_entry header; - struct sx lock; - struct mtx system_mtx; + struct vm_map_entry header; + union { + struct sx lock; + struct mtx system_mtx; + }; int nentries; vm_size_t size; u_int timestamp; - u_char needs_wakeup; - u_char system_map; - vm_flags_t flags; + u_int flags; vm_map_entry_t root; pmap_t pmap; int busy; @@ -83,12 +83,6 @@ A count of the members in use within the circular map entry list. Specifies the size of the virtual address space. .It Va timestamp Used to determine if the map has changed since its last access. -.It Va needs_wakeup -Indicates if a thread is waiting for an allocation within the map. -Used only by system maps. -.It Va system_map -Set to TRUE to indicate that map is a system map; otherwise, it belongs -to a user process. .It Va flags Map flags, described below. .It Va root @@ -106,6 +100,12 @@ Possible map flags: Wire all future pages in this map. .It Dv MAP_BUSY_WAKEUP There are waiters for the map busy status. +.It Va MAP_NEEDS_WAKEUP +Indicates if a thread is waiting for an allocation within the map. +Used only by system maps. +.It Va MAP_SYSTEM_MAP +If set, ndicates that map is a system map; otherwise, it belongs +to a user process. .El .Pp The following flags can be passed to From nobody Mon Dec 9 04:23:31 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 4Y67yq35yBz5gBwt; Mon, 09 Dec 2024 04:23:31 +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 4Y67yq2SWJz4DJ5; Mon, 9 Dec 2024 04:23:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733718211; 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=doGdRLh+1Qx9UnEv7DVzGWfLokVHHWfRnqB47qrZ0tA=; b=Vc21VZnce5oWG2Tvt8DlOUv8wSb9XBfTB8Vm806LvvHlqgy+IwaNfslXY6JEbxR6uGjiYm QGCmXefTlLIGI8eZeYfChJzoB7TE4ZXjm6VqVeAHq2r13AHEJVWnwGaDAwUvkw5UfCFM7T NIw7H1znapVtL9zqVTkEkY3D5cAQ+s5m1Yidpbpd70c3psNjW4EewcZRzuNPeBKk2qb+6+ 4gJV9n6XNVPn/SUB/+hWZoSeNBHC2TniAGL2Rht9h2rF+nUm8tXQM3vL6oGOH4BRrSAs0p 0VGtSOz/vklOMjPZ1u/GhU5xssNJw3ktfE60Iyh5HRXNLg/9ENFqAA6nyPd0eA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733718211; 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=doGdRLh+1Qx9UnEv7DVzGWfLokVHHWfRnqB47qrZ0tA=; b=ZgmlGyZ+DwsLSyYvkBVN81Gi5CC7Rr3iPC1BeIz0J7sjCECk2Qjg5njzscMCwFf9MeFzT3 sohIgD3x97J/tio0JwmmX7eIMOfbUcUTd7VY1SFv6pMhISJPQNjYvX6qsOp8AA2XGNcr82 KrQ21UFPLSoGNFUmtUstlj5NSPttyHvJdCXPWBp7y2WIJ5ngt1OWsDfiemJNsr853mIm3l Iu9MtRfRkKuv7lSGAa4flXSBKBOjDNrLXk/ErIN5BgXKSxX9NoSpIGrwByGEkMx2q39B9l DudvUpDs/8D8lgupMAAz9gum3GraM2Sgyi0grpI2abhmYJalrwaPTS8/GQL2fw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733718211; a=rsa-sha256; cv=none; b=wWZOIlfbd5V1k0WTL3tNy1hi9DwgudzEGy3X4/nwt4l5Yvkc+QnG++4SFtZ15orgCk6ABo Sf7fTo7PHmvyjdS8HkSXw50gt1/grenPADFkxgMLlVmeItUHbOOGKJOlqshkZWfDcURpID a0SVQ9SOChwLjHYYkJUVGdnD0ddQg0j6SU7hTs/UAfG48VapxU3BQ3arcz8FLhLz+9YKdK SHBIhJSYNmYLszf1ETOwluw0gXd0OM5BWIVNgh11fszJXwQEBO5pl9mX439nWuyVNSCfHs yw3anEtq9sNiPBf51txCauEm/aVMSwWZXYSeewGE8cJiBoHt0YzHUUg/IHaDVw== 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 4Y67yq23rwzMQ2; Mon, 9 Dec 2024 04:23:31 +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 4B94NVr1094640; Mon, 9 Dec 2024 04:23:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B94NV1V094637; Mon, 9 Dec 2024 04:23:31 GMT (envelope-from git) Date: Mon, 9 Dec 2024 04:23:31 GMT Message-Id: <202412090423.4B94NV1V094637@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: 9114e15a8694 - main - amd64: re-enable la57, try two 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9114e15a86949f7d168bf09dbe78a340d5444e80 Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=9114e15a86949f7d168bf09dbe78a340d5444e80 commit 9114e15a86949f7d168bf09dbe78a340d5444e80 Author: Konstantin Belousov AuthorDate: 2024-12-09 03:40:33 +0000 Commit: Konstantin Belousov CommitDate: 2024-12-09 04:06:24 +0000 amd64: re-enable la57, try two If you need to use libc with jemalloc without commit eade2001aa9d91440886de8359a4dec9edcde2a9 (head, or b90d68c9b28b0a458bdf4a963397817974ed0f90 stable/14), you have to set vm.pmap.la57 to 0 for system-global effect, or use proccontrol -m la48 on affected image. Sponsored by: The FreeBSD Foundation --- sys/amd64/amd64/pmap.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c index 82110e61d54a..265d48e26c0b 100644 --- a/sys/amd64/amd64/pmap.c +++ b/sys/amd64/amd64/pmap.c @@ -2182,6 +2182,7 @@ pmap_bootstrap_la57(void *arg __unused) if ((cpu_stdext_feature2 & CPUID_STDEXT2_LA57) == 0) return; + la57 = 1; TUNABLE_INT_FETCH("vm.pmap.la57", &la57); if (!la57) return; From nobody Mon Dec 9 04:25:27 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 4Y68134ksFz5gBtp for ; Mon, 09 Dec 2024 04:25:27 +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 4Y68133zLyz4Dgr; Mon, 9 Dec 2024 04:25:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733718327; 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=M/ZCz9kfZ7wM69tBKKjCzInGaWhLZ4iuYlLAdnziDe8=; b=bJ1/8FK3mjx1NInitBuEPdkA2DzRWu7+O1+IGY124JCf8LKis60aTioxlOOFYoE2OYS+EF YlCvj6WIiuuj+BL0DHnap7p21tXRl99gH4+lxFW6MkQTViJX0PCUhjgtSq4D7FzZpdmmtu iP1ziw1fyth5gpHbKUvtnzOeNKOnq0vNPq4p5+Jk80Yth1gDXNfTCLH1o0Y8RoCrqUJNIk IqrXWOu/eDTL2+6/IiS18Q2UyAROJXD/8rkQpSFSmBQuETrsRDFHLDohFZmYaNmPqTflzT /RjD0oWbcsSJHse1WHmDvGDB4vV8i95HhfYsRKkrb7rOO8cr15ijuGEmso5r1g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733718327; 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=M/ZCz9kfZ7wM69tBKKjCzInGaWhLZ4iuYlLAdnziDe8=; b=AcGVyIuK/399xiB5ACcKur9JXEqxZWJqSOQ4Pp0v7xyECaKwE6rc2EVluY7araRcBB0/gN UTnU0MsW/DXAX/g+gMBErTS2kj1ad0+SiAHy60Sy9L0MfjreB40KjtXiN73D33+1excT0Z yC4Sjs8AgGfj4Ub9xPSSP4wGc2RefTHnrgu9TMWUgsHY0YKC2bb/bNYmIgPlRM3HJ1eanq DUWiXN3VbqHfqxtmQ/AugKXtdyRuX7QN2PeR5DHSpvYw+5Q/YgLXrG+7s1p+xyYcVW4IPZ Q8m/gobges5nmHRaBSsbeMD+ocSX7ZBvBed5Mm5CGxi0A7ur45AfRYPOXKd18w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733718327; a=rsa-sha256; cv=none; b=ZZV9PkQ1ID7O7erpxPBpo6gw2pRdmIgp2W1ptFPppAcbCrtZYzoD+68ihQoRawCNzyrZVc npvslQZEwNhZ5cfWPOhBgeiH5LOZguYlGPVZvUAwyKtjLMlQiHfcMhUkrhL0ikFuAxqJiC YOmirCEYsvE4jc9ASPn6INdKN/ehF46MX7zWMaxNAfFMlxSr9ycKAxxC4IdD+5uld4xZ3O JFPKdE7BvVo1+BX5YBjkxK28v+3syXv2Q1E9vT5C0SwwPJaXFejQN6upLzJUYucqRx9SH8 cRwxoKCZp4PrOtwv3hh73WH/7nxjH/qkMZgwBOAt9f+aMG9KvRnFFA+M1M1Elw== 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 4Y68133FKgzN02; Mon, 9 Dec 2024 04:25:27 +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 4B94PRMZ095354; Mon, 9 Dec 2024 04:25:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B94PRTa095353; Mon, 9 Dec 2024 04:25:27 GMT (envelope-from git) Date: Mon, 9 Dec 2024 04:25:27 GMT Message-Id: <202412090425.4B94PRTa095353@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Xin LI Subject: git: 8e1eae2319cd..7277ee24655b - vendor/expat - vendor branch updated 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: delphij X-Git-Repository: src X-Git-Refname: refs/heads/vendor/expat X-Git-Reftype: branch X-Git-Commit: 7277ee24655bd9190ee1131666aebf6ed9d12390 X-Git-Oldrev: 8e1eae2319cd3a651941c88b46d95e8ee8507c6c X-Git-Newrev: 7277ee24655bd9190ee1131666aebf6ed9d12390 Auto-Submitted: auto-generated The branch vendor/expat has been updated by delphij: URL: https://cgit.FreeBSD.org/src/log/?id=8e1eae2319cd..7277ee24655b 7277ee24655b Vendor import of expat 2.6.4. From nobody Mon Dec 9 04:25:27 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 4Y68136VwSz5gC8s for ; Mon, 09 Dec 2024 04:25:27 +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 4Y68134b6xz4Dbd; Mon, 9 Dec 2024 04:25:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733718327; 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=H0tJwhIGGr3zUMYL+62h7Jm0Kw9e4U5mU5Lr4FEQMPc=; b=iO1disP/U31PCUXw43CB/aio3lYajeiIMSKwHLSwmSUlER5XoHntOx/QM1jmUAmZoh9CjA 8Guq9t3g5Tc8EgoBvalqQ146ZUMyLwWVQUEZIRVX2gFZGanBnsO8/ftjKTI5AyLVnqSW/3 BLuPiwasWvILxsEXwBlj6VOU8+B7NvkcD6zIjkNWfZ4FL5UhhUTPlJABgsNWUt+Tv1/o5R hlbWPMcKkTWZQWX70VHdEvLPFNCnB2lXmm/Qv5DrB9Yk+tmqqtEzI5ghREI0P+U9tbplsH 741fbjw9EccpfAlcuU7V+0w5fhnDqbccVqbVGR87R/K93/3hJbLZFz3+S+7IsQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733718327; 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=H0tJwhIGGr3zUMYL+62h7Jm0Kw9e4U5mU5Lr4FEQMPc=; b=bjUjixY0lD9gZvQDjvsd4XRhQX/Erhk0XiUJGUaRb6iz0Ni04td5CBDn4xMNIx4xrA3zqE HVP0MuRDlbuZ7PAbhzXieoS0ZiL5PxlFmd34C4j/9rYvmq+tiiaHT2hTD/vPNcKhsc8y56 NUxuoRMmrRXDYlZ8/dUDrCWXPSauQ0uyHF3Q6ko7kEDOSshOKcSJtc7AY5lNu08otSwJcr iLrBGFbO2B0ecUYJ4o2uWVvD9T0OpADtiF0XDlSXDOA0kc1fj53sirdEswzGY+wX7gdico /n4SDNI5yQo/WP1oZ0q0JYPM0eZP1vASpSCmNOpwOKsi8OzQ7Trc1VK4FEvD0w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733718327; a=rsa-sha256; cv=none; b=vG8LDMED5lAkcS5p5iwhTaGxa004qy2cLSji7qpAVQLdIR+bS1TqyWewkEvAzPhn36JHZo jeNvFTttMQPbHpmliQgIGZThu5TP08+4yCMm1PbjHyd0x8DDIVJMwGoRT0pdIpuTNxDh+X hA1TaXEjobCRHqp2ig5QSQXcIDkbYHYZbjNJOkpJoc3Y+o1h0wA1nHXkZ3OJeA77pSVKAu Ha5ucnv4FjJ4RXfGq+TafVPsgIa0h+Zk97i+IcBZN/LGhjfrN09lW1ucRxHs5kFN8zJmz0 880hg83PhmdcB4VFgOM1MtxoLGDd8wo10J4Fx3SA1a1vk7zKWUkMLTvHqovetQ== 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 4Y68133zkrzNCd; Mon, 9 Dec 2024 04:25:27 +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 4B94PRHn095373; Mon, 9 Dec 2024 04:25:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B94PRd2095372; Mon, 9 Dec 2024 04:25:27 GMT (envelope-from git) Date: Mon, 9 Dec 2024 04:25:27 GMT Message-Id: <202412090425.4B94PRd2095372@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Xin LI Subject: git: 2e82a5ea6ca6 - Create tag vendor/expat/2.6.4 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: delphij X-Git-Repository: src X-Git-Refname: refs/tags/vendor/expat/2.6.4 X-Git-Reftype: annotated tag X-Git-Commit: 2e82a5ea6ca62a87f4b7334a38f674c6ae7e265c Auto-Submitted: auto-generated The annotated tag vendor/expat/2.6.4 has been created by delphij: URL: https://cgit.FreeBSD.org/src/tag/?h=vendor/expat/2.6.4 tag vendor/expat/2.6.4 Tagger: Xin LI TaggerDate: 2024-12-08 19:18:31 +0000 Tag expat 2.6.4 commit 7277ee24655bd9190ee1131666aebf6ed9d12390 Author: Xin LI AuthorDate: 2024-12-08 19:17:41 +0000 Commit: Xin LI CommitDate: 2024-12-08 19:17:41 +0000 Vendor import of expat 2.6.4. From nobody Mon Dec 9 04:25:45 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 4Y681Q0gm8z5gCBr; Mon, 09 Dec 2024 04:25:46 +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 4Y681Q0QfVz4F5K; Mon, 9 Dec 2024 04:25:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733718346; 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=3OipfZjXAznFPy4iAupLm//dgMZhyJ+x6DC0yI7GDiY=; b=kApCCk7CekPxGBRoAudB5UXbz6a3/Ucz4yX4w72kwyfFJpjt2MFA7E3lIc2PCeqaNOOcaF 3pcBuqAcTS4ksKVGzP+/2m4RnOXZH3XsYqyPp9S4O5xK53fg3k/o6feLyQJUvGh7jbBAfS SULeAuvBh4oNJCNDKb304wqBXsJVoAsvYi09xiLrFwxXAnIRdGGAbPfP7DLSVFsANs3v7u K4J+SCP2oOVweoyKueYdMJcibGGUScXH8KG3MMVwOhtIcJQk0gL/zwEhjYXAViDZn17b4b QMPbiL3yna9fuwcLQVf6tC2mly65DnNwuEgAgVSJ30qDU2+aOXQh9IWVYhMeEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733718346; 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=3OipfZjXAznFPy4iAupLm//dgMZhyJ+x6DC0yI7GDiY=; b=c4Gs4cVMHWfgkuLB03ysXpTEdIOkDhO6ME2mfKuah0SXkusEWtpJWxjwL+M7tUMbp9grVy Zw4h445+JUwziQUlyZHbvOE5tTpsVAfvgcSsAuOUFU9RIw7aq2Bf/x6U1XglPQlLqCRduj /Sh0aGbmCt/ZaMeJMbgi9B0wsBnMMDb0bn+j2XrsTISByxr+V7o/nm3VDRhQvoyXhsApUZ F6CNHe/n3yODGf4PQjJWlYbOWycFF41lGeOJgMjiGuyPyT+f8EvVydwIjVpCd0DXhnl/kz NHjsGPrkYHgM1ba45oFodc9/CfIloXQoBi1wu/9VVw6qxO6UBWUl08dCcBGeWA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733718346; a=rsa-sha256; cv=none; b=HqHdINQYMxwUqsIoCQwScMptmH0jN6W1WfnV3PTddBbWSoBAR6sWhu4uTsa6Rjp9j2Ct+X f2x8p4Gu1c41hwbu/ucZ4rNBfq2fzGN71cKxLOFbz52ZGrAiPo8r6YG1QqKgFpWJqxO3PH P3lcIL1wdFD3uZOOGX8Pw8bL9eniBj2szs0rOEsxkOehJW7X0L3mJ294EvU82jdgFjonHP 6dxNNMZ2mZc3yb6vS9hi/q1OA1hie6LPxFCSt5GgrNepXDhGTG2VMjLtzD263bjV9AEVUY WwsnWQ7Y1Pe1yeTJKvRn0WtWsrHmdZasau73V/bBNKQT+JCs7PWtcQNaQgKilw== 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 4Y681Q02T2zMf1; Mon, 9 Dec 2024 04:25:46 +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 4B94Pj0a095596; Mon, 9 Dec 2024 04:25:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B94PjHx095594; Mon, 9 Dec 2024 04:25:45 GMT (envelope-from git) Date: Mon, 9 Dec 2024 04:25:45 GMT Message-Id: <202412090425.4B94PjHx095594@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Xin LI Subject: git: 908f215e80fa - main - MFV: expat 2.6.4. 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: delphij X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 908f215e80fa482aa953c39afa6bb516f561fc00 Auto-Submitted: auto-generated The branch main has been updated by delphij: URL: https://cgit.FreeBSD.org/src/commit/?id=908f215e80fa482aa953c39afa6bb516f561fc00 commit 908f215e80fa482aa953c39afa6bb516f561fc00 Merge: 9114e15a8694 7277ee24655b Author: Xin LI AuthorDate: 2024-12-09 04:24:16 +0000 Commit: Xin LI CommitDate: 2024-12-09 04:25:01 +0000 MFV: expat 2.6.4. MFC after: 2 weeks contrib/expat/Changes | 31 ++++++++++++++++++ contrib/expat/README.md | 47 ++++++++++++++++++++++++--- contrib/expat/configure.ac | 6 ++-- contrib/expat/doc/reference.html | 2 +- contrib/expat/doc/xmlwf.1 | 2 +- contrib/expat/doc/xmlwf.xml | 2 +- contrib/expat/examples/element_declarations.c | 9 ++--- contrib/expat/lib/expat.h | 6 ++-- contrib/expat/lib/xmlparse.c | 18 +++++++--- contrib/expat/tests/basic_tests.c | 17 +++++++--- contrib/expat/tests/common.c | 33 ++----------------- contrib/expat/tests/common.h | 11 +------ contrib/expat/tests/handlers.c | 42 +++++++++++++++++++----- contrib/expat/tests/handlers.h | 17 ++++++++-- contrib/expat/tests/misc_tests.c | 39 ++++++++++++++++++---- contrib/expat/xmlwf/xmlfile.c | 4 ++- lib/libexpat/expat_config.h | 9 ++--- lib/libexpat/libbsdxml.3 | 4 +-- 18 files changed, 206 insertions(+), 93 deletions(-) diff --cc contrib/expat/README.md index 180a68e4abbe,000000000000..23d26dad2b92 mode 100644,000000..100644 --- a/contrib/expat/README.md +++ b/contrib/expat/README.md @@@ -1,276 -1,0 +1,315 @@@ +[![Run Linux CI tasks](https://github.com/libexpat/libexpat/actions/workflows/linux.yml/badge.svg)](https://github.com/libexpat/libexpat/actions/workflows/linux.yml) +[![AppVeyor Build Status](https://ci.appveyor.com/api/projects/status/github/libexpat/libexpat?svg=true)](https://ci.appveyor.com/project/libexpat/libexpat) +[![Packaging status](https://repology.org/badge/tiny-repos/expat.svg)](https://repology.org/metapackage/expat/versions) +[![Downloads SourceForge](https://img.shields.io/sourceforge/dt/expat?label=Downloads%20SourceForge)](https://sourceforge.net/projects/expat/files/) +[![Downloads GitHub](https://img.shields.io/github/downloads/libexpat/libexpat/total?label=Downloads%20GitHub)](https://github.com/libexpat/libexpat/releases) + +> [!CAUTION] +> +> Expat is **understaffed** and without funding. +> There is a [call for help with details](https://github.com/libexpat/libexpat/blob/master/expat/Changes) +> at the top of the `Changes` file. + + - # Expat, Release 2.6.3 ++# Expat, Release 2.6.4 + +This is Expat, a C99 library for parsing +[XML 1.0 Fourth Edition](https://www.w3.org/TR/2006/REC-xml-20060816/), started by +[James Clark](https://en.wikipedia.org/wiki/James_Clark_%28programmer%29) in 1997. +Expat is a stream-oriented XML parser. This means that you register +handlers with the parser before starting the parse. These handlers +are called when the parser discovers the associated structures in the +document being parsed. A start tag is an example of the kind of +structures for which you may register handlers. + +Expat supports the following compilers: + +- GNU GCC >=4.5 +- LLVM Clang >=3.5 +- Microsoft Visual Studio >=16.0/2019 (rolling `${today} minus 5 years`) + +Windows users can use the +[`expat-win32bin-*.*.*.{exe,zip}` download](https://github.com/libexpat/libexpat/releases), +which includes both pre-compiled libraries and executables, and source code for +developers. + +Expat is [free software](https://www.gnu.org/philosophy/free-sw.en.html). +You may copy, distribute, and modify it under the terms of the License +contained in the file +[`COPYING`](https://github.com/libexpat/libexpat/blob/master/expat/COPYING) +distributed with this package. +This license is the same as the MIT/X Consortium license. + + +## Using libexpat in your CMake-Based Project + - There are two ways of using libexpat with CMake: ++There are three documented ways of using libexpat with CMake: + - ### a) Module Mode ++### a) `find_package` with Module Mode + +This approach leverages CMake's own [module `FindEXPAT`](https://cmake.org/cmake/help/latest/module/FindEXPAT.html). + +Notice the *uppercase* `EXPAT` in the following example: + +```cmake +cmake_minimum_required(VERSION 3.0) # or 3.10, see below + +project(hello VERSION 1.0.0) + +find_package(EXPAT 2.2.8 MODULE REQUIRED) + +add_executable(hello + hello.c +) + +# a) for CMake >=3.10 (see CMake's FindEXPAT docs) +target_link_libraries(hello PUBLIC EXPAT::EXPAT) + +# b) for CMake >=3.0 +target_include_directories(hello PRIVATE ${EXPAT_INCLUDE_DIRS}) +target_link_libraries(hello PUBLIC ${EXPAT_LIBRARIES}) +``` + - ### b) Config Mode ++### b) `find_package` with Config Mode + +This approach requires files from… + +- libexpat >=2.2.8 where packaging uses the CMake build system +or +- libexpat >=2.3.0 where packaging uses the GNU Autotools build system + on Linux +or +- libexpat >=2.4.0 where packaging uses the GNU Autotools build system + on macOS or MinGW. + +Notice the *lowercase* `expat` in the following example: + +```cmake +cmake_minimum_required(VERSION 3.0) + +project(hello VERSION 1.0.0) + +find_package(expat 2.2.8 CONFIG REQUIRED char dtd ns) + +add_executable(hello + hello.c +) + +target_link_libraries(hello PUBLIC expat::expat) +``` + ++### c) The `FetchContent` module ++ ++This approach — as demonstrated below — requires CMake >=3.18 for both the ++[`FetchContent` module](https://cmake.org/cmake/help/latest/module/FetchContent.html) ++and its support for the `SOURCE_SUBDIR` option to be available. ++ ++Please note that: ++- Use of the `FetchContent` module with *non-release* SHA1s or `master` ++ of libexpat is neither advised nor considered officially supported. ++- Pinning to a specific commit is great for robust CI. ++- Pinning to a specific commit needs updating every time there is a new ++ release of libexpat — either manually or through automation —, ++ to not miss out on libexpat security updates. ++ ++For an example that pulls in libexpat via Git: ++ ++```cmake ++cmake_minimum_required(VERSION 3.18) ++ ++include(FetchContent) ++ ++project(hello VERSION 1.0.0) ++ ++FetchContent_Declare( ++ expat ++ GIT_REPOSITORY https://github.com/libexpat/libexpat/ ++ GIT_TAG 000000000_GIT_COMMIT_SHA1_HERE_000000000 # i.e. Git tag R_0_Y_Z ++ SOURCE_SUBDIR expat/ ++) ++ ++FetchContent_MakeAvailable(expat) ++ ++add_executable(hello ++ hello.c ++) ++ ++target_link_libraries(hello PUBLIC expat) ++``` ++ + +## Building from a Git Clone + +If you are building Expat from a check-out from the +[Git repository](https://github.com/libexpat/libexpat/), +you need to run a script that generates the configure script using the +GNU autoconf and libtool tools. To do this, you need to have +autoconf 2.58 or newer. Run the script like this: + +```console +./buildconf.sh +``` + +Once this has been done, follow the same instructions as for building +from a source distribution. + + +## Building from a Source Distribution + +### a) Building with the configure script (i.e. GNU Autotools) + +To build Expat from a source distribution, you first run the +configuration shell script in the top level distribution directory: + +```console +./configure +``` + +There are many options which you may provide to configure (which you +can discover by running configure with the `--help` option). But the +one of most interest is the one that sets the installation directory. +By default, the configure script will set things up to install +libexpat into `/usr/local/lib`, `expat.h` into `/usr/local/include`, and +`xmlwf` into `/usr/local/bin`. If, for example, you'd prefer to install +into `/home/me/mystuff/lib`, `/home/me/mystuff/include`, and +`/home/me/mystuff/bin`, you can tell `configure` about that with: + +```console +./configure --prefix=/home/me/mystuff +``` + +Another interesting option is to enable 64-bit integer support for +line and column numbers and the over-all byte index: + +```console +./configure CPPFLAGS=-DXML_LARGE_SIZE +``` + +However, such a modification would be a breaking change to the ABI +and is therefore not recommended for general use — e.g. as part of +a Linux distribution — but rather for builds with special requirements. + +After running the configure script, the `make` command will build +things and `make install` will install things into their proper +location. Have a look at the `Makefile` to learn about additional +`make` options. Note that you need to have write permission into +the directories into which things will be installed. + +If you are interested in building Expat to provide document +information in UTF-16 encoding rather than the default UTF-8, follow +these instructions (after having run `make distclean`). +Please note that we configure with `--without-xmlwf` as xmlwf does not +support this mode of compilation (yet): + +1. Mass-patch `Makefile.am` files to use `libexpatw.la` for a library name: +
+ `find . -name Makefile.am -exec sed + -e 's,libexpat\.la,libexpatw.la,' + -e 's,libexpat_la,libexpatw_la,' + -i.bak {} +` + +1. Run `automake` to re-write `Makefile.in` files:
+ `automake` + +1. For UTF-16 output as unsigned short (and version/error strings as char), + run:
+ `./configure CPPFLAGS=-DXML_UNICODE --without-xmlwf`
+ For UTF-16 output as `wchar_t` (incl. version/error strings), run:
+ `./configure CFLAGS="-g -O2 -fshort-wchar" CPPFLAGS=-DXML_UNICODE_WCHAR_T + --without-xmlwf` +
Note: The latter requires libc compiled with `-fshort-wchar`, as well. + +1. Run `make` (which excludes xmlwf). + +1. Run `make install` (again, excludes xmlwf). + +Using `DESTDIR` is supported. It works as follows: + +```console +make install DESTDIR=/path/to/image +``` + +overrides the in-makefile set `DESTDIR`, because variable-setting priority is + +1. commandline +1. in-makefile +1. environment + +Note: This only applies to the Expat library itself, building UTF-16 versions +of xmlwf and the tests is currently not supported. + +When using Expat with a project using autoconf for configuration, you +can use the probing macro in `conftools/expat.m4` to determine how to +include Expat. See the comments at the top of that file for more +information. + +A reference manual is available in the file `doc/reference.html` in this +distribution. + + +### b) Building with CMake + +The CMake build system is still *experimental* and may replace the primary +build system based on GNU Autotools at some point when it is ready. + + +#### Available Options + +For an idea of the available (non-advanced) options for building with CMake: + +```console +# rm -f CMakeCache.txt ; cmake -D_EXPAT_HELP=ON -LH . | grep -B1 ':.*=' | sed 's,^--$,,' +// Choose the type of build, options are: None Debug Release RelWithDebInfo MinSizeRel ... +CMAKE_BUILD_TYPE:STRING= + +// Install path prefix, prepended onto install directories. +CMAKE_INSTALL_PREFIX:PATH=/usr/local + +// Path to a program. +DOCBOOK_TO_MAN:FILEPATH=/usr/bin/docbook2x-man + +// Build man page for xmlwf +EXPAT_BUILD_DOCS:BOOL=ON + +// Build the examples for expat library +EXPAT_BUILD_EXAMPLES:BOOL=ON + +// Build fuzzers for the expat library +EXPAT_BUILD_FUZZERS:BOOL=OFF + +// Build pkg-config file +EXPAT_BUILD_PKGCONFIG:BOOL=ON + +// Build the tests for expat library +EXPAT_BUILD_TESTS:BOOL=ON + +// Build the xmlwf tool for expat library +EXPAT_BUILD_TOOLS:BOOL=ON + +// Character type to use (char|ushort|wchar_t) [default=char] +EXPAT_CHAR_TYPE:STRING=char + +// Install expat files in cmake install target +EXPAT_ENABLE_INSTALL:BOOL=ON + +// Use /MT flag (static CRT) when compiling in MSVC +EXPAT_MSVC_STATIC_CRT:BOOL=OFF + +// Build fuzzers via ossfuzz for the expat library +EXPAT_OSSFUZZ_BUILD:BOOL=OFF + +// Build a shared expat library +EXPAT_SHARED_LIBS:BOOL=ON + +// Treat all compiler warnings as errors +EXPAT_WARNINGS_AS_ERRORS:BOOL=OFF + +// Make use of getrandom function (ON|OFF|AUTO) [default=AUTO] +EXPAT_WITH_GETRANDOM:STRING=AUTO + +// Utilize libbsd (for arc4random_buf) +EXPAT_WITH_LIBBSD:BOOL=OFF + +// Make use of syscall SYS_getrandom (ON|OFF|AUTO) [default=AUTO] +EXPAT_WITH_SYS_GETRANDOM:STRING=AUTO +``` diff --cc lib/libexpat/expat_config.h index 5d39aeb2e870,000000000000..2bb52a4baa03 mode 100644,000000..100644 --- a/lib/libexpat/expat_config.h +++ b/lib/libexpat/expat_config.h @@@ -1,152 -1,0 +1,149 @@@ +/* expat_config.h. Generated from expat_config.h.in by configure. */ +/* expat_config.h.in. Generated from configure.ac by autoheader. */ + +#ifndef EXPAT_CONFIG_H +#define EXPAT_CONFIG_H 1 + +#include + +/* Define if building universal (internal helper macro) */ +/* #undef AC_APPLE_UNIVERSAL_BUILD */ + +/* 1234 = LILENDIAN, 4321 = BIGENDIAN */ +#if BYTE_ORDER == LITTLE_ENDIAN +#define BYTEORDER 1234 +#else +#define BYTEORDER 4321 +#endif + +/* Define to 1 if you have the `arc4random' function. */ +#define HAVE_ARC4RANDOM 1 + +/* Define to 1 if you have the `arc4random_buf' function. */ +#define HAVE_ARC4RANDOM_BUF 1 + +/* define if the compiler supports basic C++11 syntax */ +#define HAVE_CXX11 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_DLFCN_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_FCNTL_H 1 + +/* Define to 1 if you have the `getpagesize' function. */ +#define HAVE_GETPAGESIZE 1 + +/* Define to 1 if you have the `getrandom' function. */ +#define HAVE_GETRANDOM 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_INTTYPES_H 1 + +/* Define to 1 if you have the `bsd' library (-lbsd). */ +/* #undef HAVE_LIBBSD */ + +/* Define to 1 if you have a working `mmap' system call. */ +#define HAVE_MMAP 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDINT_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDIO_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDLIB_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STRINGS_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STRING_H 1 + +/* Define to 1 if you have `syscall' and `SYS_getrandom'. */ +#define HAVE_SYSCALL_GETRANDOM 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_PARAM_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_STAT_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_TYPES_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_UNISTD_H 1 + +/* Define to the sub-directory where libtool stores uninstalled libraries. */ +#define LT_OBJDIR ".libs/" + +/* Name of package */ +#define PACKAGE "expat" + +/* Define to the address where bug reports for this package should be sent. */ +#define PACKAGE_BUGREPORT "https://github.com/libexpat/libexpat/issues" + +/* Define to the full name of this package. */ +#define PACKAGE_NAME "expat" + +/* Define to the full name and version of this package. */ - #define PACKAGE_STRING "expat 2.6.3" ++#define PACKAGE_STRING "expat 2.6.4" + +/* Define to the one symbol short name of this package. */ +#define PACKAGE_TARNAME "expat" + +/* Define to the home page for this package. */ +#define PACKAGE_URL "" + +/* Define to the version of this package. */ - #define PACKAGE_VERSION "2.6.3" ++#define PACKAGE_VERSION "2.6.4" + +/* Define to 1 if all of the C90 standard headers exist (not just the ones + required in a freestanding environment). This macro is provided for + backward compatibility; new code need not use it. */ +#define STDC_HEADERS 1 + +/* Version number of package */ - #define VERSION "2.6.3" ++#define VERSION "2.6.4" + +/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most + significant byte first (like Motorola and SPARC, unlike Intel). */ +#if defined AC_APPLE_UNIVERSAL_BUILD +# if defined __BIG_ENDIAN__ +# define WORDS_BIGENDIAN 1 +# endif +#else +# ifndef WORDS_BIGENDIAN +/* # undef WORDS_BIGENDIAN */ +# endif +#endif + +/* Define to allow retrieving the byte offsets for attribute names and values. + */ +/* #undef XML_ATTR_INFO */ + +/* Define to specify how much context to retain around the current parse + point, 0 to disable. */ +#define XML_CONTEXT_BYTES 1024 + +/* Define to include code reading entropy from `/dev/urandom'. */ +#define XML_DEV_URANDOM 1 + +/* Define to make parameter entity parsing functionality available. */ +#define XML_DTD 1 + +/* Define as 1/0 to enable/disable support for general entities. */ +#define XML_GE 1 + +/* Define to make XML Namespaces functionality available. */ +#define XML_NS 1 + +/* Define to empty if `const' does not conform to ANSI C. */ +/* #undef const */ + +/* Define to `long int' if does not define. */ +/* #undef off_t */ + - /* Define to `unsigned int' if does not define. */ - /* #undef size_t */ - +#endif // ndef EXPAT_CONFIG_H diff --cc lib/libexpat/libbsdxml.3 index 2ec1f71b58bb,000000000000..21c07d39e5e2 mode 100644,000000..100644 --- a/lib/libexpat/libbsdxml.3 +++ b/lib/libexpat/libbsdxml.3 @@@ -1,67 -1,0 +1,67 @@@ +.\"- +.\" Copyright (c) 2002 Poul-Henning Kamp +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\"/ - .Dd October 1, 2024 ++.Dd December 8, 2024 +.Dt LIBBSDXML 3 +.Os +.Sh NAME +.Nm libbsdxml +.Nd eXpat XML parser library +.Sh SYNOPSIS +.In bsdxml.h +.Sh DESCRIPTION +The +.Nm - library is a verbatim copy of the eXpat XML library version 2.6.3. ++library is a verbatim copy of the eXpat XML library version 2.6.4. +.Pp +The +.Nm +library is intended to be used within the +.Fx +base system only. +Use of the +.Nm +library for other purposes is not supported and discouraged. +.Pp +To avoid version and autoconfiguration issues, the library has been +renamed to +.Nm +rather than retain the original eXpat library and include file names +to prevent confusion and autoconfiguration issues for 3rd party +software. +.Sh SEE ALSO +For full documentation, please see the eXpat webpage at +.Pa http://www.libexpat.org/ . +.Sh AUTHORS +.An -nosplit +The original eXpat was written by +.An James Clark Aq Mt jjc@jclark.com . +.Pp +Subsequently eXpat maintenance and development been taken up by a group +of people under the leadership of +.An Fred Drake Aq Mt fdrake@acm.com , +.An Paul Prescod , +and +.An Clark Cooper . From nobody Mon Dec 9 06:01:17 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 4Y6B7d6qm5z5gJDl for ; Mon, 09 Dec 2024 06:01:17 +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 4Y6B7d6151z4LCK; Mon, 9 Dec 2024 06:01:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733724077; 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=TWgnjuHDeY7Cr2uz109wZzfqxWJfBCbGgJmznHPRfYQ=; b=jJQxW8Pli/O0XXyBDLu8aad/FISIwMmIjSc8WJs1VIsYcr1RiTRGoCRk1EBekfA2GqSBZg no8Oylhj5u8so++Kpmfgu5mQtIwiVYGvYLGS1A554RQC/O34Ojhu86uf+9AyJfTkOp4vyU HB0G0oUbbwMnhUP1wtsrzWZPAOTG1gw4hZh8L3nb1EX+972ZroTLlF03LWSV6MNYwfuKhG PqNsvsRGDcplFZVm91x9uwuLP7HRBQT5fDfdxi27PYLkr1r6Ompyh5UITmT+Sg7GeiSF5E fj2XJ1movDCMhLpDd5jz1qwrCuv2iGKYw6rdpGLxtwHGYUZtAKgd/MK4UBpeAA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733724077; 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=TWgnjuHDeY7Cr2uz109wZzfqxWJfBCbGgJmznHPRfYQ=; b=b6zBKgEfYKpHL9RzWjCcK94pPk28FrLDrhqf0JQnSQRWNQxbeNI2w639OpAGD9JJlXc0J1 Zt0mfs6CUkZc71hxx1h+3qqE0IYbBPzm7g53CQ/mtompeobD6q/fTiuHz8IoxAJhCHa7uO rW9j/GmNqz/b512Yi1f184LiH4SmY0aM0xiuLow0SkW1LDvwz4nGl6K+oKy6XPF8IJB7bM vV/nRNB3T5jM0aNbwr9KnaiQtVRHkjhswwDAkl69EAvAtuwI+VPDYpWw2Jil0frxFPe2Vk rNSjVp/y1M8gULy6Fuzs0bKlic+KjNiwEeYg5UoUDOTKHdBNt5o3nX/th3VtWg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733724077; a=rsa-sha256; cv=none; b=HGy4JGaT2ufGX8WxKFmsW7Vx846AVQnl5Zg6yLP6BtLzWfqKtqTMN4Dsyu6qokOE5yomZU /vWdAab8QSVTCWk3oPbjHEW9fIHi8Tu6BK9cg4rhUnpBRegbrK8P86NITzw/3SyqE18an9 IDFcP2l4osNol/jFFSKhYX4tvbuV9cKESNm836duYJHm48xtBoPkTfaqrLn6IdFbARxywl nlK+bJZbSyEenGhspasLwwqy4cPLC+wRIL6PJd9sp4H89C67Qbu5mB0+9XP0OQ4gzGCh0s QDqObgMbfZz5DDQpxpX/iqO8lqrwKqc43MfMWQMX0rAkds7ahee+gOLd4a6r/Q== 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 4Y6B7d5KS4zPy1; Mon, 9 Dec 2024 06:01:17 +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 4B961Hb9073830; Mon, 9 Dec 2024 06:01:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B961Hxm073829; Mon, 9 Dec 2024 06:01:17 GMT (envelope-from git) Date: Mon, 9 Dec 2024 06:01:17 GMT Message-Id: <202412090601.4B961Hxm073829@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Xin LI Subject: git: d8dcaf73f690 - Create tag vendor/less/v668 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: delphij X-Git-Repository: src X-Git-Refname: refs/tags/vendor/less/v668 X-Git-Reftype: annotated tag X-Git-Commit: d8dcaf73f690f7fcc58d0f88ea2bfbf3eced7dbc Auto-Submitted: auto-generated The annotated tag vendor/less/v668 has been created by delphij: URL: https://cgit.FreeBSD.org/src/tag/?h=vendor/less/v668 tag vendor/less/v668 Tagger: Xin LI TaggerDate: 2024-12-09 04:30:23 +0000 Tag less v668. commit 8c9fd1007159a1cfe994ccf7021688a679a0a39c Author: Xin LI AuthorDate: 2024-12-09 04:30:02 +0000 Commit: Xin LI CommitDate: 2024-12-09 04:30:02 +0000 Vendor import of less v668. From nobody Mon Dec 9 06:01:17 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 4Y6B7d6pGgz5gJH3 for ; Mon, 09 Dec 2024 06:01:17 +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 4Y6B7d5qPXz4LZ2; Mon, 9 Dec 2024 06:01:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733724077; 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=1nC54cMpDog+SAKMPbadaZs7lwqpkT+EC6EVLzm7bsI=; b=dHv1SY47W1jGitZsAkAiTWv9LUEUUGJYuVm3U2uGTpfNIjWavp+sykpSlG1oPDFUbKHcYY gVDMLp0/l8UUq0gNZ7diQ+2lctSQ7OBVFhyRbmdaguKXpUvhb6wF9aKjBfyBU8ns6F1kUU J5rggk9wMBcowPRLHtpkOqHPDo2fibk/666DUhrIFiwX7PLCcSJGdypwoZCIHPGTHS9IST VOtmZpvmxSCMEY4KFNsv5+TILYsJoyFINoz36qRJkqhJCb8p8jS5iJfOaRcjDfMH4HCc0j 5xJchZsgBeW/1HpZjhKng9Y5qiwfDwx/td8obdg6QAEvZJY2S6yqmKg5VbTO4w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733724077; 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=1nC54cMpDog+SAKMPbadaZs7lwqpkT+EC6EVLzm7bsI=; b=VE27A9REWP9+GENCJHMLAuZOgSJpqwpUoMh37JcdRbTaezYFXsohw5z36cD1rwFHfjrHf5 +QSxO/bhL11y79FhqLqlqRJlf/VSTGQpbJBJ3fOy3976j+w9lBtSHOZgs+gqbU8C3OWuk2 Pf5rDHFmp+w7j5f6mgIWNpTFwGgEtrmo8djTy52BgnxqMR+CwtOFmp3cFkxc3Q1kZO9QuX EdaqiK13hlqG+Ygsq7LCb85i/OHtDNBf/valCzNqQaVMI3wrFU27xw3hrXxPnFBhYLgryc cwdHlOgeSVdVI1cgwbaIVkM0YUrMbeuFaxnmRZIAFUwL7p3Cb1Oo9rTmDeU3Bg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733724077; a=rsa-sha256; cv=none; b=i/8nAYKL1wdHYkQ6InhUcT3FN25GQlKFDTt5EuE1OeaH/maqCesSgvTm4Xxu+/1aJyK1f6 2NlZKgwt1KrT/xEBY4enUPZFh3vGwxU89mtC/eNXaHC9d+qB5/Jt34exoMyBBqR7em40xZ luxcMYQDjjACtdEocG6Ie9tWTdqEubjoYmkvoRtr+Ek1FtpBfkN9vbvto00WsEwW5izGQM qcvSijppooAFbeGXy4TT9RJVcIPCRaPMgQT524s7qCM7GwwV8c+u9MleCNgIGIaKpVQsLd wVCT3XK4RICW7Aia1rUkqtbN02ZL3PKPwv4gMvkBkELgXp2njQ5krA4J0/zl6g== 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 4Y6B7d57T8zQGj; Mon, 9 Dec 2024 06:01:17 +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 4B961H1U073811; Mon, 9 Dec 2024 06:01:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B961H1P073810; Mon, 9 Dec 2024 06:01:17 GMT (envelope-from git) Date: Mon, 9 Dec 2024 06:01:17 GMT Message-Id: <202412090601.4B961H1P073810@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Xin LI Subject: git: e8ec4b5d1202..8c9fd1007159 - vendor/less - vendor branch updated 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: delphij X-Git-Repository: src X-Git-Refname: refs/heads/vendor/less X-Git-Reftype: branch X-Git-Commit: 8c9fd1007159a1cfe994ccf7021688a679a0a39c X-Git-Oldrev: e8ec4b5d1202d935bcc6ed75c361b618e8da627f X-Git-Newrev: 8c9fd1007159a1cfe994ccf7021688a679a0a39c Auto-Submitted: auto-generated The branch vendor/less has been updated by delphij: URL: https://cgit.FreeBSD.org/src/log/?id=e8ec4b5d1202..8c9fd1007159 8c9fd1007159 Vendor import of less v668. From nobody Mon Dec 9 06:53:09 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 4Y6CHT4pSlz5gLXr; Mon, 09 Dec 2024 06:53:09 +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 4Y6CHT4TLHz4PVJ; Mon, 9 Dec 2024 06:53:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733727189; 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=qU/KqFXSkux0YeN5uzDz0WfkqzOGoCH29E2eReuPNWk=; b=Kk5QB6n9l1L+a0x6HtGfE3Lf1wHy63cS24fIgYoaI65ntlYSGaIhHT4qvzEMGnmwIjZ2Ay YqrXC+253StmBGn15rZyhSdZOsjGlTZbM3Om4X+S7XOyW2w8kwgdoonUkc+Re1ba5VDC7V KuhKOvDP1hxEHd61nQRbWGbNzvF5z2RA10l6Lcb2eUe+Plc6GxWqMGTz+4uGfRloPrxrcp KzOXE7rWuRus6dOwIqh1tNPdc6tlZ4IXHvDpxv5Gtb0lFaMSwFD98TSR8vjPeggzAaDCkv BK8UP2tM6aLEZqbbV853LihmVUgqU0WUldufBtnfRhBniMaChusMasccFnVktA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733727189; 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=qU/KqFXSkux0YeN5uzDz0WfkqzOGoCH29E2eReuPNWk=; b=NA2y4ZoeAIve5MB5lQ42z7+nBIayH4cq26OeyVw8/GrBFaeZ2oICPt72gG12nZOGZi6osc F/1vi/mhEYc3s3++9lq1/Axivr97MQ567VEtrb6QswowhITqu2NxkpcgDExCTqwmeyeynn bYjr35JM63lBKHs/35u1P1D2BgkDzSFXU9OaMNVfbKMIFQfHjPyYs3Q0X7/7COJ5qzGDUR wcvroaJzrGhrgRBxg6VmLcf8KbrIUgQBsov2UomQosgGIn0fJFMCJSChyyGYY1MsbdROgK 516cF5HbY6raro7zHr3hNIDAPhpak1XjBtBXjCiDxohJjW+vlMQwsqDiLIPRXQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733727189; a=rsa-sha256; cv=none; b=Z7LSWSefm/f5GlhF9lS3yjzTXy7IOv/+H85ujgFYY7YWCxfXuAcI4O+LxEuq3JK0tgDhYz z8hfQWvyNJ4RXAJO6AHxC67K7vuso0AMbtW5rayMLiUfTdyzm9Dw237AI7eusjJn9iEXsB Rb0nyDk3Xf7fkbEowyTf8WhOgkP2hpPAoO9HGPffzPFYxiOyG3nXf/yny4LmvRONS+c4K9 5FZmPijzeDiPJs6fOIv+8uRh3bMOmLv9VxPx1u/Ef8s54xr5tjXdZ9rVshFIEOMQiIHUFQ WX019/EbTuybKQ/ZMbr6GvCye/SZCQyY6DhD05qgdrItQiK2jpRSnR85inkzQg== 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 4Y6CHT44cWzS16; Mon, 9 Dec 2024 06:53:09 +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 4B96r9rv072601; Mon, 9 Dec 2024 06:53:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B96r9Ef072598; Mon, 9 Dec 2024 06:53:09 GMT (envelope-from git) Date: Mon, 9 Dec 2024 06:53:09 GMT Message-Id: <202412090653.4B96r9Ef072598@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Xin LI Subject: git: c77c48892655 - main - MFV: less v668. 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: delphij X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c77c488926555ca344ae3a417544cf7a720e1de1 Auto-Submitted: auto-generated The branch main has been updated by delphij: URL: https://cgit.FreeBSD.org/src/commit/?id=c77c488926555ca344ae3a417544cf7a720e1de1 commit c77c488926555ca344ae3a417544cf7a720e1de1 Merge: 908f215e80fa 8c9fd1007159 Author: Xin LI AuthorDate: 2024-12-09 04:50:00 +0000 Commit: Xin LI CommitDate: 2024-12-09 05:22:12 +0000 MFV: less v668. MFC after: 2 weeks contrib/less/LICENSE | 2 +- contrib/less/NEWS | 134 ++++++++ contrib/less/brac.c | 2 +- contrib/less/ch.c | 131 ++++---- contrib/less/charset.c | 181 +++++----- contrib/less/charset.h | 2 +- contrib/less/cmd.h | 6 +- contrib/less/cmdbuf.c | 217 ++++++------ contrib/less/command.c | 392 ++++++++++++++-------- contrib/less/compose.uni | 2 +- contrib/less/cvt.c | 33 +- contrib/less/decode.c | 376 +++++++++++++++------ contrib/less/edit.c | 362 ++++++++++---------- contrib/less/evar.c | 192 +++++++++++ contrib/less/filename.c | 430 ++++++++++++------------ contrib/less/fmt.uni | 2 +- contrib/less/forwback.c | 84 +++-- contrib/less/funcs.h | 387 ++++++++++++---------- contrib/less/help.c | 54 +-- contrib/less/ifile.c | 18 +- contrib/less/input.c | 109 +++--- contrib/less/jump.c | 51 ++- contrib/less/lang.h | 57 ++++ contrib/less/less.h | 125 ++++--- contrib/less/less.hlp | 52 ++- contrib/less/less.nro | 389 +++++++++++++++++----- contrib/less/lessecho.c | 15 +- contrib/less/lessecho.nro | 6 +- contrib/less/lesskey.c | 73 ++-- contrib/less/lesskey.h | 24 +- contrib/less/lesskey.nro | 38 ++- contrib/less/lesskey_parse.c | 114 +++++-- contrib/less/lglob.h | 2 +- contrib/less/line.c | 440 ++++++++++++++++-------- contrib/less/linenum.c | 83 +++-- contrib/less/lsystem.c | 17 +- contrib/less/main.c | 272 ++++++++++++--- contrib/less/mark.c | 36 +- contrib/less/optfunc.c | 533 ++++++++++++++++++----------- contrib/less/option.c | 262 ++++++++++----- contrib/less/option.h | 9 +- contrib/less/opttbl.c | 113 ++++--- contrib/less/os.c | 64 ++-- contrib/less/output.c | 501 ++++++++++++++++------------ contrib/less/pattern.c | 40 +-- contrib/less/pattern.h | 6 +- contrib/less/pckeys.h | 2 +- contrib/less/position.c | 70 +++- contrib/less/position.h | 2 +- contrib/less/prompt.c | 112 ++++--- contrib/less/regexp.c | 120 +++---- contrib/less/regexp.h | 14 +- contrib/less/screen.c | 744 ++++++++++++++++++++++++++--------------- contrib/less/scrsize.c | 2 +- contrib/less/search.c | 774 +++++++++++++++++++++++++++++++++++++------ contrib/less/signal.c | 22 +- contrib/less/tags.c | 79 ++--- contrib/less/ttyin.c | 47 ++- contrib/less/ubin.uni | 2 +- contrib/less/version.c | 47 ++- contrib/less/wide.uni | 6 +- contrib/less/xbuf.c | 64 +++- contrib/less/xbuf.h | 13 +- usr.bin/less/Makefile | 2 +- usr.bin/less/defines.h | 62 ++-- 65 files changed, 5718 insertions(+), 2904 deletions(-) diff --cc contrib/less/command.c index c1003d55fada,000000000000..27eba082e520 mode 100644,000000..100644 --- a/contrib/less/command.c +++ b/contrib/less/command.c @@@ -1,2096 -1,0 +1,2226 @@@ +/* $FreeBSD$ */ +/* - * Copyright (C) 1984-2023 Mark Nudelman ++ * Copyright (C) 1984-2024 Mark Nudelman + * + * You may distribute under the terms of either the GNU General Public + * License or the Less License, as specified in the README file. + * + * For more information, see the README file. + */ + + +/* + * User-level command processor. + */ + +#include "less.h" +#if MSDOS_COMPILER==WIN32C +#include +#endif +#include "position.h" +#include "option.h" +#include "cmd.h" + +extern int erase_char, erase2_char, kill_char; +extern int sigs; +extern int quit_if_one_screen; +extern int one_screen; - extern int squished; +extern int sc_width; +extern int sc_height; +extern char *kent; +extern int swindow; +extern int jump_sline; +extern int quitting; +extern int wscroll; +extern int top_scroll; +extern int ignore_eoi; - extern int secure; +extern int hshift; +extern int bs_mode; +extern int proc_backspace; +extern int show_attn; +extern int less_is_more; - extern int status_col; +extern POSITION highest_hilite; - extern POSITION start_attnpos; - extern POSITION end_attnpos; +extern char *every_first_cmd; +extern char version[]; +extern struct scrpos initial_scrpos; +extern IFILE curr_ifile; +extern void *ml_search; +extern void *ml_examine; +extern int wheel_lines; - extern int header_lines; +extern int def_search_type; - extern int updown_match; ++extern lbool search_wrapped; +#if SHELL_ESCAPE || PIPEC +extern void *ml_shell; +#endif +#if EDITOR - extern char *editor; - extern char *editproto; ++extern constant char *editproto; ++#endif ++#if OSC8_LINK ++extern char *osc8_uri; +#endif - extern int screen_trashed; /* The screen has been overwritten */ +extern int shift_count; - extern int oldbot; +extern int forw_prompt; +extern int incr_search; +extern int full_screen; +#if MSDOS_COMPILER==WIN32C +extern int utf_mode; ++extern unsigned less_acp; +#endif + +#if SHELL_ESCAPE +static char *shellcmd = NULL; /* For holding last shell command for "!!" */ +#endif +static int mca; /* The multicharacter command (action) */ +static int search_type; /* The previous type of search */ +static int last_search_type; /* Type of last executed search */ +static LINENUM number; /* The number typed by the user */ +static long fraction; /* The fractional part of the number */ +static struct loption *curropt; +static int opt_lower; +static int optflag; - static int optgetname; ++static lbool optgetname; +static POSITION bottompos; +static int save_hshift; +static int save_bs_mode; +static int save_proc_backspace; ++static int screen_trashed_value = 0; ++static lbool literal_char = FALSE; +#if PIPEC +static char pipec; +#endif + +/* Stack of ungotten chars (via ungetcc) */ +struct ungot { + struct ungot *ug_next; - LWCHAR ug_char; ++ char ug_char; ++ lbool ug_end_command; +}; +static struct ungot* ungot = NULL; + - static void multi_search (char *pattern, int n, int silent); ++static void multi_search(constant char *pattern, int n, int silent); + +/* + * Move the cursor to start of prompt line before executing a command. + * This looks nicer if the command takes a long time before + * updating the screen. + */ +static void cmd_exec(void) +{ + clear_attn(); + clear_bot(); + flush(); +} + +/* + * Indicate we are reading a multi-character command. + */ +static void set_mca(int action) +{ + mca = action; + clear_bot(); + clear_cmd(); +} + +/* + * Indicate we are not reading a multi-character command. + */ +static void clear_mca(void) +{ + if (mca == 0) + return; + mca = 0; +} + +/* + * Set up the display to start a new multi-character command. + */ +static void start_mca(int action, constant char *prompt, void *mlist, int cmdflags) +{ + set_mca(action); + cmd_putstr(prompt); + set_mlist(mlist, cmdflags); +} + +public int in_mca(void) +{ + return (mca != 0 && mca != A_PREFIX); +} + +/* + * Set up the display to start a new search command. + */ +static void mca_search1(void) +{ + int i; + +#if HILITE_SEARCH + if (search_type & SRCH_FILTER) + set_mca(A_FILTER); + else +#endif + if (search_type & SRCH_FORW) + set_mca(A_F_SEARCH); + else + set_mca(A_B_SEARCH); + + if (search_type & SRCH_NO_MATCH) + cmd_putstr("Non-match "); + if (search_type & SRCH_FIRST_FILE) + cmd_putstr("First-file "); + if (search_type & SRCH_PAST_EOF) + cmd_putstr("EOF-ignore "); + if (search_type & SRCH_NO_MOVE) + cmd_putstr("Keep-pos "); + if (search_type & SRCH_NO_REGEX) + cmd_putstr("Regex-off "); + if (search_type & SRCH_WRAP) + cmd_putstr("Wrap "); + for (i = 1; i <= NUM_SEARCH_COLORS; i++) + { + if (search_type & SRCH_SUBSEARCH(i)) + { + char buf[INT_STRLEN_BOUND(int)+8]; + SNPRINTF1(buf, sizeof(buf), "Sub-%d ", i); + cmd_putstr(buf); + } + } ++ if (literal_char) ++ cmd_putstr("Lit "); + +#if HILITE_SEARCH + if (search_type & SRCH_FILTER) + cmd_putstr("&/"); + else +#endif + if (search_type & SRCH_FORW) + cmd_putstr("/"); + else + cmd_putstr("?"); + forw_prompt = 0; +} + +static void mca_search(void) +{ + mca_search1(); + set_mlist(ml_search, 0); +} + +/* + * Set up the display to start a new toggle-option command. + */ +static void mca_opt_toggle(void) +{ - int no_prompt; - int flag; - char *dash; ++ int no_prompt = (optflag & OPT_NO_PROMPT); ++ int flag = (optflag & ~OPT_NO_PROMPT); ++ constant char *dash = (flag == OPT_NO_TOGGLE) ? "_" : "-"; + - no_prompt = (optflag & OPT_NO_PROMPT); - flag = (optflag & ~OPT_NO_PROMPT); - dash = (flag == OPT_NO_TOGGLE) ? "_" : "-"; - + set_mca(A_OPT_TOGGLE); + cmd_putstr(dash); + if (optgetname) + cmd_putstr(dash); + if (no_prompt) + cmd_putstr("(P)"); + switch (flag) + { + case OPT_UNSET: + cmd_putstr("+"); + break; + case OPT_SET: + cmd_putstr("!"); + break; + } + forw_prompt = 0; + set_mlist(NULL, 0); +} + +/* + * Execute a multicharacter command. + */ +static void exec_mca(void) +{ - char *cbuf; ++ constant char *cbuf; ++ char *p; + + cmd_exec(); + cbuf = get_cmdbuf(); + if (cbuf == NULL) + return; + + switch (mca) + { + case A_F_SEARCH: + case A_B_SEARCH: + multi_search(cbuf, (int) number, 0); + break; +#if HILITE_SEARCH + case A_FILTER: + search_type ^= SRCH_NO_MATCH; + set_filter_pattern(cbuf, search_type); + break; +#endif + case A_FIRSTCMD: + /* + * Skip leading spaces or + signs in the string. + */ + while (*cbuf == '+' || *cbuf == ' ') + cbuf++; + if (every_first_cmd != NULL) + free(every_first_cmd); + if (*cbuf == '\0') + every_first_cmd = NULL; + else + every_first_cmd = save(cbuf); + break; + case A_OPT_TOGGLE: + toggle_option(curropt, opt_lower, cbuf, optflag); + curropt = NULL; + break; + case A_F_BRACKET: + match_brac(cbuf[0], cbuf[1], 1, (int) number); + break; + case A_B_BRACKET: + match_brac(cbuf[1], cbuf[0], 0, (int) number); + break; +#if EXAMINE + case A_EXAMINE: - if (secure) ++ if (!secure_allow(SF_EXAMINE)) + break; - edit_list(cbuf); ++ p = save(cbuf); ++ edit_list(p); ++ free(p); +#if TAGS + /* If tag structure is loaded then clean it up. */ + cleantags(); +#endif + break; +#endif +#if SHELL_ESCAPE - case A_SHELL: ++ case A_SHELL: { + /* + * !! just uses whatever is in shellcmd. + * Otherwise, copy cmdbuf to shellcmd, + * expanding any special characters ("%" or "#"). + */ ++ constant char *done_msg = (*cbuf == CONTROL('P')) ? NULL : "!done"; ++ if (done_msg == NULL) ++ ++cbuf; + if (*cbuf != '!') + { + if (shellcmd != NULL) + free(shellcmd); + shellcmd = fexpand(cbuf); + } - - if (secure) ++ if (!secure_allow(SF_SHELL)) + break; + if (shellcmd == NULL) - lsystem("", "!done"); - else - lsystem(shellcmd, "!done"); - break; - case A_PSHELL: - if (secure) ++ shellcmd = ""; ++ lsystem(shellcmd, done_msg); ++ break; } ++ case A_PSHELL: { ++ constant char *done_msg = (*cbuf == CONTROL('P')) ? NULL : "#done"; ++ if (done_msg == NULL) ++ ++cbuf; ++ if (!secure_allow(SF_SHELL)) + break; - lsystem(pr_expand(cbuf), "#done"); - break; ++ lsystem(pr_expand(cbuf), done_msg); ++ break; } +#endif +#if PIPEC - case A_PIPE: - if (secure) ++ case A_PIPE: { ++ constant char *done_msg = (*cbuf == CONTROL('P')) ? NULL : "|done"; ++ if (done_msg == NULL) ++ ++cbuf; ++ if (!secure_allow(SF_PIPE)) + break; + (void) pipe_mark(pipec, cbuf); - error("|done", NULL_PARG); - break; ++ if (done_msg != NULL) ++ error(done_msg, NULL_PARG); ++ break; } +#endif + } +} + +/* + * Is a character an erase or kill char? + */ - static int is_erase_char(int c) ++static lbool is_erase_char(char c) +{ + return (c == erase_char || c == erase2_char || c == kill_char); +} + +/* + * Is a character a carriage return or newline? + */ - static int is_newline_char(int c) ++static lbool is_newline_char(char c) +{ + return (c == '\n' || c == '\r'); +} + +/* + * Handle the first char of an option (after the initial dash). + */ - static int mca_opt_first_char(int c) ++static int mca_opt_first_char(char c) +{ + int no_prompt = (optflag & OPT_NO_PROMPT); + int flag = (optflag & ~OPT_NO_PROMPT); + if (flag == OPT_NO_TOGGLE) + { + switch (c) + { + case '_': + /* "__" = long option name. */ + optgetname = TRUE; + mca_opt_toggle(); + return (MCA_MORE); + } + } else + { + switch (c) + { + case '+': + /* "-+" = UNSET. */ + optflag = no_prompt | ((flag == OPT_UNSET) ? + OPT_TOGGLE : OPT_UNSET); + mca_opt_toggle(); + return (MCA_MORE); + case '!': + /* "-!" = SET */ + optflag = no_prompt | ((flag == OPT_SET) ? + OPT_TOGGLE : OPT_SET); + mca_opt_toggle(); + return (MCA_MORE); + case CONTROL('P'): + optflag ^= OPT_NO_PROMPT; + mca_opt_toggle(); + return (MCA_MORE); + case '-': + /* "--" = long option name. */ + optgetname = TRUE; + mca_opt_toggle(); + return (MCA_MORE); + } + } + /* Char was not handled here. */ + return (NO_MCA); +} + +/* + * Add a char to a long option name. + * See if we've got a match for an option name yet. + * If so, display the complete name and stop + * accepting chars until user hits RETURN. + */ - static int mca_opt_nonfirst_char(int c) ++static int mca_opt_nonfirst_char(char c) +{ - char *p; - char *oname; - int err; ++ constant char *p; ++ constant char *oname; ++ lbool ambig; + + if (curropt != NULL) + { + /* + * Already have a match for the name. + * Don't accept anything but erase/kill. + */ + if (is_erase_char(c)) + return (MCA_DONE); + return (MCA_MORE); + } + /* + * Add char to cmd buffer and try to match + * the option name. + */ + if (cmd_char(c) == CC_QUIT) + return (MCA_DONE); + p = get_cmdbuf(); + if (p == NULL) + return (MCA_MORE); + opt_lower = ASCII_IS_LOWER(p[0]); - err = 0; - curropt = findopt_name(&p, &oname, &err); ++ curropt = findopt_name(&p, &oname, &ambig); + if (curropt != NULL) + { + /* + * Got a match. + * Remember the option and + * display the full option name. + */ + cmd_reset(); + mca_opt_toggle(); + for (p = oname; *p != '\0'; p++) + { + c = *p; + if (!opt_lower && ASCII_IS_LOWER(c)) + c = ASCII_TO_UPPER(c); + if (cmd_char(c) != CC_OK) + return (MCA_DONE); + } - } else if (err != OPT_AMBIG) ++ } else if (!ambig) + { + bell(); + } + return (MCA_MORE); +} + +/* + * Handle a char of an option toggle command. + */ - static int mca_opt_char(int c) ++static int mca_opt_char(char c) +{ + PARG parg; + + /* + * This may be a short option (single char), + * or one char of a long option name, + * or one char of the option parameter. + */ + if (curropt == NULL && len_cmdbuf() == 0) + { + int ret = mca_opt_first_char(c); + if (ret != NO_MCA) + return (ret); + } + if (optgetname) + { + /* We're getting a long option name. */ + if (!is_newline_char(c) && c != '=') + return (mca_opt_nonfirst_char(c)); + if (curropt == NULL) + { + parg.p_string = get_cmdbuf(); + if (parg.p_string == NULL) + return (MCA_MORE); + error("There is no --%s option", &parg); + return (MCA_DONE); + } + optgetname = FALSE; + cmd_reset(); + } else + { + if (is_erase_char(c)) + return (NO_MCA); + if (curropt != NULL) + /* We're getting the option parameter. */ + return (NO_MCA); + curropt = findopt(c); + if (curropt == NULL) + { + parg.p_string = propt(c); + error("There is no %s option", &parg); + return (MCA_DONE); + } + opt_lower = ASCII_IS_LOWER(c); + } + /* + * If the option which was entered does not take a + * parameter, toggle the option immediately, + * so user doesn't have to hit RETURN. + */ + if ((optflag & ~OPT_NO_PROMPT) != OPT_TOGGLE || + !opt_has_param(curropt)) + { + toggle_option(curropt, opt_lower, "", optflag); + return (MCA_DONE); + } + /* + * Display a prompt appropriate for the option parameter. + */ - start_mca(A_OPT_TOGGLE, opt_prompt(curropt), (void*)NULL, 0); ++ start_mca(A_OPT_TOGGLE, opt_prompt(curropt), NULL, 0); + return (MCA_MORE); +} + +/* + * Normalize search type. + */ +public int norm_search_type(int st) +{ + /* WRAP and PAST_EOF are mutually exclusive. */ + if ((st & (SRCH_PAST_EOF|SRCH_WRAP)) == (SRCH_PAST_EOF|SRCH_WRAP)) + st ^= SRCH_PAST_EOF; + return st; +} + +/* + * Handle a char of a search command. + */ - static int mca_search_char(int c) ++static int mca_search_char(char c) +{ + int flag = 0; + + /* + * Certain characters as the first char of + * the pattern have special meaning: + * ! Toggle the NO_MATCH flag + * * Toggle the PAST_EOF flag + * @ Toggle the FIRST_FILE flag + */ - if (len_cmdbuf() > 0) ++ if (len_cmdbuf() > 0 || literal_char) ++ { ++ literal_char = FALSE; + return (NO_MCA); ++ } + + switch (c) + { + case '*': + if (less_is_more) + break; + case CONTROL('E'): /* ignore END of file */ + if (mca != A_FILTER) + flag = SRCH_PAST_EOF; + search_type &= ~SRCH_WRAP; + break; + case '@': + if (less_is_more) + break; + case CONTROL('F'): /* FIRST file */ + if (mca != A_FILTER) + flag = SRCH_FIRST_FILE; + break; + case CONTROL('K'): /* KEEP position */ + if (mca != A_FILTER) + flag = SRCH_NO_MOVE; + break; + case CONTROL('S'): { /* SUBSEARCH */ + char buf[INT_STRLEN_BOUND(int)+24]; + SNPRINTF1(buf, sizeof(buf), "Sub-pattern (1-%d):", NUM_SEARCH_COLORS); + clear_bot(); + cmd_putstr(buf); + flush(); + c = getcc(); + if (c >= '1' && c <= '0'+NUM_SEARCH_COLORS) + flag = SRCH_SUBSEARCH(c-'0'); + else + flag = -1; /* calls mca_search() below to repaint */ + break; } + case CONTROL('W'): /* WRAP around */ + if (mca != A_FILTER) + flag = SRCH_WRAP; + break; + case CONTROL('R'): /* Don't use REGULAR EXPRESSIONS */ + flag = SRCH_NO_REGEX; + break; + case CONTROL('N'): /* NOT match */ + case '!': + flag = SRCH_NO_MATCH; + break; ++ case CONTROL('L'): ++ literal_char = TRUE; ++ flag = -1; ++ break; + } + + if (flag != 0) + { + if (flag != -1) + search_type = norm_search_type(search_type ^ flag); + mca_search(); + return (MCA_MORE); + } + return (NO_MCA); +} + +/* + * Handle a character of a multi-character command. + */ - static int mca_char(int c) ++static int mca_char(char c) +{ + int ret; + + switch (mca) + { + case 0: + /* + * We're not in a multicharacter command. + */ + return (NO_MCA); + + case A_PREFIX: + /* + * In the prefix of a command. + * This not considered a multichar command + * (even tho it uses cmdbuf, etc.). + * It is handled in the commands() switch. + */ + return (NO_MCA); + + case A_DIGIT: + /* + * Entering digits of a number. + * Terminated by a non-digit. + */ + if ((c >= '0' && c <= '9') || c == '.') + break; + switch (editchar(c, ECF_PEEK|ECF_NOHISTORY|ECF_NOCOMPLETE|ECF_NORIGHTLEFT)) + { + case A_NOACTION: + /* + * Ignore this char and get another one. + */ + return (MCA_MORE); + case A_INVALID: + /* + * Not part of the number. + * End the number and treat this char + * as a normal command character. + */ + number = cmd_int(&fraction); + clear_mca(); + cmd_accept(); + return (NO_MCA); + } + break; + + case A_OPT_TOGGLE: + ret = mca_opt_char(c); + if (ret != NO_MCA) + return (ret); + break; + + case A_F_SEARCH: + case A_B_SEARCH: + case A_FILTER: + ret = mca_search_char(c); + if (ret != NO_MCA) + return (ret); + break; + + default: + /* Other multicharacter command. */ + break; + } + + /* + * The multichar command is terminated by a newline. + */ + if (is_newline_char(c)) + { + /* + * Execute the command. + */ + exec_mca(); + return (MCA_DONE); + } + + /* + * Append the char to the command buffer. + */ + if (cmd_char(c) == CC_QUIT) + /* + * Abort the multi-char command. + */ + return (MCA_DONE); + + switch (mca) + { + case A_F_BRACKET: + case A_B_BRACKET: + if (len_cmdbuf() >= 2) + { + /* + * Special case for the bracket-matching commands. + * Execute the command after getting exactly two + * characters from the user. + */ + exec_mca(); + return (MCA_DONE); + } + break; + case A_F_SEARCH: + case A_B_SEARCH: + if (incr_search) + { + /* Incremental search: do a search after every input char. */ + int st = (search_type & (SRCH_FORW|SRCH_BACK|SRCH_NO_MATCH|SRCH_NO_REGEX|SRCH_NO_MOVE|SRCH_WRAP|SRCH_SUBSEARCH_ALL)); - char *pattern = get_cmdbuf(); ++ ssize_t save_updown; ++ constant char *pattern = get_cmdbuf(); + if (pattern == NULL) + return (MCA_MORE); + /* + * Must save updown_match because mca_search + * reinits it. That breaks history scrolling. + * {{ This is ugly. mca_search probably shouldn't call set_mlist. }} + */ - int save_updown_match = updown_match; ++ save_updown = save_updown_match(); + cmd_exec(); + if (*pattern == '\0') + { + /* User has backspaced to an empty pattern. */ + undo_search(1); + } else + { + if (search(st | SRCH_INCR, pattern, 1) != 0) + /* No match, invalid pattern, etc. */ + undo_search(1); + } + /* Redraw the search prompt and search string. */ - if (!full_screen) ++ if (is_screen_trashed() || !full_screen) + { + clear(); + repaint(); + } + mca_search1(); - updown_match = save_updown_match; ++ restore_updown_match(save_updown); + cmd_repaint(NULL); + } + break; + } + + /* + * Need another character. + */ + return (MCA_MORE); +} + +/* + * Discard any buffered file data. + */ +static void clear_buffers(void) +{ + if (!(ch_getflags() & CH_CANSEEK)) + return; + ch_flush(); + clr_linenum(); +#if HILITE_SEARCH + clr_hilite(); +#endif +} + ++public void screen_trashed_num(int trashed) ++{ ++ screen_trashed_value = trashed; ++} ++ ++public void screen_trashed(void) ++{ ++ screen_trashed_num(1); ++} ++ ++public int is_screen_trashed(void) ++{ ++ return screen_trashed_value; ++} ++ +/* + * Make sure the screen is displayed. + */ +static void make_display(void) +{ + /* + * If not full_screen, we can't rely on scrolling to fill the screen. + * We need to clear and repaint screen before any change. + */ + if (!full_screen && !(quit_if_one_screen && one_screen)) + clear(); + /* + * If nothing is displayed yet, display starting from initial_scrpos. + */ + if (empty_screen()) + { + if (initial_scrpos.pos == NULL_POSITION) + jump_loc(ch_zero(), 1); + else + jump_loc(initial_scrpos.pos, initial_scrpos.ln); - } else if (screen_trashed || !full_screen) ++ } else if (is_screen_trashed() || !full_screen) + { + int save_top_scroll = top_scroll; + int save_ignore_eoi = ignore_eoi; + top_scroll = 1; + ignore_eoi = 0; - if (screen_trashed == 2) ++ if (is_screen_trashed() == 2) + { + /* Special case used by ignore_eoi: re-open the input file + * and jump to the end of the file. */ + reopen_curr_ifile(); + jump_forw(); + } + repaint(); + top_scroll = save_top_scroll; + ignore_eoi = save_ignore_eoi; *** 3006 LINES SKIPPED *** From nobody Mon Dec 9 09:39:27 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 4Y6GzM4zdMz5g3KF; Mon, 09 Dec 2024 09:39:27 +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 4Y6GzM4B5pz4fcQ; Mon, 9 Dec 2024 09:39:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733737167; 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=6bN0iGWFQ//gbPW4wDAmnBa7P4Ojd1szo27M2Xnnckw=; b=kBwaJ8+1c6Xkyc+HB3351QABrE9zKvaE3/xvBS14mhIBclCn26lLrsZqWeO3+H6LAnxnhe JPS/6Y6kt5cdkE77sPbU1Jp9olQhC1Kh9/jwe8fFqNnDA10i5Cmt2YXKwX1gjy8sI2/Cnr NrCm03r7xiM2J47zEhE4q7XPyP2QQ0/2tW1Gz8bjKZKCD7bWEeJi/dxJtGMMW6yxjS4vsk ip4StrtHWCTM5zc6/SWE1LEEUDLhOuIj/HBIrei78pUn2DE7AkVlwA/SA/M7H1yeulelED a78B20QFeVwi9vEeIlhJQjLYm2v4+DTXkA6mXFUUG7qTqUyu/JLtPakXiFohzA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733737167; 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=6bN0iGWFQ//gbPW4wDAmnBa7P4Ojd1szo27M2Xnnckw=; b=EaDBsh7ZfnNU/cVGtSvbnq3lBQtrUXPol1/PEC7+OlaCQVdi932y7+GsAoYq5qjmGoZ8Dy e0sGKDfq671uIyY49H71DMqfvv3stLBS9+y/aU12YJtlIMDJci5+kpGvB3Y8+20EiNqACv Sw3ToRWhE24VICrVpd8UckVuubT2nY5m90dbeNRvcDX4Z1gspo0lbv3Qg+OnmMEmhBvONl N5wqUWaEcdvqUaWQ7RyT/uh7/v50m64e4CkqosFoHaRdb9o1HGvDy4xFuF+qI1UxYeJ1x5 iWn3i30wAYOCTGdxdRKjQHjGEGqs8938KCTuRKTwAM2xH+JkSP5YfngmqFQiVQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733737167; a=rsa-sha256; cv=none; b=irvV5YhFJIZ+0jJ52kxkyZw71VvWKOD8TGxlPsNIUnsHoubyc3avKi+xmubPxCPAcHWJWE fcwE8mKSprATtwi3n9F1SUTkPVK+rmQGw9TbCG38eeQ2/yYSi1ngZycbVrXjNq3/wVmYhg PwS6tlmpex6eY+MWg1uxlaMOWvSXD8Cxtul0SydXdHDASRsJUtSGl5qhp2zeD+KoKVzgVi yhCWAEZqiooeRECs9dPne8ewJryWEkLFfGTjEZQolpdsTYct00w3jeYnttVclizKC4jChi YN+5y8eXXqjg6CKbuTaVLwuPLlMsTCgnPI519O8uiyndMe4ia7d3tU1GeRNfQg== 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 4Y6GzM3nJJzXcb; Mon, 9 Dec 2024 09:39:27 +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 4B99dRXD072157; Mon, 9 Dec 2024 09:39:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B99dRhr072153; Mon, 9 Dec 2024 09:39:27 GMT (envelope-from git) Date: Mon, 9 Dec 2024 09:39:27 GMT Message-Id: <202412090939.4B99dRhr072153@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kristof Provost Subject: git: 5b59b0c61e29 - main - pfctl: add -T `reset` to touch pfras_tzero only for non-zero entries 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: kp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5b59b0c61e29f684a019afdd2848ffe2d5604e0c Auto-Submitted: auto-generated The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=5b59b0c61e29f684a019afdd2848ffe2d5604e0c commit 5b59b0c61e29f684a019afdd2848ffe2d5604e0c Author: Leonid Evdokimov AuthorDate: 2024-12-06 12:08:54 +0000 Commit: Kristof Provost CommitDate: 2024-12-09 09:36:34 +0000 pfctl: add -T `reset` to touch pfras_tzero only for non-zero entries This will make it easier for scripts to detect idle hosts in tables. PR: 282984 Reviewed by: kp MFC after: 2 weeks --- sbin/pfctl/pfctl.8 | 7 +++- sbin/pfctl/pfctl.c | 2 +- sbin/pfctl/pfctl_radix.c | 2 +- sbin/pfctl/pfctl_table.c | 44 ++++++++++++++++++++++++ tests/sys/netpfil/pf/table.sh | 80 +++++++++++++++++++++++++++++++++++++++++++ 5 files changed, 132 insertions(+), 3 deletions(-) diff --git a/sbin/pfctl/pfctl.8 b/sbin/pfctl/pfctl.8 index 45a6ea525694..00fbda042b7c 100644 --- a/sbin/pfctl/pfctl.8 +++ b/sbin/pfctl/pfctl.8 @@ -24,7 +24,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd November 20, 2024 +.Dd November 25, 2024 .Dt PFCTL 8 .Os .Sh NAME @@ -508,6 +508,11 @@ Show the content (addresses) of a table. Test if the given addresses match a table. .It Fl T Cm zero Op Ar address ... Clear all the statistics of a table, or only for specified addresses. +.It Fl T Cm reset +Clear statistics only for addresses with non-zero statistics. Addresses +with counter values at zero and their +.Dq Cleared +timestamp are left untouched. .It Fl T Cm load Load only the table definitions from .Xr pf.conf 5 . diff --git a/sbin/pfctl/pfctl.c b/sbin/pfctl/pfctl.c index 555c5181eac8..aa3db4619972 100644 --- a/sbin/pfctl/pfctl.c +++ b/sbin/pfctl/pfctl.c @@ -239,7 +239,7 @@ static const char * const showopt_list[] = { static const char * const tblcmdopt_list[] = { "kill", "flush", "add", "delete", "load", "replace", "show", - "test", "zero", "expire", NULL + "test", "zero", "expire", "reset", NULL }; static const char * const debugopt_list[] = { diff --git a/sbin/pfctl/pfctl_radix.c b/sbin/pfctl/pfctl_radix.c index 749e8b4affc9..9bea219a7d81 100644 --- a/sbin/pfctl/pfctl_radix.c +++ b/sbin/pfctl/pfctl_radix.c @@ -292,7 +292,7 @@ pfr_clr_astats(struct pfr_table *tbl, struct pfr_addr *addr, int size, { struct pfioc_table io; - if (size < 0 || (size && !tbl) || addr == NULL) { + if (size < 0 || !tbl || (size && !addr)) { errno = EINVAL; return (-1); } diff --git a/sbin/pfctl/pfctl_table.c b/sbin/pfctl/pfctl_table.c index 25d9b87d8718..aac031ce26b2 100644 --- a/sbin/pfctl/pfctl_table.c +++ b/sbin/pfctl/pfctl_table.c @@ -60,6 +60,7 @@ static void print_table(struct pfr_table *, int, int); static void print_tstats(struct pfr_tstats *, int); static int load_addr(struct pfr_buffer *, int, char *[], char *, int); static void print_addrx(struct pfr_addr *, struct pfr_addr *, int); +static int nonzero_astats(struct pfr_astats *); static void print_astats(struct pfr_astats *, int); static void radix_perror(void); static void xprintf(int, const char *, ...); @@ -293,6 +294,36 @@ pfctl_table(int argc, char *argv[], char *tname, const char *command, if ((opts & PF_OPT_VERBOSE2) || a->pfra_fback) print_addrx(a, NULL, opts & PF_OPT_USEDNS); + } else if (!strcmp(command, "reset")) { + struct pfr_astats *as; + + b.pfrb_type = PFRB_ASTATS; + b2.pfrb_type = PFRB_ADDRS; + if (argc || file != NULL) + usage(); + do { + pfr_buf_grow(&b, b.pfrb_size); + b.pfrb_size = b.pfrb_msize; + RVTEST(pfr_get_astats(&table, b.pfrb_caddr, + &b.pfrb_size, flags)); + } while (b.pfrb_size > b.pfrb_msize); + PFRB_FOREACH(as, &b) { + as->pfras_a.pfra_fback = 0; + if (nonzero_astats(as)) + if (pfr_buf_add(&b2, &as->pfras_a)) + err(1, "duplicate buffer"); + } + + if (opts & PF_OPT_VERBOSE) + flags |= PFR_FLAG_FEEDBACK; + RVTEST(pfr_clr_astats(&table, b2.pfrb_caddr, b2.pfrb_size, + &nzero, flags)); + xprintf(opts, "%d/%d stats cleared", nzero, b.pfrb_size); + if (opts & PF_OPT_VERBOSE) + PFRB_FOREACH(a, &b2) + if ((opts & PF_OPT_VERBOSE2) || a->pfra_fback) + print_addrx(a, NULL, + opts & PF_OPT_USEDNS); } else if (!strcmp(command, "show")) { b.pfrb_type = (opts & PF_OPT_VERBOSE) ? PFRB_ASTATS : PFRB_ADDRS; @@ -484,6 +515,19 @@ print_addrx(struct pfr_addr *ad, struct pfr_addr *rad, int dns) printf("\n"); } +int +nonzero_astats(struct pfr_astats *as) +{ + uint64_t s = 0; + + for (int dir = 0; dir < PFR_DIR_MAX; dir++) + for (int op = 0; op < PFR_OP_ADDR_MAX; op++) + s |= as->pfras_packets[dir][op] | + as->pfras_bytes[dir][op]; + + return (!!s); +} + void print_astats(struct pfr_astats *as, int dns) { diff --git a/tests/sys/netpfil/pf/table.sh b/tests/sys/netpfil/pf/table.sh index 828d76a998be..62c9d66d80ce 100644 --- a/tests/sys/netpfil/pf/table.sh +++ b/tests/sys/netpfil/pf/table.sh @@ -165,6 +165,85 @@ zero_one_cleanup() pft_cleanup } +atf_test_case "reset_nonzero" "cleanup" +reset_nonzero_head() +{ + atf_set descr 'Test zeroing an address with non-zero counters' + atf_set require.user root +} + +reset_nonzero_body() +{ + epair_send=$(vnet_mkepair) + ifconfig ${epair_send}a 192.0.2.1/24 up + ifconfig ${epair_send}a inet alias 192.0.2.3/24 + + vnet_mkjail alcatraz ${epair_send}b + jexec alcatraz ifconfig ${epair_send}b 192.0.2.2/24 up + jexec alcatraz pfctl -e + + pft_set_rules alcatraz \ + "table counters { 192.0.2.1, 192.0.2.3 }" \ + "table counters { }" \ + "block all" \ + "pass in from to any" \ + "pass out from any to " \ + "pass on notReallyAnIf from to " \ + "set skip on lo" + + # Nonexisting table can't be reset, following `-T show`. + atf_check -o ignore \ + -s not-exit:0 \ + -e inline:"pfctl: Table does not exist.\n" \ + jexec alcatraz pfctl -t nonexistent -T reset + + atf_check -o ignore \ + -s exit:0 \ + -e inline:"0/0 stats cleared.\n" \ + jexec alcatraz pfctl -t bar -T reset + + # No-op is a valid operation. + atf_check -s exit:0 \ + -e inline:"0/2 stats cleared.\n" \ + jexec alcatraz pfctl -t foo -T reset + + atf_check -s exit:0 -o ignore ping -c 3 -S 192.0.2.3 192.0.2.2 + + atf_check -s exit:0 -e ignore \ + -o match:'In/Pass:.*'"$TABLE_STATS_ZERO_REGEXP" \ + -o match:'In/Pass:.*'"$TABLE_STATS_NONZERO_REGEXP" \ + -o match:'Out/Pass:.*'"$TABLE_STATS_ZERO_REGEXP" \ + -o match:'Out/Pass:.*'"$TABLE_STATS_NONZERO_REGEXP" \ + jexec alcatraz pfctl -t foo -vvT show + + local clrd uniq + clrd=`jexec alcatraz pfctl -t foo -vvT show | grep -c Cleared` + uniq=`jexec alcatraz pfctl -t foo -vvT show | sort -u | grep -c Cleared` + atf_check_equal "$clrd" 2 + atf_check_equal "$uniq" 1 # time they were added + + atf_check -s exit:0 -e ignore \ + -e inline:"1/2 stats cleared.\n" \ + jexec alcatraz pfctl -t foo -T reset + + clrd=`jexec alcatraz pfctl -t foo -vvT show | grep -c Cleared` + uniq=`jexec alcatraz pfctl -t foo -vvT show | sort -u | grep -c Cleared` + atf_check_equal "$clrd" 2 + atf_check_equal "$uniq" 2 # 192.0.2.3 should get new timestamp + + atf_check -s exit:0 -e ignore \ + -o not-match:'In/Pass:.*'"$TABLE_STATS_NONZERO_REGEXP" \ + -o not-match:'Out/Pass:.*'"$TABLE_STATS_NONZERO_REGEXP" \ + -o match:'In/Pass:.*'"$TABLE_STATS_ZERO_REGEXP" \ + -o match:'Out/Pass:.*'"$TABLE_STATS_ZERO_REGEXP" \ + jexec alcatraz pfctl -t foo -vvT show +} + +reset_nonzero_cleanup() +{ + pft_cleanup +} + atf_test_case "pr251414" "cleanup" pr251414_head() { @@ -381,6 +460,7 @@ atf_init_test_cases() atf_add_test_case "v4_counters" atf_add_test_case "v6_counters" atf_add_test_case "zero_one" + atf_add_test_case "reset_nonzero" atf_add_test_case "pr251414" atf_add_test_case "automatic" atf_add_test_case "network" From nobody Mon Dec 9 12:38:39 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 4Y6Ly72g7Dz5gFWy; Mon, 09 Dec 2024 12:38:39 +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 4Y6Ly726hcz4428; Mon, 9 Dec 2024 12:38:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733747919; 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=AlxSjsy+AVBQA13F2uEKntXoke7ViOgEZcrW0CTOVYo=; b=eyRiNv7Oag7IW31vDtK4KEn1TuHd1mBmnV37pBZjs69MXpc6TPWQ/De67kV6IltVZHsoVt V8vqcLnqy3kBxu2PqmsRuBqrzxgXT3LLFp7MzmaPJNLdNDbcDMHbq41l2uCEZJW7oWOa6Q Ls25g5cHbdSb4j1IHlJxRE4gjmfgQ8HK5FoynZIdMCvd0hmb5INBR+lmFS+odivoyyikbS oGDcgRWBp0wV6gjTFvCBKbDwetnN56C8ffPcfUfSiMuH6OyehNJLqG4dNycQG95ymgA3me GbNK+nbgeLPnd4CULhBTq6rWUX6oY61byhVymRbUh4m5hzUpzs+USUKlpYEdTg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733747919; 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=AlxSjsy+AVBQA13F2uEKntXoke7ViOgEZcrW0CTOVYo=; b=IjP18ENnO/Aeni4cUBXIy/Dqh363ymh9kQDtlNeI/KbIzR/09SyQRecvr1e2LnMQQlboQS PIlixjWZpHMsSDk0D37N9FS9CeWw7hGNP7qCCKrGeINjxpwODiV3fwV3Ba0VCt3vzSWX+T ZvCaNzGW2RD0PuuiGJQBwy7nxZFXnIIb+Vp/wAE4vCq44hHGYt4lpLBVZjN7Qyd8qzsKgb h7ySm3e3WYV0O/3sIQN20gY3JTjE7uPf1maxtB1a1hX6TTbCQRD0fdbXoHrqZK77TQhJcr C2aSw0cAHujmzwwgHdPDAFES4I4N1p3CQ/8z3adnhcXkh+J2jpUsAJuwDiE4DQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733747919; a=rsa-sha256; cv=none; b=VxQjg/xoeeuc8mqQuzp3Q4dCVCPT/ncM7wdhQlct+SwFSsSyTuuVBsMYplugRdUh+iizdS r81z0a4272NUpHINkvLXLa/7xwopIpocmuUcv58pyKOp1Lkqhf+xmtfRgZuJZ4eFckQytu nnDA5EtVVxz0+kFbMzkxK2sJ39UAZ2UNInk9OXybEzPts6s+3fAPuUaNttCfZgWEjrj2Do 3jxCntJdq32zRsGuNz2IqwbXaUbblUXnsnL8+94Bh4MFDumm6Z+4dwnGiqPJIgXPy0i+me WCeg4HI+DeY2j8BxuaywKDhP7mPTy1W84xntT/NSZ67tS8OhAAxV8PdnzABL8g== 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 4Y6Ly71brSzdBs; Mon, 9 Dec 2024 12:38:39 +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 4B9Ccdch007918; Mon, 9 Dec 2024 12:38:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9CcdTl007915; Mon, 9 Dec 2024 12:38:39 GMT (envelope-from git) Date: Mon, 9 Dec 2024 12:38:39 GMT Message-Id: <202412091238.4B9CcdTl007915@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: 4285e024baa8 - main - strptime: Fix day-of-week calculation. 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: des X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 4285e024baa80f81d13cdcc016fdf0721fe57862 Auto-Submitted: auto-generated The branch main has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=4285e024baa80f81d13cdcc016fdf0721fe57862 commit 4285e024baa80f81d13cdcc016fdf0721fe57862 Author: Dag-Erling Smørgrav AuthorDate: 2024-12-09 12:37:45 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2024-12-09 12:38:22 +0000 strptime: Fix day-of-week calculation. The day-of-week calculation used the raw year value without adjusting for TM_YEAR_BASE, so it was off by one for 300 years out of every 400; it just happened to be correct for 1901 through 2000. It also used a loop where a simple addition would have sufficed. While here, simplify our version of Gauss's algorithm, and document that we assume the Gregorian calendar. MFC after: 1 week PR: 282916 Reviewed by: imp, allanjude, philip Differential Revision: https://reviews.freebsd.org/D47977 --- etc/mtree/BSD.tests.dist | 2 ++ lib/libc/stdtime/strptime.3 | 7 ++++- lib/libc/stdtime/strptime.c | 22 ++++++--------- lib/libc/tests/Makefile | 1 + lib/libc/tests/stdtime/Makefile | 7 +++++ lib/libc/tests/stdtime/strptime_test.c | 50 ++++++++++++++++++++++++++++++++++ 6 files changed, 74 insertions(+), 15 deletions(-) diff --git a/etc/mtree/BSD.tests.dist b/etc/mtree/BSD.tests.dist index 1762bbfb7bdc..e0c16bd5e570 100644 --- a/etc/mtree/BSD.tests.dist +++ b/etc/mtree/BSD.tests.dist @@ -382,6 +382,8 @@ .. stdlib .. + stdtime + .. string .. sys diff --git a/lib/libc/stdtime/strptime.3 b/lib/libc/stdtime/strptime.3 index 0dfa33aa29cb..7df73d2d080a 100644 --- a/lib/libc/stdtime/strptime.3 +++ b/lib/libc/stdtime/strptime.3 @@ -23,7 +23,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" " -.Dd October 2, 2014 +.Dd December 9, 2024 .Dt STRPTIME 3 .Os .Sh NAME @@ -135,6 +135,11 @@ function has been contributed by Powerdog Industries. .Pp This man page was written by .An J\(:org Wunsch . +.Sh CAVEATS +The +.Fn strptime +function assumes the Gregorian calendar and will produce incorrect +results for dates prior to its introduction. .Sh BUGS Both the .Fa %e diff --git a/lib/libc/stdtime/strptime.c b/lib/libc/stdtime/strptime.c index c988d968d580..5f1293c7a267 100644 --- a/lib/libc/stdtime/strptime.c +++ b/lib/libc/stdtime/strptime.c @@ -62,17 +62,16 @@ static char * _strptime(const char *, const char *, struct tm *, int *, locale_t #define FLAG_WDAY (1 << 5) /* - * Calculate the week day of the first day of a year. Valid for - * the Gregorian calendar, which began Sept 14, 1752 in the UK - * and its colonies. Ref: - * http://en.wikipedia.org/wiki/Determination_of_the_day_of_the_week + * Gauss's algorithm for the day of the week of the first day of any year + * in the Gregorian calendar. */ - static int first_wday_of(int year) { - return (((2 * (3 - (year / 100) % 4)) + (year % 100) + - ((year % 100) / 4) + (isleap(year) ? 6 : 0) + 1) % 7); + return ((1 + + 5 * ((year - 1) % 4) + + 4 * ((year - 1) % 100) + + 6 * ((year - 1) % 400)) % 7); } static char * @@ -674,13 +673,8 @@ label: flags |= FLAG_MDAY; } if (!(flags & FLAG_WDAY)) { - i = 0; - wday_offset = first_wday_of(tm->tm_year); - while (i++ <= tm->tm_yday) { - if (wday_offset++ >= 6) - wday_offset = 0; - } - tm->tm_wday = wday_offset; + wday_offset = first_wday_of(tm->tm_year + TM_YEAR_BASE); + tm->tm_wday = (wday_offset + tm->tm_yday) % 7; flags |= FLAG_WDAY; } } diff --git a/lib/libc/tests/Makefile b/lib/libc/tests/Makefile index 76a79a9f578b..975c895770ee 100644 --- a/lib/libc/tests/Makefile +++ b/lib/libc/tests/Makefile @@ -16,6 +16,7 @@ TESTS_SUBDIRS+= secure TESTS_SUBDIRS+= setjmp TESTS_SUBDIRS+= stdio TESTS_SUBDIRS+= stdlib +TESTS_SUBDIRS+= stdtime TESTS_SUBDIRS+= string TESTS_SUBDIRS+= sys TESTS_SUBDIRS+= termios diff --git a/lib/libc/tests/stdtime/Makefile b/lib/libc/tests/stdtime/Makefile new file mode 100644 index 000000000000..c7a7f5b9436f --- /dev/null +++ b/lib/libc/tests/stdtime/Makefile @@ -0,0 +1,7 @@ +.include + +ATF_TESTS_C+= strptime_test + +TESTSDIR:= ${TESTSBASE}/${RELDIR:C/libc\/tests/libc/} + +.include diff --git a/lib/libc/tests/stdtime/strptime_test.c b/lib/libc/tests/stdtime/strptime_test.c new file mode 100644 index 000000000000..79a97764999c --- /dev/null +++ b/lib/libc/tests/stdtime/strptime_test.c @@ -0,0 +1,50 @@ +/*- + * Copyright (c) 2024 Dag-Erling Smørgrav + * + * SPDX-License-Identifier: BSD-2-Clause + */ + +#include + +#include + +ATF_TC_WITHOUT_HEAD(dayofweek); +ATF_TC_BODY(dayofweek, tc) +{ + static const struct { + const char *str; + int wday; + } cases[] = { + { "1582-12-20", 1 }, + { "1700-03-01", 1 }, + { "1752-09-14", 4 }, + { "1800-12-31", 3 }, + { "1801-01-01", 4 }, + { "1900-12-31", 1 }, + { "1901-01-01", 2 }, + { "2000-12-31", 0 }, + { "2001-01-01", 1 }, + { "2100-12-31", 5 }, + { "2101-01-01", 6 }, + { "2200-12-31", 3 }, + { "2201-01-01", 4 }, + { }, + }; + struct tm tm; + + for (unsigned int i = 0; cases[i].str != NULL; i++) { + if (strptime(cases[i].str, "%Y-%m-%d", &tm) == NULL) { + atf_tc_fail_nonfatal("failed to parse %s", + cases[i].str); + } else if (tm.tm_wday != cases[i].wday) { + atf_tc_fail_nonfatal("expected %d for %s, got %d", + cases[i].wday, cases[i].str, tm.tm_wday); + } + } +} + +ATF_TP_ADD_TCS(tp) +{ + ATF_TP_ADD_TC(tp, dayofweek); + return (atf_no_error()); +} From nobody Mon Dec 9 12:39:41 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 4Y6LzK4QGgz5gFvT; Mon, 09 Dec 2024 12:39:41 +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 4Y6LzK3yjKz44FB; Mon, 9 Dec 2024 12:39:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733747981; 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=KA16uSGFvc5UWadDhwIN7OTzpkLjrejJAbgLwU836Fc=; b=uY7kjQimowp63ZXUCXb8hQkB/fbgjW9UphpdLQGnjiBiD9Qd6SSN8hbICE+NhCqCmxhGND szoQ/4r6VSbPxycWJvS/9uNZ7c78ptDtp2DCfTV69uyUFCiWx0tay3na8ilc+ZHedk/tF0 orcb+Nc6ZX7kWTMB9083OW3Nsw49SKg2YlaIuZkLy5QY9o0y+GohOHOzuVKiR7+fceCziD 4rdNSGj+XGSuefIGnCgPcaXCO7pZtBk0Un84/MgW8xUDN+r9o3T6A+KWaJ0/X0TF8Egvq5 aQZy+trGxdLlinStIb/g8QaudAjmOr/46befKaZXjN03v1VUrv7CLjMTv4kb8g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733747981; 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=KA16uSGFvc5UWadDhwIN7OTzpkLjrejJAbgLwU836Fc=; b=x2hWxPPHPy5Fd594dpXfnumkxsFKjVx4MJd3KgWrxa3hRn5Ydpqcn6dlMPs4gRqZ3pYFGM 8YZQ6uyXLra08ZCD97xOgfoZvbvFxn/MzQukgEyFm25FVCal4Q3bwLfHu03a2c1Z9Qk/90 PVdxKvEZX8LPxsoXOejBrIY0RWB9lUEuV/j/ik9e+4N34KVSZXbHeYtB4zfLKnXuLBNP/y p/IUsUGUSXC5YtKJ1Q3SGgtlwIiS4uF9Hw1XlgDD510NP/2G6oU0y9Yg5k2mIyBYZ30YPY ymMtwliXQPvGjxMrNhWeLnZz/UAcXoXehIy66iQGLNayX2b+2can5XwWtyEopg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733747981; a=rsa-sha256; cv=none; b=lbUUcnq6o59yUX+XLJehbOJekqB0hESE+d/epMpqGcFv0oD7FQ/cO4MCLiJrAUDhdqkH7w 33ji/2dP1lHH9apNqfn/Qry+U500Qp6Hq6vVK2KalYMfjOS7TKWhCFGnmV8e7jOzu3QlFY FX2T9HII5nLDS47eDgfXuma5R6GkxMEOl3CfbYfAa/pCNhP524Wx17WAiggRg0rfVWHcd1 4C3DNUX9NHO8RSxc7dgHvK923yxWhzpT6u7RZziLrP9u6XCyWK+FiFirW9fCI5tKkf31XZ FHeOJmiSGfe846CNREntIefdTPjfgw3GUxvyzPG/9c2s6aBPL+VLacf7OtLJyA== 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 4Y6LzK3Z3KzdYJ; Mon, 9 Dec 2024 12:39:41 +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 4B9CdfJj008369; Mon, 9 Dec 2024 12:39:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9CdfY6008366; Mon, 9 Dec 2024 12:39:41 GMT (envelope-from git) Date: Mon, 9 Dec 2024 12:39:41 GMT Message-Id: <202412091239.4B9CdfY6008366@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: 0ff2b4a85b66 - stable/14 - Improve reliability of stdout tests. 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: des X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 0ff2b4a85b66d5fb8cf526a47c6367671bc2bc42 Auto-Submitted: auto-generated The branch stable/14 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=0ff2b4a85b66d5fb8cf526a47c6367671bc2bc42 commit 0ff2b4a85b66d5fb8cf526a47c6367671bc2bc42 Author: Dag-Erling Smørgrav AuthorDate: 2024-11-14 19:41:35 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2024-12-09 12:39:21 +0000 Improve reliability of stdout tests. If the test runner is under heavy load, the command we are testing may succeed in printing to stdout before the dummy receiver has terminated. Add a short delay to reduce the likelihood of this happening. MFC after: 1 week Sponsored by: Klara, Inc. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D47572 (cherry picked from commit b697835ce614de2fa30ba066983d7e71c48f34ce) --- usr.bin/asa/tests/asa_test.sh | 1 + usr.bin/cmp/tests/cmp_test2.sh | 1 + usr.bin/env/tests/env_test.sh | 1 + 3 files changed, 3 insertions(+) diff --git a/usr.bin/asa/tests/asa_test.sh b/usr.bin/asa/tests/asa_test.sh index 91515bb55d95..2b8fecb12d98 100644 --- a/usr.bin/asa/tests/asa_test.sh +++ b/usr.bin/asa/tests/asa_test.sh @@ -70,6 +70,7 @@ stdout_head() { stdout_body() { ( trap "" PIPE + sleep 1 echo " $a $b" | asa 2>stderr echo $? >result ) | true diff --git a/usr.bin/cmp/tests/cmp_test2.sh b/usr.bin/cmp/tests/cmp_test2.sh index 2ec6071851d3..bca8fc18a6b8 100755 --- a/usr.bin/cmp/tests/cmp_test2.sh +++ b/usr.bin/cmp/tests/cmp_test2.sh @@ -138,6 +138,7 @@ atf_check_stdout() { ( trap "" PIPE + sleep 1 cmp "$@" 2>stderr echo $? >result ) | true diff --git a/usr.bin/env/tests/env_test.sh b/usr.bin/env/tests/env_test.sh index 2dc8f1a4c911..3210361eb223 100644 --- a/usr.bin/env/tests/env_test.sh +++ b/usr.bin/env/tests/env_test.sh @@ -139,6 +139,7 @@ stdout_body() { ( trap "" PIPE + sleep 1 env 2>stderr echo $? >result ) | true From nobody Mon Dec 9 14:06:16 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 4Y6NvF0x5cz5gLNM; Mon, 09 Dec 2024 14:06:17 +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 4Y6NvF0GxWz4D83; Mon, 9 Dec 2024 14:06:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733753177; 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=QdJBY1EQOkw4dlZThDxW+xHNxfMGdcuEe3jNMHNvgx0=; b=wt4OGn2uXzDPFGQPMlXcTzTUSLZNrJFrml3UAHayZt3zkC/hta4FItp1UgWVgzVlIvnXun Fp23YHsAmnT3kLRM44/3vWeh5yDrRZp7PAmA3Kl9F3CAk1QN68RPNHFOOIuf3Ga+Ph9NOw mR+nH0sD48y30+OSN0bUMXYmiSq69QEET7T/5edAjG3ciajHAtVgdgtn5mTMT2O1AW0h8Q uqrjJ4ybZDPnTTA21vJdQThe/eQ8S1Evi1B0KGkvdmDelp687UX3DSNhFgPqdKmgKu4Pwl o/DwkJLnDOr3a7EaBCuofCZlUSUu/CDukN+cENqinRGw14JomkHQ8BfXkkKBug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733753177; 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=QdJBY1EQOkw4dlZThDxW+xHNxfMGdcuEe3jNMHNvgx0=; b=kPpVAjD0XH8i6zTcJnRU2i/MYj4nxwijs6zD8SeBiY+PJqUHRaxkrI68D+sCLZeHmx1pw8 tn2Gx0NK7/phiiUekKjfUcttRA8gy0cef6M4DaKwZlH/9I+sMQ00c1SVNSeFmNw/JtD2to KizyoXm3tRs6apkwJhItYPMR06f+UAQEgHgb/J69QjF9OPSHiOqpwwGNPPvkX78uAj1CPq WfaVlF2C7l8pt4uacejEuA0mB2NW80PR3lGq1HEoGr3AL6zOu951vpPKEWk3rqvvYs3jso mtEQb4HXqnIEebTprC3rweQxXBCl8vJwOEe/EtrdtkbqQgI0o56J9E2744NcXQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733753177; a=rsa-sha256; cv=none; b=XdlUAMJtzeAsuC0bSHBXItr9FzRW3BVtq4smOiOswlAm1u2QX3vulblqSinOcjHjl8DAzS V2xBpH5RPtVaH4mTFqEXFZwnHsWuk0QRCwuFbpw+n9So05ce0MW4vGiARqYclLS/JvmIas Y3EhkqZnrEUmegH86al0foPSRJpJ4WQvmNeFNPhl5x9j7SvHJU0dwtYJ+4lTC++mLaJGeD 8T4tHMC2mvhh6qmAvJBp6YZsy9PPmbCkCebXqXeW2I0V2k0VGaQkEV+pggabCkPpB1ERvz XNVZF3lYfZo5xE3pK2ZH+hfNHhL3hmXjdDHYSDXSRwzhUByyWgPvTGHhdSNF7w== 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 4Y6NvD6sgqzhFw; Mon, 9 Dec 2024 14:06:16 +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 4B9E6GjZ076285; Mon, 9 Dec 2024 14:06:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9E6GRJ076282; Mon, 9 Dec 2024 14:06:16 GMT (envelope-from git) Date: Mon, 9 Dec 2024 14:06:16 GMT Message-Id: <202412091406.4B9E6GRJ076282@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dimitry Andric Subject: git: 210ff8644846 - stable/13 - depend-cleanup: fix after 99b2ab71c5b6 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: dim X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 210ff86448461dd00dce6f826ae58deb5ae44822 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=210ff86448461dd00dce6f826ae58deb5ae44822 commit 210ff86448461dd00dce6f826ae58deb5ae44822 Author: Dimitry Andric AuthorDate: 2024-12-09 14:05:07 +0000 Commit: Dimitry Andric CommitDate: 2024-12-09 14:05:07 +0000 depend-cleanup: fix after 99b2ab71c5b6 After commit 99b2ab71c5b6 was merged, the stable/13 version of depend-cleanup gives an error "run: not found". This is because the "dry run" functionality from commit 1ec7cb1b5d18 was never merged. Remove the "run" invocation to make the script correctly again, as merging commit 1ec7cb1b5d18 results in many conflicts. Direct commit to stable/13, since this does not apply to other branches. Reported by: des Fixes: 99b2ab71c5b6 --- tools/build/depend-cleanup.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/build/depend-cleanup.sh b/tools/build/depend-cleanup.sh index effb6376d225..fd0d7eb01fe7 100755 --- a/tools/build/depend-cleanup.sh +++ b/tools/build/depend-cleanup.sh @@ -102,6 +102,6 @@ f="$p"/arm_mve_builtin_sema.inc if [ -e "$f" ]; then if grep -q SemaBuiltinConstantArgRange "$f"; then echo "Removing pre-llvm19 clang-tblgen output" - run rm -f "$p"/*.inc + rm -f "$p"/*.inc fi fi From nobody Mon Dec 9 14:47:15 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 4Y6PpW2ZMYz5gNnK; Mon, 09 Dec 2024 14:47:15 +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 4Y6PpW1l41z4JK7; Mon, 9 Dec 2024 14:47:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733755635; 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=ysPORChBMjmvd1jbg0hgDpmtqYXkHG+rL2Dw4uflRP4=; b=aA2JVBnNAuLMFMiigsFKuoCg6L+Oc4TunyrZ3gd9wYlkvdMKYjgfTRfyn1Xgx00+GFWJwH 4ttnqwDfF7/OI6SOO75SD9+1K8CUbg4/uHzocOCrEbfenkIdwQPcZsx2E37Rvz5lpf70yr bnZBicHnTNqSZ3cjBsHZLduF9hKIiX6WfS+qg1YF/wfVRqBVPQBwR45UB1OEuxWRRaSYUb 7tq99xfqyUXucWBWE6dkFy5H+7skfxBMzqfL7vM5FgvGWZAKfrMg0OLELG7Ratsl2dShPG CunqocGj+PH+RmZHHjpXQ8G2WbsBQpnvRtoQnAqUBrPUMzpsfhtPWder6u4nvA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733755635; 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=ysPORChBMjmvd1jbg0hgDpmtqYXkHG+rL2Dw4uflRP4=; b=g5ZVJW9MkAHkPMhSbikAErvQ81Az2TS8K5DKQ2jucPfd0DDaLPbAIxXAci1dLP37bVuSsL 9+2ll0U3pAXp69kqsuXQ8vnwdE3HCWWsp0hHgoklOv6F8z79v80OjkeYvwHs2imbTSSj4H wyXh4btiS3b3O639XW0FTESI+xnHVMIg9MCdpJD0fgx3neId9W+cA4BZQGuLPdQ7quSGme QKYK+/dxpPhFYg7clBmJhULylJUisM2IVNkGgSEe1MCPlTaUMvwLIt6XWDzSITtRZ6oaVd EGCTVA6yQRl27G0lpnz6uvO786urOePDuVQo6K9CSyHTJZPuBXyiDqn5pxUpeA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733755635; a=rsa-sha256; cv=none; b=WIR+r7pfKitm7qASElSeWTbY59H7sHEyOuNL4JFgBeLq/f38gskPq6I+E/p8huIA9tmhwB iy+o4FITnQJ0btqkZHH040Cc2ZGp7BP0Y/xoNDnBlh3V5S8Zqgag8RxC7YvktZqobpNKPB WCQFzPoRL1qtKyGtc1Edzi5M9bbJWkrGKGHTu/Tn8nFu9LFLf7dhmrvwLTgtUMFvAN7swl KeOeeSUyQ/3i69Kq6mkwsInWGjCaOJDGq0P9iPsML31vVsXFZdKXHJyZqUWhpTLivnWGbJ xPrtS83ot4sHuIpZshFgndHG5ONo58TW4WzfewSMAxZMA2W/miGzUC/V4F6uWg== 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 4Y6PpW1C43zj0n; Mon, 9 Dec 2024 14:47:15 +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 4B9ElFgA050289; Mon, 9 Dec 2024 14:47:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9ElFBH050286; Mon, 9 Dec 2024 14:47:15 GMT (envelope-from git) Date: Mon, 9 Dec 2024 14:47:15 GMT Message-Id: <202412091447.4B9ElFBH050286@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 87e140a5c6f8 - main - iwlwifi: avoid (hard) hang on loading module 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: bz X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 87e140a5c6f89eea7ea6320d1ae34566492abfc0 Auto-Submitted: auto-generated The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=87e140a5c6f89eea7ea6320d1ae34566492abfc0 commit 87e140a5c6f89eea7ea6320d1ae34566492abfc0 Author: Bjoern A. Zeeb AuthorDate: 2024-12-08 20:24:10 +0000 Commit: Bjoern A. Zeeb CommitDate: 2024-12-09 14:45:24 +0000 iwlwifi: avoid (hard) hang on loading module For certain users or chipsets (reports were for CNVi devices but we are not sure if this is limited or specific to them) loading if_iwlwifi hangs. The reason for this is that a SYSINIT (module_load_order()) has not yet run in this case and the Linux driver tries to load the chipsets-specific module. On FreeBSD all supported sub-modules are part of if_iwlwifi so we do not have to load them separately but calling into kern_kldload via LinuxKPI request_module while loading the module gives us a hard hang. iwlwifi calls request_module_nowait() so we can simply skip over this and continue and the SYSINIT will do the job later if no other dependencies fail. Sponsored by: The FreeBSD Foundation MFC after: 3 days PR: 282789 Tested by: Ruslan Makhmatkhanov, Pete Wright Differential Revision: https://reviews.freebsd.org/D47994 --- sys/contrib/dev/iwlwifi/iwl-drv.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/sys/contrib/dev/iwlwifi/iwl-drv.c b/sys/contrib/dev/iwlwifi/iwl-drv.c index 7f4746e5591e..61e5c064de80 100644 --- a/sys/contrib/dev/iwlwifi/iwl-drv.c +++ b/sys/contrib/dev/iwlwifi/iwl-drv.c @@ -1749,7 +1749,20 @@ static void iwl_req_fw_callback(const struct firmware *ucode_raw, void *context) goto out_unbind; } } else { +#if defined(__linux__) request_module_nowait("%s", op->name); +#elif defined(__FreeBSD__) + /* + * In FreeBSD if_iwlwifi contains all drv modules in a single + * module. SYSINIT will do the job later. We cannot call + * into kern_kldload() while being called from kern_kldload(): + * LinuxKPI request_module[_nowait] will hang hard. + * Given this is request_module_nowait() we can simply skip it. + */ + if (bootverbose) + printf("%s: module '%s' not yet available; will be" + "initialized in a moment\n", __func__, op->name); +#endif } mutex_unlock(&iwlwifi_opmode_table_mtx); From nobody Mon Dec 9 15:21:41 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 4Y6QZF5CM9z5gQ3Z for ; Mon, 09 Dec 2024 15:21:41 +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 4Y6QZF2tjtz4M0J; Mon, 9 Dec 2024 15:21:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733757701; 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=VBagEMeR7QlpNcSXXyupdlrNWN4M21EYLknS+G2YGoA=; b=GmXxEdd4wwrHARpqaq8b0EnwCVvNqJcBMk51N8Fn7689yZ1q2G6TIo22IgF38Zdg7cKKE1 BnwURAuRwr8xFzOw8Y8h6KnxgA+sGYSAIWTIMUkfdl/6Ujw0RA9T3OXxFETQHNBx/dJJPu zJVjBuVSqXjMrJOJKZb17VVfqVen6lkKL5If+WngDxJ1lQfLgxkC+RuERjcNLEbAeVSSLg VMm7Jq1vMziIsBJDix7l1fwpq7RfoKm3VW2OY1rftN7Kvx6mr0r2dx4eIoyXEWxXx12gZR Sg/qwK0LGud/i1SmIk6Ff1uFHLIdz3GYk6IiG8Dg6Uh0/uXq15obI5QhGf3rXA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733757701; 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=VBagEMeR7QlpNcSXXyupdlrNWN4M21EYLknS+G2YGoA=; b=cH6b2sqKNAixkVt7PcbLBalzWo316jSs7LoJZGBfHdN8aV6Haje66SgkwIClkMzVdPEkDD 8zMvDdZ0F6J8x+gWSu8WvsHePMTJ/a05VtQS7UAVjMIDwh/N5YtJrU1ulKTeCDwOonkoSG YRKhU8xsZ0xQE6AvId/njPUEG1FM/uZiPfZhRvodlfJ1Mb49ob2BOsF1XAfd5fB8bd2Oiy CfX/HJ5PRKSuXJip/Zv7GAtM3ed1QMIjyxmWQSSt6IbP/x6EyBVsU0Pya0p9XPsA7x7H5a 1JHLO75mT0ODYbHF7bX2ud08PNFIHpTpmH5eRRNFJs5QRjT8BtIt3947yzRNhA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733757701; a=rsa-sha256; cv=none; b=C+ugBaRZQmg+0W9u9H1k0iX/V5bWEgqCBjVZwS5gvJcRlt+OqQq82lXvKgKQf40ardAAXL tdpMMeDAEFjv53ISRUQiSjfjQs+1brNgbIW7j3q5XaPUO75S+AnKH5so0eQsqNE6MNKnVo GnfUIxt58kCcTrALox6hAQHEfw9eE9UfNxuxIP2i3VNe++R0CtD2vimucoGGXnASQxEJoT 9aGkXT8lkaE4dt0HsX/WGKK9FDI8BHF7KHf2cNQDrZz7xLIskizbyEh7TIA8V9K+kQLXDv HpcM5ky2xlj6DnYZIW7Dp50Vf6wMVdwbEgzzOCx/faPxhJWEMn59uARq5q8URw== 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 4Y6QZF2CpVzjm8; Mon, 9 Dec 2024 15:21:41 +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 4B9FLfP7021430; Mon, 9 Dec 2024 15:21:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9FLfPm021429; Mon, 9 Dec 2024 15:21:41 GMT (envelope-from git) Date: Mon, 9 Dec 2024 15:21:41 GMT Message-Id: <202412091521.4B9FLfPm021429@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org From: Xin LI Subject: git: 5a7f4fa440e9 - Create tag vendor/xz/5.6.3 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: delphij X-Git-Repository: src X-Git-Refname: refs/tags/vendor/xz/5.6.3 X-Git-Reftype: annotated tag X-Git-Commit: 5a7f4fa440e969fbc7fa92043762d993a4eda81b Auto-Submitted: auto-generated The annotated tag vendor/xz/5.6.3 has been created by delphij: URL: https://cgit.FreeBSD.org/src/tag/?h=vendor/xz/5.6.3 tag vendor/xz/5.6.3 Tagger: Xin LI TaggerDate: 2024-12-09 08:42:51 +0000 Tag xz 5.6.3. commit 956197bcea3aa907f58c3550fa935dec81930f4c Author: Xin LI AuthorDate: 2024-12-09 08:42:41 +0000 Commit: Xin LI CommitDate: 2024-12-09 08:42:41 +0000 Vendor import of xz 5.6.3 (trimmed) From nobody Mon Dec 9 15:22:02 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 4Y6QZk2xQpz5gQns; Mon, 09 Dec 2024 15:22:06 +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 4Y6QZk2n9Jz4MW1; Mon, 9 Dec 2024 15:22:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733757726; 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=ab8LxQJmypWtY/ViAVhMM9P/jR8+FA2qOT6kPJ2kCqo=; b=j0bq9okaSVKVe9n7/V2QB3GwNA12pIQHuKi6zPgEiN69zbgS7IavCxYgSk3Izo0J+abeT0 yAflTZ+bjbumC4aN7beJpbG/R2Dlg4L0w+thBss7vSDanfjYyYkxgf2HFQE1crmn8UJeBI nd3Nsxkk8cC6R6tkdK8iNRY+7F89k1tBwt/0jLuUzqD2hKWE0aNmz9A62cBH50Q7Ar7kW6 PbAx+CFbofXyTXmsxU/Ov8hanoUg0x7zbSxTB95H6rQOO4wumep628Ia76O7XutbTQ3Q+l KYUkcgmZ5EtkB7los+buXb8v+jdofUYPQfkmHVzxeOBw06gRQKvTwiWHPyR/4A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733757726; 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=ab8LxQJmypWtY/ViAVhMM9P/jR8+FA2qOT6kPJ2kCqo=; b=Pnq/j/S0m+1QujRe2+WcpkjFzd9zrsvzcPYgTh10oCdQFENyOulYdSqweq9/MzydtHaLN8 hY5nFWaE3SVowQx0CpS9yb4/XLzgmjVX/WMFGZQ1Z9qszuvwqq7xCt57ZO6bDaurAORNgL P7LC6tGOKackdvQfy5I0CMwfrapol+G3m5TWfCLmoe5eLfbe2Vsa2La7RFv4YB+aSjbS3r 2+8EG2rkqLXM77JOkuq5ZBueZnKsIAfOKhzv7giIdNqp+AcPuV7PiLfYJYzjhuC8212y9A QVjc30P4oPaXcCAfm0HRvF+cZBaTxdfNkRDEpijyLatuxqrQu0e1c1mDmYAEdg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733757726; a=rsa-sha256; cv=none; b=ksCDFm0qjpXp+FXLrHmh0xggpoaWS74MsEALym6F3Af/dKuA6x5pU8fe7U23a4ZO40A2AW 9F+JOdumokkZWm6NgF0pJuS3RIrq6aPcwR+ibtr6dJ/Y2akHrrTVRgwCzsUn3HdlJygh/4 XB3gjmx2WdETvzWC9AIjBoKBWx+G5YP2FwSc8Dibgoo7RqxFdSIfuwj/AKsYRe06xcz6VJ uhsXnx9+pdel7aC9ocz3TNnoSwiosFwiX3uGt+1PKfaXb6LIZVu7uMPEt/5Sp0uw51EeE+ qo/3snRPEKoDEYnBu3U/NOITQmdCAtp/6+zmN4dVAmIANfZbjBRobX/K+KkN1A== 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 4Y6QZk2NRVzk9b; Mon, 9 Dec 2024 15:22:06 +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 4B9FM6hW023855; Mon, 9 Dec 2024 15:22:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9FM2pK023841; Mon, 9 Dec 2024 15:22:02 GMT (envelope-from git) Date: Mon, 9 Dec 2024 15:22:02 GMT Message-Id: <202412091522.4B9FM2pK023841@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Xin LI Subject: git: 26743408e9ff - main - MFV: xz 5.6.3 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: delphij X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 26743408e9ff53ac0e041407c359ed3c17c15596 Auto-Submitted: auto-generated The branch main has been updated by delphij: URL: https://cgit.FreeBSD.org/src/commit/?id=26743408e9ff53ac0e041407c359ed3c17c15596 commit 26743408e9ff53ac0e041407c359ed3c17c15596 Merge: 87e140a5c6f8 956197bcea3a Author: Xin LI AuthorDate: 2024-12-09 15:20:04 +0000 Commit: Xin LI CommitDate: 2024-12-09 15:20:04 +0000 MFV: xz 5.6.3 MFC after: 2 weeks contrib/xz/ChangeLog | 1246 +++++++++++++++++++++ contrib/xz/THANKS | 19 + contrib/xz/src/common/tuklib_integer.h | 14 +- contrib/xz/src/liblzma/api/lzma/container.h | 2 +- contrib/xz/src/liblzma/api/lzma/version.h | 2 +- contrib/xz/src/liblzma/check/crc32_table.c | 10 +- contrib/xz/src/liblzma/check/crc_common.h | 6 +- contrib/xz/src/liblzma/check/crc_x86_clmul.h | 12 +- contrib/xz/src/liblzma/rangecoder/range_decoder.h | 24 +- contrib/xz/src/liblzma/simple/arm64.c | 4 +- contrib/xz/src/lzmainfo/lzmainfo.c | 5 +- contrib/xz/src/xz/args.c | 1 - contrib/xz/src/xz/list.c | 7 + contrib/xz/src/xz/mytime.c | 2 +- contrib/xz/src/xzdec/xzdec.c | 2 +- lib/liblzma/config.h | 9 +- 16 files changed, 1321 insertions(+), 44 deletions(-) diff --cc lib/liblzma/config.h index ca7375dd8725,000000000000..3e51b0b92463 mode 100644,000000..100644 --- a/lib/liblzma/config.h +++ b/lib/liblzma/config.h @@@ -1,643 -1,0 +1,640 @@@ +/* config.h. Generated from config.h.in by configure. */ +/* config.h.in. Generated from configure.ac by autoheader. */ + +/* Define if building universal (internal helper macro) */ +/* #undef AC_APPLE_UNIVERSAL_BUILD */ + +/* How many MiB of RAM to assume if the real amount cannot be determined. */ +#define ASSUME_RAM 128 + +/* Define to 1 if translation of program messages to the user's native + language is requested. */ +/* FreeBSD - disabled intentionally */ +/* #undef ENABLE_NLS */ + +/* Define to 1 if ARM64 CRC32 instruction is supported. See configure.ac for + details. */ +/* #undef HAVE_ARM64_CRC32 */ + +/* Define to 1 if bswap_16 is available. */ +/* #undef HAVE_BSWAP_16 */ + +/* Define to 1 if bswap_32 is available. */ +/* #undef HAVE_BSWAP_32 */ + +/* Define to 1 if bswap_64 is available. */ +/* #undef HAVE_BSWAP_64 */ + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_BYTESWAP_H */ + +#ifndef WITHOUT_CAPSICUM +/* Define to 1 if you have the 'cap_rights_limit' function. */ +#define HAVE_CAP_RIGHTS_LIMIT 1 +#endif + +/* Define to 1 if the system has the type 'CC_SHA256_CTX'. */ +/* #undef HAVE_CC_SHA256_CTX */ + +/* Define to 1 if you have the 'CC_SHA256_Init' function. */ +/* #undef HAVE_CC_SHA256_INIT */ + +/* Define to 1 if you have the Mac OS X function + CFLocaleCopyPreferredLanguages in the CoreFoundation framework. */ +/* #undef HAVE_CFLOCALECOPYPREFERREDLANGUAGES */ + +/* Define to 1 if you have the Mac OS X function CFPreferencesCopyAppValue in + the CoreFoundation framework. */ +/* #undef HAVE_CFPREFERENCESCOPYAPPVALUE */ + +/* Define to 1 if crc32 integrity check is enabled. */ +#define HAVE_CHECK_CRC32 1 + +/* Define to 1 if crc64 integrity check is enabled. */ +#define HAVE_CHECK_CRC64 1 + +/* Define to 1 if sha256 integrity check is enabled. */ +#define HAVE_CHECK_SHA256 1 + +/* Define to 1 if you have the 'clock_gettime' function. */ +#define HAVE_CLOCK_GETTIME 1 + +/* Define to 1 if 'CLOCK_MONOTONIC' is declared in . */ +#define HAVE_CLOCK_MONOTONIC 1 + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_COMMONCRYPTO_COMMONDIGEST_H */ + +/* Define to 1 if you have the header file. */ +#define HAVE_CPUID_H 1 + +/* Define if the GNU dcgettext() function is already present or preinstalled. + */ +/* FreeBSD - disabled intentionally */ +/* #undef HAVE_DCGETTEXT */ + +/* Define to 1 if any of HAVE_DECODER_foo have been defined. */ +#define HAVE_DECODERS 1 + +/* Define to 1 if arm decoder is enabled. */ +#define HAVE_DECODER_ARM 1 + +/* Define to 1 if arm64 decoder is enabled. */ +#define HAVE_DECODER_ARM64 1 + +/* Define to 1 if armthumb decoder is enabled. */ +#define HAVE_DECODER_ARMTHUMB 1 + +/* Define to 1 if delta decoder is enabled. */ +#define HAVE_DECODER_DELTA 1 + +/* Define to 1 if ia64 decoder is enabled. */ +#define HAVE_DECODER_IA64 1 + +/* Define to 1 if lzma1 decoder is enabled. */ +#define HAVE_DECODER_LZMA1 1 + +/* Define to 1 if lzma2 decoder is enabled. */ +#define HAVE_DECODER_LZMA2 1 + +/* Define to 1 if powerpc decoder is enabled. */ +#define HAVE_DECODER_POWERPC 1 + +/* Define to 1 if riscv decoder is enabled. */ +#define HAVE_DECODER_RISCV 1 + +/* Define to 1 if sparc decoder is enabled. */ +#define HAVE_DECODER_SPARC 1 + +/* Define to 1 if x86 decoder is enabled. */ +#define HAVE_DECODER_X86 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_DLFCN_H 1 + +/* Define to 1 if you have the 'elf_aux_info' function. */ +/* #undef HAVE_ELF_AUX_INFO */ + +/* Define to 1 if any of HAVE_ENCODER_foo have been defined. */ +#define HAVE_ENCODERS 1 + +/* Define to 1 if arm encoder is enabled. */ +#define HAVE_ENCODER_ARM 1 + +/* Define to 1 if arm64 encoder is enabled. */ +#define HAVE_ENCODER_ARM64 1 + +/* Define to 1 if armthumb encoder is enabled. */ +#define HAVE_ENCODER_ARMTHUMB 1 + +/* Define to 1 if delta encoder is enabled. */ +#define HAVE_ENCODER_DELTA 1 + +/* Define to 1 if ia64 encoder is enabled. */ +#define HAVE_ENCODER_IA64 1 + +/* Define to 1 if lzma1 encoder is enabled. */ +#define HAVE_ENCODER_LZMA1 1 + +/* Define to 1 if lzma2 encoder is enabled. */ +#define HAVE_ENCODER_LZMA2 1 + +/* Define to 1 if powerpc encoder is enabled. */ +#define HAVE_ENCODER_POWERPC 1 + +/* Define to 1 if riscv encoder is enabled. */ +#define HAVE_ENCODER_RISCV 1 + +/* Define to 1 if sparc encoder is enabled. */ +#define HAVE_ENCODER_SPARC 1 + +/* Define to 1 if x86 encoder is enabled. */ +#define HAVE_ENCODER_X86 1 + +/* Define to 1 if __attribute__((__constructor__)) is supported for functions. + */ +#define HAVE_FUNC_ATTRIBUTE_CONSTRUCTOR 1 + +/* Define to 1 if you have the 'futimens' function. */ +#define HAVE_FUTIMENS 1 + +/* Define to 1 if you have the 'futimes' function. */ +/* #undef HAVE_FUTIMES */ + +/* Define to 1 if you have the 'futimesat' function. */ +/* #undef HAVE_FUTIMESAT */ + +/* Define to 1 if you have the 'getauxval' function. */ +/* #undef HAVE_GETAUXVAL */ + +/* Define to 1 if you have the header file. */ +#define HAVE_GETOPT_H 1 + +/* Define to 1 if you have the 'getopt_long' function. */ +#define HAVE_GETOPT_LONG 1 + +/* Define if the GNU gettext() function is already present or preinstalled. */ +/* FreeBSD - disabled intentionally */ +/* #undef HAVE_GETTEXT */ + +/* Define if you have the iconv() function and it works. */ +#define HAVE_ICONV 1 + +/* Define to 1 if you have the header file. */ +/* FreeBSD - only with clang because the base gcc does not support it */ +#if defined(__clang__) && defined(__FreeBSD__) && defined(__amd64__) +#define HAVE_IMMINTRIN_H 1 +#endif + +/* Define to 1 if you have the header file. */ +#define HAVE_INTTYPES_H 1 + +/* Define to 1 if Linux Landlock is supported. See configure.ac for details. + */ +/* #undef HAVE_LINUX_LANDLOCK */ + +/* Define to 1 if .lz (lzip) decompression support is enabled. */ +#define HAVE_LZIP_DECODER 1 + +/* Define to 1 if mbrtowc and mbstate_t are properly declared. */ +#define HAVE_MBRTOWC 1 + +/* Define to 1 to enable bt2 match finder. */ +#define HAVE_MF_BT2 1 + +/* Define to 1 to enable bt3 match finder. */ +#define HAVE_MF_BT3 1 + +/* Define to 1 to enable bt4 match finder. */ +#define HAVE_MF_BT4 1 + +/* Define to 1 to enable hc3 match finder. */ +#define HAVE_MF_HC3 1 + +/* Define to 1 to enable hc4 match finder. */ +#define HAVE_MF_HC4 1 + - /* Define to 1 if MicroLZMA support is enabled. */ - #define HAVE_MICROLZMA 1 - +/* Define to 1 if you have the header file. */ +/* #undef HAVE_MINIX_CONFIG_H */ + +/* Define to 1 if getopt.h declares extern int optreset. */ +#define HAVE_OPTRESET 1 + +/* Define to 1 if you have the 'pledge' function. */ +/* #undef HAVE_PLEDGE */ + +/* Define to 1 if you have the 'posix_fadvise' function. */ +#define HAVE_POSIX_FADVISE 1 + +/* Define to 1 if 'program_invocation_name' is declared in . */ +/* #undef HAVE_PROGRAM_INVOCATION_NAME */ + +/* Define to 1 if you have the 'pthread_condattr_setclock' function. */ +#define HAVE_PTHREAD_CONDATTR_SETCLOCK 1 + +/* Have PTHREAD_PRIO_INHERIT. */ +#define HAVE_PTHREAD_PRIO_INHERIT 1 + +/* Define to 1 if you have the 'SHA256Init' function. */ +/* #undef HAVE_SHA256INIT */ + +/* Define to 1 if the system has the type 'SHA256_CTX'. */ +#define HAVE_SHA256_CTX 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SHA256_H 1 + +/* Define to 1 if you have the 'SHA256_Init' function. */ +#define HAVE_SHA256_INIT 1 + +/* Define to 1 if the system has the type 'SHA2_CTX'. */ +/* #undef HAVE_SHA2_CTX */ + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_SHA2_H */ + +/* Define to 1 if optimizing for size. */ +/* #undef HAVE_SMALL */ + +/* Define to 1 if stdbool.h conforms to C99. */ +#define HAVE_STDBOOL_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDINT_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDIO_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDLIB_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STRINGS_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STRING_H 1 + +/* Define to 1 if 'st_atimensec' is a member of 'struct stat'. */ +#define HAVE_STRUCT_STAT_ST_ATIMENSEC 1 + +/* Define to 1 if 'st_atimespec.tv_nsec' is a member of 'struct stat'. */ +#define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1 + +/* Define to 1 if 'st_atim.st__tim.tv_nsec' is a member of 'struct stat'. */ +/* #undef HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC */ + +/* Define to 1 if 'st_atim.tv_nsec' is a member of 'struct stat'. */ +#define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1 + +/* Define to 1 if 'st_uatime' is a member of 'struct stat'. */ +/* #undef HAVE_STRUCT_STAT_ST_UATIME */ + +/* Define to 1 to if GNU/Linux-specific details are unconditionally wanted for + symbol versioning. Define to 2 to if these are wanted only if also PIC is + defined (allows building both shared and static liblzma at the same time + with Libtool if neither --with-pic nor --without-pic is used). This define + must be used together with liblzma_linux.map. */ +/* #undef HAVE_SYMBOL_VERSIONS_LINUX */ + +/* Define to 1 if you have the 'sysctlbyname' function. */ +/* #undef HAVE_SYSCTLBYNAME */ + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_SYS_BYTEORDER_H */ + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_CDEFS_H 1 + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_SYS_ENDIAN_H */ + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_PARAM_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_STAT_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_TYPES_H 1 + +/* Define to 1 if the system has the type 'uintptr_t'. */ +#define HAVE_UINTPTR_T 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_UNISTD_H 1 + +/* Define to 1 if _mm_set_epi64x and _mm_clmulepi64_si128 are usable. See + configure.ac for details. */ +#if defined(__FreeBSD__) && defined(__amd64__) +#define HAVE_USABLE_CLMUL 1 +#endif + +/* Define to 1 if you have the 'utime' function. */ +/* #undef HAVE_UTIME */ + +/* Define to 1 if you have the 'utimes' function. */ +/* #undef HAVE_UTIMES */ + +/* Define to 1 or 0, depending whether the compiler supports simple visibility + declarations. */ +#define HAVE_VISIBILITY 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_WCHAR_H 1 + +/* Define to 1 if you have the 'wcwidth' function. */ +#define HAVE_WCWIDTH 1 + +/* Define to 1 if the system has the type '_Bool'. */ +#define HAVE__BOOL 1 + +/* Define to 1 if you have the '_futime' function. */ +/* #undef HAVE__FUTIME */ + +/* Define to 1 if _mm_movemask_epi8 is available. */ +#if defined(__FreeBSD__) && defined(__amd64__) +#define HAVE__MM_MOVEMASK_EPI8 1 +#endif + +/* Define to 1 if the GNU C extension __builtin_assume_aligned is supported. + */ +#define HAVE___BUILTIN_ASSUME_ALIGNED 1 + +/* Define to 1 if the GNU C extensions __builtin_bswap16/32/64 are supported. + */ +#define HAVE___BUILTIN_BSWAPXX 1 + +/* Define to the sub-directory where libtool stores uninstalled libraries. */ +#define LT_OBJDIR ".libs/" + +/* Define to 1 when using POSIX threads (pthreads). */ +#define MYTHREAD_POSIX 1 + +/* Define to 1 when using Windows Vista compatible threads. This uses features + that are not available on Windows XP. */ +/* #undef MYTHREAD_VISTA */ + +/* Define to 1 when using Windows 95 (and thus XP) compatible threads. This + avoids use of features that were added in Windows Vista. */ +/* #undef MYTHREAD_WIN95 */ + +/* Define to 1 to disable debugging code. */ +#define NDEBUG 1 + +/* Name of package */ +#define PACKAGE "xz" + +/* Define to the address where bug reports for this package should be sent. */ +#define PACKAGE_BUGREPORT "xz@tukaani.org" + +/* Define to the full name of this package. */ +#define PACKAGE_NAME "XZ Utils" + +/* Define to the full name and version of this package. */ - #define PACKAGE_STRING "XZ Utils 5.6.2" ++#define PACKAGE_STRING "XZ Utils 5.6.3" + +/* Define to the one symbol short name of this package. */ +#define PACKAGE_TARNAME "xz" + +/* Define to the home page for this package. */ +#define PACKAGE_URL "https://tukaani.org/xz/" + +/* Define to the version of this package. */ - #define PACKAGE_VERSION "5.6.2" ++#define PACKAGE_VERSION "5.6.3" + +/* Define to necessary symbol if this constant uses a non-standard name on + your system. */ +/* #undef PTHREAD_CREATE_JOINABLE */ + +/* The size of 'size_t', as computed by sizeof. */ +#define SIZEOF_SIZE_T 8 + +/* Define to 1 if all of the C89 standard headers exist (not just the ones + required in a freestanding environment). This macro is provided for + backward compatibility; new code need not use it. */ +#define STDC_HEADERS 1 + +/* Define to 1 if the number of available CPU cores can be detected with + cpuset(2). */ +#define TUKLIB_CPUCORES_CPUSET 1 + +/* Define to 1 if the number of available CPU cores can be detected with + pstat_getdynamic(). */ +/* #undef TUKLIB_CPUCORES_PSTAT_GETDYNAMIC */ + +/* Define to 1 if the number of available CPU cores can be detected with + sched_getaffinity() */ +/* #undef TUKLIB_CPUCORES_SCHED_GETAFFINITY */ + +/* Define to 1 if the number of available CPU cores can be detected with + sysconf(_SC_NPROCESSORS_ONLN) or sysconf(_SC_NPROC_ONLN). */ +/* #undef TUKLIB_CPUCORES_SYSCONF */ + +/* Define to 1 if the number of available CPU cores can be detected with + sysctl(). */ +/* #undef TUKLIB_CPUCORES_SYSCTL */ + +/* Define to 1 if the system supports fast unaligned access to 16-bit, 32-bit, + and 64-bit integers. */ +/* FreeBSD - derive from __NO_STRICT_ALIGNMENT */ +/* #undef TUKLIB_FAST_UNALIGNED_ACCESS */ + +/* Define to 1 if the amount of physical memory can be detected with + _system_configuration.physmem. */ +/* #undef TUKLIB_PHYSMEM_AIX */ + +/* Define to 1 if the amount of physical memory can be detected with + getinvent_r(). */ +/* #undef TUKLIB_PHYSMEM_GETINVENT_R */ + +/* Define to 1 if the amount of physical memory can be detected with + getsysinfo(). */ +/* #undef TUKLIB_PHYSMEM_GETSYSINFO */ + +/* Define to 1 if the amount of physical memory can be detected with + pstat_getstatic(). */ +/* #undef TUKLIB_PHYSMEM_PSTAT_GETSTATIC */ + +/* Define to 1 if the amount of physical memory can be detected with + sysconf(_SC_PAGESIZE) and sysconf(_SC_PHYS_PAGES). */ +#define TUKLIB_PHYSMEM_SYSCONF 1 + +/* Define to 1 if the amount of physical memory can be detected with sysctl(). + */ +/* #undef TUKLIB_PHYSMEM_SYSCTL */ + +/* Define to 1 if the amount of physical memory can be detected with Linux + sysinfo(). */ +/* #undef TUKLIB_PHYSMEM_SYSINFO */ + +/* Define to 1 to use unsafe type punning, e.g. char *x = ...; *(int *)x = + 123; which violates strict aliasing rules and thus is undefined behavior + and might result in broken code. */ +/* #undef TUKLIB_USE_UNSAFE_TYPE_PUNNING */ + +/* Enable extensions on AIX, Interix, z/OS. */ +#ifndef _ALL_SOURCE +# define _ALL_SOURCE 1 +#endif +/* Enable general extensions on macOS. */ +#ifndef _DARWIN_C_SOURCE +# define _DARWIN_C_SOURCE 1 +#endif +/* Enable general extensions on Solaris. */ +#ifndef __EXTENSIONS__ +# define __EXTENSIONS__ 1 +#endif +/* Enable GNU extensions on systems that have them. */ +#ifndef _GNU_SOURCE +# define _GNU_SOURCE 1 +#endif +/* Enable X/Open compliant socket functions that do not require linking + with -lxnet on HP-UX 11.11. */ +#ifndef _HPUX_ALT_XOPEN_SOCKET_API +# define _HPUX_ALT_XOPEN_SOCKET_API 1 +#endif +/* Identify the host operating system as Minix. + This macro does not affect the system headers' behavior. + A future release of Autoconf may stop defining this macro. */ +#ifndef _MINIX +/* # undef _MINIX */ +#endif +/* Enable general extensions on NetBSD. + Enable NetBSD compatibility extensions on Minix. */ +#ifndef _NETBSD_SOURCE +# define _NETBSD_SOURCE 1 +#endif +/* Enable OpenBSD compatibility extensions on NetBSD. + Oddly enough, this does nothing on OpenBSD. */ +#ifndef _OPENBSD_SOURCE +# define _OPENBSD_SOURCE 1 +#endif +/* Define to 1 if needed for POSIX-compatible behavior. */ +#ifndef _POSIX_SOURCE +/* # undef _POSIX_SOURCE */ +#endif +/* Define to 2 if needed for POSIX-compatible behavior. */ +#ifndef _POSIX_1_SOURCE +/* # undef _POSIX_1_SOURCE */ +#endif +/* Enable POSIX-compatible threading on Solaris. */ +#ifndef _POSIX_PTHREAD_SEMANTICS +# define _POSIX_PTHREAD_SEMANTICS 1 +#endif +/* Enable extensions specified by ISO/IEC TS 18661-5:2014. */ +#ifndef __STDC_WANT_IEC_60559_ATTRIBS_EXT__ +# define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1 +#endif +/* Enable extensions specified by ISO/IEC TS 18661-1:2014. */ +#ifndef __STDC_WANT_IEC_60559_BFP_EXT__ +# define __STDC_WANT_IEC_60559_BFP_EXT__ 1 +#endif +/* Enable extensions specified by ISO/IEC TS 18661-2:2015. */ +#ifndef __STDC_WANT_IEC_60559_DFP_EXT__ +# define __STDC_WANT_IEC_60559_DFP_EXT__ 1 +#endif +/* Enable extensions specified by C23 Annex F. */ +#ifndef __STDC_WANT_IEC_60559_EXT__ +# define __STDC_WANT_IEC_60559_EXT__ 1 +#endif +/* Enable extensions specified by ISO/IEC TS 18661-4:2015. */ +#ifndef __STDC_WANT_IEC_60559_FUNCS_EXT__ +# define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1 +#endif +/* Enable extensions specified by C23 Annex H and ISO/IEC TS 18661-3:2015. */ +#ifndef __STDC_WANT_IEC_60559_TYPES_EXT__ +# define __STDC_WANT_IEC_60559_TYPES_EXT__ 1 +#endif +/* Enable extensions specified by ISO/IEC TR 24731-2:2010. */ +#ifndef __STDC_WANT_LIB_EXT2__ +# define __STDC_WANT_LIB_EXT2__ 1 +#endif +/* Enable extensions specified by ISO/IEC 24747:2009. */ +#ifndef __STDC_WANT_MATH_SPEC_FUNCS__ +# define __STDC_WANT_MATH_SPEC_FUNCS__ 1 +#endif +/* Enable extensions on HP NonStop. */ +#ifndef _TANDEM_SOURCE +# define _TANDEM_SOURCE 1 +#endif +/* Enable X/Open extensions. Define to 500 only if necessary + to make mbstate_t available. */ +#ifndef _XOPEN_SOURCE +/* # undef _XOPEN_SOURCE */ +#endif + + +/* Version number of package */ - #define VERSION "5.6.2" ++#define VERSION "5.6.3" + +/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most + significant byte first (like Motorola and SPARC, unlike Intel). */ +#if defined(__FreeBSD__) +#include +#if defined(__NO_STRICT_ALIGNMENT) +#define TUKLIB_FAST_UNALIGNED_ACCESS 1 +#endif +#include +#if _BYTE_ORDER == _BIG_ENDIAN +# define WORDS_BIGENDIAN 1 +#endif +#endif + +/* Number of bits in a file offset, on hosts where this is settable. */ +/* #undef _FILE_OFFSET_BITS */ + +/* Define to 1 on platforms where this makes off_t a 64-bit type. */ +/* #undef _LARGE_FILES */ + +/* Number of bits in time_t, on hosts where this is settable. */ +/* #undef _TIME_BITS */ + +/* Define for Solaris 2.5.1 so the uint32_t typedef from , + , or is not used. If the typedef were allowed, the + #define below would cause a syntax error. */ +/* #undef _UINT32_T */ + +/* Define for Solaris 2.5.1 so the uint64_t typedef from , + , or is not used. If the typedef were allowed, the + #define below would cause a syntax error. */ +/* #undef _UINT64_T */ + +/* Define for Solaris 2.5.1 so the uint8_t typedef from , + , or is not used. If the typedef were allowed, the + #define below would cause a syntax error. */ +/* #undef _UINT8_T */ + +/* Define to rpl_ if the getopt replacement functions and variables should be + used. */ +/* #undef __GETOPT_PREFIX */ + +/* Define to 1 on platforms where this makes time_t a 64-bit type. */ +/* #undef __MINGW_USE_VC2005_COMPAT */ + +/* Define to the type of a signed integer type of width exactly 32 bits if + such a type exists and the standard includes do not define it. */ +/* #undef int32_t */ + +/* Define to the type of a signed integer type of width exactly 64 bits if + such a type exists and the standard includes do not define it. */ +/* #undef int64_t */ + +/* Define to the type of an unsigned integer type of width exactly 16 bits if + such a type exists and the standard includes do not define it. */ +/* #undef uint16_t */ + +/* Define to the type of an unsigned integer type of width exactly 32 bits if + such a type exists and the standard includes do not define it. */ +/* #undef uint32_t */ + +/* Define to the type of an unsigned integer type of width exactly 64 bits if + such a type exists and the standard includes do not define it. */ +/* #undef uint64_t */ + +/* Define to the type of an unsigned integer type of width exactly 8 bits if + such a type exists and the standard includes do not define it. */ +/* #undef uint8_t */ + +/* Define to the type of an unsigned integer type wide enough to hold a + pointer, if such a type exists, and if the system does not define it. */ +/* #undef uintptr_t */ From nobody Mon Dec 9 15:45:04 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 4Y6R5D2mGDz5gS3W; Mon, 09 Dec 2024 15:45:04 +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 4Y6R5D2Ftzz4Nrb; Mon, 9 Dec 2024 15:45:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733759104; 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=KJd7NIL50KkuRmhComfUED8MLF76pN1nc8j30Tein1c=; b=RC/HdvEEjNYqeDn0B3hBcHdV5WokycJjp2n3TyB9ksWFNfe5zNzJ0Rpnfbcp2YNtO72Cga x+1g0nlQYT2p9capJ6GD7JLqEntl33YEvXJ6YpXiCEac5Z9OkUISWkJ2xvpjqaWBmo5mKE Y6Es9WRNWCnE+Ye3Qu56Xu/CU3a2RRTMU9CR+oRbUxcLDdap5VNhWshu1EF0YucuAZeTqS Xx9zNWtU/HDRLberwm9Ds4n1WuVvlNNdxuWCO6y7zrFJvruivmnvdtcARZ+kv3Wf4Y62yj 62JusPEvLriszTbvgNpjvqCCCNxKyt0e0LIb98ZowaMC70s0q1IZNRHylHh6dQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733759104; 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=KJd7NIL50KkuRmhComfUED8MLF76pN1nc8j30Tein1c=; b=MUK0vTtv+ntuEfWrWhWdEW7RkilyX59qcW2CUvfxCcZHSLo2Gf/mFO0M52Q2EkJBOhyuro RphCsERT2+RMeDdxShgRuS17ySJ6QcC0sVc9bm2heG96fk/vLvpJy7b6Onosi9qqw6vOax bPWndFYGa8gODVN4q+Am/skO1UKmajcdBylGBY1Fn+EzjcU1+k1ekdTdYSdnUFFCFfDo63 JfYapYKFVaOHlhjcZ2oB5zLAmDXvOuJGj39KxMlGUCaF8fNvWr9wDayLF5CmrE0yHVUI/o zR6gTOgCuj+Vt8jqPYEc16MqifiBNVj0gT4ADg0xqE45UjXHC8H35VLUoASiHg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733759104; a=rsa-sha256; cv=none; b=nbf7/EudrizkFQNmYoyJBLdh34BMJnHO5CZFF2S3C28KhfCWXFGN+ch/T1yp2i7tG8BVwt if/cNkM/T6zC/fxVqDtkh48X9mQ8pQj+mmlPnPM/6v9xpKb21so8rD97UQAo1DVV25FXJ4 CUwq7FVzC46nTyMH8ZfsILtcS6elFDHXniluZrfumGVHkUI9T/LdJa5+ohejISSJdMdozq Vh81kX4s8cZNxRmLJy9hy9V+JaB3kL6rdMQStJMEUNUsf6QYVS0kbZ4d6Z4Ojg38nHX+sa +k0E3dTxmPfQHQKSETKNUAu25TwECa5hE8Tpzr6HbBxfzcPp5MMByynb6HAE6A== 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 4Y6R5D1spNzkZZ; Mon, 9 Dec 2024 15:45:04 +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 4B9Fj4dJ062460; Mon, 9 Dec 2024 15:45:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9Fj4MS062457; Mon, 9 Dec 2024 15:45:04 GMT (envelope-from git) Date: Mon, 9 Dec 2024 15:45:04 GMT Message-Id: <202412091545.4B9Fj4MS062457@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Andrew Turner Subject: git: 65ec52e6e09f - main - buf_ring: Remove unneeded memory barriers 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: andrew X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 65ec52e6e09f8b2a610a26638ff65a35ee5557b4 Auto-Submitted: auto-generated The branch main has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=65ec52e6e09f8b2a610a26638ff65a35ee5557b4 commit 65ec52e6e09f8b2a610a26638ff65a35ee5557b4 Author: Andrew Turner AuthorDate: 2024-12-09 15:04:37 +0000 Commit: Andrew Turner CommitDate: 2024-12-09 15:44:30 +0000 buf_ring: Remove unneeded memory barriers We no longer need a memory barrier on the compare and set operations. If these fail then there are appropriate barriers on the loads earlier in the loop, and if they succeed then no other threads can be accessing the br_ring entry so any store to it is safe. Reviewed by: alc Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D46381 --- sys/sys/buf_ring.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/sys/buf_ring.h b/sys/sys/buf_ring.h index 9a4bfa9fb549..ab7e683ed0e9 100644 --- a/sys/sys/buf_ring.h +++ b/sys/sys/buf_ring.h @@ -116,7 +116,7 @@ buf_ring_enqueue(struct buf_ring *br, void *buf) } continue; } - } while (!atomic_cmpset_acq_32(&br->br_prod_head, prod_head, prod_next)); + } while (!atomic_cmpset_32(&br->br_prod_head, prod_head, prod_next)); prod_idx = prod_head & mask; #ifdef DEBUG_BUFRING if (br->br_ring[prod_idx] != NULL) @@ -163,7 +163,7 @@ buf_ring_dequeue_mc(struct buf_ring *br) critical_exit(); return (NULL); } - } while (!atomic_cmpset_acq_32(&br->br_cons_head, cons_head, cons_next)); + } while (!atomic_cmpset_32(&br->br_cons_head, cons_head, cons_next)); cons_idx = cons_head & mask; buf = br->br_ring[cons_idx]; From nobody Mon Dec 9 15:45:05 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 4Y6R5F43pkz5gRpR; Mon, 09 Dec 2024 15:45:05 +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 4Y6R5F3BXXz4PBt; Mon, 9 Dec 2024 15:45:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733759105; 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=A2KDw4iEBnrzUdgohvaxPHalSydkH/jJrZZ41O0FcSo=; b=NJ1d5GaTfIpLe1hgAJ0aZvZ5hBFD9lTvJs3kfPIS/Y5n8ROhHwGf+vEReJ9iUh82syM/x8 Aze1rd7PgQ37oL+jsMLeee2qGCXDK6TIU9CEhUbuHcqOy9x0MJNECPuGiazaZJKMulgtVj uATRjAgL6OVd62mA5OiUy00Z0tq+K4jzbe8Fa48jrWkhuVa09tiV92iWTIQfhQbFl8W2ma 28Ph/z19SWUAu1mZfMD/9EiCeIbJSYshtpcQ3may9bktcz66DYyiLVZGugck0JYfz5RAEP xZmilHkZGOsfkHgPbZg3col3LYAwoOM9q7hv4Dr89q3KdrVJZrvKXwK4iH+Tww== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733759105; 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=A2KDw4iEBnrzUdgohvaxPHalSydkH/jJrZZ41O0FcSo=; b=tuu9n/2mr78LZ32kIZ+Y1DgkD8bOVOyemaihi8zkN/SZe9Kh47O93oiyQ/4Psf0NexCFNx FzBztSfoubzBmssHzR1VkJ1fClqkI7TFLxJhHkgAd2UFEOfPU6s1HqGFC7IaZdUWo+MNef kWPx0iGBsiSSEPla7QzTcnJQ4DOmP4lvlEtmowBDFuft+VQyA+jIRNGGZBY0BSz3oapOZW Vg2tYAFTiUePu5oHab43MAu2j7v5sIykpX/NC/nK6eotjAQc8iv0loFN3hoG8BXOTjgqN8 GwZcDM1MdmviyWuA17PIQDVN6/BJ6hfgSLJhRt/m/uDpu1ieHY9GDOXHlCUNoQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733759105; a=rsa-sha256; cv=none; b=dMyGeTutNBToM//KUUhM5xUQqpSTBYjfBXU1ix/LWkbpSVVm2SWobdySpTbdzjZJhwD2It fkLX1bg8BolrcuHXZo7PXCmXMBTbyAkhACu5SU9crloQ/rqDkI5ojR+B2e7wgkHx3JSUOz qw2ucWgKOIeEBJgiW/qHenzGX6AKVh2x437VTHCpo5MNGd6dqeP7NfmATp7U1+Z0fVacBw 7Td3EyB4UVT3rOpKPzyVn6FxTOK3bRzOO93ZV5R0tbiZSOoA48KBdapK/jMkualnwMe2Ij dQkaCFzS8o3BvXDTJllHu9ORLoblaMUqdto7VGTjLCi13fQTJICcome1EwN6Zw== 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 4Y6R5F2psRzk8Y; Mon, 9 Dec 2024 15:45:05 +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 4B9Fj5Qe062508; Mon, 9 Dec 2024 15:45:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9Fj5Qu062505; Mon, 9 Dec 2024 15:45:05 GMT (envelope-from git) Date: Mon, 9 Dec 2024 15:45:05 GMT Message-Id: <202412091545.4B9Fj5Qu062505@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Andrew Turner Subject: git: bb8c68b25333 - main - acpi_gpiobus: Fix cleanup on set flags failure 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: andrew X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: bb8c68b25333638a20838500ccffee23b4291427 Auto-Submitted: auto-generated The branch main has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=bb8c68b25333638a20838500ccffee23b4291427 commit bb8c68b25333638a20838500ccffee23b4291427 Author: Andrew Turner AuthorDate: 2024-12-09 15:14:13 +0000 Commit: Andrew Turner CommitDate: 2024-12-09 15:44:30 +0000 acpi_gpiobus: Fix cleanup on set flags failure When GPIOBUS_PIN_SETFLAGS fails we called gpiobus_free_ivars to clean up the contents of the ivar, then would free the ivar. This lead to a use-after-free as the ivar had already been set on the child so gpiobus_child_deleted would try to free it again. Fix this by removing the early cleanup and letting gpiobus_child_deleted handle it. Fixes: c9e880c0ceef ("gpiobus: Use a bus_child_deleted method to free ivars for children") Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D47670 --- sys/dev/gpio/acpi_gpiobus.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/sys/dev/gpio/acpi_gpiobus.c b/sys/dev/gpio/acpi_gpiobus.c index e766c25e5336..be3889f6a89b 100644 --- a/sys/dev/gpio/acpi_gpiobus.c +++ b/sys/dev/gpio/acpi_gpiobus.c @@ -203,8 +203,6 @@ acpi_gpiobus_enumerate_aei(ACPI_RESOURCE *res, void *context) for (int i = 0; i < devi->gpiobus.npins; i++) { if (GPIOBUS_PIN_SETFLAGS(bus, child, 0, devi->flags)) { - gpiobus_free_ivars(&devi->gpiobus); - free(devi, M_DEVBUF); device_delete_child(bus, child); return (AE_OK); } From nobody Mon Dec 9 16:19:26 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 4Y6Rrv0k5Zz5gTsb; Mon, 09 Dec 2024 16:19:27 +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 4Y6Rrv0Cw0z4SmS; Mon, 9 Dec 2024 16:19:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733761167; 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=FxjzKmPFtNf5vw0boeFdVWdusFGuh8ZmcuXoM3j8Teg=; b=qcY/UfqpJdF8Hp6PcFtbI+gHNW/GaBdgMBtB0lM5FPU217axBx3rXhm5rdOPvGZjeDjavw wR/JD8vg894odYaV+bgQZ1N+0UngLn7OgnXjkJ/ZRfabLJV3jrJzbcW4WvxR1LP43Pzxyo 2QSLMKj1tVMcFZ9HQqAk7iMu8O2CpBtkVcWYSVj8eFJOp6FCVguTVA5XBdeiRfhrvLcOFG n/4kWdj3ssiF/rDAv5niWdYyx6jzJpHzWteHmKYQw5Wr483ADQzDciuPXL5NUW+gNRnLOA MLbq4MTNfI7xcwtlaNeTxJi7+q92PRjMyVaAaCbpVbmyjXpmBCoi44GxAmo+Hw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733761167; 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=FxjzKmPFtNf5vw0boeFdVWdusFGuh8ZmcuXoM3j8Teg=; b=hZuq0o6mhi+kCRR31JVmrOMgzfffC/kWy0cgMSZNGUlSR6um9JZ9fdfrDIdPwqPhzMgU3V rOxQmeLhiYaNh6LUqkGvLmHcNcqKfez7cQIIYI9IVjFkIH4X8tSdlKUHgMotTCxt/4E3UF OJ1zhrIfuSGkXXUTgcHGKC6hsW65+CXweS9pTSBKBjyUrRtz79hqFvtSi7ORlv2NE1W2a4 yXj90SpCF4V0VgN/Q+twdPBgnN04JS506gD0rCm2oQTu5F3nk65Vv7QzbTVt07DlfVjYo0 mkjsLSHakJcBgvMGCoPLrDqNzv4piUD1PB6FIPFkpiOg/5dFCmdFqy2QUVl51Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733761167; a=rsa-sha256; cv=none; b=YPvraBIiL16REuyGLehN9xeSrqaiwXPXGUU0iahY72QfxteOh+RwaROldr1B2yLbN4MLu9 lU/Eh+MNIjms+ejA3I7WUnEuAqUpAfZaB0aWpiEFtA0qhm/GgQ0cjU0OZl6aXqpfXSgSx4 wL6i5Rz0WBPgKHj8zOxIRXeKz5c1jkmeUaZmY+wrzJbV33ozgjhex7Yv7vaQNwTM1DRpXp APSUv2urevOJ+krO8YAwA+VIZSeFkThH2MIm5Kfhfuy6NTbuw1F/uhiddjJUabXEFxoAr3 d3GErELRKldRIthGG6U5jk7KuoXVTA2V+lXppsAW7kuKe+L2HKDWTmQ2p09bCw== 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 4Y6Rrt6p4CzlRv; Mon, 9 Dec 2024 16:19:26 +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 4B9GJQ7G019820; Mon, 9 Dec 2024 16:19:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9GJQud019817; Mon, 9 Dec 2024 16:19:26 GMT (envelope-from git) Date: Mon, 9 Dec 2024 16:19:26 GMT Message-Id: <202412091619.4B9GJQud019817@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: d3f035f8d96a - main - ifnet: make sa_dl_equal() a static function 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: glebius X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d3f035f8d96ae0e1c49ab725aa9d86be63d293d6 Auto-Submitted: auto-generated The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=d3f035f8d96ae0e1c49ab725aa9d86be63d293d6 commit d3f035f8d96ae0e1c49ab725aa9d86be63d293d6 Author: Gleb Smirnoff AuthorDate: 2024-12-09 16:18:56 +0000 Commit: Gleb Smirnoff CommitDate: 2024-12-09 16:18:56 +0000 ifnet: make sa_dl_equal() a static function No functional change. Also clears last use of CLLADDR() macro. --- sys/net/if.c | 15 +++++++++------ sys/net/if_dl.h | 1 - 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/sys/net/if.c b/sys/net/if.c index 8dc212ae4ac7..25cad0222c06 100644 --- a/sys/net/if.c +++ b/sys/net/if.c @@ -1799,13 +1799,16 @@ ifa_free(struct ifaddr *ifa) * structs used to represent other address families, it is necessary * to perform a different comparison. */ +static bool +sa_dl_equal(const struct sockaddr *a, const struct sockaddr *b) +{ + const struct sockaddr_dl *sdl1 = (const struct sockaddr_dl *)a; + const struct sockaddr_dl *sdl2 = (const struct sockaddr_dl *)b; -#define sa_dl_equal(a1, a2) \ - ((((const struct sockaddr_dl *)(a1))->sdl_len == \ - ((const struct sockaddr_dl *)(a2))->sdl_len) && \ - (bcmp(CLLADDR((const struct sockaddr_dl *)(a1)), \ - CLLADDR((const struct sockaddr_dl *)(a2)), \ - ((const struct sockaddr_dl *)(a1))->sdl_alen) == 0)) + return (sdl1->sdl_len == sdl2->sdl_len && + bcmp(sdl1->sdl_data + sdl1->sdl_nlen, + sdl2->sdl_data + sdl2->sdl_nlen, sdl1->sdl_alen) == 0); +} /* * Locate an interface based on a complete address. diff --git a/sys/net/if_dl.h b/sys/net/if_dl.h index e19f4a84a7c1..77663c2a20d7 100644 --- a/sys/net/if_dl.h +++ b/sys/net/if_dl.h @@ -66,7 +66,6 @@ struct sockaddr_dl { }; #define LLADDR(s) ((caddr_t)((s)->sdl_data + (s)->sdl_nlen)) -#define CLLADDR(s) ((c_caddr_t)((s)->sdl_data + (s)->sdl_nlen)) #define LLINDEX(s) ((s)->sdl_index) struct ifnet; From nobody Mon Dec 9 16:19:27 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 4Y6Rrw22zFz5gTWL; Mon, 09 Dec 2024 16:19:28 +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 4Y6Rrw0sjWz4SWK; Mon, 9 Dec 2024 16:19:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733761168; 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=hh0ygwpshNhJ2YBwjucvbjrPs/ErNpzvNzKMlB0n5cc=; b=vUdDSNNyISft+aHalz+s62oWF0WcsWNc86zToEd0cSUuSTxQ2W8y9j6Rsh/CvmavA9v+n6 94nkmvNEuNldSq7veN/lLnGzfmSuGvphby3/7gNbQwjzRePndtcOrVXINiSVP/kJ3U2JWG oiX5EriKA46RubmGYsTjBbTClB6CWO0XZ9bbmqRXMbnIfVczWBoHC+JOHksIyyJkconG/S RKr6lJ5vk7taTSUVTB1aL8r5b2MjYQLfcZz/fgeaGY6/judj9yiM8zb1/+DAm8Wikc7Ytf 8ZDbeBpEqOOzdNuCHA9/irVuyCrd4Np+74eevhYUgkVsHqcH8oVIdCvnIAcLhA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733761168; 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=hh0ygwpshNhJ2YBwjucvbjrPs/ErNpzvNzKMlB0n5cc=; b=LlsELDLvrTyFWWvGFl+Y+Q/3WcRE3GmXNghBIf/Mi86LJuWTaniM5KZ1JTIoaS1Ng9QRJW 1UazMsWlaPnrV57esMgjOpkuSUY7/sJjZ5Fa/Ilxlo1WckbOVjcDDf7chYCGsGocK2P/Y9 Mi7vMKdkRN1pK6mVSmrVoH7ZxXReVy3FdEOMeZ1i04lGEV+0SNm7TLUo0almasF0Rsbb4/ PE1cTBJVuIZNbXS89FmtL1R21OSb4AQokeNWyQqS5op5/LSmD+dfW853NEiJbVffrhQ1GW ErLumuAXkX4QIhyZD4zP0+iKirFlOT5HOO2PbFGB8wzFF/qbbSbtTWCzy7kzdw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733761168; a=rsa-sha256; cv=none; b=ihyztDUA4GdfXmzgNKT8lBZQvW08m3Nqt4OpAaUFZkhHC3iczpdah3gHlMvdm9mg3nHLfF +DQZKBRmEKV9URfqp4pb7aksHCVaYrtzeAJMq6XlRRYa8+pRvrWQ7gJBbRfztKVZlv2Bll mzw/jpRNXqOEqoyBdSMq8NFBSuNjf1cKl3p27Ol6jfUk6ZTdtfaGvprRhE2WPukQUrvECk eVLCGWQwmfh8FR2UQtm6fAhfMrn2o8i01jRxbG2awSGGvv4pVaNgboyuHYecX2Nr5k/KnF wDUaL+GF4CqAMIEkZKtrxlXpZpXPMxWLwaiatTpgiQJj3RWJEbYtFrnMp6tUGw== 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 4Y6Rrw0TtzzkYM; Mon, 9 Dec 2024 16:19:28 +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 4B9GJRUF019898; Mon, 9 Dec 2024 16:19:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9GJREQ019895; Mon, 9 Dec 2024 16:19:27 GMT (envelope-from git) Date: Mon, 9 Dec 2024 16:19:27 GMT Message-Id: <202412091619.4B9GJREQ019895@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: 8e1af80243ff - main - IfAPI: make if_getlladdr() to return char HEAD branches config description git-daemon-export-ok gl-conf hooks info objects packed-refs refs 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: glebius X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8e1af80243ff97f56918b363196832af9406597e Auto-Submitted: auto-generated The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=8e1af80243ff97f56918b363196832af9406597e commit 8e1af80243ff97f56918b363196832af9406597e Author: Gleb Smirnoff AuthorDate: 2024-12-09 16:18:56 +0000 Commit: Gleb Smirnoff CommitDate: 2024-12-09 16:18:56 +0000 IfAPI: make if_getlladdr() to return char * No functional change. The caddr_t is a relic typedef from C version that didn't have void pointer. In this particular change we really need a char * pointer rather than void, because some consumers use the link level address as a char array. --- sys/net/if.c | 2 +- sys/net/if_var.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/net/if.c b/sys/net/if.c index 25cad0222c06..08c59627b196 100644 --- a/sys/net/if.c +++ b/sys/net/if.c @@ -4888,7 +4888,7 @@ if_setifheaderlen(if_t ifp, int len) return (0); } -caddr_t +char * if_getlladdr(const if_t ifp) { return (IF_LLADDR(ifp)); diff --git a/sys/net/if_var.h b/sys/net/if_var.h index a0271cfe2a7c..83d33330987e 100644 --- a/sys/net/if_var.h +++ b/sys/net/if_var.h @@ -643,7 +643,7 @@ void if_setrcvif(struct mbuf *m, if_t ifp); void if_setvtag(struct mbuf *m, u_int16_t tag); u_int16_t if_getvtag(struct mbuf *m); int if_vlantrunkinuse(if_t ifp); -caddr_t if_getlladdr(const if_t ifp); +char *if_getlladdr(const if_t ifp); struct vnet *if_getvnet(const if_t ifp); void *if_gethandle(u_char); void if_vlancap(if_t ifp); From nobody Mon Dec 9 16:19:29 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 4Y6Rrx4Kk3z5gTRx; Mon, 09 Dec 2024 16:19:29 +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 4Y6Rrx1hPqz4SSv; Mon, 9 Dec 2024 16:19:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733761169; 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=wPw+CqCWw8kNwY293SUA1RtxmiaGmFD1tkFx2cxwhNg=; b=g1Q5QAE2st+0oexUYEFgAUSOeiAE53V8n0CytHqpPnLJ1P8+olHNOv4XSBx7as6ahKdrK7 M3lzyd4tlOwpDevHTuFxuD8w1z3/3vLubwdF8hMfYW0RlVeWriXj8eNY85xZsgdF0bYhE6 3HfHUkIPcauIr0jDb46QijLsfAllHhNadgxCLLIHlxCg8D8QjK/JxIkcNh5YXGpCblcTSO FSiXvdlo/2zjlY9X06RSBWHyK6VNW5gCt3Jv9O60wSOd1BeU+0TMibEhCCTzQx9GgRcboU UMSYLD/LcyZfoNXXT5Y04YZvEoFS8cEHL7nBu1QphnbCE3lIQOPFSbpDycuMxw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733761169; 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=wPw+CqCWw8kNwY293SUA1RtxmiaGmFD1tkFx2cxwhNg=; b=lxHRGLvME3DA1jnfP/9pgUsk7FzxnX9kPpOrcNiZc6Gcl0CN885F6M9vCB0rcvbfGMIFkk 6d7h/BsFO6oJDTFJ4eZXUtexhXeVWcG3nnU5qEWyQYBqpXAuAV6AlbvpNLfVma5vo//EPU 6o3DL3YCBQ7f1DbKuDp0Guv2XW37+M2P9saGQ20Qb5VX6jYPu0IMtJwc+k3a1DyzkBZdie 7VJO1cnxB5pp4sH93l3L2eNz8UJZTUFxvfhE9cfTyn1KWn0DCt3NuI7Mo1wFLmkAfrJzOr DG3CSQ/Uf8zLnQXp+neXKHwRTIYdOjMRemoQ4al/bCnb8JESwjzKdyK/hXM6vA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733761169; a=rsa-sha256; cv=none; b=UyR1mGWa0fmtTQ/N1TTnTyJIZysHNQFAYliawsknQ3ji5L0Mbm70llgTn0R41pcIsdhYXF WHgnIWEOUHuZHoGnKyLsX5Hp54mvsUmsQQHnd6TZiJz8fkdK2h+neiR6IXcoArvgtHUhBG ayq5YdG5eh2Rwvo23d89u8HVe0jqbmVqW44tRrvZkN7bdVSJMw8Vg1hXg1xk9GAzAqOtsx R0O02WNiFKOIpq4IbzyJJWMPKHOb626+Ht4fXN0CrLNDyI/CATFxJRaMwcgwyUAMSMwwb4 om0P5W51LO59JvOvyiqo0mIYf9l9Ch+wKPmZavFYJ5hmb7muMMrnjj3Vf4gNQw== 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 4Y6Rrx15C5zlRw; Mon, 9 Dec 2024 16:19:29 +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 4B9GJTaH019965; Mon, 9 Dec 2024 16:19:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9GJTIp019962; Mon, 9 Dec 2024 16:19:29 GMT (envelope-from git) Date: Mon, 9 Dec 2024 16:19:29 GMT Message-Id: <202412091619.4B9GJTIp019962@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: a6a0b8d50e87 - main - in6_var.h: make struct in6_ifaddr declaration searchable with grep(1) 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: glebius X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a6a0b8d50e87c9c18b39e803e06986dcd9b7761b Auto-Submitted: auto-generated The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=a6a0b8d50e87c9c18b39e803e06986dcd9b7761b commit a6a0b8d50e87c9c18b39e803e06986dcd9b7761b Author: Gleb Smirnoff AuthorDate: 2024-12-09 16:18:56 +0000 Commit: Gleb Smirnoff CommitDate: 2024-12-09 16:18:56 +0000 in6_var.h: make struct in6_ifaddr declaration searchable with grep(1) --- sys/netinet6/in6_var.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netinet6/in6_var.h b/sys/netinet6/in6_var.h index ef79d11b558d..969625a58934 100644 --- a/sys/netinet6/in6_var.h +++ b/sys/netinet6/in6_var.h @@ -115,7 +115,7 @@ struct in6_ifextra { SLIST_HEAD(in6_multi_head, in6_multi); MALLOC_DECLARE(M_IP6MADDR); -struct in6_ifaddr { +struct in6_ifaddr { struct ifaddr ia_ifa; /* protocol-independent info */ #define ia_ifp ia_ifa.ifa_ifp #define ia_flags ia_ifa.ifa_flags From nobody Mon Dec 9 16:25:00 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 4Y6RzK1jQWz5gVJV; Mon, 09 Dec 2024 16:25:01 +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 4Y6RzK0tKVz4VpQ; Mon, 9 Dec 2024 16:25:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733761501; 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=nwLJGnw500U/7pshiupsdv02j9FSB2HPyNH5yoDL5dE=; b=HkuAgP6AHulC+ZsuodKrOlOYYLnLZGIAnNILfib+AghyKoQ/jFrjyDhngxlHIT8hT3Puhv DbYeQRavOGeYYnzUkB1osPImflnpng0LOl4o1ONfNrONo/0aFUgQIowCXEMbMQKwCp5v/m RfYqq1xiJCCuDTWQQc5z8zza8WUuXT3GhUYXQIh+aAVW3SKaPg6uAKX6LrZ8TZTko8WFiB PGW4KJQxWEumGUoVD2xDPe4oNVCKUepuFMWvtzfj9eW4O+wFe0V7VCQItcylUot1rqoKKQ /aM+ZhGAVc+mFCX1/UNU+8rSiUtmCljN3JurZHCWRfhvMMDdwbNxo0c+h5jZMg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733761501; 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=nwLJGnw500U/7pshiupsdv02j9FSB2HPyNH5yoDL5dE=; b=LwVB3uhOUTzIPiW0voKeA1wW3Qb6vhCX6iQEe/ttQjAcZRKJJRbk7J/42y+9VMoJHbWSsT yD3GEk7hXph23KA1v453pxLu0SuYVNyzFuJ8u6oh8MXW7BC8D0uzcSQ5toSQwPU9do+dnU +4Vyb6IsK2Fw43rH9lmFgIZd/+9VZ/kEVeLC+5zJ6iO12i9mig9jqcuhciFq/DEn2KuNhj quMGBi6C3O2itG77Nnh2mQJrkqmrjZir+rFY7gYwt3FkFyLkHUnh9bkQ9m2sw2SoIAmNh+ d+A3/LyysXsgLJmYirkbVc3cpY5Uko+aRDPLB5ap2tWrd0WgV1X84ZutjmIdKw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733761501; a=rsa-sha256; cv=none; b=KdDz/fnnMFHTfvmfuUuXXYzxrFBkSW4muNF/xMZJRud5Nr8bk4IeYLofdzdSUjLcqvqu49 6dJbUtAjLdolzxuaKLD4tv9RPqIEp1Tqa1s9LamQwpgG0yDoSKEjFR4j8Ckmvoj82p/CZb 4h/JWmGOJu/ALq61P5lvTR7cJMDZAb2rv8A6rMsPL4Jm6LLRDStyPaXwSpSwapJwrn4J1A tOY4FiJZP/8gXuco76EG6WTE3O+u2E2pWnnC0lEZTaMm4y0blr7kHEJLeNJiokH/gCnWKf KSClf/UkwflwXl8CiCl5hbOMoEUc4N23TnvDJ1Nazu1GKIW82PQPrPSWsyDPiQ== 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 4Y6RzK0Ls5zlbr; Mon, 9 Dec 2024 16:25:01 +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 4B9GP04J037157; Mon, 9 Dec 2024 16:25:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9GP02K037154; Mon, 9 Dec 2024 16:25:00 GMT (envelope-from git) Date: Mon, 9 Dec 2024 16:25:00 GMT Message-Id: <202412091625.4B9GP02K037154@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Jessica Clarke Subject: git: 9266d812eaf4 - stable/14 - depend-cleanup.sh: Fix pretend (-n) mode 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: jrtc27 X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 9266d812eaf4d810eeb482b07fbe320d405e7361 Auto-Submitted: auto-generated The branch stable/14 has been updated by jrtc27: URL: https://cgit.FreeBSD.org/src/commit/?id=9266d812eaf4d810eeb482b07fbe320d405e7361 commit 9266d812eaf4d810eeb482b07fbe320d405e7361 Author: Jessica Clarke AuthorDate: 2024-09-10 16:14:37 +0000 Commit: Jessica Clarke CommitDate: 2024-12-09 16:24:25 +0000 depend-cleanup.sh: Fix pretend (-n) mode Fixes: 26a09db3add3 ("Fix incremental build with WITH_NVME newly enabled") MFC after: 1 week (cherry picked from commit 7ce171bd4220b2e8946556bb806c787b51324993) --- tools/build/depend-cleanup.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/build/depend-cleanup.sh b/tools/build/depend-cleanup.sh index 6da37606300c..aad4f6b9218f 100755 --- a/tools/build/depend-cleanup.sh +++ b/tools/build/depend-cleanup.sh @@ -164,7 +164,7 @@ fi if [ -f "$OBJTOP"/rescue/rescue/rescue.mk ] && \ grep -q -v 'nvme_util.o' "$OBJTOP"/rescue/rescue/rescue.mk; then echo "removing rescue.mk without nvme_util.o" - rm -f "$OBJTOP"/rescue/rescue/rescue.mk + run rm -f "$OBJTOP"/rescue/rescue/rescue.mk fi # 20241018 5deeebd8c6ca Merge llvm-project release/19.x llvmorg-19.1.2-0-g7ba7d8e2f7b6 From nobody Mon Dec 9 16:25:02 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 4Y6RzL1dByz5gV1w; Mon, 09 Dec 2024 16:25:02 +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 4Y6RzL10Brz4VtZ; Mon, 9 Dec 2024 16:25:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733761502; 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=vOktDMzuAXZO5ELoTq6HrSPoLMBZ7hDDgtAvWJ8BmPI=; b=W0ADkNKl9dfmsuv9I75jwOusTkKfkTkufAOWwK9mFai/MyhlzT3hnf5U/5jg77+PwCozl6 kzY0ttssUGVw7Ihk8gD0kNYRUJLWhU7Qon3DlF7McYDwUxSJr+rqdpGbuWm8tfraJBAcgN HM0PrXPQZh/4ltoUQQSMk2OoO+N25r4Oy34+pEL2kIw5yZmYnkRAM/GG2UwMAcDMYoEhfu Rtztuhm6kizJMBI0YQyi4A74t/zP9CMZnNwx5k+nUSK7/i9EKSOH+RbgK0R4YSVcn98ACt N5Ruyl5JS5se31zKiY7wcvoFoEDDNqpVG6dLjn+UAdXTM87l0jsyni8cDfpr+Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733761502; 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=vOktDMzuAXZO5ELoTq6HrSPoLMBZ7hDDgtAvWJ8BmPI=; b=VOUpm2CvVN7jjWEEydNjZGnW2U/i9e71TNVet+rzKPu0SoaGXUVFk+TIbLORfdOjnaozwx SAlHDST4g0CX2V2qfybXc/ZuS9gSTasq2S7LuwGEe96zZ4hmDenbwIAYhnYDTUaQKSUwx0 1EHiQjdVSk4K1UhBh6ecghCU0F398RbVnFJ0B7/vmiUeJdxAdLJ+3TrVmkNVSVp75ZU5T6 X+2avXDJ2aDgOTnNNaDDg2sZ3O7oTJVfH/QC2nUIpM2NXGXFf/x00cARto2N8ABF6QxAAw rufkSG+Py5LLtVJlOny8Q6ZI3xhUIcQxcI08cqtsVmwOcUPG8VFmYCarKo+1wQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733761502; a=rsa-sha256; cv=none; b=pHPkgW9P4PB+dh09jVYzpKjEVVPb4xuJFyx3I/J1+b7rgxawYAY/6AJjh8QaNzp7Klrj6t TtbLnRr0oswGQzsTaaKYgMOUbJSVw4KvWzVPLIljktKs7gVQOQv4cCBOqslVScMzea+KRM T1VNF08rP1HGduudOC6q79fL8kYwR88gLGKcSakMy9v5HZ9xf1awtYCcG+NCrclvBSq25c 48Fsftm8SM0d8fBerg7PjbtyeonKbaKS1tYFKYgZDHxW+O71RbCPJ4+M4daBjM4PxF1IYK 3OPwvyAITf9KjifiXgB/5u+8tSOU2nwID6n/RkbiWC/SORv6hRaQM1XPDP25lg== 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 4Y6RzL0cBNzlnV; Mon, 9 Dec 2024 16:25:02 +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 4B9GP2vR037216; Mon, 9 Dec 2024 16:25:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9GP2wF037211; Mon, 9 Dec 2024 16:25:02 GMT (envelope-from git) Date: Mon, 9 Dec 2024 16:25:02 GMT Message-Id: <202412091625.4B9GP2wF037211@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Jessica Clarke Subject: git: be778581eb31 - stable/14 - depend-cleanup.sh: Fix overzealous rescue.mk cleanup 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: jrtc27 X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: be778581eb3168bcd8f9d8034e5175873efba416 Auto-Submitted: auto-generated The branch stable/14 has been updated by jrtc27: URL: https://cgit.FreeBSD.org/src/commit/?id=be778581eb3168bcd8f9d8034e5175873efba416 commit be778581eb3168bcd8f9d8034e5175873efba416 Author: Jessica Clarke AuthorDate: 2024-09-10 16:33:06 +0000 Commit: Jessica Clarke CommitDate: 2024-12-09 16:24:25 +0000 depend-cleanup.sh: Fix overzealous rescue.mk cleanup grep -q -v means "are there any lines that don't match", not "are there no lines that match", and since the file has lines other than ones with nvme_util.o when up-to-date this triggers on every build. Fixes: 26a09db3add3 ("Fix incremental build with WITH_NVME newly enabled") MFC after: 1 week (cherry picked from commit e546c3950a2c98b298b8ddfb68b50cb496fe7fac) --- tools/build/depend-cleanup.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/build/depend-cleanup.sh b/tools/build/depend-cleanup.sh index aad4f6b9218f..7441cd1d7d81 100755 --- a/tools/build/depend-cleanup.sh +++ b/tools/build/depend-cleanup.sh @@ -162,7 +162,7 @@ fi # 20240416 2fda3ab0ac19 WITH_NVME: Remove from broken if [ -f "$OBJTOP"/rescue/rescue/rescue.mk ] && \ - grep -q -v 'nvme_util.o' "$OBJTOP"/rescue/rescue/rescue.mk; then + ! grep -q 'nvme_util.o' "$OBJTOP"/rescue/rescue/rescue.mk; then echo "removing rescue.mk without nvme_util.o" run rm -f "$OBJTOP"/rescue/rescue/rescue.mk fi From nobody Mon Dec 9 16:33:18 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 4Y6S8v5MhFz5gW5L; Mon, 09 Dec 2024 16:33:19 +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 4Y6S8v0nw2z4X40; Mon, 9 Dec 2024 16:33:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733761999; 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=4lilf1iBxrXg/YuCZ/AmxpjGPpwLKhmdJaQLtOvAb/8=; b=lUUWXDV6Qrq0IF/+ByAr2bsSPqzp0uOnFuaJX5t/4nLYOYlzGKGXaeLN7SPVqro/4NZOK2 esGFItvcNV0nGwkXnDOM7CPGFtecawEi5vaYE561ysD0mDnPkiRkeM6TyqCOwCSRznoxdF UFmVon4E4LjSRj+XUF/IxqodmbJLHA85cTjJtE+MmhmyNbD+dT9m1VFG3isxIXEysaXUpp kCDjaykv1j2ygSiK49R8mfjXsdrkIJQqqqqPmEPT/z+Kt6PJ0vNQaYydoiieoucIj4d4on Q04Jyqm7XvIulQPENR857jzEGXqyHkkMqXuBYYlU7MTGVth1g9plE6T9t9rK9w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733761999; 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=4lilf1iBxrXg/YuCZ/AmxpjGPpwLKhmdJaQLtOvAb/8=; b=gGgrbFxm5+Ak7pPzFqsKd1xq8Pl8hC7qNrhXe0tdCyBg1K32drJwfA2oI7f9uxzHziPzyW Aqxbz2sM74NzgyUOBBnoctpE3d4x4FdocX9JQcgDRwLNVl9qbjhfwTRg9LeH7PfFVkJCWM ZyynWmvueq70P6f2iH3PWPs/a7o2rkWfFTdSilxdmDHjO/Zu97vIT7i+Lsa+jDLO1TTW/7 psHMZIlWYcG0aFH1aY9zdT2P6kGC72Pcxo7F+9/FtyUqkJi5V7W3FUZrm/3YU2LwGvdf1t vNyFtJnwk1KDW6RXMNd321ZukCQb0aD9hL6aGH8SeEZG7bEuBU7goWPChWVDLg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733761999; a=rsa-sha256; cv=none; b=hcuaGUZS6ABY+Qj078uRp0Jrbs9K8ohmBdW9amLQHUIZu3QhqSduH6toVDjsNjpxKDeIRE iBUcObnC++o+9eQUqWEtLoOLZIosdX1ODhCfXC4hYnLOwiK+ks2Cr/izt0Hl6tKytqIo1K pyM/SVuDPVoKg3z2lTfjdROyzOZL64UxbZNMHVgAQqjrXm224ybmv/WMsyCBgzI6EgF3mO W3uMFnLJPcNAF5yvJVUeFEAuxUagsQTmoms1G6Ht9az5g3F5jPprR5/jya4FHTvJ0+Dq0J Ck6729EWanhodXDWxw1JtCTuFTCb2YlhJQZWSOXRuaFPcf4ORISvAmSSY4jUZw== 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 4Y6S8v0PnCzln8; Mon, 9 Dec 2024 16:33:19 +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 4B9GXIm5055167; Mon, 9 Dec 2024 16:33:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9GXIUS055164; Mon, 9 Dec 2024 16:33:18 GMT (envelope-from git) Date: Mon, 9 Dec 2024 16:33:18 GMT Message-Id: <202412091633.4B9GXIUS055164@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: 3f879ed6eee9 - stable/14 - sys/sys/kernel.h: Various whitespace fixes 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 3f879ed6eee9618ff7611f5de7a73868ef0cebb9 Auto-Submitted: auto-generated The branch stable/14 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=3f879ed6eee9618ff7611f5de7a73868ef0cebb9 commit 3f879ed6eee9618ff7611f5de7a73868ef0cebb9 Author: Zhenlei Huang AuthorDate: 2024-12-06 11:39:18 +0000 Commit: Zhenlei Huang CommitDate: 2024-12-09 16:32:43 +0000 sys/sys/kernel.h: Various whitespace fixes MFC after: 3 days (cherry picked from commit 5c623697d6011de63bc762560a648c09379e06d2) --- sys/sys/kernel.h | 100 +++++++++++++++++++++++++++---------------------------- 1 file changed, 50 insertions(+), 50 deletions(-) diff --git a/sys/sys/kernel.h b/sys/sys/kernel.h index 62b9e6a02b3c..f547ff4690de 100644 --- a/sys/sys/kernel.h +++ b/sys/sys/kernel.h @@ -86,16 +86,16 @@ extern volatile int ticks; * The SI_SUB_LAST value must have the highest lexical value. */ enum sysinit_sub_id { - SI_SUB_DUMMY = 0x0000000, /* not executed; for linker*/ - SI_SUB_DONE = 0x0000001, /* processed*/ + SI_SUB_DUMMY = 0x0000000, /* not executed; for linker */ + SI_SUB_DONE = 0x0000001, /* processed */ SI_SUB_TUNABLES = 0x0700000, /* establish tunable values */ - SI_SUB_COPYRIGHT = 0x0800001, /* first use of console*/ + SI_SUB_COPYRIGHT = 0x0800001, /* first use of console */ SI_SUB_VM = 0x1000000, /* virtual memory system init */ SI_SUB_COUNTER = 0x1100000, /* counter(9) is initialized */ - SI_SUB_KMEM = 0x1800000, /* kernel memory*/ + SI_SUB_KMEM = 0x1800000, /* kernel memory */ SI_SUB_HYPERVISOR = 0x1A40000, /* * Hypervisor detection and - * virtualization support + * virtualization support * setup. */ SI_SUB_WITNESS = 0x1A80000, /* witness initialization */ @@ -105,7 +105,7 @@ enum sysinit_sub_id { SI_SUB_VNET_PRELINK = 0x1E00000, /* vnet init before modules */ SI_SUB_KLD = 0x2000000, /* KLD and module setup */ SI_SUB_KHELP = 0x2080000, /* khelp modules */ - SI_SUB_CPU = 0x2100000, /* CPU resource(s)*/ + SI_SUB_CPU = 0x2100000, /* CPU resource(s) */ SI_SUB_RACCT = 0x2110000, /* resource accounting */ SI_SUB_KDTRACE = 0x2140000, /* Kernel dtrace hooks */ SI_SUB_RANDOM = 0x2160000, /* random number generator */ @@ -113,21 +113,21 @@ enum sysinit_sub_id { SI_SUB_MAC_POLICY = 0x21C0000, /* TrustedBSD MAC policies */ SI_SUB_MAC_LATE = 0x21D0000, /* TrustedBSD MAC subsystem */ SI_SUB_VNET = 0x21E0000, /* vnet 0 */ - SI_SUB_INTRINSIC = 0x2200000, /* proc 0*/ - SI_SUB_VM_CONF = 0x2300000, /* config VM, set limits*/ + SI_SUB_INTRINSIC = 0x2200000, /* proc 0 */ + SI_SUB_VM_CONF = 0x2300000, /* config VM, set limits */ SI_SUB_DDB_SERVICES = 0x2380000, /* capture, scripting, etc. */ - SI_SUB_RUN_QUEUE = 0x2400000, /* set up run queue*/ + SI_SUB_RUN_QUEUE = 0x2400000, /* set up run queue */ SI_SUB_KTRACE = 0x2480000, /* ktrace */ SI_SUB_OPENSOLARIS = 0x2490000, /* OpenSolaris compatibility */ SI_SUB_AUDIT = 0x24C0000, /* audit */ - SI_SUB_CREATE_INIT = 0x2500000, /* create init process*/ + SI_SUB_CREATE_INIT = 0x2500000, /* create init process */ SI_SUB_SCHED_IDLE = 0x2600000, /* required idle procs */ SI_SUB_MBUF = 0x2700000, /* mbuf subsystem */ SI_SUB_INTR = 0x2800000, /* interrupt threads */ SI_SUB_TASKQ = 0x2880000, /* task queues */ SI_SUB_EPOCH = 0x2888000, /* epoch subsystem */ #ifdef EARLY_AP_STARTUP - SI_SUB_SMP = 0x2900000, /* start the APs*/ + SI_SUB_SMP = 0x2900000, /* start the APs */ #endif SI_SUB_SOFTINTR = 0x2A00000, /* start soft interrupt thread */ SI_SUB_DEVFS = 0x2F00000, /* devfs ready for devices */ @@ -138,40 +138,40 @@ enum sysinit_sub_id { SI_SUB_DTRACE_ANON = 0x308C000, /* DTrace anon enabling */ SI_SUB_DRIVERS = 0x3100000, /* Let Drivers initialize */ SI_SUB_CONFIGURE = 0x3800000, /* Configure devices */ - SI_SUB_VFS = 0x4000000, /* virtual filesystem*/ - SI_SUB_CLOCKS = 0x4800000, /* real time and stat clocks*/ - SI_SUB_SYSV_SHM = 0x6400000, /* System V shared memory*/ - SI_SUB_SYSV_SEM = 0x6800000, /* System V semaphores*/ - SI_SUB_SYSV_MSG = 0x6C00000, /* System V message queues*/ + SI_SUB_VFS = 0x4000000, /* virtual filesystem */ + SI_SUB_CLOCKS = 0x4800000, /* real time and stat clocks */ + SI_SUB_SYSV_SHM = 0x6400000, /* System V shared memory */ + SI_SUB_SYSV_SEM = 0x6800000, /* System V semaphores */ + SI_SUB_SYSV_MSG = 0x6C00000, /* System V message queues */ SI_SUB_P1003_1B = 0x6E00000, /* P1003.1B realtime */ - SI_SUB_PSEUDO = 0x7000000, /* pseudo devices*/ + SI_SUB_PSEUDO = 0x7000000, /* pseudo devices */ SI_SUB_EXEC = 0x7400000, /* execve() handlers */ SI_SUB_PROTO_BEGIN = 0x8000000, /* VNET initialization */ SI_SUB_PROTO_PFIL = 0x8100000, /* Initialize pfil before FWs */ - SI_SUB_PROTO_IF = 0x8400000, /* interfaces*/ + SI_SUB_PROTO_IF = 0x8400000, /* interfaces */ SI_SUB_PROTO_DOMAININIT = 0x8600000, /* domain registration system */ SI_SUB_PROTO_MC = 0x8700000, /* Multicast */ - SI_SUB_PROTO_DOMAIN = 0x8800000, /* domains (address families?)*/ + SI_SUB_PROTO_DOMAIN = 0x8800000, /* domains (address families?) */ SI_SUB_PROTO_FIREWALL = 0x8806000, /* Firewalls */ SI_SUB_PROTO_IFATTACHDOMAIN = 0x8808000,/* domain dependent data init */ SI_SUB_PROTO_END = 0x8ffffff, /* VNET helper functions */ - SI_SUB_KPROF = 0x9000000, /* kernel profiling*/ - SI_SUB_KICK_SCHEDULER = 0xa000000, /* start the timeout events*/ + SI_SUB_KPROF = 0x9000000, /* kernel profiling */ + SI_SUB_KICK_SCHEDULER = 0xa000000, /* start the timeout events */ SI_SUB_INT_CONFIG_HOOKS = 0xa800000, /* Interrupts enabled config */ SI_SUB_ROOT_CONF = 0xb000000, /* Find root devices */ - SI_SUB_INTRINSIC_POST = 0xd000000, /* proc 0 cleanup*/ + SI_SUB_INTRINSIC_POST = 0xd000000, /* proc 0 cleanup */ SI_SUB_SYSCALLS = 0xd800000, /* register system calls */ SI_SUB_VNET_DONE = 0xdc00000, /* vnet registration complete */ - SI_SUB_KTHREAD_INIT = 0xe000000, /* init process*/ - SI_SUB_KTHREAD_PAGE = 0xe400000, /* pageout daemon*/ - SI_SUB_KTHREAD_VM = 0xe800000, /* vm daemon*/ - SI_SUB_KTHREAD_BUF = 0xea00000, /* buffer daemon*/ - SI_SUB_KTHREAD_UPDATE = 0xec00000, /* update daemon*/ - SI_SUB_KTHREAD_IDLE = 0xee00000, /* idle procs*/ + SI_SUB_KTHREAD_INIT = 0xe000000, /* init process */ + SI_SUB_KTHREAD_PAGE = 0xe400000, /* pageout daemon */ + SI_SUB_KTHREAD_VM = 0xe800000, /* vm daemon */ + SI_SUB_KTHREAD_BUF = 0xea00000, /* buffer daemon */ + SI_SUB_KTHREAD_UPDATE = 0xec00000, /* update daemon */ + SI_SUB_KTHREAD_IDLE = 0xee00000, /* idle procs */ #ifndef EARLY_AP_STARTUP - SI_SUB_SMP = 0xf000000, /* start the APs*/ -#endif - SI_SUB_RACCTD = 0xf100000, /* start racctd*/ + SI_SUB_SMP = 0xf000000, /* start the APs */ +#endif + SI_SUB_RACCTD = 0xf100000, /* start racctd */ SI_SUB_LAST = 0xfffffff /* final initialization */ }; @@ -179,16 +179,16 @@ enum sysinit_sub_id { * Some enumerated orders; "ANY" sorts last. */ enum sysinit_elem_order { - SI_ORDER_FIRST = 0x0000000, /* first*/ - SI_ORDER_SECOND = 0x0000001, /* second*/ - SI_ORDER_THIRD = 0x0000002, /* third*/ - SI_ORDER_FOURTH = 0x0000003, /* fourth*/ - SI_ORDER_FIFTH = 0x0000004, /* fifth*/ - SI_ORDER_SIXTH = 0x0000005, /* sixth*/ - SI_ORDER_SEVENTH = 0x0000006, /* seventh*/ - SI_ORDER_EIGHTH = 0x0000007, /* eighth*/ + SI_ORDER_FIRST = 0x0000000, /* first */ + SI_ORDER_SECOND = 0x0000001, /* second */ + SI_ORDER_THIRD = 0x0000002, /* third */ + SI_ORDER_FOURTH = 0x0000003, /* fourth */ + SI_ORDER_FIFTH = 0x0000004, /* fifth */ + SI_ORDER_SIXTH = 0x0000005, /* sixth */ + SI_ORDER_SEVENTH = 0x0000006, /* seventh */ + SI_ORDER_EIGHTH = 0x0000007, /* eighth */ SI_ORDER_MIDDLE = 0x1000000, /* somewhere in the middle */ - SI_ORDER_ANY = 0xfffffff /* last*/ + SI_ORDER_ANY = 0xfffffff /* last */ }; /* @@ -218,10 +218,10 @@ typedef void (*sysinit_nfunc_t)(void *); typedef void (*sysinit_cfunc_t)(const void *); struct sysinit { - enum sysinit_sub_id subsystem; /* subsystem identifier*/ - enum sysinit_elem_order order; /* init order within subsystem*/ + enum sysinit_sub_id subsystem; /* subsystem identifier */ + enum sysinit_elem_order order; /* init order within subsystem */ STAILQ_ENTRY(sysinit) next; /* singly-linked list */ - sysinit_cfunc_t func; /* function */ + sysinit_cfunc_t func; /* function */ const void *udata; /* multiplexer/argument */ }; @@ -240,13 +240,13 @@ struct sysinit { #ifdef TSLOG struct sysinit_tslog { sysinit_cfunc_t func; - const void * data; - const char * name; + const void *data; + const char *name; }; static inline void -sysinit_tslog_shim(const void * data) +sysinit_tslog_shim(const void *data) { - const struct sysinit_tslog * x = data; + const struct sysinit_tslog *x = data; TSRAW(curthread, TS_ENTER, "SYSINIT", x->name); (x->func)(x->data); @@ -265,7 +265,7 @@ sysinit_tslog_shim(const void * data) sysinit_tslog_shim, \ &uniquifier ## _sys_init_tslog \ }; \ - DATA_WSET(sysinit_set,uniquifier ## _sys_init) + DATA_WSET(sysinit_set, uniquifier ## _sys_init) #else #define C_SYSINIT(uniquifier, subsystem, order, func, ident) \ static struct sysinit uniquifier ## _sys_init = { \ @@ -275,7 +275,7 @@ sysinit_tslog_shim(const void * data) func, \ (ident) \ }; \ - DATA_WSET(sysinit_set,uniquifier ## _sys_init) + DATA_WSET(sysinit_set, uniquifier ## _sys_init) #endif #define SYSINIT(uniquifier, subsystem, order, func, ident) \ @@ -293,7 +293,7 @@ sysinit_tslog_shim(const void * data) func, \ (ident) \ }; \ - DATA_WSET(sysuninit_set,uniquifier ## _sys_uninit) + DATA_WSET(sysuninit_set, uniquifier ## _sys_uninit) #define SYSUNINIT(uniquifier, subsystem, order, func, ident) \ C_SYSUNINIT(uniquifier, subsystem, order, \ From nobody Mon Dec 9 16:37:27 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 4Y6SFg5wg2z5gWDM; Mon, 09 Dec 2024 16:37:27 +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 4Y6SFg5RTQz4Yjv; Mon, 9 Dec 2024 16:37:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733762247; 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=mmV/YuOnVx1JdtL6rS5G+8+HA+jUMucCDQzMBKf7uA0=; b=YF31bw96I5ndYE7mQQQ3EyW4QQXYMKYByeOXT2iWOKLrWvoU7CvJJhf327fM/O7w8H69gk R04JxytvsYhHgOyAk9lKuQ9nIngXMWW//ZIVF2GyE+3tXb1MYBjLXfyke4q6b1wk/BpeYX rHtc6ldhn02ScWl29yJtF3PyqaBJeuqUCd9h7s40P9rMhw3mj5+pLRqpjd7sowPwYHjRx7 FFm6okgu9Wt1SRNeFcwOZyM2NC49mVovhX5MiiFOV8juSR+iNhJxm25aiVO+Rbpf1GZ2RY dimGC/PwmCAXJnoW+jkEPvapPMrZC3I3MI015yS3ph99wSs8CuKilmhhpx2Oag== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733762247; 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=mmV/YuOnVx1JdtL6rS5G+8+HA+jUMucCDQzMBKf7uA0=; b=q0qa/NiK1u0bSKsw0LVpdKpSqpj8RrZ/VkUSS/7zUwuDgi0lW6F6nc5lSEJNfBqeCyOgqg n/uUDq6CJupzBarHS1Orm/XHe3ODXMCD4Ou3MvX/zmI1gwp4tligM1DUdQ9+399DFy+fPl T9cuEPkKH2qUkzP8yw11zIM1Nh+jsdv6gZT3FzcvMwRye54G+uTsiaLJ0F1hBJiFp9pAsK 43mcfIZT1xGM/HZ581ApxMsEwXGM6gTkitX0aY2DjNtQ66wmaxfmlZAe7xiiF7zxqTsy1o RoOEp/rOkohzLPwo3hdp0DXnZa7fiN+boA9elMIzCKi2OxVaKuAXbF5foTkdqw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733762247; a=rsa-sha256; cv=none; b=hCNJ32u2SW+EchlfgfVgytzBDGBGiH13z4l4Zp1h98aFUtXRMSYuw3RqnJwri25kGIrCmp by3vcFA3Bfrw6IaZCUNyiLhTtbSGmptD3SghUxwnMZuhL2FKnG7Cyylr8HMJfLaWcLDRCY ISSGEAwQoe2PcdYPpHh66kn8zESpN3wtVCgNLCSZBBEllTVnxgz4Fw8Q3sNoFCjCT0QtY/ xHmefdp27wOh5JSqXcUMmF4FzLgwht7q5mNn4QzQD4PdON9J2jEpzp1mMtBuFLCheNzE1A R7OpnIzw68NiEi0MGHfTA9Mc83AYyADNHKEptUOZLkRNqyiCjEg9ql4CT2QG6w== 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 4Y6SFg51JGzlTK; Mon, 9 Dec 2024 16:37:27 +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 4B9GbREM056472; Mon, 9 Dec 2024 16:37:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9GbRig056469; Mon, 9 Dec 2024 16:37:27 GMT (envelope-from git) Date: Mon, 9 Dec 2024 16:37:27 GMT Message-Id: <202412091637.4B9GbRig056469@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: f507e664dc9d - stable/13 - sys/sys/kernel.h: Various whitespace fixes 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f507e664dc9d6acccd9b969e5ac808d7eb7bdc9f Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=f507e664dc9d6acccd9b969e5ac808d7eb7bdc9f commit f507e664dc9d6acccd9b969e5ac808d7eb7bdc9f Author: Zhenlei Huang AuthorDate: 2024-12-06 11:39:18 +0000 Commit: Zhenlei Huang CommitDate: 2024-12-09 16:36:49 +0000 sys/sys/kernel.h: Various whitespace fixes MFC after: 3 days (cherry picked from commit 5c623697d6011de63bc762560a648c09379e06d2) (cherry picked from commit 3f879ed6eee9618ff7611f5de7a73868ef0cebb9) --- sys/sys/kernel.h | 100 +++++++++++++++++++++++++++---------------------------- 1 file changed, 50 insertions(+), 50 deletions(-) diff --git a/sys/sys/kernel.h b/sys/sys/kernel.h index fccf96f3febf..e1ef7ff10dfa 100644 --- a/sys/sys/kernel.h +++ b/sys/sys/kernel.h @@ -86,16 +86,16 @@ extern volatile int ticks; * The SI_SUB_LAST value must have the highest lexical value. */ enum sysinit_sub_id { - SI_SUB_DUMMY = 0x0000000, /* not executed; for linker*/ - SI_SUB_DONE = 0x0000001, /* processed*/ + SI_SUB_DUMMY = 0x0000000, /* not executed; for linker */ + SI_SUB_DONE = 0x0000001, /* processed */ SI_SUB_TUNABLES = 0x0700000, /* establish tunable values */ - SI_SUB_COPYRIGHT = 0x0800001, /* first use of console*/ + SI_SUB_COPYRIGHT = 0x0800001, /* first use of console */ SI_SUB_VM = 0x1000000, /* virtual memory system init */ SI_SUB_COUNTER = 0x1100000, /* counter(9) is initialized */ - SI_SUB_KMEM = 0x1800000, /* kernel memory*/ + SI_SUB_KMEM = 0x1800000, /* kernel memory */ SI_SUB_HYPERVISOR = 0x1A40000, /* * Hypervisor detection and - * virtualization support + * virtualization support * setup. */ SI_SUB_WITNESS = 0x1A80000, /* witness initialization */ @@ -105,7 +105,7 @@ enum sysinit_sub_id { SI_SUB_VNET_PRELINK = 0x1E00000, /* vnet init before modules */ SI_SUB_KLD = 0x2000000, /* KLD and module setup */ SI_SUB_KHELP = 0x2080000, /* khelp modules */ - SI_SUB_CPU = 0x2100000, /* CPU resource(s)*/ + SI_SUB_CPU = 0x2100000, /* CPU resource(s) */ SI_SUB_RACCT = 0x2110000, /* resource accounting */ SI_SUB_KDTRACE = 0x2140000, /* Kernel dtrace hooks */ SI_SUB_RANDOM = 0x2160000, /* random number generator */ @@ -113,21 +113,21 @@ enum sysinit_sub_id { SI_SUB_MAC_POLICY = 0x21C0000, /* TrustedBSD MAC policies */ SI_SUB_MAC_LATE = 0x21D0000, /* TrustedBSD MAC subsystem */ SI_SUB_VNET = 0x21E0000, /* vnet 0 */ - SI_SUB_INTRINSIC = 0x2200000, /* proc 0*/ - SI_SUB_VM_CONF = 0x2300000, /* config VM, set limits*/ + SI_SUB_INTRINSIC = 0x2200000, /* proc 0 */ + SI_SUB_VM_CONF = 0x2300000, /* config VM, set limits */ SI_SUB_DDB_SERVICES = 0x2380000, /* capture, scripting, etc. */ - SI_SUB_RUN_QUEUE = 0x2400000, /* set up run queue*/ + SI_SUB_RUN_QUEUE = 0x2400000, /* set up run queue */ SI_SUB_KTRACE = 0x2480000, /* ktrace */ SI_SUB_OPENSOLARIS = 0x2490000, /* OpenSolaris compatibility */ SI_SUB_AUDIT = 0x24C0000, /* audit */ - SI_SUB_CREATE_INIT = 0x2500000, /* create init process*/ + SI_SUB_CREATE_INIT = 0x2500000, /* create init process */ SI_SUB_SCHED_IDLE = 0x2600000, /* required idle procs */ SI_SUB_MBUF = 0x2700000, /* mbuf subsystem */ SI_SUB_INTR = 0x2800000, /* interrupt threads */ SI_SUB_TASKQ = 0x2880000, /* task queues */ SI_SUB_EPOCH = 0x2888000, /* epoch subsystem */ #ifdef EARLY_AP_STARTUP - SI_SUB_SMP = 0x2900000, /* start the APs*/ + SI_SUB_SMP = 0x2900000, /* start the APs */ #endif SI_SUB_SOFTINTR = 0x2A00000, /* start soft interrupt thread */ SI_SUB_DEVFS = 0x2F00000, /* devfs ready for devices */ @@ -138,40 +138,40 @@ enum sysinit_sub_id { SI_SUB_DTRACE_ANON = 0x308C000, /* DTrace anon enabling */ SI_SUB_DRIVERS = 0x3100000, /* Let Drivers initialize */ SI_SUB_CONFIGURE = 0x3800000, /* Configure devices */ - SI_SUB_VFS = 0x4000000, /* virtual filesystem*/ - SI_SUB_CLOCKS = 0x4800000, /* real time and stat clocks*/ - SI_SUB_SYSV_SHM = 0x6400000, /* System V shared memory*/ - SI_SUB_SYSV_SEM = 0x6800000, /* System V semaphores*/ - SI_SUB_SYSV_MSG = 0x6C00000, /* System V message queues*/ + SI_SUB_VFS = 0x4000000, /* virtual filesystem */ + SI_SUB_CLOCKS = 0x4800000, /* real time and stat clocks */ + SI_SUB_SYSV_SHM = 0x6400000, /* System V shared memory */ + SI_SUB_SYSV_SEM = 0x6800000, /* System V semaphores */ + SI_SUB_SYSV_MSG = 0x6C00000, /* System V message queues */ SI_SUB_P1003_1B = 0x6E00000, /* P1003.1B realtime */ - SI_SUB_PSEUDO = 0x7000000, /* pseudo devices*/ + SI_SUB_PSEUDO = 0x7000000, /* pseudo devices */ SI_SUB_EXEC = 0x7400000, /* execve() handlers */ SI_SUB_PROTO_BEGIN = 0x8000000, /* VNET initialization */ SI_SUB_PROTO_PFIL = 0x8100000, /* Initialize pfil before FWs */ - SI_SUB_PROTO_IF = 0x8400000, /* interfaces*/ + SI_SUB_PROTO_IF = 0x8400000, /* interfaces */ SI_SUB_PROTO_DOMAININIT = 0x8600000, /* domain registration system */ SI_SUB_PROTO_MC = 0x8700000, /* Multicast */ - SI_SUB_PROTO_DOMAIN = 0x8800000, /* domains (address families?)*/ + SI_SUB_PROTO_DOMAIN = 0x8800000, /* domains (address families?) */ SI_SUB_PROTO_FIREWALL = 0x8806000, /* Firewalls */ SI_SUB_PROTO_IFATTACHDOMAIN = 0x8808000,/* domain dependent data init */ SI_SUB_PROTO_END = 0x8ffffff, /* VNET helper functions */ - SI_SUB_KPROF = 0x9000000, /* kernel profiling*/ - SI_SUB_KICK_SCHEDULER = 0xa000000, /* start the timeout events*/ + SI_SUB_KPROF = 0x9000000, /* kernel profiling */ + SI_SUB_KICK_SCHEDULER = 0xa000000, /* start the timeout events */ SI_SUB_INT_CONFIG_HOOKS = 0xa800000, /* Interrupts enabled config */ SI_SUB_ROOT_CONF = 0xb000000, /* Find root devices */ - SI_SUB_INTRINSIC_POST = 0xd000000, /* proc 0 cleanup*/ + SI_SUB_INTRINSIC_POST = 0xd000000, /* proc 0 cleanup */ SI_SUB_SYSCALLS = 0xd800000, /* register system calls */ SI_SUB_VNET_DONE = 0xdc00000, /* vnet registration complete */ - SI_SUB_KTHREAD_INIT = 0xe000000, /* init process*/ - SI_SUB_KTHREAD_PAGE = 0xe400000, /* pageout daemon*/ - SI_SUB_KTHREAD_VM = 0xe800000, /* vm daemon*/ - SI_SUB_KTHREAD_BUF = 0xea00000, /* buffer daemon*/ - SI_SUB_KTHREAD_UPDATE = 0xec00000, /* update daemon*/ - SI_SUB_KTHREAD_IDLE = 0xee00000, /* idle procs*/ + SI_SUB_KTHREAD_INIT = 0xe000000, /* init process */ + SI_SUB_KTHREAD_PAGE = 0xe400000, /* pageout daemon */ + SI_SUB_KTHREAD_VM = 0xe800000, /* vm daemon */ + SI_SUB_KTHREAD_BUF = 0xea00000, /* buffer daemon */ + SI_SUB_KTHREAD_UPDATE = 0xec00000, /* update daemon */ + SI_SUB_KTHREAD_IDLE = 0xee00000, /* idle procs */ #ifndef EARLY_AP_STARTUP - SI_SUB_SMP = 0xf000000, /* start the APs*/ -#endif - SI_SUB_RACCTD = 0xf100000, /* start racctd*/ + SI_SUB_SMP = 0xf000000, /* start the APs */ +#endif + SI_SUB_RACCTD = 0xf100000, /* start racctd */ SI_SUB_LAST = 0xfffffff /* final initialization */ }; @@ -179,16 +179,16 @@ enum sysinit_sub_id { * Some enumerated orders; "ANY" sorts last. */ enum sysinit_elem_order { - SI_ORDER_FIRST = 0x0000000, /* first*/ - SI_ORDER_SECOND = 0x0000001, /* second*/ - SI_ORDER_THIRD = 0x0000002, /* third*/ - SI_ORDER_FOURTH = 0x0000003, /* fourth*/ - SI_ORDER_FIFTH = 0x0000004, /* fifth*/ - SI_ORDER_SIXTH = 0x0000005, /* sixth*/ - SI_ORDER_SEVENTH = 0x0000006, /* seventh*/ - SI_ORDER_EIGHTH = 0x0000007, /* eighth*/ + SI_ORDER_FIRST = 0x0000000, /* first */ + SI_ORDER_SECOND = 0x0000001, /* second */ + SI_ORDER_THIRD = 0x0000002, /* third */ + SI_ORDER_FOURTH = 0x0000003, /* fourth */ + SI_ORDER_FIFTH = 0x0000004, /* fifth */ + SI_ORDER_SIXTH = 0x0000005, /* sixth */ + SI_ORDER_SEVENTH = 0x0000006, /* seventh */ + SI_ORDER_EIGHTH = 0x0000007, /* eighth */ SI_ORDER_MIDDLE = 0x1000000, /* somewhere in the middle */ - SI_ORDER_ANY = 0xfffffff /* last*/ + SI_ORDER_ANY = 0xfffffff /* last */ }; /* @@ -218,9 +218,9 @@ typedef void (*sysinit_nfunc_t)(void *); typedef void (*sysinit_cfunc_t)(const void *); struct sysinit { - enum sysinit_sub_id subsystem; /* subsystem identifier*/ - enum sysinit_elem_order order; /* init order within subsystem*/ - sysinit_cfunc_t func; /* function */ + enum sysinit_sub_id subsystem; /* subsystem identifier */ + enum sysinit_elem_order order; /* init order within subsystem */ + sysinit_cfunc_t func; /* function */ const void *udata; /* multiplexer/argument */ }; @@ -239,13 +239,13 @@ struct sysinit { #ifdef TSLOG struct sysinit_tslog { sysinit_cfunc_t func; - const void * data; - const char * name; + const void *data; + const char *name; }; static inline void -sysinit_tslog_shim(const void * data) +sysinit_tslog_shim(const void *data) { - const struct sysinit_tslog * x = data; + const struct sysinit_tslog *x = data; TSRAW(curthread, TS_ENTER, "SYSINIT", x->name); (x->func)(x->data); @@ -263,7 +263,7 @@ sysinit_tslog_shim(const void * data) sysinit_tslog_shim, \ &uniquifier ## _sys_init_tslog \ }; \ - DATA_WSET(sysinit_set,uniquifier ## _sys_init) + DATA_WSET(sysinit_set, uniquifier ## _sys_init) #else #define C_SYSINIT(uniquifier, subsystem, order, func, ident) \ static struct sysinit uniquifier ## _sys_init = { \ @@ -272,7 +272,7 @@ sysinit_tslog_shim(const void * data) func, \ (ident) \ }; \ - DATA_WSET(sysinit_set,uniquifier ## _sys_init) + DATA_WSET(sysinit_set, uniquifier ## _sys_init) #endif #define SYSINIT(uniquifier, subsystem, order, func, ident) \ @@ -289,7 +289,7 @@ sysinit_tslog_shim(const void * data) func, \ (ident) \ }; \ - DATA_WSET(sysuninit_set,uniquifier ## _sys_uninit) + DATA_WSET(sysuninit_set, uniquifier ## _sys_uninit) #define SYSUNINIT(uniquifier, subsystem, order, func, ident) \ C_SYSUNINIT(uniquifier, subsystem, order, \ From nobody Mon Dec 9 16:51:06 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 4Y6SYQ4gt8z5gWkb; Mon, 09 Dec 2024 16:51:06 +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 4Y6SYQ43XPz4bbv; Mon, 9 Dec 2024 16:51:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733763066; 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=oTULH1ftgxjJ97b9zKhNsBSquI38xcQkRVCx5uT01d0=; b=HXQ5HfzHpuBUGb6ZPbV01gGCHnBzUWpW+CQu1pLoxg/XDqOvE+0YJa6A6M7J7ecgH8hRRb iSiuVbc4F7MrLb6xwjXmIUzESuBIkf+5Eg8yRtArnxfOrAcGqFxUKDbdmeHgJ5AkQBCVC2 gF15QXseWp7o4E2C+gmn0TRgF1xEuqtO837FhEFlUBlv7O2WfRH7h21YPr4/J00zCauN9L 6s5IQbeMq1bZtaCWJ2WzKF6R81dueUqagXDbjsSJ+ZBAkHX7o1vys1fjnDTYipEvgnHxv5 bHSbjqm+LnR6713SgSTavanfRIb8oQbHcqP0YHqLzwzdU8YIJDW5jUvLUo5t0g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733763066; 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=oTULH1ftgxjJ97b9zKhNsBSquI38xcQkRVCx5uT01d0=; b=dR+7dFa+q9irS3t5970YwJGMei//aXpKxn9Isf9/VrRI9MK3WaaC1J5/txiVPeJpDQC4Ah HHHiQ92EZP7gJFKNhIfLtDa5sR0B6gebDZtW+2yIhZ8f54S+Rh8wEdeJBMdZNfaDwpWD2v dE1rKz/Nn8dmRyTGvUbBeHY7qOZ5Dp1HQWKWgtZJ/xMHeQRh8TRN2lkPQM6G7IC4Sj2IHU /Iv85KGxngtumkeO0ta/8uhXLaG///Uy62qs7q+O6v4umdaovtbE7j41JcTR+UHVjR7VYj T84DsUQQXWAphwm9FrubO0WniIha+08CwbkYzzXqzrq92QfAEDqi4zROShI7RQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733763066; a=rsa-sha256; cv=none; b=ywypsM8Xp0QbzX7ufliGuolxew44jgEK7f6qfIDd/+QIH9N8zk8oxNjnUzSV3N4S/RHsiy daijGn0agmt71zW1vMGUdP1+fMvSkdPsWQCzZs+FGDm/jWlYWMc67LA3aE5AGb+BMffpk1 WjGzOn+4zd6/SVNZ4AMpll4u+P9LdUJul+G9Ewfjg35eB5TEYi17aS9WhnEw1FKGeBwJOZ cvyeaujwpYKrEsBOMptPEKBOdBDdJ+lluwXPrBbIc3NRBjGf705pTtcP+l3m9TnsZtjw9a 1+BexST76f/l/EYaoVoR0Lk3D5AUNVBtvgWov+jBvqtoKDHuwmjz2thrqUiVOA== 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 4Y6SYQ3fn6zmLJ; Mon, 9 Dec 2024 16:51:06 +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 4B9Gp6mN085443; Mon, 9 Dec 2024 16:51:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9Gp6gl085440; Mon, 9 Dec 2024 16:51:06 GMT (envelope-from git) Date: Mon, 9 Dec 2024 16:51:06 GMT Message-Id: <202412091651.4B9Gp6gl085440@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alexander Motin Subject: git: 40fb1b8bc1cf - main - isp: Fix use after free in aborts handling 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: mav X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 40fb1b8bc1cf452d83edc5b25bc1d8bd13c0e72d Auto-Submitted: auto-generated The branch main has been updated by mav: URL: https://cgit.FreeBSD.org/src/commit/?id=40fb1b8bc1cf452d83edc5b25bc1d8bd13c0e72d commit 40fb1b8bc1cf452d83edc5b25bc1d8bd13c0e72d Author: Alexander Motin AuthorDate: 2024-12-09 16:47:03 +0000 Commit: Alexander Motin CommitDate: 2024-12-09 16:47:03 +0000 isp: Fix use after free in aborts handling When aborting command waiting in restart queue remove it from the queue before freeing it. This should fix NULL dereference panics we saw on some very busy system. MFC after: 2 weeks --- sys/dev/isp/isp_freebsd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/isp/isp_freebsd.c b/sys/dev/isp/isp_freebsd.c index fdf4c0eb4e1f..51c1e3abb6de 100644 --- a/sys/dev/isp/isp_freebsd.c +++ b/sys/dev/isp/isp_freebsd.c @@ -1904,11 +1904,11 @@ isp_target_mark_aborted_early(ispsoftc_t *isp, int chan, tstate_t *tptr, uint32_ STAILQ_FOREACH_SAFE(ntp, &tptr->restart_queue, next, tmp) { this_tag_id = ((at7_entry_t *)ntp->data)->at_rxid; if ((uint64_t)tag_id == TAG_ANY || tag_id == this_tag_id) { + STAILQ_REMOVE(&tptr->restart_queue, ntp, + inot_private_data, next); isp_endcmd(isp, ntp->data, NIL_HANDLE, chan, ECMD_TERMINATE, 0); isp_put_ntpd(isp, chan, ntp); - STAILQ_REMOVE(&tptr->restart_queue, ntp, - inot_private_data, next); } } From nobody Mon Dec 9 17:11:00 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 4Y6T0N2QSwz5gY1J; Mon, 09 Dec 2024 17:11:00 +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 4Y6T0N20Zfz4fV3; Mon, 9 Dec 2024 17:11:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733764260; 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=qrvD6hVHI6wI1EyC333Jn8ABSMEV/KzRRyfunucAgaE=; b=WVRfXWNxD+icss8oLP/VDXH4omnoxTaZaH3g+L+bsn/DH0AwUJPGnc0Ntsd1rWFX4htSOl KFYtm1Q/lgAn9dpBwe+W4zWUvq8TQAXy9vaycKgGOA96LgK+BYGCH9+97o0m1LiHe6wd6i GgvvP9Oe5TEtYvLESy0sly0EFsmnca5+SXZh5V+fDnVmZ8wHM2S6ELJ1K+35b1lurrelX5 IP9Z6uoypK4gmKKd4pgB/0JEdbZCEbmnjLV/zNu33Ek2XzTQjXqGnYjmHi/bXiP6B/vbQP AydUauwuGO1FIttgPlV3S/4AfIUMJr02L/iJXzM4r5rWj+wEQ6fLkDB0v+VFCQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733764260; 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=qrvD6hVHI6wI1EyC333Jn8ABSMEV/KzRRyfunucAgaE=; b=xjlMDwHthw2TJvqVIyit093a+4BY6Mpfj3SfTQxHNotWvNnEs0SOY/1RZzTseEVZd5Y2M7 oyqq+NnmqQYBA7s8fw18Xg2aGHNpf1gRVTk7lPp9F7uQMemUFL9kde6c3DlRvUaaNYcDF4 RciJB5xvAlhX7U17HktQqMcwk6EXEf7qqRdi5tRbrXjtCo5EEpLCJjtO4hbaft5/7feVml XaHTUT3IEDb4BVRrq46bC1n8tKoOv9XdPP70PhOcw52BeD8NGJPMf+mN+uwyoWEE4wl++W cOYM0iFoO5nN55q/NLSCN8Bk1Orc1H+Yia3nQiGT2wf07TSIqPW3whR9Uuh0wg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733764260; a=rsa-sha256; cv=none; b=ZufWBW584QDEVFL57B6RdgoBmz1p6FszQtSXmaG0n8ea3IHFdIDrOuR9MnxUIDObi/lUIU ZKTvzyABGzBfyH3WOrJofqeppnxU+mZL3m7OdKliheF1eg/ZQmpfft/G6pdEgNka+FL9sa O02kEpQkUcVpAOr099mz9QUSyeadF5fDr67NV1XRMjKxGqjJwW8+ltYq32stBPVm9abDJ9 kdGlLH+XNPPT13Pjsmmv7BLay6vG4ms9E4W4VPDXIrlgpO8pggHvi5WYxOcgharJLCfUcQ V/qGmNGB68kIvxjF2p+WgsdQfNXCRzPr7UEfmQ7XDUoE9OUXY5o3i/0TIeT0Rg== 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 4Y6T0N1Tbczmbd; Mon, 9 Dec 2024 17:11:00 +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 4B9HB0v7027487; Mon, 9 Dec 2024 17:11:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9HB06V027484; Mon, 9 Dec 2024 17:11:00 GMT (envelope-from git) Date: Mon, 9 Dec 2024 17:11:00 GMT Message-Id: <202412091711.4B9HB06V027484@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Alexander Motin Subject: git: ec3175fc3b2c - main - isp: Improve task aborts handling 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: mav X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ec3175fc3b2c1b07144a85e6a3e2fe534acc0c87 Auto-Submitted: auto-generated The branch main has been updated by mav: URL: https://cgit.FreeBSD.org/src/commit/?id=ec3175fc3b2c1b07144a85e6a3e2fe534acc0c87 commit ec3175fc3b2c1b07144a85e6a3e2fe534acc0c87 Author: Alexander Motin AuthorDate: 2024-12-09 16:52:26 +0000 Commit: Alexander Motin CommitDate: 2024-12-09 16:52:26 +0000 isp: Improve task aborts handling - When handling notify acknowledge from target code for task abort request, not only send abort to the firmware, but also delete the ATIO private data associated with the command. It is required for proper tag reuse, allowing new "conflicting" commands to be passed to the target. CTL was already fixed to handle that right, instead of delaying them in restart queue of the driver. - When target finally aborts the command (which it should have done before the notify ack) we should not send another abort to the firmware. Since we already sent the abort and deleted ATIO private data above, just return successful completion here, doing nothing. Since the tag can be reused by that time, we can not rely on its uniqueness, so when searching to the ATIO private data compare also the aborted CCB pointer in addition to the tag. - Fix BA_RJT sending in isp_acknak_abts(). While it should be rare, teach the code to send error responses for ABTS requests. MFC after: 2 weeks --- sys/dev/isp/isp_freebsd.c | 142 +++++++++++++++++++++------------------------- sys/dev/isp/isp_freebsd.h | 9 ++- sys/dev/isp/isp_target.c | 11 ++-- 3 files changed, 77 insertions(+), 85 deletions(-) diff --git a/sys/dev/isp/isp_freebsd.c b/sys/dev/isp/isp_freebsd.c index 51c1e3abb6de..d5aa7a54142e 100644 --- a/sys/dev/isp/isp_freebsd.c +++ b/sys/dev/isp/isp_freebsd.c @@ -626,8 +626,9 @@ isp_free_pcmd(ispsoftc_t *isp, union ccb *ccb) */ #ifdef ISP_TARGET_MODE static ISP_INLINE tstate_t *get_lun_statep(ispsoftc_t *, int, lun_id_t); -static atio_private_data_t *isp_get_atpd(ispsoftc_t *, int, uint32_t); +static atio_private_data_t *isp_get_atpd(ispsoftc_t *, int, uint32_t, void *); static atio_private_data_t *isp_find_atpd(ispsoftc_t *, int, uint32_t); +static atio_private_data_t *isp_find_atpd_ccb(ispsoftc_t *, int, uint32_t, void *); static void isp_put_atpd(ispsoftc_t *, int, atio_private_data_t *); static inot_private_data_t *isp_get_ntpd(ispsoftc_t *, int); static inot_private_data_t *isp_find_ntpd(ispsoftc_t *, int, uint32_t, uint32_t); @@ -715,7 +716,7 @@ isp_tmcmd_restart(ispsoftc_t *isp) } static atio_private_data_t * -isp_get_atpd(ispsoftc_t *isp, int chan, uint32_t tag) +isp_get_atpd(ispsoftc_t *isp, int chan, uint32_t tag, void *ccb) { struct isp_fc *fc = ISP_FC_PC(isp, chan); atio_private_data_t *atp; @@ -723,6 +724,7 @@ isp_get_atpd(ispsoftc_t *isp, int chan, uint32_t tag) atp = LIST_FIRST(&fc->atfree); if (atp) { LIST_REMOVE(atp, next); + atp->ccb = ccb; atp->tag = tag; LIST_INSERT_HEAD(&fc->atused[ATPDPHASH(tag)], atp, next); } @@ -742,6 +744,23 @@ isp_find_atpd(ispsoftc_t *isp, int chan, uint32_t tag) return (NULL); } +/* + * Similar to above, but in addition to tag searches for opaque CCB pointer, + * It can be used in situations when the tag alone may already be reused. + */ +static atio_private_data_t * +isp_find_atpd_ccb(ispsoftc_t *isp, int chan, uint32_t tag, void *ccb) +{ + struct isp_fc *fc = ISP_FC_PC(isp, chan); + atio_private_data_t *atp; + + LIST_FOREACH(atp, &fc->atused[ATPDPHASH(tag)], next) { + if (atp->tag == tag && atp->ccb == ccb) + return (atp); + } + return (NULL); +} + static void isp_put_atpd(ispsoftc_t *isp, int chan, atio_private_data_t *atp) { @@ -967,16 +986,6 @@ isp_target_start_ctio(ispsoftc_t *isp, union ccb *ccb, enum Start_Ctio_How how) continue; } - /* - * Is this command a dead duck? - */ - if (atp->dead) { - isp_prt(isp, ISP_LOGERR, "%s: [0x%x] not sending a CTIO for a dead command", __func__, cso->tag_id); - ccb->ccb_h.status = CAM_REQ_ABORTED; - xpt_done(ccb); - continue; - } - /* * Check to make sure we're still in target mode. */ @@ -1378,7 +1387,7 @@ isp_handle_platform_atio7(ispsoftc_t *isp, at7_entry_t *aep) */ goto noresrc; } - atp = isp_get_atpd(isp, chan, aep->at_rxid); + atp = isp_get_atpd(isp, chan, aep->at_rxid, atiop); if (atp == NULL) { isp_prt(isp, ISP_LOGTDEBUG0, "[0x%x] out of atps", aep->at_rxid); isp_endcmd(isp, aep, nphdl, chan, SCSI_BUSY, 0); @@ -1733,32 +1742,8 @@ isp_handle_platform_target_notify_ack(ispsoftc_t *isp, isp_notify_t *mp, uint32_ /* * This case is for a responding to an ABTS frame */ - if (mp->nt_lreserved && ((isphdr_t *)mp->nt_lreserved)->rqs_entry_type == RQSTYPE_ABTS_RCVD) { - - /* - * Overload nt_need_ack here to mark whether we've terminated the associated command. - */ - if (mp->nt_need_ack) { - abts_t *abts = (abts_t *)mp->nt_lreserved; - - ISP_MEMZERO(cto, sizeof (ct7_entry_t)); - isp_prt(isp, ISP_LOGTDEBUG0, "%s: [%x] terminating after ABTS received", __func__, abts->abts_rxid_task); - cto->ct_header.rqs_entry_type = RQSTYPE_CTIO7; - cto->ct_header.rqs_entry_count = 1; - cto->ct_nphdl = mp->nt_nphdl; - cto->ct_rxid = abts->abts_rxid_task; - cto->ct_iid_lo = mp->nt_sid; - cto->ct_iid_hi = mp->nt_sid >> 16; - cto->ct_oxid = abts->abts_ox_id; - cto->ct_vpidx = mp->nt_channel; - cto->ct_flags = CT7_NOACK|CT7_TERMINATE; - if (isp_send_entry(isp, cto)) { - return (ENOMEM); - } - mp->nt_need_ack = 0; - } - return (isp_acknak_abts(isp, mp->nt_lreserved, 0)); - } + if (mp->nt_lreserved && ((isphdr_t *)mp->nt_lreserved)->rqs_entry_type == RQSTYPE_ABTS_RCVD) + return (isp_acknak_abts(isp, mp->nt_lreserved, (rsp == 0) ? 0 : EINVAL)); /* * General purpose acknowledgement @@ -1890,17 +1875,15 @@ bad: } } +/* + * Clean aborted commands pending restart + */ static void isp_target_mark_aborted_early(ispsoftc_t *isp, int chan, tstate_t *tptr, uint32_t tag_id) { - struct isp_fc *fc = ISP_FC_PC(isp, chan); - atio_private_data_t *atp; inot_private_data_t *ntp, *tmp; uint32_t this_tag_id; - /* - * First, clean any commands pending restart - */ STAILQ_FOREACH_SAFE(ntp, &tptr->restart_queue, next, tmp) { this_tag_id = ((at7_entry_t *)ntp->data)->at_rxid; if ((uint64_t)tag_id == TAG_ANY || tag_id == this_tag_id) { @@ -1911,16 +1894,6 @@ isp_target_mark_aborted_early(ispsoftc_t *isp, int chan, tstate_t *tptr, uint32_ isp_put_ntpd(isp, chan, ntp); } } - - /* - * Now mark other ones dead as well. - */ - for (atp = fc->atpool; atp < &fc->atpool[ATPDPSIZE]; atp++) { - if (atp->lun != tptr->ts_lun) - continue; - if ((uint64_t)tag_id == TAG_ANY || atp->tag == tag_id) - atp->dead = 1; - } } #endif @@ -2283,6 +2256,25 @@ isp_kthread(void *arg) } #ifdef ISP_TARGET_MODE +static int +isp_abort_atpd(ispsoftc_t *isp, int chan, atio_private_data_t *atp) +{ + uint8_t storage[QENTRY_LEN]; + ct7_entry_t *cto = (ct7_entry_t *) storage; + + ISP_MEMZERO(cto, sizeof (ct7_entry_t)); + cto->ct_header.rqs_entry_type = RQSTYPE_CTIO7; + cto->ct_header.rqs_entry_count = 1; + cto->ct_nphdl = atp->nphdl; + cto->ct_vpidx = chan; + cto->ct_iid_lo = atp->sid; + cto->ct_iid_hi = atp->sid >> 16; + cto->ct_rxid = atp->tag; + cto->ct_flags = CT7_NOACK|CT7_TERMINATE; + cto->ct_oxid = atp->oxid; + return (isp_send_entry(isp, cto)); +} + static void isp_abort_atio(ispsoftc_t *isp, union ccb *ccb) { @@ -2308,30 +2300,16 @@ isp_abort_atio(ispsoftc_t *isp, union ccb *ccb) } /* Search for the ATIO among running. */ - atp = isp_find_atpd(isp, XS_CHANNEL(accb), accb->atio.tag_id); + atp = isp_find_atpd_ccb(isp, XS_CHANNEL(accb), accb->atio.tag_id, accb); if (atp != NULL) { - /* Send TERMINATE to firmware. */ - if (!atp->dead) { - uint8_t storage[QENTRY_LEN]; - ct7_entry_t *cto = (ct7_entry_t *) storage; - - ISP_MEMZERO(cto, sizeof (ct7_entry_t)); - cto->ct_header.rqs_entry_type = RQSTYPE_CTIO7; - cto->ct_header.rqs_entry_count = 1; - cto->ct_nphdl = atp->nphdl; - cto->ct_rxid = atp->tag; - cto->ct_iid_lo = atp->sid; - cto->ct_iid_hi = atp->sid >> 16; - cto->ct_oxid = atp->oxid; - cto->ct_vpidx = XS_CHANNEL(accb); - cto->ct_flags = CT7_NOACK|CT7_TERMINATE; - isp_send_entry(isp, cto); + if (isp_abort_atpd(isp, XS_CHANNEL(accb), atp)) { + ccb->ccb_h.status = CAM_UA_ABORT; + return; } isp_put_atpd(isp, XS_CHANNEL(accb), atp); - ccb->ccb_h.status = CAM_REQ_CMP; - } else { - ccb->ccb_h.status = CAM_UA_ABORT; } + + ccb->ccb_h.status = CAM_REQ_CMP; } static void @@ -2504,6 +2482,7 @@ isp_action(struct cam_sim *sim, union ccb *ccb) } case XPT_NOTIFY_ACKNOWLEDGE: /* notify ack */ { + atio_private_data_t *atp; inot_private_data_t *ntp; /* @@ -2522,8 +2501,19 @@ isp_action(struct cam_sim *sim, union ccb *ccb) xpt_done(ccb); break; } - if (isp_handle_platform_target_notify_ack(isp, &ntp->nt, - (ccb->ccb_h.flags & CAM_SEND_STATUS) ? ccb->cna2.arg : 0)) { + + /* + * Target should abort all affected CCBs before ACK-ing INOT, + * but if/since it doesn't, add this hack to allow tag reuse. + */ + uint32_t rsp = (ccb->ccb_h.flags & CAM_SEND_STATUS) ? ccb->cna2.arg : 0; + if (ntp->nt.nt_ncode == NT_ABORT_TASK && (rsp & 0xff) == 0 && + (atp = isp_find_atpd(isp, XS_CHANNEL(ccb), ccb->cna2.seq_id)) != NULL) { + if (isp_abort_atpd(isp, XS_CHANNEL(ccb), atp) == 0) + isp_put_atpd(isp, XS_CHANNEL(ccb), atp); + } + + if (isp_handle_platform_target_notify_ack(isp, &ntp->nt, rsp)) { cam_freeze_devq(ccb->ccb_h.path); cam_release_devq(ccb->ccb_h.path, RELSIM_RELEASE_AFTER_TIMEOUT, 0, 10, 0); ccb->ccb_h.status &= ~CAM_STATUS_MASK; diff --git a/sys/dev/isp/isp_freebsd.h b/sys/dev/isp/isp_freebsd.h index bd5bba92c0a9..5bb3dd43b6de 100644 --- a/sys/dev/isp/isp_freebsd.h +++ b/sys/dev/isp/isp_freebsd.h @@ -89,10 +89,11 @@ void isp_put_ecmd(struct ispsoftc *, isp_ecmd_t *); #include typedef struct atio_private_data { LIST_ENTRY(atio_private_data) next; + void * ccb; + uint32_t tag; /* typically f/w RX_ID */ uint32_t orig_datalen; uint32_t bytes_xfered; uint32_t bytes_in_transit; - uint32_t tag; /* typically f/w RX_ID */ lun_id_t lun; uint32_t nphdl; uint32_t sid; @@ -102,11 +103,9 @@ typedef struct atio_private_data { uint16_t word3; /* PRLI word3 params */ uint16_t ctcnt; /* number of CTIOs currently active */ uint8_t seqno; /* CTIO sequence number */ - uint32_t - srr_notify_rcvd : 1, - cdb0 : 8, + uint8_t cdb0; + uint8_t srr_notify_rcvd : 1, sendst : 1, - dead : 1, tattr : 3, state : 3; void * ests; diff --git a/sys/dev/isp/isp_target.c b/sys/dev/isp/isp_target.c index 081524aff53c..9d8f8e2a3766 100644 --- a/sys/dev/isp/isp_target.c +++ b/sys/dev/isp/isp_target.c @@ -481,10 +481,14 @@ isp_acknak_abts(ispsoftc_t *isp, void *arg, int errno) ISP_MEMCPY(rsp, abts, QENTRY_LEN); rsp->abts_rsp_header.rqs_entry_type = RQSTYPE_ABTS_RSP; + isp_prt(isp, ISP_LOGTINFO, "[0x%x] ABTS of 0x%x being %s'd", + rsp->abts_rsp_rxid_abts, rsp->abts_rsp_rxid_task, + (errno == 0) ? "BA_ACC" : "BA_RJT"); + rsp->abts_rsp_r_ctl = (errno == 0) ? BA_ACC : BA_RJT; + /* * Swap destination and source for response. */ - rsp->abts_rsp_r_ctl = BA_ACC; tmpw = rsp->abts_rsp_did_lo; tmpb = rsp->abts_rsp_did_hi; rsp->abts_rsp_did_lo = rsp->abts_rsp_sid_lo; @@ -505,15 +509,14 @@ isp_acknak_abts(ispsoftc_t *isp, void *arg, int errno) rx_id = rsp->abts_rsp_rx_id; ox_id = rsp->abts_rsp_ox_id; ISP_MEMZERO(&rsp->abts_rsp_payload.ba_acc, sizeof (rsp->abts_rsp_payload.ba_acc)); - isp_prt(isp, ISP_LOGTINFO, "[0x%x] ABTS of 0x%x being BA_ACC'd", rsp->abts_rsp_rxid_abts, rsp->abts_rsp_rxid_task); rsp->abts_rsp_payload.ba_acc.aborted_rx_id = rx_id; rsp->abts_rsp_payload.ba_acc.aborted_ox_id = ox_id; rsp->abts_rsp_payload.ba_acc.high_seq_cnt = 0xffff; } else { - ISP_MEMZERO(&rsp->abts_rsp_payload.ba_rjt, sizeof (rsp->abts_rsp_payload.ba_acc)); + ISP_MEMZERO(&rsp->abts_rsp_payload.ba_rjt, sizeof (rsp->abts_rsp_payload.ba_rjt)); switch (errno) { case ENOMEM: - rsp->abts_rsp_payload.ba_rjt.reason = 5; /* Logical Unit Busy */ + rsp->abts_rsp_payload.ba_rjt.reason = 5; /* Logical busy */ break; default: rsp->abts_rsp_payload.ba_rjt.reason = 9; /* Unable to perform command request */ From nobody Mon Dec 9 17:14:47 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 4Y6T4l52wmz5gY4d; Mon, 09 Dec 2024 17:14:47 +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 4Y6T4l461Qz4gLR; Mon, 9 Dec 2024 17:14:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733764487; 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=bH2DTZzVc8rpPtdqHTBFt9ai8VShLiZBBn/lBHwO0GE=; b=rwolde9PnIyTKC5Xf+IJP1rbNuOStbJRU/Mko/LntG7UENehTNAtul0UhYqkAeqDfdo6/0 u6twTTDJzIvONNfoKldKwm4wFP66pI6blXHpF3WCt3NuV2qYmU9i/r1Dh4JxPVe96hTdke /h+dsni7ExwKHqTJGZF/RFhFshB3qOwipMNcpgw7MwOv1kGiHkpkendBHQ9WJgrbtgvRil klnYKWjL2ALGMYg1P5ZIctjI7gSbHZDRwiCj3jkyhGUM8TGwX48bOvXzCE+lSkTjd3RJKP TrBomVsTKucznzsItaxOKGhPOs7d5vNgKVa3mA8sCyXV6ZV6lGwCUl90Daukjg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733764487; 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=bH2DTZzVc8rpPtdqHTBFt9ai8VShLiZBBn/lBHwO0GE=; b=RAb81AcXVV1i/hDHahqpbJzBJwby5KArkin6X/PNgMTW/edK66zb4TiQAZpHMyw5E+nVhZ wxvhtNjS8tAzDESUG5E2S8vE1MFssVaBtTREAdjvdpj6CgyL/7p0GEFAbBYyrLHSffHxGA 47h8CI/GFQF5m+Bz9gQVK2C0cw9oq28xc+Vha5MNQqbYcdEzgB/KYkOcgjyAaNiqfILHFn hbI8xPuYVxNpOowyy1gbUhL/r+SXtDYKavL0yKpZITEsUagiHS2FJOobLNJaf4fXqBBQ4m YirhoE81FsLTG59QQZ99y4qFV6rbIIFtQzTo/7JSRinIC8pALnFz1TqRxDAg2A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733764487; a=rsa-sha256; cv=none; b=FCp65bZb0NvKfbkIxY1dd/crL2ExtRb2v+3eyQaZHLbPweyLWBWb9hU6LnZ3q/FkS8zKsp XAupM3jgVmJERKplxOp4E40EJytU7DS13ShNTRHJ0mToRSbvJO/ZouSJiSPmSeQoB7K3NO 7x2C0ptMTzIXWdoYnwOAdDRN/NcRQae9QzWgMtKL3bddETlyX39n3sg0S4jvfgWgvV5CxB ArczaP3b6mpzHe/dkyZ2lj0sz/hvrnyawh7lrqaGKj9QkIc0o4e4G6K6vRsIWR5sYSbO12 dQzHW6MNMCtQS5aySqk5noB7euPmypAPE3kwksw9E9MhPXOKHaMmz98A5IvowA== 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 4Y6T4l3hxQzmcF; Mon, 9 Dec 2024 17:14:47 +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 4B9HElgM030841; Mon, 9 Dec 2024 17:14:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9HEl5Q030838; Mon, 9 Dec 2024 17:14:47 GMT (envelope-from git) Date: Mon, 9 Dec 2024 17:14:47 GMT Message-Id: <202412091714.4B9HEl5Q030838@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Zhenlei Huang Subject: git: 6854a1488932 - main - cuse: Use NULL for SYSUNINIT's last arg, which is a pointer type 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6854a1488932cd043da940b87eb956d6df7d8522 Auto-Submitted: auto-generated The branch main has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=6854a1488932cd043da940b87eb956d6df7d8522 commit 6854a1488932cd043da940b87eb956d6df7d8522 Author: Zhenlei Huang AuthorDate: 2024-12-09 17:14:07 +0000 Commit: Zhenlei Huang CommitDate: 2024-12-09 17:14:07 +0000 cuse: Use NULL for SYSUNINIT's last arg, which is a pointer type MFC after: 3 days --- sys/fs/cuse/cuse.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/fs/cuse/cuse.c b/sys/fs/cuse/cuse.c index e32154654386..d63a7d4691cf 100644 --- a/sys/fs/cuse/cuse.c +++ b/sys/fs/cuse/cuse.c @@ -332,7 +332,7 @@ cuse_kern_uninit(void *arg) mtx_destroy(&cuse_global_mtx); } -SYSUNINIT(cuse_kern_uninit, SI_SUB_DEVFS, SI_ORDER_ANY, cuse_kern_uninit, 0); +SYSUNINIT(cuse_kern_uninit, SI_SUB_DEVFS, SI_ORDER_ANY, cuse_kern_uninit, NULL); static int cuse_server_get(struct cuse_server **ppcs) From nobody Mon Dec 9 17:14:48 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 4Y6T4m606pz5gXvp; Mon, 09 Dec 2024 17:14:48 +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 4Y6T4m5QpPz4gT8; Mon, 9 Dec 2024 17:14:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733764488; 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=ITc9dIBK9LdStibNxyWmPDmG/XooJAcbi2npeXbztPQ=; b=Zq/zmQGOYg1oazpXueGmZQVm992OVvfyCnzVP021Pm7e217rWSvbkb5kxehO/9B+vc5/IJ YRSpGmwVD8+wsyHLzBqIYMpV65xjdHM34fYBst8lsBzQ04AnbrN/2xltrWUkL3w5MEFgmt xEl9WRTtdnPPU/hZhiyISerVu4eYDFlnHXyCJkVRe/ToP0mNBNj1zoShCQJkq/Ob+OChdf TUfd8jo3cyiNjzB0FhUR5tioJ/wVeYD+tDdpfGtJ6zGJdgLePyuPPD+t8NCQxXoWVd1LUb eYfn1SG1BbW7T8Cw0j/bCwryay95uGyP4OY2APAOFs97JeQam4FPXGLK0ns5tA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733764488; 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=ITc9dIBK9LdStibNxyWmPDmG/XooJAcbi2npeXbztPQ=; b=HRPXRJdFuxPtZQ+BP81g2X2zU3oLxAhIeXaazuLClziz+YxRiGUPas7SsuIVSbAoviKur7 1iT8hz1BkKumnXOvO3BffaLfBE4QspcUFQWpei5QDSEoZqdLU3weiMdCOhZiOClMk5WZE6 RxIMMhjgrGXz0smgKz4dTkXz4elxb/+6xFGD+SNuVGO2nDFCJoq0h7DcV02Bf6z+ZhNtOp roAB9HMVAk4qdhmKMcWciGNxrJNuhmSQv5wdjtzhKSlA1GTlK6/4UE0GOaeMxOjltoQNF6 RKjg3+yaqi9alcfwUmutykcGzF6CqEwfr8D14/UMaoqlyetDI66JeOab1x4vbA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733764488; a=rsa-sha256; cv=none; b=d6zoDebj/Q7v9vtV8wa3AyTIx0pJ6Tilf4Ld+pvekLyIBN/iZe8cBAAdF46bNQ2Ch5eiaY icnmziin4K3iv7XDasAfycuA6Ej6FVp02rxigfN77b3xHEcgDvcU1ritD5H2BSmr0J8+wI ji/xhhhnPZm3uzcfmgqXMVIapTLo0a7VV2hYUijCgbSg7rSd3qrIQJdYzByMMpWg8ferlR dJEQ1rCUAbz/t/q03X3yK9O821pYXAw5GwIv3KGpGofYajBSa+6bavwJVsHb4VKYb4g72B fC+wlTzrHLJBoThqyUIJrSV5OGBlqQdvX8CrZOzZHx1Ccp5r7w1I9gvoUunXNw== 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 4Y6T4m52Cszmqk; Mon, 9 Dec 2024 17:14:48 +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 4B9HEmTX030916; Mon, 9 Dec 2024 17:14:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9HEmNI030913; Mon, 9 Dec 2024 17:14:48 GMT (envelope-from git) Date: Mon, 9 Dec 2024 17:14:48 GMT Message-Id: <202412091714.4B9HEmNI030913@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Zhenlei Huang Subject: git: 12b2d68bed37 - main - routing: Use NULL for VNET_SYS[UN]INIT's last arg, which is a pointer type 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 12b2d68bed37e379929cd9b5e0afe34c387be360 Auto-Submitted: auto-generated The branch main has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=12b2d68bed37e379929cd9b5e0afe34c387be360 commit 12b2d68bed37e379929cd9b5e0afe34c387be360 Author: Zhenlei Huang AuthorDate: 2024-12-09 17:14:08 +0000 Commit: Zhenlei Huang CommitDate: 2024-12-09 17:14:08 +0000 routing: Use NULL for VNET_SYS[UN]INIT's last arg, which is a pointer type MFC after: 3 days --- sys/net/route/route_tables.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/net/route/route_tables.c b/sys/net/route/route_tables.c index da829503b846..176ca43fa1c5 100644 --- a/sys/net/route/route_tables.c +++ b/sys/net/route/route_tables.c @@ -314,7 +314,7 @@ vnet_rtables_init(const void *unused __unused) RTABLES_UNLOCK(); } VNET_SYSINIT(vnet_rtables_init, SI_SUB_PROTO_DOMAIN, SI_ORDER_FOURTH, - vnet_rtables_init, 0); + vnet_rtables_init, NULL); #ifdef VIMAGE static void @@ -353,7 +353,7 @@ rtables_destroy(const void *unused __unused) #endif } VNET_SYSUNINIT(rtables_destroy, SI_SUB_PROTO_DOMAIN, SI_ORDER_FIRST, - rtables_destroy, 0); + rtables_destroy, NULL); #endif static inline struct rib_head * From nobody Mon Dec 9 17:14: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 4Y6T4p0q8Xz5gXsy; Mon, 09 Dec 2024 17:14:50 +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 4Y6T4n6gMYz4gTM; Mon, 9 Dec 2024 17:14:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733764489; 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=7CBl/TnYXa1fVKHPD5hXLe6mtl34jtLhQ/nLmvk3zdw=; b=oWhpIXvMxmKPV74CR4dWiL78K4Ng2NlSJ/nCFea9rkSBLptC9eCX2pdqUFhsQF1YzkGLVX +SfjJ5Rh1OJa+s1yur8XONs6VFuYnLFhQ567HCAK0G7NG1TQJVgt8ZNqpEDIOOHJ3D6fRR NRQusCMrBW5+soZE6srH5NTuGNVC4gqzSOQUM10nXhG6n2oTF/NnXoP6g1XczeytSl8GDM gjARRhvvsJi6/0z+C/NJntNzX7tFQIy9R/mUeYjHEYoTkuhAXQSuB1EMvmSxExongvY67/ oPm0S86SPN3J4st6iZ39+ifBhFCNljahgEAZty2Ndshn7kBANF3l7wB8unw7zQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733764489; 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=7CBl/TnYXa1fVKHPD5hXLe6mtl34jtLhQ/nLmvk3zdw=; b=IPxwxA/KAUZTGuoz7XhEpaSIwUsMIHkCJY9jplpl4X9ctacwMbT6RywQIcIgwlJpOErBnv HDgL+Fxg9AhqAlb5qL2Mh8PJIbxQ4XgxNDWdTuqLQGJhGtMF5sbKEBv/rBuZ+mVQZdPvMK MI7jtIdo2RhQ3hXByx9pN3N4nRjne0W9ojRLu6ok6hTDQ5t7sHvbxdxgubZI2JdFZ7qTdr Hy1O19fcSgkU0e2kyTqUZx6g7RjUNc5SGlKLfrBCNKatOhE84RuWTatvRmdtzyFZH/e84H dFk1LHJA8QbbQIhSnUMCAsQ/haG46l/u+PXoTvFQWTylYjvEoKE4hIRjvd0Kyg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733764489; a=rsa-sha256; cv=none; b=anwfrr9btEybUg5VCnKs4O1frFj3F7gq/WgnaUeGRoz25MRhExSRj2SvmI3WPseaJRXP47 QB9GAXdJOz0z6tEDwYsrVRI7HkhPRWqgJ4XnOiNK0by0iKqEJQ/TEfYbcWZIAm7rEfTIsy cYP8M3zgmk6q99J68JCYUSs+Lwj/+G0CoMch302Me1F6OdLdQKA1eS9NkEzTuSHYe+tkgc D++muQV0ZSHFRjVEDgwQ5E+GQM0Gmata1iASjuoZZqZ/lFx47xyaTFs2At2WPQfBX1GvJX uheY8umd7oeGtnF7Iq63jYXVdpZVe0XRYZ5IafTJJi6so9UT1nn2+cas8KDznQ== 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 4Y6T4n66T1zmDf; Mon, 9 Dec 2024 17:14: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 4B9HEnxF030996; Mon, 9 Dec 2024 17:14:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9HEnBE030993; Mon, 9 Dec 2024 17:14:49 GMT (envelope-from git) Date: Mon, 9 Dec 2024 17:14:49 GMT Message-Id: <202412091714.4B9HEnBE030993@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Zhenlei Huang Subject: git: adc573c8e217 - main - rtsock: Use NULL for VNET_SYS[UN]INIT's last arg, which is a pointer type 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: adc573c8e2179310777cef4d6bda19db2ae63dd5 Auto-Submitted: auto-generated The branch main has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=adc573c8e2179310777cef4d6bda19db2ae63dd5 commit adc573c8e2179310777cef4d6bda19db2ae63dd5 Author: Zhenlei Huang AuthorDate: 2024-12-09 17:14:08 +0000 Commit: Zhenlei Huang CommitDate: 2024-12-09 17:14:08 +0000 rtsock: Use NULL for VNET_SYS[UN]INIT's last arg, which is a pointer type MFC after: 3 days --- sys/net/rtsock.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/net/rtsock.c b/sys/net/rtsock.c index a5395dcf1469..ce5ec9ce22af 100644 --- a/sys/net/rtsock.c +++ b/sys/net/rtsock.c @@ -261,7 +261,7 @@ vnet_rts_init(void) #endif } VNET_SYSINIT(vnet_rtsock, SI_SUB_PROTO_DOMAIN, SI_ORDER_THIRD, - vnet_rts_init, 0); + vnet_rts_init, NULL); #ifdef VIMAGE static void @@ -271,7 +271,7 @@ vnet_rts_uninit(void) netisr_unregister_vnet(&rtsock_nh); } VNET_SYSUNINIT(vnet_rts_uninit, SI_SUB_PROTO_DOMAIN, SI_ORDER_THIRD, - vnet_rts_uninit, 0); + vnet_rts_uninit, NULL); #endif static void From nobody Mon Dec 9 17:14:50 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 4Y6T4q2FHNz5gXt2; Mon, 09 Dec 2024 17:14:51 +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 4Y6T4p6zWnz4gWR; Mon, 9 Dec 2024 17:14:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733764491; 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=F4TeeuvUZ0rRWGFAUMZKxdQIeKo2uN1NlJivIsJ7omA=; b=dRO3qd9VcAKUdE+M74KYDBDR7y264h9UwUR89rRg33Un7/ZLEC7q5ymlgrHlMEV1XECH4M DYRYYJKd/OEuzz/ZRLpiKYvvUnlM5uGTz9k+gH36hKJk2hTkiQAWBnLyWaxolAp31Vn8hK N6QLC1tE2phpgfsgUmd4sKjqJvUjPtKFYZLH0ASEz6dAubQ85eVStxRVXGTe5OTGr6FLt+ 6SNKoM1IOlRiKHtngt9xpAPSvkW8bzEX2xCNHBWSPmanwSAEh0LlqBVFZg1u4eedd5rBqX C/5lsNnmOazHs/y0dGELNN2QA5kBA9WcC9RKjT94cHJEzaUXKyQkufXjErNbuA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733764491; 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=F4TeeuvUZ0rRWGFAUMZKxdQIeKo2uN1NlJivIsJ7omA=; b=FU7nteo32MONyh9OK/crwMM3gNAU4AGvb7XIqEHsYP4VECDq4S/mQ4A0lgETwot/SHqQSE WP1DiAI1Uf3s9cZKy8zXmi+YuJJgdvyaLkcNls/c/cZBqCCsvMr735dzgUYFvz1e95D0GB cprvHzLw+Ql7ilrsJdnvCCzUaZqxwdCQhHPKgmziCM8o2G2wJYqUJa8W6x3mJcmYcfzh6I bT1JT4d7lQ0eCdXe9fJQRJayaJ4LVlZDUjEVW7Y3ndW0fH+4Q9pEN5LV0v37uD9+WFxYj1 V3AiMggyIbBMDRJN7/WEQN6d91Rs6WFfRefbnAwxHhRzjk0yvB89g/LE5sjltw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733764491; a=rsa-sha256; cv=none; b=sepa1GSNQYrHiET/L1TTvbMK3ovh69Vsadpd5phnCk+0DVpw/EWVgaB/7/k2euqH9lufXk Y/g1U9kY8Hu0X5QiOCZ57V9G3l4wKoVJI0JDe4VYLHRc5SXynFLLZTxpWuz5ZGA8+6XUUB FbEzLOLAQMPkMAJ62DQN7tg2/ZQTjvkbtsn4iWQs5oTPGLkT8KYfPTIcICNvgpwIZdPX1S MqFybkh96e0aJe0y9MhB3UQGyIwGhQdVrumF2fTahc7nP5Ix3NastGlchez0ZVfGvtEEle hiG1Yn5IjB5HOLxlG1338gzq2en2A0JWzhKIfVuhijgM/rhWoGJu+o3j1UPo7g== 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 4Y6T4p6bswzmDg; Mon, 9 Dec 2024 17:14:50 +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 4B9HEoB3031059; Mon, 9 Dec 2024 17:14:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9HEotj031056; Mon, 9 Dec 2024 17:14:50 GMT (envelope-from git) Date: Mon, 9 Dec 2024 17:14:50 GMT Message-Id: <202412091714.4B9HEotj031056@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Zhenlei Huang Subject: git: ec6e7677a0db - main - inpcb: Use NULL for VNET_SYSINIT's last arg, which is a pointer type 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ec6e7677a0dbfbcdb4b740b28a1105256f1fc93e Auto-Submitted: auto-generated The branch main has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=ec6e7677a0dbfbcdb4b740b28a1105256f1fc93e commit ec6e7677a0dbfbcdb4b740b28a1105256f1fc93e Author: Zhenlei Huang AuthorDate: 2024-12-09 17:14:08 +0000 Commit: Zhenlei Huang CommitDate: 2024-12-09 17:14:08 +0000 inpcb: Use NULL for VNET_SYSINIT's last arg, which is a pointer type MFC after: 3 days --- sys/netinet/in_pcb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netinet/in_pcb.c b/sys/netinet/in_pcb.c index 1309d19121cd..87489e8f457c 100644 --- a/sys/netinet/in_pcb.c +++ b/sys/netinet/in_pcb.c @@ -232,7 +232,7 @@ in_pcbhashseed_init(void) V_in_pcbhashseed = arc4random(); } VNET_SYSINIT(in_pcbhashseed_init, SI_SUB_PROTO_DOMAIN, SI_ORDER_FIRST, - in_pcbhashseed_init, 0); + in_pcbhashseed_init, NULL); #ifdef INET VNET_DEFINE_STATIC(int, connect_inaddr_wild) = 1; From nobody Mon Dec 9 17:14:52 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 4Y6T4r2mTjz5gYLh; Mon, 09 Dec 2024 17:14:52 +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 4Y6T4r1Fvsz4gWq; Mon, 9 Dec 2024 17:14:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733764492; 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=pLBZgBi+8/RtAq8o9cixEdATELEUCJmwLlq3U6l9FDU=; b=I/MWxhj96fPoZIO5HMztFHVMYiKEeGUzOXkRi1tR0dhqUO1gi6z0xrTLnC4u1Xyhn3Mz8h HxMo5Y+g7T/Rw22SN9Bp0GV6T7TpGn0tDHPX0ydN5OxUl9lNSnjOuHYNAxytvvuglM4IAw G7YcDwlrlub4xSZ9222/GV4Dj+Uj5rz+Wv+YcGG4kPbNQvB/RlNhRKhPVnRruJPGk2yE86 A6Lpm+ckke3KubLylx2+aYP8PjMTKIh6MfCO6xYbEaGJNJ7DJPJHdSoidw5A+cVfN0uJl7 QwqkCXNG1KHuEP/qD7Kmwoii26A+XFJ/MBgI668bdCOkCWiV2Q0shD3WR8IVRA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733764492; 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=pLBZgBi+8/RtAq8o9cixEdATELEUCJmwLlq3U6l9FDU=; b=Hjpj0mmBXRaMaz9Uv1Luo3aACTnluAPrc26cnaznj+3sPdIWHpnsPo/BhiCKt5ZzLPmJgc jSot65GnuruHGf0tti0ncCJctqPUVRlcAHKSDfrIjq3+R4zbVTWxUcrojsaMkYO20rXdBJ wNhthCqKrG/2PhzOF+HFuFex9rxJUzXfcM6eYFIfwTwgHroUay7GMmyWRnxqad3rMrK444 FkNzMRnReWzLB1ZRU8EOs0BwXULpNBOvi675Zpym1qMdS5+njvI/5zWGty8tk4QIHhTDAu gCYGw30yaGoh6byoZitdd9IROmImECf3222UE8rAjb9QELsn6riIcHGNJPwREA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733764492; a=rsa-sha256; cv=none; b=ZRzUvtV6DlUdjPTAGd+9LLoFCUBsb4Krp9YSBgWAmG/zu4XbWjmVHZN4ivEn9THrvcE08E MyefDzh0KQihSiGQzkP7B8+RkmGigHgLRXyv1s4dhswu6XlCJuPSAr95NuW0lY1t47akCq scx8wnaTkiYtQMKNsEYrCHMUg7EkJIE8mhWwxZqUZnzDTwY21K0uA3LwO57LajZ9ztwOj3 GfJAR/jd0G8nDIeTs9grtkzjSBBkTAZQiZJ7mltWlDPdYX+Aql9ljCUpRT+qqfpZHp2YhJ wpxMk8ZCKCBM02DHej989RInoj0mqMx7fbhkLGT8wWqmJkLaU0yRLN6J7mdX3Q== 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 4Y6T4r0sSQzmDh; Mon, 9 Dec 2024 17:14:52 +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 4B9HEqRL031122; Mon, 9 Dec 2024 17:14:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9HEqAj031119; Mon, 9 Dec 2024 17:14:52 GMT (envelope-from git) Date: Mon, 9 Dec 2024 17:14:52 GMT Message-Id: <202412091714.4B9HEqAj031119@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Zhenlei Huang Subject: git: ac51711cab6e - main - netinet: Use NULL for VNET_SYSINIT's last arg, which is a pointer type 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ac51711cab6e55a99ee0a565fe0ae30c0305c854 Auto-Submitted: auto-generated The branch main has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=ac51711cab6e55a99ee0a565fe0ae30c0305c854 commit ac51711cab6e55a99ee0a565fe0ae30c0305c854 Author: Zhenlei Huang AuthorDate: 2024-12-09 17:14:08 +0000 Commit: Zhenlei Huang CommitDate: 2024-12-09 17:14:08 +0000 netinet: Use NULL for VNET_SYSINIT's last arg, which is a pointer type MFC after: 3 days --- sys/netinet/if_ether.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netinet/if_ether.c b/sys/netinet/if_ether.c index 543e6a3922fb..81f4b901f21b 100644 --- a/sys/netinet/if_ether.c +++ b/sys/netinet/if_ether.c @@ -1506,7 +1506,7 @@ vnet_arp_init(void) #endif } VNET_SYSINIT(vnet_arp_init, SI_SUB_PROTO_DOMAIN, SI_ORDER_SECOND, - vnet_arp_init, 0); + vnet_arp_init, NULL); #ifdef VIMAGE /* From nobody Mon Dec 9 17:56:16 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 4Y6V0d0cj5z5gbFV; Mon, 09 Dec 2024 17:56:17 +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 4Y6V0c6xT0z4p49; Mon, 9 Dec 2024 17:56:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733766977; 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=TK0uOn+mz+jRXbtnYedwveU6UotQjGwpVk7aUMRxSvc=; b=NzOJfvYJ+qDvc9ZpRMXxihPKClvtyQCLIaQhUNkRN0C+tYjl4+xUv5Hj+FLImcsQ7uj6I3 AH8qYw0Q83DBqjp/Mk6iNEJ5EUR58ezDfmJ5aWD+lLL+b7EsXHpTsiwHZsISBbb8hchApt HwZ6B0SkAK0XIL+ekCTZghLa0leUBHyvM94xyFyTuI6HO8ZL29l0iI8pS0V3zXT1EgRyaM WnN/shxfJ2I253Pb4R8w9tfaBSmDWuEf4+mzgKNsY86hW0WWpI7dd/hyGks8ttmWavT0WF GGlD43K3VU9N4ssKvKf+1RLisyexPUufN/EcJzXVtqYG1qzvr2YAibjpJ/1YGQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733766977; 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=TK0uOn+mz+jRXbtnYedwveU6UotQjGwpVk7aUMRxSvc=; b=HvJQGlb78EWTv2Rla1myFiXDCBl2fIWW9bEopZrefHaceS2e/UBkF+R4kO9f7kXiaxb/jw rwxRXG2C3afUUNN4gRh7V9KM/Jxm4eK5H7cF8BQU53b8wXGxx6pLyku0Ut0HumXW1E+RpV eTbzJHm/yyZlDu/Th5iBAMuhDQIltC5Q4ngBpC4f4M7Uf0z8kgjW26Nb20amffzfc7zXDd xs6uMiKmait6XLRieKYsTuho1tz05m7YUYoAvs/3v6UQ4qd3vHat9vhX0gPAsJnSrMxgQ3 z/beAEcEfHDiTfQRF4I/sIaxzK7lRXvPdGTmSarAezNlN00RtU/x1HMoYybPpA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733766977; a=rsa-sha256; cv=none; b=eQRGE8YvBY/73UzgrSIEo1Ejy+lHK+y3OHq0FUkW4QfHek6XlY8H4U7mqh9VHZesnyirGL iV1dKUdq0JDG3uEvjJ70lXFJNXFziEccrtndH08/0suO1XSOpKYrzwACR7M/WA9BSF7Fu/ RdRMCEPGwzZy6NtkbVphawys6KFXjV83K34H310YC5dzoqF3Gq5qapL1Qc3GZ23bwM7oCX /Fy0OqymPa52r3BPZ6Q9/xwH9J97SQRbyhYoxdVI9p8kyyIGr2YW6kctOjm+KsSbdk9csp rG1TH7RrsTudnN28fmrPjL7U4H0mUAMQDGMv+ZZjhAG1XrrCYEAig1XGFCDr/A== 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 4Y6V0c6X9Gznh4; Mon, 9 Dec 2024 17:56:16 +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 4B9HuGV7004953; Mon, 9 Dec 2024 17:56:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9HuG1G004950; Mon, 9 Dec 2024 17:56:16 GMT (envelope-from git) Date: Mon, 9 Dec 2024 17:56:16 GMT Message-Id: <202412091756.4B9HuG1G004950@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Brooks Davis Subject: git: 3ca117c6bb1d - main - mandoc: drop 3p section 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: brooks X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 3ca117c6bb1dffaa3542f58339154a7dd166d169 Auto-Submitted: auto-generated The branch main has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=3ca117c6bb1dffaa3542f58339154a7dd166d169 commit 3ca117c6bb1dffaa3542f58339154a7dd166d169 Author: Brooks Davis AuthorDate: 2024-12-09 17:25:36 +0000 Commit: Brooks Davis CommitDate: 2024-12-09 17:25:36 +0000 mandoc: drop 3p section The 3p is an OpenBSD thing and this list of sections is otherwise entierly customized to FreeBSD. Reviewed by: imp, bapt Differential Revision: https://reviews.freebsd.org/D47948 --- contrib/mandoc/msec.in | 1 - 1 file changed, 1 deletion(-) diff --git a/contrib/mandoc/msec.in b/contrib/mandoc/msec.in index fc198202fbf1..1d7518a5e43d 100644 --- a/contrib/mandoc/msec.in +++ b/contrib/mandoc/msec.in @@ -26,7 +26,6 @@ LINE("1", "FreeBSD General Commands Manual") LINE("2", "FreeBSD System Calls Manual") LINE("3", "FreeBSD Library Functions Manual") LINE("3lua", "Lua Library Functions Manual") -LINE("3p", "Perl Library Functions Manual") LINE("4", "FreeBSD Kernel Interfaces Manual") LINE("5", "FreeBSD File Formats Manual") LINE("6", "FreeBSD Games Manual") From nobody Mon Dec 9 19:22:57 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 4Y6Wwv0PMTz5ggxT for ; Mon, 09 Dec 2024 19:23:11 +0000 (UTC) (envelope-from jrtc27@jrtc27.com) Received: from mail-wr1-f42.google.com (mail-wr1-f42.google.com [209.85.221.42]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Y6Wwt4VzZz42dk for ; Mon, 9 Dec 2024 19:23:10 +0000 (UTC) (envelope-from jrtc27@jrtc27.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-wr1-f42.google.com with SMTP id ffacd0b85a97d-3863494591bso1213682f8f.1 for ; Mon, 09 Dec 2024 11:23:10 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1733772189; x=1734376989; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=/trqQltnxaFmieXyrCpU3ggCuBHAzyvWY0HquB88V/E=; b=hFRRonmOVH5U9vi3Q+X7Wa6PMYVFgDDyCQLPtj+Nh1OW7MFvAB73POqpheU4pCgi5K 0CNCvUQM0EVpma6U/niO8NwNffGgD1RBUKL5ICy0V4gL0Jca3YO2ZQTf9MIeWTFChY7J u51wmwyLGO//PRvd362b3/anhCus4hI5UdIY7xnll6/spL7bhkg5WQ35jc7rj+EOabW+ hwni6oQ49mjwShVbR9SOvWzqk4Gv4xGQ3giiJQ1+1X8POHlHdTlDYxWdw7Gu6C0lCb3r 3HLwzcWT+IQaIeA1OeU/pKwLG36YICiHH3oc5IUuUgWyzLvKh+J4EAwmTp5AsHADbygW XtUA== X-Forwarded-Encrypted: i=1; AJvYcCWnkb02LD5bHFspGLQL4w0MRAVPjxCVQW/IjQBiDLHnwMCeEibj9CtVMoXZf3rVte0Plc/bwJfdURZkAn93Bh/OOZH7@freebsd.org X-Gm-Message-State: AOJu0YyMVdoG7PeyX/2OqZt8QIX1t6cPfMTDmxiC8jcFW7nsYw4J7drT KaIxBuXmceKrGdCMiqePVl025fV0CFLetPBGUaIbpSz2rw0kK0lrXge3wedu9Fs= X-Gm-Gg: ASbGnctGxftywqk8vdvJ1qOPjobS2uvvEM4SpQ4w3yH2Brg9RfL/02GFybiKakBnnLc FAlT7R1LDdS0g8FBZ5B4q8ycUCPwxnzjzXrynd5/f+e0UMwTNemN+hNd+9Boqx1soXMRR584e6T GNqzx9O5myzWSVrIsxrC2PGh4zbb3SIwZ1P1r1zrFPhpxVPPTKImXCBQEYen0+WICZFnoeAiJXK m/xAwfybkVSDMW/TaYzsJ0SlHxoTWC7zfYMSeWqKRk5or2YwMp676eXRJQr+bNF X-Google-Smtp-Source: AGHT+IEuMTWONBjsYG1bzTWhye4LeQv1ijKw3Ke6mUJj6s1oEU8hoqO3Xdt+Kwnyx2wJJfnEdx4pyQ== X-Received: by 2002:a05:6000:1fa5:b0:385:e38f:8cc with SMTP id ffacd0b85a97d-386453f691emr1345679f8f.38.1733772188611; Mon, 09 Dec 2024 11:23:08 -0800 (PST) Received: from smtpclient.apple ([131.111.5.201]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-38621fbbdd8sm13882239f8f.95.2024.12.09.11.23.07 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 09 Dec 2024 11:23:08 -0800 (PST) Content-Type: text/plain; charset=utf-8 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 (Mac OS X Mail 16.0 \(3826.200.121\)) Subject: Re: git: 87e140a5c6f8 - main - iwlwifi: avoid (hard) hang on loading module From: Jessica Clarke In-Reply-To: <202412091447.4B9ElFBH050286@gitrepo.freebsd.org> Date: Mon, 9 Dec 2024 19:22:57 +0000 Cc: "src-committers@freebsd.org" , "dev-commits-src-all@freebsd.org" , "dev-commits-src-main@freebsd.org" Content-Transfer-Encoding: quoted-printable Message-Id: <6F9C2C43-A3DD-4CF5-AC27-899FE139E9A6@freebsd.org> References: <202412091447.4B9ElFBH050286@gitrepo.freebsd.org> To: "Bjoern A. Zeeb" X-Mailer: Apple Mail (2.3826.200.121) X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:15169, ipnet:209.85.128.0/17, country:US] X-Rspamd-Queue-Id: 4Y6Wwt4VzZz42dk X-Spamd-Bar: ---- On 9 Dec 2024, at 14:47, Bjoern A. Zeeb wrote: >=20 > The branch main has been updated by bz: >=20 > URL: = https://cgit.FreeBSD.org/src/commit/?id=3D87e140a5c6f89eea7ea6320d1ae34566= 492abfc0 >=20 > commit 87e140a5c6f89eea7ea6320d1ae34566492abfc0 > Author: Bjoern A. Zeeb > AuthorDate: 2024-12-08 20:24:10 +0000 > Commit: Bjoern A. Zeeb > CommitDate: 2024-12-09 14:45:24 +0000 >=20 > iwlwifi: avoid (hard) hang on loading module >=20 > For certain users or chipsets (reports were for CNVi devices but > we are not sure if this is limited or specific to them) loading > if_iwlwifi hangs. >=20 > The reason for this is that a SYSINIT (module_load_order()) has not > yet run in this case and the Linux driver tries to load the > chipsets-specific module. On FreeBSD all supported sub-modules are > part of if_iwlwifi so we do not have to load them separately but > calling into kern_kldload via LinuxKPI request_module while loading > the module gives us a hard hang. >=20 > iwlwifi calls request_module_nowait() so we can simply skip over = this > and continue and the SYSINIT will do the job later if no other > dependencies fail. >=20 > Sponsored by: The FreeBSD Foundation > MFC after: 3 days > PR: 282789 > Tested by: Ruslan Makhmatkhanov, Pete Wright > Differential Revision: https://reviews.freebsd.org/D47994 > --- > sys/contrib/dev/iwlwifi/iwl-drv.c | 13 +++++++++++++ > 1 file changed, 13 insertions(+) >=20 > diff --git a/sys/contrib/dev/iwlwifi/iwl-drv.c = b/sys/contrib/dev/iwlwifi/iwl-drv.c > index 7f4746e5591e..61e5c064de80 100644 > --- a/sys/contrib/dev/iwlwifi/iwl-drv.c > +++ b/sys/contrib/dev/iwlwifi/iwl-drv.c > @@ -1749,7 +1749,20 @@ static void iwl_req_fw_callback(const struct = firmware *ucode_raw, void *context) > goto out_unbind; > } > } else { > +#if defined(__linux__) > request_module_nowait("%s", op->name); > +#elif defined(__FreeBSD__) > + /* > + * In FreeBSD if_iwlwifi contains all drv modules in a single > + * module. SYSINIT will do the job later. We cannot call > + * into kern_kldload() while being called from kern_kldload(): > + * LinuxKPI request_module[_nowait] will hang hard. > + * Given this is request_module_nowait() we can simply skip it. > + */ > + if (bootverbose) > + printf("%s: module '%s' not yet available; will be" > + "initialized in a moment\n", __func__, op->name); Missing a space in the string. Also, why not just have request_module_nowait itself defer the load until it can be done, at which point it can notice that there=E2=80=99s = nothing to do? Jess > +#endif > } > mutex_unlock(&iwlwifi_opmode_table_mtx); >=20 From nobody Mon Dec 9 19:45:19 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 4Y6XQS0X2lz5ghvl; Mon, 09 Dec 2024 19:45:20 +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 4Y6XQS00DVz44P7; Mon, 9 Dec 2024 19:45:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733773520; 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=hpvqOedn8wu42Bkm5DRVoosyXFUX4QcYvtAQ3QhRBIg=; b=OiOZclX16RFgHGwoqbjlReJrSffsjgldtl4nA93nKPuVfqE7hlE8kGyGn99B/BJrvMtORq 6tAd6dypxG8j5BKna8y3MROR8nqHxJ1Z2nBHqbFom1+aUOI7qx6l1Ttwf8E1bpTbLC4p7B CaFpmfqm+98JICtdlOcTlBwutGGCVRU3IEN3yAaf0oKxqzjg+RQsJHlhC4DFFVZ1xHbHIl X+AQgOWefSWb2ABBfmxPijypK/UpUQO/V9Oo6dbZOT+f+b4g3Plv3DfXfFGXQ7ZA95wsGF jN8s2ALsJ6WXh7FgV/TCDGpYxQLD18RVfnlwgFBu7OJ+KBGLVjXQe0UiwoLAGA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733773520; 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=hpvqOedn8wu42Bkm5DRVoosyXFUX4QcYvtAQ3QhRBIg=; b=SelYICUzu3qB5LtwVQ+F4nOjOJPwMzdmFvoFFJqHlZRRvgN05qWadK5xxh+CgtZOmfMxKV ABZB4YWnMmYrwvd9iMD2ytaJwIezneYEXPHvZMQNjzNjKBZoCbG8oX/PEmGxTLpKScSLmr wwjKz9YQrq+fhNRynu14PlZ0JwOK5x1MuslMvMlg2jnqokXeICvdLG5aVRKbGk6dzUm0B7 uao3B89KK/rY5iVjDW9SCqhIxTaW7m0e/DN0cywCSEMDfFPcwLTtI/2yYwY3VF6OUTi39a 392/H404vAqxjuV9Cw+CkFo8cMMHvVoBA76/SoVep+ZkJtKEl22K/ednQLSbxA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733773520; a=rsa-sha256; cv=none; b=jYbXQlHj3a4YIwDCBhxoDddYbetDBsrG6R+ZVaeRLhGP72buqg8kLFEGIBAehAbfIi0LEm cY6f/Ibu2dYgKZx5KjH2+OO+I7+3k3mLMXc/W2uSprUBpXQ5vuFxthNc6rI6XLWHE8hUEa zABHihfMaVLKIhilWsbF36axWBxlTZfa5ytLNtdEALmTvdpuJsp5xxGz4NwWBMCNH1QkcR AzxlrwJ5gABTPJsLrHYs5aPkNLD5jgY+gNxKPh/+L7NEpambtFm7EkFnQBxdm+OJNXg7c9 KbKC2F4hdQnkIIl7NYFlp8/JOy5vpKvBaUg1noDIVHdzIh6QX6CYEBPbCat5JA== 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 4Y6XQR6QkQzqy3; Mon, 9 Dec 2024 19:45:19 +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 4B9JjJlQ009429; Mon, 9 Dec 2024 19:45:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9JjJZj009426; Mon, 9 Dec 2024 19:45:19 GMT (envelope-from git) Date: Mon, 9 Dec 2024 19:45:19 GMT Message-Id: <202412091945.4B9JjJZj009426@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: b93791f5e7b0 - main - uniq: Correctly document the -D option. 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: des X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b93791f5e7b0246b121dd98c10d6563298d6b2b0 Auto-Submitted: auto-generated The branch main has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=b93791f5e7b0246b121dd98c10d6563298d6b2b0 commit b93791f5e7b0246b121dd98c10d6563298d6b2b0 Author: Dag-Erling Smørgrav AuthorDate: 2024-12-09 19:44:34 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2024-12-09 19:44:34 +0000 uniq: Correctly document the -D option. The -D option takes an optional argument; modify the usage message and the manual page's synopsis to correctly reflect this. Also update the tests to exercise -D with and without an argument. MFC after: 1 week Sponsored by: Klara, Inc. Reviewed by: asomers Differential Revision: https://reviews.freebsd.org/D47999 --- usr.bin/uniq/tests/uniq_test.sh | 13 +++++++++++++ usr.bin/uniq/uniq.1 | 6 +++--- usr.bin/uniq/uniq.c | 4 ++-- 3 files changed, 18 insertions(+), 5 deletions(-) diff --git a/usr.bin/uniq/tests/uniq_test.sh b/usr.bin/uniq/tests/uniq_test.sh index 9d37245dee4e..fa37c1959a77 100755 --- a/usr.bin/uniq/tests/uniq_test.sh +++ b/usr.bin/uniq/tests/uniq_test.sh @@ -53,7 +53,12 @@ count_repeated_head() { count_repeated_body() { printf "a\na\nb\nb\na\n" >input printf " 2 a\n 2 b\n" >expected + atf_check_uniq -cd + atf_check_uniq -c -d + atf_check_uniq -dc + atf_check_uniq -d -c atf_check_uniq --count --repeated + atf_check_uniq --repeated --count } atf_test_case all_repeated @@ -64,7 +69,15 @@ all_repeated_body() { printf "a\na\nb\na\na\n" >input printf "a\na\na\na\n" >expected atf_check_uniq -D + atf_check_uniq -Dnone atf_check_uniq --all-repeated + atf_check_uniq --all-repeated=none + printf "\na\na\n\na\na\n" >expected + atf_check_uniq -Dprepend + atf_check_uniq --all-repeated=prepend + printf "a\na\n\na\na\n" >expected + atf_check_uniq -Dseparate + atf_check_uniq --all-repeated=separate } atf_test_case skip_fields diff --git a/usr.bin/uniq/uniq.1 b/usr.bin/uniq/uniq.1 index 30dee856d772..0918420e2229 100644 --- a/usr.bin/uniq/uniq.1 +++ b/usr.bin/uniq/uniq.1 @@ -28,7 +28,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd January 12, 2024 +.Dd December 9, 2024 .Dt UNIQ 1 .Os .Sh NAME @@ -36,8 +36,8 @@ .Nd report or filter out repeated lines in a file .Sh SYNOPSIS .Nm -.Op Fl c | Fl d | Fl D | Fl u -.Op Fl i +.Op Fl cdiu +.Op Fl D Ns Op Ar septype .Op Fl f Ar num .Op Fl s Ar chars .Oo diff --git a/usr.bin/uniq/uniq.c b/usr.bin/uniq/uniq.c index 9978c4996dc7..1c022e633cf3 100644 --- a/usr.bin/uniq/uniq.c +++ b/usr.bin/uniq/uniq.c @@ -366,7 +366,7 @@ obsolete(char *argv[]) static void usage(void) { - (void)fprintf(stderr, -"usage: uniq [-c | -d | -D | -u] [-i] [-f fields] [-s chars] [input [output]]\n"); + (void)fprintf(stderr, "usage: uniq [-cdiu] [-D[septype]] " + "[-f fields] [-s chars] [input [output]]\n"); exit(1); } From nobody Mon Dec 9 19:45:20 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 4Y6XQT1ddPz5gjVv; Mon, 09 Dec 2024 19:45:21 +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 4Y6XQT10jkz44PB; Mon, 9 Dec 2024 19:45:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733773521; 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=k3n0zvOcz2SxE3f18lxHvlv8wJaeYrfdx9HZRYt/H4M=; b=Niq7Xfsyz9e8qixbPefNudB1vYA2ameBSPGeITFdy859JC+UtQbITguxguXOkDGbsQt4w/ tVRFFiginL3Gd/2V6jAdI1OffefhqWJCbehxsookL2GbFXTccZTDa4t7B1nQcf6ENeErok tsZDX59MS/uRtuo9xfS9fl1PY3yIzN/dfDWjwc70a+RnXTqH8I3b6N3DLrIGgNC5jgEAeC xfLX/+b6pP8gcI3E9ohOr009uKeFDFNxQI5KSJo8NselE0y7Z4IIFHGCkpSsEqyluo1Fjs Ydcr9INAJ78660CX2sVN8ANDiRKyiqlUA1P3Bd5RcIZQ+Unlv6RMw0wKNCJ/bw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733773521; 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=k3n0zvOcz2SxE3f18lxHvlv8wJaeYrfdx9HZRYt/H4M=; b=I/8AuKI81tAJKl1iiutVTKvlDk6wdmExTM6zrg/naPvyN+jLkGX3ZvOoeHIWems4GNEkN2 YO7N/aSsvPij0HTBTkgbyHtCOsogb10/4+5noNldJnBCBsOfPGVDnVIHgREAJSqjiI0tq3 tJtUZJohn8SEFemui9pv9FIlap3OdgPaITE7aI07MNCTYzTomVHTl06iSwOKjICbwZwrmj VR3p9lWYOBAAjWTNVX3n51YXjttsj0SEUXwPMCwasRwc/4KZsAiphQneiq7leactOSTIDm bmsW3O5qC3lPMcs7/kWU3PP0qic8ogiV8w8Wq02eyU1h9ESZYQMqdugsHf6P2w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733773521; a=rsa-sha256; cv=none; b=lo1ADNI4IQt6dWFoGx568T0rFZi/o1xt2TDvii1iEUyRBQK9KuX2GAA0xVRY33oB92Vb5F FF+9saFrN5qaS2aCs0n8Z5kMQFg81xcbEyF/gf8lcEfH4XMEZvARLPBY/i3BwxkWBC224r 6+0Q2MYLP0f8o4r9NjUgnoxO7WAuV+YJ6q+E0MR/iM6mfsdX+fLx4eeDz/N6Epl+VZZbCn 9ZMOIjBQ3bBZdfzpbHMm1AF9COexnRFPDsY4fubdAI+70PpmDpdQLfFhbyX7+A5gGOVrZJ TBhYvKdCi41+5Y8svkNm+ANPM7kXBSTi7fiofkJd/oqvq61+OK9Ti/jhdTzvoA== 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 4Y6XQT0bDBzrs6; Mon, 9 Dec 2024 19:45:21 +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 4B9JjKgP009484; Mon, 9 Dec 2024 19:45:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9JjKDi009481; Mon, 9 Dec 2024 19:45:20 GMT (envelope-from git) Date: Mon, 9 Dec 2024 19:45:20 GMT Message-Id: <202412091945.4B9JjKDi009481@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: c3f8900e6969 - main - uniq: Fix off-by-one bug in -cD case. 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: des X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c3f8900e696998c410dc16f9bd9d45c24c413e6b Auto-Submitted: auto-generated The branch main has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=c3f8900e696998c410dc16f9bd9d45c24c413e6b commit c3f8900e696998c410dc16f9bd9d45c24c413e6b Author: Dag-Erling Smørgrav AuthorDate: 2024-12-09 19:44:46 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2024-12-09 19:44:46 +0000 uniq: Fix off-by-one bug in -cD case. When printing only duplicated lines, the first line of each set is not printed until we encounter the second. When that happens, we need to increment the repetition count between printing the first and the second line, so that if we are also printing counts, we don't print the same (pre-increment) count twice. MFC after: 1 week PR: 275764 Reported by: Yu-Sheng Ma Submitted by: Daniel Tameling (original patch) Sponsored by: Klara, Inc. Reviewed by: tamelingdaniel_gmail.com, asomers, emaste Differential Revision: https://reviews.freebsd.org/D48000 --- usr.bin/uniq/tests/uniq_test.sh | 20 ++++++++++++++++++++ usr.bin/uniq/uniq.c | 3 ++- 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/usr.bin/uniq/tests/uniq_test.sh b/usr.bin/uniq/tests/uniq_test.sh index fa37c1959a77..fc143632bdd2 100755 --- a/usr.bin/uniq/tests/uniq_test.sh +++ b/usr.bin/uniq/tests/uniq_test.sh @@ -80,6 +80,25 @@ all_repeated_body() { atf_check_uniq --all-repeated=separate } +atf_test_case count_all_repeated +count_all_repeated_head() { + atf_set descr "count and print every instance of repeated lines" +} +count_all_repeated_body() { + printf "a\na\nb\na\na\n" >input + printf " 1 a\n 2 a\n 1 a\n 2 a\n" >expected + atf_check_uniq -D -c + atf_check_uniq -Dnone -c + atf_check_uniq -cD + atf_check_uniq -cDnone + atf_check_uniq -c -D + atf_check_uniq -c -Dnone + atf_check_uniq --all-repeated --count + atf_check_uniq --all-repeated=none --count + atf_check_uniq --count --all-repeated + atf_check_uniq --count --all-repeated=none +} + atf_test_case skip_fields skip_fields_head() { atf_set descr "skip fields" @@ -196,6 +215,7 @@ atf_init_test_cases() atf_add_test_case repeated atf_add_test_case count_repeated atf_add_test_case all_repeated + atf_add_test_case count_all_repeated atf_add_test_case skip_fields atf_add_test_case skip_fields_tab atf_add_test_case ignore_case diff --git a/usr.bin/uniq/uniq.c b/usr.bin/uniq/uniq.c index 1c022e633cf3..0650ec2e2137 100644 --- a/usr.bin/uniq/uniq.c +++ b/usr.bin/uniq/uniq.c @@ -225,12 +225,13 @@ main (int argc, char *argv[]) fputc('\n', ofp); show(ofp, prevline); } - show(ofp, thisline); } else if (dflag && !cflag) { if (repeats == 0) show(ofp, prevline); } ++repeats; + if (Dflag) + show(ofp, thisline); } } if (ferror(ifp)) From nobody Mon Dec 9 21:48:55 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 4Y6b934f4Lz5gqPw; Mon, 09 Dec 2024 21:48:55 +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 4Y6b933vKXz4H8n; Mon, 9 Dec 2024 21:48:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780935; 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=vrmXUvt9xsfJNP3mkEVBGPyX2W/sM+oPYqBevRGdZLc=; b=wstz44XxuSBlKDX1heqcvQvnJLbFcMdozO3ctNtIxyr2SLdYPzrysRhgXOAMcLj88SC5b/ BX4kNtIF7h1lKUT6UXRCD4TxWOlaSsbW6zdbib+tiLtI5zDqBgtbF1sLMtWPnqPSEk3NjQ muaiPH9bGnwK5ge91SKV10ejweaha+5m8evuD3PNgKZhG0SkVCrxhaDGLGnd3J84rCMZYP 8y3a8XMpqbOWRhaED7qN+5RRyDXJxFDqc2G6ivPJrIRrrnk9sJVtWU0qmxQoMmgD3TNrYV Zdqv0h02vVwNwVmPFLheAbTxVaVAjsaOzT5XLM2FHe9mTkx5feBSesz96iAMtQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780935; 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=vrmXUvt9xsfJNP3mkEVBGPyX2W/sM+oPYqBevRGdZLc=; b=WO0L+z/BeNY1pCO9G7bE1/igDRStuIBSkNaOYiS6BSyPggdYL1dfRVC1kjI83lW8Mkd+Gs TQuohdmZOVqcSjHarJGs+pbbqUkPfCxP9PydiHwZjzY1bXdCDvVldb/5pqbi7VMHAF69Ea 1/g3lGwufOY+2GHXjtKyr9kzzypQbW7nTTqHt20BxVoCV7OASwOYCkt7d8lFPvrjguK2Jx mp+6IVYijN8LAIaOzk2PmlsardoR1tzNhaPTCzfK+D05AUPjs6YgDzS5hL1xmo9kXuwYHO Q6j0S9M8vkgFe1XLibZopE1TN8nD94wO1lBnqyApgOEkTDkC2bkmF+TYe1BySw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733780935; a=rsa-sha256; cv=none; b=ZRG8+FXEs/yOVhg+SRPbJdl9eyinA9dYpycUgZRmNa6FNmhbAOH8tVckyKQt5qcdFPEmxo DyuhS0a7bp3wdH0dZ7dHMBos9FO18lCMx6oUyHwVHbBFFL3kZeg36zcG67KAUIkc1DEwYm PgmhTFxNRl341vJ2GXPk2jMZVdSSiGUFFvNIAteLVkiOBdVaZOnV81jH5DcwJB7uUjhpDL HCzrXAXnhrp1HkqFHKFwzkbeimTwK5hAEU87II8LTRmFIPP9yK4E2pK677v9l/2yHTzuLV 877JVIF8houXs2tGi83QaJCY023mbQFgbF7H/vfvksgccjS3smnivcfHx8iy/g== 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 4Y6b9339h5zvG7; Mon, 9 Dec 2024 21:48:55 +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 4B9Lmts0033039; Mon, 9 Dec 2024 21:48:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9Lmtlr033036; Mon, 9 Dec 2024 21:48:55 GMT (envelope-from git) Date: Mon, 9 Dec 2024 21:48:55 GMT Message-Id: <202412092148.4B9Lmtlr033036@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Brooks Davis Subject: git: 82fcae46051c - stable/13 - depend-cleanup.sh: Simplify the logic, and clean bootstrap tools. 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: brooks X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 82fcae46051c3e395585d07e9bbfb8ef5f92a391 Auto-Submitted: auto-generated The branch stable/13 has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=82fcae46051c3e395585d07e9bbfb8ef5f92a391 commit 82fcae46051c3e395585d07e9bbfb8ef5f92a391 Author: Dag-Erling Smørgrav AuthorDate: 2023-02-08 22:58:51 +0000 Commit: Brooks Davis CommitDate: 2024-12-09 21:46:29 +0000 depend-cleanup.sh: Simplify the logic, and clean bootstrap tools. * There's no need to check if the file exists before grepping it; if it does not exist, grep will fail, which is what we want. Just redirect the error message to /dev/null. * There's no need to split the .o and .pico cases; the bodies are identical, so combine the conditions. Use a glob to avoid a false negative if one exists but not the other. * Also run depend-cleanup.sh on the bootstrap build tree. This unbreaks the build after 29c5f8bf9a01. Sponsored by: Klara, Inc. Sponsored by: NetApp, Inc. Differential Revision: https://reviews.freebsd.org/D38447 (cherry picked from commit 0dfaefa975477cee2ec3155c3e0689ba1fcdde9a) Pull Request: https://github.com/freebsd/freebsd-src/pull/1543 --- Makefile.inc1 | 3 +++ tools/build/depend-cleanup.sh | 11 ++--------- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/Makefile.inc1 b/Makefile.inc1 index fc5e82d39eca..48cd0f1c772c 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -1084,6 +1084,9 @@ _bootstrap-tools: @echo "--------------------------------------------------------------" @echo ">>> stage 1.2: bootstrap tools" @echo "--------------------------------------------------------------" +.if ${MK_CLEAN} != "yes" + ${_+_}cd ${.CURDIR}; ${BMAKE} _NO_INCLUDE_COMPILERMK=t _cleanobj_fast_depend_hack +.endif ${_+_}cd ${.CURDIR}; ${BMAKE} bootstrap-tools mkdir -p ${WORLDTMP}/usr ${WORLDTMP}/lib/casper ${WORLDTMP}/lib/geom \ ${WORLDTMP}/bin diff --git a/tools/build/depend-cleanup.sh b/tools/build/depend-cleanup.sh index fd0d7eb01fe7..fd29c50593a5 100755 --- a/tools/build/depend-cleanup.sh +++ b/tools/build/depend-cleanup.sh @@ -27,15 +27,8 @@ fi # $3 source extension clean_dep() { - if [ -e "$OBJTOP"/$1/.depend.$2.pico ] && \ - egrep -qw "$2\.$3" "$OBJTOP"/$1/.depend.$2.pico; then \ - echo "Removing stale dependencies and objects for $2.$3"; \ - rm -f \ - "$OBJTOP"/$1/.depend.$2.* \ - "$OBJTOP"/$1/$2.*o - fi - if egrep -qw "$2\.$3" "$OBJTOP"/obj-lib32/$1/.depend.$2.*o 2>/dev/null; then - echo "Removing 32-bit stale dependencies and objects for $2.$3" + if egrep -qw "$2\.$3" "$OBJTOP"/$1/.depend.$2.*o 2>/dev/null; then + echo "Removing stale dependencies and objects for $2.$3" rm -f \ "$OBJTOP"/obj-lib32/$1/.depend.$2.* \ "$OBJTOP"/obj-lib32/$1/$2.*o From nobody Mon Dec 9 21:48:56 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 4Y6b945JqFz5gqQ1; Mon, 09 Dec 2024 21:48:56 +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 4Y6b94404Nz4HKj; Mon, 9 Dec 2024 21:48:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780936; 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=d0LSBNyf5ughbVSlQBPSHYp0rakjVnbR+nr99wrHUI8=; b=OiAJ8JGE9wrWUmtJliYuVlRhq4wshEliZBJnqfneaHaS39snJkK0isTlQ3N413Ge+SMlIu /P1XDJaG1q7CWiWnmYQyIoOyfR9nRoX5uP8Wd2B+l/ykjZJ9EpzLvXYMoVrDHHbyl7XlEw uuLzS4fcV9BImKJEyvgWIMZRkeAChv0y5QVowwpcexATTFRA7qmOKQnDFgGB2Vcjm30xw5 SDkZ9EQp8sq8G6HRKBcEMXs/CJbyrvJXFM3kMtZHXaNt2qvxkWulc1CNW+Bw99sJPrHq5z RI5dxqm6daUXgh6JXFBfhGoh1A77K7u0rbqUgy+m++ABt4rSSVJLY2INXS3nLA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780936; 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=d0LSBNyf5ughbVSlQBPSHYp0rakjVnbR+nr99wrHUI8=; b=tfWsq1hbuAritOiGWJjQMZ71+zUBseX3xHomJSnUI3oDpm+MEXveZExV9r6yxEtssWZDN+ ScwFaSHx7N1xY83yb8meE6miXP7N2SWO8de5DqsixAsEPcJMDK9tyLGLMpczI5Fuwj2ezM mX/oKiaZekHvwbZ22MLTKYgMhyoF84IPc2A2SZDssWzc9aUeMP1Jeux9fu1EVlMnw1uxUh gfj3ht6x39PGJy1zXIRkG8egDFZeqjtEt4ZQUe3KxcrlnxHak7nNrkg/45ZbZv73ZDj7tn UiD6K/oqlctoy1XM7Uhojd7300BYvN2xEBkfV/awEu6FGLKGuFHoniUm78OUbQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733780936; a=rsa-sha256; cv=none; b=G50mKZtbNBeEd99U8UJdR3nDRfoir/pViIDUsIseQ6Db2KFnmtMXapl5S0GNQHd99QRdEo w7FeQg2rNGBPzsibFcLv4t3oTwxCh9cpagIRmGB/Q91vQey9r2RvZzOdNE5tOF/e1gDiHR ROEMEGKhlYIXPqp996t/epE+YamZQxVq4rUSC0bUz2ZN3laJe7wClTHU5P79dM+2NAGevy m3S0OQR9W0hyusxZV24Hatasv1BjzSrqpwqDdEsqXbPzO+EpQOwXmEsszECB5C3e+TiEeN 9aMqQcFhgEmVCOYnXjA2fI2D09hw7zhU9nL4m1OdvqxTHmW/DvhTfEELt1e/jw== 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 4Y6b943bmvzvVJ; Mon, 9 Dec 2024 21:48:56 +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 4B9LmumA033113; Mon, 9 Dec 2024 21:48:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9Lmuoj033110; Mon, 9 Dec 2024 21:48:56 GMT (envelope-from git) Date: Mon, 9 Dec 2024 21:48:56 GMT Message-Id: <202412092148.4B9Lmuoj033110@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Brooks Davis Subject: git: 37d2e25a2dc7 - stable/13 - Make sure MACHINE(_ARCH) are exported for depend-cleanup.sh 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: brooks X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 37d2e25a2dc7c9a12148b71dc6cf4a0c4bffdcd2 Auto-Submitted: auto-generated The branch stable/13 has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=37d2e25a2dc7c9a12148b71dc6cf4a0c4bffdcd2 commit 37d2e25a2dc7c9a12148b71dc6cf4a0c4bffdcd2 Author: Jessica Clarke AuthorDate: 2023-07-11 00:53:04 +0000 Commit: Brooks Davis CommitDate: 2024-12-09 21:46:43 +0000 Make sure MACHINE(_ARCH) are exported for depend-cleanup.sh We run depend-cleanup.sh twice during the build. The second time is the normal run, where we run it under WMAKEENV and thus have CROSSENV's MACHINE(_ARCH)=${TARGET(_ARCH)} in the environment. However, the first time is for bootstrap-tools, where it's run under BMAKEENV and we don't have any assignments to MACHINE(_ARCH) in the environment, meaning the script sees them as unset. In practice this doesn't matter since the only use doesn't apply to bootstrap-tools, but it could be a future issue. Thus, explicitly export them for depend-cleanup.sh and have the script verify they're set. Differential Revision: https://reviews.freebsd.org/D40968 (cherry picked from commit c70dd03a7ff649f832f1d29179b9094720392bce) Pull Request: https://github.com/freebsd/freebsd-src/pull/1543 --- Makefile.inc1 | 3 ++- tools/build/depend-cleanup.sh | 10 ++++++++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/Makefile.inc1 b/Makefile.inc1 index 48cd0f1c772c..c8b5fc856dd5 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -1029,7 +1029,8 @@ _sanity_check: .PHONY .MAKE # replacing generated files. Handle these cases here in an ad-hoc fashion. _cleanobj_fast_depend_hack: .PHONY @echo ">>> Deleting stale dependencies..."; - sh ${.CURDIR}/tools/build/depend-cleanup.sh ${OBJTOP} + MACHINE=${MACHINE} MACHINE_ARCH=${MACHINE_ARCH} \ + sh ${.CURDIR}/tools/build/depend-cleanup.sh ${OBJTOP} _worldtmp: .PHONY @echo diff --git a/tools/build/depend-cleanup.sh b/tools/build/depend-cleanup.sh index fd29c50593a5..385df785b426 100755 --- a/tools/build/depend-cleanup.sh +++ b/tools/build/depend-cleanup.sh @@ -22,6 +22,16 @@ if [ ! -d "$OBJTOP" ]; then exit 1 fi +if [ -z "${MACHINE+set}" ]; then + echo "$(basename "$0"): MACHINE not set" >&2 + exit 1 +fi + +if [ -z "${MACHINE_ARCH+set}" ]; then + echo "$(basename "$0"): MACHINE_ARCH not set" >&2 + exit 1 +fi + # $1 directory # $2 source filename w/o extension # $3 source extension From nobody Mon Dec 9 21:48:57 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 4Y6b960jmcz5gqrm; Mon, 09 Dec 2024 21:48:58 +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 4Y6b9550k9z4HN5; Mon, 9 Dec 2024 21:48:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780937; 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=neVJL3gttiLjc7OZdHVocLqyGVV9T99YXA9WmXyYy9s=; b=HO3LvX1ksJ3UgOEhIVSOJz2Pr86tNEfj0/jc+IWTpJT4qrIpsVc5B+jYf1I1ly7b7s8/D6 VedBu6Liohk63toxtBIuRd/uDy0MR3RAqSWrRpmY81wH4/9/h4BDB0ZFpBF1rUvlKPPFbr BQJz7joW/I2ke0VTncrLkHUQs3HFoMKzUhKTyE4muL909gazeMP9MNajIaG4ZtEsgjifgn 8knuUD8UNYZOKV0br2/kPsmVAPmxGadgaUzsYQyzRXuCwVwOi1FzqwxAsc/JIupnEdrMmW xCa10DkoqH9qWlPvQ/jXn5zm4nYX0ll8rWjxeg6VJC5jsuHtJjcFh9AcMg4B7Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780937; 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=neVJL3gttiLjc7OZdHVocLqyGVV9T99YXA9WmXyYy9s=; b=KnJ3tSGJeyI3Ytak+wQZAd8MNjy8Yc3LxqHJfRaBxIhzmbVz5Jn+stxwV8Oo+yTY8OtaUg sgR6NdQ+4xgffNaoRIdg3pw3JNsH3m7TdgzAsVeYRTH3jOERdWHli6QpyBcCnGFMhzKrlo jyGDm8rseVgK6SozxQXpA9tnNJ6mFsslfGfSBIHzc+9fw6rrwGAWYWgsKNndxws0lIl20s cc1JXonCBLGyorTfVeHDAtapKHo9RVq7QNngDYr0YBiiUwEZ2mR1+Btehkrx7GADNyNMCK FFk7rIf7HZGeHc3X4L/prOaGyrFqauM7yGd3AWXuBv+jtNDREYDiVNEFL0XxGQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733780937; a=rsa-sha256; cv=none; b=rfTNb8ur3ngntDjSBDLu9rjLtmijIvKMXVknnrXB87mclAOKafdVbaxMqSv5gmDLnqeraG 1ULE9LAyoLn6nmT8hFn0ch1ogmORgaSwIofTMyZVOOpgCJUx+QIKeLwe3EZDM0uYrGtB8t RBNyJ7vwt7tpQV4ZzdLuRX5mxS9G+A3QixlyvApV1/mz+YVeZxdtMDDYMF6fcaWL2+8lgw JOUtsX4196m7CpMp4+KiLRTNVbcIKHrUbY5b1PAtEW6iPYU3enDUAEHIsepzMpgrM0WQAr M5UtBYFGCxdOw+tCBkdXu+x8I2WGAvGEE4qOSoB9VfOGpR/WwlyV0XqsymziJA== 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 4Y6b954cDJzvG8; Mon, 9 Dec 2024 21:48:57 +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 4B9LmvSn033165; Mon, 9 Dec 2024 21:48:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9Lmvcj033162; Mon, 9 Dec 2024 21:48:57 GMT (envelope-from git) Date: Mon, 9 Dec 2024 21:48:57 GMT Message-Id: <202412092148.4B9Lmvcj033162@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Brooks Davis Subject: git: 0f00a4c39b65 - stable/13 - depend-cleanup: Add verbose (-v) and pretend/dry-run (-n) flags 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: brooks X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 0f00a4c39b65172f3e12bf7e12d31c1b4bc40e34 Auto-Submitted: auto-generated The branch stable/13 has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=0f00a4c39b65172f3e12bf7e12d31c1b4bc40e34 commit 0f00a4c39b65172f3e12bf7e12d31c1b4bc40e34 Author: Jessica Clarke AuthorDate: 2023-07-11 00:53:04 +0000 Commit: Brooks Davis CommitDate: 2024-12-09 21:46:48 +0000 depend-cleanup: Add verbose (-v) and pretend/dry-run (-n) flags These are useful for testing new additions to the script. Whilst here, harden the script a little and improve error messages. Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D31007 (cherry picked from commit 1ec7cb1b5d1800b05c0682e0b673be0dece98779) Pull Request: https://github.com/freebsd/freebsd-src/pull/1543 --- tools/build/depend-cleanup.sh | 76 +++++++++++++++++++++++++++++++++++-------- 1 file changed, 63 insertions(+), 13 deletions(-) diff --git a/tools/build/depend-cleanup.sh b/tools/build/depend-cleanup.sh index 385df785b426..e88a765357a5 100755 --- a/tools/build/depend-cleanup.sh +++ b/tools/build/depend-cleanup.sh @@ -16,22 +16,72 @@ # anyone would try a NO_CLEAN build against an object tree from before the # related change. One year should be sufficient. +set -e +set -u + +warn() +{ + echo "$(basename "$0"):" "$@" >&2 +} + +err() +{ + warn "$@" + exit 1 +} + +usage() +{ + echo "usage: $(basename $0) [-v] [-n] objtop" >&2 +} + +VERBOSE= +PRETEND= +while getopts vn o; do + case "$o" in + v) + VERBOSE=1 + ;; + n) + PRETEND=1 + ;; + *) + usage + exit 1 + ;; + esac +done +shift $((OPTIND-1)) + +if [ $# -ne 1 ]; then + usage + exit 1 +fi + OBJTOP=$1 +shift if [ ! -d "$OBJTOP" ]; then - echo "usage: $(basename $0) objtop" >&2 - exit 1 + err "$OBJTOP: Not a directory" fi if [ -z "${MACHINE+set}" ]; then - echo "$(basename "$0"): MACHINE not set" >&2 - exit 1 + err "MACHINE not set" fi if [ -z "${MACHINE_ARCH+set}" ]; then - echo "$(basename "$0"): MACHINE_ARCH not set" >&2 - exit 1 + err "MACHINE_ARCH not set" fi +run() +{ + if [ "$VERBOSE" ]; then + echo "$@" + fi + if ! [ "$PRETEND" ]; then + "$@" + fi +} + # $1 directory # $2 source filename w/o extension # $3 source extension @@ -39,7 +89,7 @@ clean_dep() { if egrep -qw "$2\.$3" "$OBJTOP"/$1/.depend.$2.*o 2>/dev/null; then echo "Removing stale dependencies and objects for $2.$3" - rm -f \ + run rm -f \ "$OBJTOP"/obj-lib32/$1/.depend.$2.* \ "$OBJTOP"/obj-lib32/$1/$2.*o fi @@ -56,14 +106,14 @@ if [ -e "$OBJTOP"/cddl/lib/libzfs/.depend.libzfs_changelist.o ] && \ egrep -qw "cddl/contrib/opensolaris/lib/libzfs/common/libzfs_changelist.c" \ "$OBJTOP"/cddl/lib/libzfs/.depend.libzfs_changelist.o; then echo "Removing old ZFS tree" - rm -rf "$OBJTOP"/cddl "$OBJTOP"/obj-lib32/cddl + run rm -rf "$OBJTOP"/cddl "$OBJTOP"/obj-lib32/cddl fi # 20200916 WARNS bumped, need bootstrapped crunchgen stubs if [ -e "$OBJTOP"/rescue/rescue/rescue.c ] && \ ! grep -q 'crunched_stub_t' "$OBJTOP"/rescue/rescue/rescue.c; then echo "Removing old rescue(8) tree" - rm -rf "$OBJTOP"/rescue/rescue + run rm -rf "$OBJTOP"/rescue/rescue fi # 20210105 fda7daf06301 pfctl gained its own version of pf_ruleset.c @@ -71,13 +121,13 @@ if [ -e "$OBJTOP"/sbin/pfctl/.depend.pf_ruleset.o ] && \ egrep -qw "sys/netpfil/pf/pf_ruleset.c" \ "$OBJTOP"/sbin/pfctl/.depend.pf_ruleset.o; then echo "Removing old pf_ruleset dependecy file" - rm -rf "$OBJTOP"/sbin/pfctl/.depend.pf_ruleset.o + run rm -rf "$OBJTOP"/sbin/pfctl/.depend.pf_ruleset.o fi # 20210108 821aa63a0940 non-widechar version of ncurses removed if [ -e "$OBJTOP"/lib/ncurses/ncursesw ]; then echo "Removing stale ncurses objects" - rm -rf "$OBJTOP"/lib/ncurses "$OBJTOP"/obj-lib32/lib/ncurses + run rm -rf "$OBJTOP"/lib/ncurses "$OBJTOP"/obj-lib32/lib/ncurses fi # 20210608 f20893853e8e move from atomic.S to atomic.c @@ -89,14 +139,14 @@ clean_dep lib/libc pdfork S if stat "$OBJTOP"/tests/sys/kqueue/libkqueue/*kqtest* \ "$OBJTOP"/tests/sys/kqueue/libkqueue/.depend.kqtest* >/dev/null 2>&1; then echo "Removing old kqtest" - rm -f "$OBJTOP"/tests/sys/kqueue/libkqueue/.depend.* \ + run rm -f "$OBJTOP"/tests/sys/kqueue/libkqueue/.depend.* \ "$OBJTOP"/tests/sys/kqueue/libkqueue/* fi # 20230110 bc42155199b5 usr.sbin/zic/zic -> usr.sbin/zic if [ -d "$OBJTOP"/usr.sbin/zic/zic ] ; then echo "Removing old zic directory" - rm -rf "$OBJTOP"/usr.sbin/zic/zic + run rm -rf "$OBJTOP"/usr.sbin/zic/zic fi # 20241018 5deeebd8c6ca Merge llvm-project release/19.x llvmorg-19.1.2-0-g7ba7d8e2f7b6 From nobody Mon Dec 9 21:48:58 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 4Y6b970m56z5gqgX; Mon, 09 Dec 2024 21:48:59 +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 4Y6b966G3Fz4HBy; Mon, 9 Dec 2024 21:48:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780938; 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=iBwlukL00HrCJJkKRki7eI7yw2pwQXsTJucmuaouTjE=; b=FYaUQQZHnz3y7LKq0c3iBVXCf2nUkKB1wiGMwu4co+NzQUhRIp4D5R3N+/KpfPfHxMeimI 3iAO0Y+lgow6JMNbUt+w+1LaGpVakMCs+9MNHoPznA4FQZzH0Gh9BEnamTFp8fh/2bUY5e IqNOxHZ9La/k/KXT7Z6akBCJWY79h4+HtnJH6cvyB1f8iuYyyDiDsbdI4x57XUa6+waGru iNrIdMFCUkBhIxAn6brS6LMNN12ZEhsZYCT1g3fl1DezVwMf8Z4oW6zZdRdsfF1fNz0YFP 02D0TUjJyStP7M72Zz3AFswVAQwmfcZplP6S1vmcpG4yYlDsKGvI3rWrVEOB0A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780938; 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=iBwlukL00HrCJJkKRki7eI7yw2pwQXsTJucmuaouTjE=; b=R05arJUTkShwbOAV3gQP6GQPnsV42qwmAnPWEUyN1agh6DNXWuulZMn16VmhMPNLLnlH+J /mUuaM+GO9wBawY01DsIHv58pERLMxt+j3QTVYuesdtU+TaVwie6frP5Fw62t1IM04PGzH EU1fjDTgDaKxIvdDcufsgCpEry4iVSav6Zqu+2ZjI06PLaU5LNnOsjLqNFo8jsPvouPhIL +qnok8/HsNCrUCy8XDaNwCBHsFrZOCyhTMKEa9sB8bcymETuvDGgYHfP0eq/MA3hsd3pGl Qv9iqaQAPB8RF/pyQtqF7O7IUkQwpXeQbRCYSN4V0Xpy0SD+p1o1K+o1d+H6Tg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733780938; a=rsa-sha256; cv=none; b=C2RompANLJOLxCAaKvfI3vdYI1Gb5x63Y7p/IH9LEH5F6GKQ61sOShYIhesFHdElu54i+Q h4n7PzS0wFIFLN72tQErFXU9k8bIEx9MIL6gEvlhjY5NuISAtXK+a3FwinA2Vm3HNrvPdf Vrr9RT/bWKRotb05OAndG8ZWwwhg/lO8HOB7ap4J2s9nAr6/+cOFtESgb6acq3SrP5NjvH 9jeP2CUbIzhsN3Tm/pZpxlu0T37sV7HWTWmzVqkyyR1y9rgJ/QA1bQS5nqKmLK5Sc/Gvuh 8qySyvlkpGrIgU6nbyXH1UFLCm315CP5Gi8YUNky82n9uJNAlTKXxMrrpygK6g== 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 4Y6b965RNrzvG9; Mon, 9 Dec 2024 21:48:58 +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 4B9LmwRI033224; Mon, 9 Dec 2024 21:48:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9Lmwp8033219; Mon, 9 Dec 2024 21:48:58 GMT (envelope-from git) Date: Mon, 9 Dec 2024 21:48:58 GMT Message-Id: <202412092148.4B9Lmwp8033219@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Brooks Davis Subject: git: 50291c77306b - stable/13 - depend-cleanup.sh: Generalise lib32 code and avoid duplication 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: brooks X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 50291c77306be87ee9f85fe557d47b65c8af50ed Auto-Submitted: auto-generated The branch stable/13 has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=50291c77306be87ee9f85fe557d47b65c8af50ed commit 50291c77306be87ee9f85fe557d47b65c8af50ed Author: Jessica Clarke AuthorDate: 2023-07-27 04:10:47 +0000 Commit: Brooks Davis CommitDate: 2024-12-09 21:46:55 +0000 depend-cleanup.sh: Generalise lib32 code and avoid duplication By passing through _ALL_libcompats we can avoid hard-coding the list of libcompats in depend-cleanup.sh. This cleanup also makes clean_dep shorter by using a loop instead of handling each case explicitly (at the expense of slightly tweaked logging). Reviewed by: brooks, jhb Differential Revision: https://reviews.freebsd.org/D41187 (cherry picked from commit 81805ec30074363e5d7d7add37b3ccf4f1eb396b) Pull Request: https://github.com/freebsd/freebsd-src/pull/1543 --- tools/build/depend-cleanup.sh | 28 ++++++++++++++++++++-------- 1 file changed, 20 insertions(+), 8 deletions(-) diff --git a/tools/build/depend-cleanup.sh b/tools/build/depend-cleanup.sh index e88a765357a5..7299ee0ccf6b 100755 --- a/tools/build/depend-cleanup.sh +++ b/tools/build/depend-cleanup.sh @@ -72,6 +72,9 @@ if [ -z "${MACHINE_ARCH+set}" ]; then err "MACHINE_ARCH not set" fi +# XXX: _ALL_libcompats not MFC'd in Makefile.inc1 +ALL_libcompats=32 + run() { if [ "$VERBOSE" ]; then @@ -87,12 +90,15 @@ run() # $3 source extension clean_dep() { - if egrep -qw "$2\.$3" "$OBJTOP"/$1/.depend.$2.*o 2>/dev/null; then - echo "Removing stale dependencies and objects for $2.$3" - run rm -f \ - "$OBJTOP"/obj-lib32/$1/.depend.$2.* \ - "$OBJTOP"/obj-lib32/$1/$2.*o - fi + for libcompat in "" $ALL_libcompats; do + dirprfx=${libcompat:+obj-lib${libcompat}/} + if egrep -qw "$2\.$3" "$OBJTOP"/$dirprfx$1/.depend.$2.*o 2>/dev/null; then + echo "Removing stale ${libcompat:+lib${libcompat} }dependencies and objects for $2.$3" + run rm -f \ + "$OBJTOP"/$dirprfx$1/.depend.$2.* \ + "$OBJTOP"/$dirprfx$1/$2.*o + fi + done } # Date Rev Description @@ -106,7 +112,10 @@ if [ -e "$OBJTOP"/cddl/lib/libzfs/.depend.libzfs_changelist.o ] && \ egrep -qw "cddl/contrib/opensolaris/lib/libzfs/common/libzfs_changelist.c" \ "$OBJTOP"/cddl/lib/libzfs/.depend.libzfs_changelist.o; then echo "Removing old ZFS tree" - run rm -rf "$OBJTOP"/cddl "$OBJTOP"/obj-lib32/cddl + for libcompat in "" $ALL_libcompats; do + dirprfx=${libcompat:+obj-lib${libcompat}/} + run rm -rf "$OBJTOP"/${dirprfx}cddl + done fi # 20200916 WARNS bumped, need bootstrapped crunchgen stubs @@ -127,7 +136,10 @@ fi # 20210108 821aa63a0940 non-widechar version of ncurses removed if [ -e "$OBJTOP"/lib/ncurses/ncursesw ]; then echo "Removing stale ncurses objects" - run rm -rf "$OBJTOP"/lib/ncurses "$OBJTOP"/obj-lib32/lib/ncurses + for libcompat in "" $ALL_libcompats; do + dirprfx=${libcompat:+obj-lib${libcompat}/} + run rm -rf "$OBJTOP"/${dirprfx}lib/ncurses + done fi # 20210608 f20893853e8e move from atomic.S to atomic.c From nobody Mon Dec 9 21:48:59 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 4Y6b981LWLz5gqdC; Mon, 09 Dec 2024 21:49:00 +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 4Y6b976nrkz4H6k; Mon, 9 Dec 2024 21:48:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780940; 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=Tfkg1rcZmxqTIaFQeXtCFY9HVzjkWoP8ub/K++Jh30c=; b=nYYrdwaPo0eodl7pxTxqsOzZXlUZ/X1IR7vcv4K6309OyeLrWNQCba4wONQ7JuNo7aSXde 2n2uLrI4aoRt+4rhYJxPLlLbaQKtVUC4JvSvWEvzn98CmcL03d5b2uzGOd/v+kMrZ38lLy 0NI+wlTLMA6OqbmvRBzM/d5EJT6IZYTpfuVktPalaCsfRkOZaeNE1c2u/1niB/aXhbhcQo ti5XJYVjoBVSxBa7voi/NFex0Ju5K86NvqOWIs4+e7rQa3tfcyWCYG0Xkxswa2cMAua6j+ nFmQGVG81sfjAnhoH4NNps1heCkFg1+MgpgUqTyQhSGx6mE87kqGvrjpM7WyaA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780939; 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=Tfkg1rcZmxqTIaFQeXtCFY9HVzjkWoP8ub/K++Jh30c=; b=HK3DuOzW6vuGHDXqLBhecdKtXWsWCv3ES2e9OgbZUwZVthtbazNxsWnrgc9GQFWCeo3cym 6QWDA1MoRaBBEbet5faTvHEVTivBBtLogoEfQaVIxj6F2UXslzOP///ImxmpRRHdsNbdom rfdsCmCMC+8V1fixlW3TjJkc8GtqHZymBTkmfNe4AhzD4ntRe1DBB5afQN7RawVG5olTyH l+DJSgVT1S9RcBGvfvpbzhaEHgsuCoChV/KmZL90jg4zX4e3RTisycIrO9GgM9CbDxKNVB rolvdYzwiToDqM1prSYjmzUY8qIZTsp1E8sO1fj205qkrFGmPom908n0CwYjTA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733780940; a=rsa-sha256; cv=none; b=OFmukC6G67dQR7PZJNj5a1YaboYMHbawRGHREGgVkn2lgisvTpBT+riC8BJVUWYKxx/EP9 GVjFevq3TUc5R8hPQmUERR2O2sE8k6dZXQZfZW9XFudRjKgdRnT6PyPwCYMwZXct7bo2+N 2KsZj0UrlzZaaaws2VwznJYJVLF2b32wRbMVsFSFmw9M8mrrslsRxtRpRj1J6fXE0heqQN R3fGJ+3YUDTsPfVZKNinqB8nwZ8VW+Dt7g4r0kY4wE+BY8R+9E266dlisOq73xQl7pc8xI LTBN4skqTIxLx6XDszingg7WVBoiUphjV46JIFTCRSLmjg2AIfzrZj4T9Pw78A== 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 4Y6b976QPJzvVK; Mon, 9 Dec 2024 21:48:59 +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 4B9LmxGR033277; Mon, 9 Dec 2024 21:48:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9LmxuA033274; Mon, 9 Dec 2024 21:48:59 GMT (envelope-from git) Date: Mon, 9 Dec 2024 21:48:59 GMT Message-Id: <202412092148.4B9LmxuA033274@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Brooks Davis Subject: git: 91549cf666db - stable/13 - Revert "depend-cleanup: fix after 99b2ab71c5b6" 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: brooks X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 91549cf666db4e6064f43dfa6062904db3385a8f Auto-Submitted: auto-generated The branch stable/13 has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=91549cf666db4e6064f43dfa6062904db3385a8f commit 91549cf666db4e6064f43dfa6062904db3385a8f Author: Brooks Davis AuthorDate: 2024-12-09 19:29:10 +0000 Commit: Brooks Davis CommitDate: 2024-12-09 21:47:00 +0000 Revert "depend-cleanup: fix after 99b2ab71c5b6" Dry run support has been merged. This reverts commit 210ff86448461dd00dce6f826ae58deb5ae44822. Pull Request: https://github.com/freebsd/freebsd-src/pull/1543 --- tools/build/depend-cleanup.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/build/depend-cleanup.sh b/tools/build/depend-cleanup.sh index 7299ee0ccf6b..22baf65517fe 100755 --- a/tools/build/depend-cleanup.sh +++ b/tools/build/depend-cleanup.sh @@ -167,6 +167,6 @@ f="$p"/arm_mve_builtin_sema.inc if [ -e "$f" ]; then if grep -q SemaBuiltinConstantArgRange "$f"; then echo "Removing pre-llvm19 clang-tblgen output" - rm -f "$p"/*.inc + run rm -f "$p"/*.inc fi fi From nobody Mon Dec 9 21:49:00 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 4Y6b992nTRz5gqbm; Mon, 09 Dec 2024 21:49:01 +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 4Y6b990Pqdz4HLl; Mon, 9 Dec 2024 21:49:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780941; 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=IFVMyUHc1vQu1f29WShEPI1QukYsbyi4R7KVFVioWOQ=; b=yGm7Tq0kZD+3N6X7H1LESTTt7DGfweTfjFlsjZcxnnLtxgbFMXnyUkyMxGJmd4nNuEk2cJ C86xIRbSraZzlC2GYjDDn/iL3sNXkzkWjfjQn0CB6yzyS53vAnWeaRsObhc5eJmzcULx0/ QOUDIuRcpW1VcRYGJOnAgTxcrl0I1hHbNQwkchDordyyzSY+b3g5SDEvTEnxnlN2TCrJ/C 1tZ1fWdg6swwxEecyDhVTxbFwepdIfzumtIgIcHV1LszI/LJVjwHxqXFNHWlHQzFvdAJB4 wm/TKgDpA3O4UlhWgMm8kGILvvZVXvffPTDd7q9rZrQF5ZqdG/X/63D+h8MJog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733780941; 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=IFVMyUHc1vQu1f29WShEPI1QukYsbyi4R7KVFVioWOQ=; b=XcGVCCDpCoM46FwdlFT8MHJhZaajxVRzssDgZabwh3lC8h74KLHN8xtNl7UbQkjzelqNIS DbrPPIrY0at1mn7eXijLc3+kMi108Nz/GXgr+k4JJlxjsWOU96PXeY5Qp1wUQ/uzRVK879 voDuOnX/nV7df5pKfIha4VdXsFZ/FDdbMJUeotfz9QOE9Z6/oDydYzNVTiDuLa37P7O3+M RpysCxJI0bBcMbLRukZDoMRCCJS0P3s+kl0/GB24IrIRgHLa4UdH2thJMKlwuExKwJHapf lGzsbPhTJMKahZAZ3VSVAKHRlmTXbJ+F/puZa/kcw0MV/IoPqE+j4BKNeAN1ww== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733780941; a=rsa-sha256; cv=none; b=hbC3zMZz9afJsYTLxbrbosUl9djFPaMT8o4Mh71VPgFsam5vprXA0FThM0BZMkUesA0Pkt 6gejtzyCiVaQUXUnaIKM87A15AxQsr9sV+IePm2XBa282JEP1fRNvVgDmECkGWoq/SNnOQ aZWlh1XI1rJu0Ewnmr55aOTuh9ruUGqrdoD4bXIy8KE24OQWv/5u85V1kd5icHUcDdttDy 7YHFBCLI8wmPRU3geYjyw/3snY7c6KmjgHzSojLc6k04baG9zW6SGfsPSegWiBhis2HXoU OPCYoeRo3I9jVGpoLYMgBgY0Wkn+bawXXKaQdzNCJDxBYOE8lIE4rufjJklv7A== 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 4Y6b9902J8zvv5; Mon, 9 Dec 2024 21:49:01 +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 4B9Ln0Hb033334; Mon, 9 Dec 2024 21:49:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9Ln0Cw033331; Mon, 9 Dec 2024 21:49:00 GMT (envelope-from git) Date: Mon, 9 Dec 2024 21:49:00 GMT Message-Id: <202412092149.4B9Ln0Cw033331@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Brooks Davis Subject: git: 6608a478cddb - stable/13 - depend-cleanup.sh: Extend clean_dep to support a custom regex 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: brooks X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 6608a478cddb98c1ad52ec0abae5240915fb2c57 Auto-Submitted: auto-generated The branch stable/13 has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=6608a478cddb98c1ad52ec0abae5240915fb2c57 commit 6608a478cddb98c1ad52ec0abae5240915fb2c57 Author: Jessica Clarke AuthorDate: 2024-09-10 17:54:44 +0000 Commit: Brooks Davis CommitDate: 2024-12-09 21:47:08 +0000 depend-cleanup.sh: Extend clean_dep to support a custom regex This will avoid having to duplicate the loop every time the default regex isn't good enough, and will be used by upcoming commits. (cherry picked from commit cc30f4ae6790cf4f19bc4787d7528dfea79ef27a) Pull Request: https://github.com/freebsd/freebsd-src/pull/1543 --- tools/build/depend-cleanup.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/build/depend-cleanup.sh b/tools/build/depend-cleanup.sh index 22baf65517fe..c12c8e203324 100755 --- a/tools/build/depend-cleanup.sh +++ b/tools/build/depend-cleanup.sh @@ -88,11 +88,12 @@ run() # $1 directory # $2 source filename w/o extension # $3 source extension +# $4 optional regex for egrep -w clean_dep() { for libcompat in "" $ALL_libcompats; do dirprfx=${libcompat:+obj-lib${libcompat}/} - if egrep -qw "$2\.$3" "$OBJTOP"/$dirprfx$1/.depend.$2.*o 2>/dev/null; then + if egrep -qw "${4:-$2\.$3}" "$OBJTOP"/$dirprfx$1/.depend.$2.*o 2>/dev/null; then echo "Removing stale ${libcompat:+lib${libcompat} }dependencies and objects for $2.$3" run rm -f \ "$OBJTOP"/$dirprfx$1/.depend.$2.* \ From nobody Mon Dec 9 21:55:54 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 4Y6bK65wxfz5grM3; Mon, 09 Dec 2024 21:55: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 "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Y6bK6531tz4KDp; Mon, 9 Dec 2024 21:55:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733781354; 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=ePwT8idOdhPr9Sa/ngTU61wUWB8djTIRu4hbX6MKS/c=; b=VdiJomIZx/cA/FsKRugpoeRKZRGyT/Zdx0Ds33qvgKHav51yZGDyIfTYk7CT36JCqs7x78 FZsw/d7Ss/qzTFe2nhCcW0P77XgxFd9sjSrd959SDu7BHTXzNd/G1lyk1t3UCh3mEz4C88 vYOFS/G1bxKN2JzFxhV6cl8EyBxQ3Wp2CTWB0SZj5IDeBiQExUHJOB71bGzQ0QtUVzEXE8 XRZ/9s1CiS4QU8r58mbI9vT/LrJrtnU46H3aLvwq4ha9wLQ6ArrwFq0HiLt/OQcjG8l4n6 eruuOL+aVnyrrkwTw3nsJx9XFEmCFXYfAbAbLiCsZKSlApuTMgfgI7B/rRGyeA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733781354; 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=ePwT8idOdhPr9Sa/ngTU61wUWB8djTIRu4hbX6MKS/c=; b=NiB8VNNMmlgxVgCl7FZXE6jxYvt8Ecj9wk6fwyMCPhRKMwPm2Lq7xrwHhAvwqqpHF6Zm3W paq7GIOPYuF8EX3MgrXdezb2Rxzb/oxRQ+PcWWkJJZgSvkv6hSAIluCXtm5BUnZ+FeJWCC yo8BedZZbHsc9b088k1uiGG1aBaO7293smkpGK2nto2W26JVI7IMV6Fq56inPbKjJjDnMs kalB5bZcazYz0WIG4PSkqNZKItBaN7HTgXreZdn9VkOR7BI8fFVCzhI4ScJNiGajItt4xt pxROuUdyMtL81gCdJ1u166PtovFwIDEDW7U1+tI8yb9aYCYMDVZo3iaOeY5lEA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733781354; a=rsa-sha256; cv=none; b=Hkg8CU0xg8GyueXO/XshBvP5q6H7o9O9eR/Ncs7pmI44KW7FvG0GT0HIi0SaiolsaNzOGD Wx7WmRjI/ngjWQHkdLABpBSi+sIIiaroCekqBhF9zGMSNvr14Mi9oMLSpgtFT8gIHFZumh OZKhmoPopy2VNEuj35w8RQzf7G92Q6mUxpxal9lovFPJoK2jKvwiD048VBWxAjQ6INo43S aDGwhmGLx39bxh9MU1cbhFSfXcaxZjzBXIpngFVnI/L8UDDldfgypwokvlGOGwydPNxmia 5S/Q+Skbz38Jj3Tm9mi85kn9efFuymoPL36SeQVjZh1Mv+9399+T4TrfwArt0g== 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 4Y6bK63xpDzvVv; Mon, 9 Dec 2024 21:55:54 +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 4B9Ltsu6052214; Mon, 9 Dec 2024 21:55:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4B9Ltscn052211; Mon, 9 Dec 2024 21:55:54 GMT (envelope-from git) Date: Mon, 9 Dec 2024 21:55:54 GMT Message-Id: <202412092155.4B9Ltscn052211@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Jessica Clarke Subject: git: f8c90b704189 - main - gic_v3: Correctly handle GICC GIGR Base Address case 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: jrtc27 X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f8c90b704189c94275d22d7cc204d1d74e821d86 Auto-Submitted: auto-generated The branch main has been updated by jrtc27: URL: https://cgit.FreeBSD.org/src/commit/?id=f8c90b704189c94275d22d7cc204d1d74e821d86 commit f8c90b704189c94275d22d7cc204d1d74e821d86 Author: Jessica Clarke AuthorDate: 2024-12-09 21:55:06 +0000 Commit: Jessica Clarke CommitDate: 2024-12-09 21:55:06 +0000 gic_v3: Correctly handle GICC GIGR Base Address case When using the GICR Base Address field from each GICC structure instead of GICR structures, the field gives the address of a single redistributor page. However, that does not mean that they are not contiguous, and so GICR_TYPER.Last could be clear on them. Thus we must ignore GICR_TYPER.Last in this case and always treat each region as having a single page. Normally we'd do that as a result of checking against the rman's size (though that's a rather roundabout and iffy way of achieving it), but for whatever reason this is bigger on the Qualcomm Snapdragon X Elite (I assume the MADT reports GICv4 but TYPER doesn't report VLPIS and so there is a mismatch between the rman size and the stride used) and we end up walking off the region's mapping. Reviewed by: andrew, phk MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D47560 --- sys/arm64/arm64/gic_v3.c | 2 +- sys/arm64/arm64/gic_v3_acpi.c | 1 + sys/arm64/arm64/gic_v3_var.h | 6 ++++++ 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/sys/arm64/arm64/gic_v3.c b/sys/arm64/arm64/gic_v3.c index 964a129111e2..201cdae6de09 100644 --- a/sys/arm64/arm64/gic_v3.c +++ b/sys/arm64/arm64/gic_v3.c @@ -1434,7 +1434,7 @@ gic_v3_redist_find(struct gic_v3_softc *sc) (GICR_VLPI_BASE_SIZE + GICR_RESERVED_SIZE); } } while (offset < rman_get_size(r_res) && - (typer & GICR_TYPER_LAST) == 0); + !sc->gic_redists.single && (typer & GICR_TYPER_LAST) == 0); } device_printf(sc->dev, "No Re-Distributor found for CPU%u\n", cpuid); diff --git a/sys/arm64/arm64/gic_v3_acpi.c b/sys/arm64/arm64/gic_v3_acpi.c index 44c55cf5bbf2..7c3495fd442b 100644 --- a/sys/arm64/arm64/gic_v3_acpi.c +++ b/sys/arm64/arm64/gic_v3_acpi.c @@ -300,6 +300,7 @@ gic_v3_acpi_count_regions(device_t dev) acpi_walk_subtables(madt + 1, (char *)madt + madt->Header.Length, madt_count_gicc_redistrib, sc); + sc->gic_redists.single = true; } acpi_unmap_table(madt); diff --git a/sys/arm64/arm64/gic_v3_var.h b/sys/arm64/arm64/gic_v3_var.h index 1c5d354ee217..8bc0f456d91e 100644 --- a/sys/arm64/arm64/gic_v3_var.h +++ b/sys/arm64/arm64/gic_v3_var.h @@ -53,6 +53,12 @@ struct gic_redists { struct resource ** regions; /* Number of Re-Distributor regions */ u_int nregions; + /* + * Whether to treat each region as a single Re-Distributor page or a + * series of contiguous pages (i.e. from each ACPI MADT GICC's GICR + * Base Address field) + */ + bool single; /* Per-CPU Re-Distributor data */ struct redist_pcpu *pcpu; }; From nobody Tue Dec 10 00:05:27 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 4Y6fBb32pTz5gyRC; Tue, 10 Dec 2024 00:05:27 +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 4Y6fBb2Kg0z4XQp; Tue, 10 Dec 2024 00:05:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733789127; 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=Qx9RUVNhJruYH1l0Z75yTKFPE9M9u01Hd9lcJhn3WrQ=; b=dIcs/FnPH66jspOFIpmueQBoLcpBbadTULZCI55v0OnjPBvPaxx1NlN533ozDB00O5hv6Z 4XMp1wlJg27cqfmmMdhFQGJLKB+InN51owmY3SE1vrMRObmQJ48FxaCTY+Hy1+ptubOrjc oe1F2EVfdlcXFJxs+V7RuGkn7rmDiq2+QClmk5IgM5v0tGs3Mc0TYRuOmgRmJloMgJvTln g23Z5/AshiN0KaEPK684tf6FSNaNdCIRQ5M8gpdKxdoR5GcmZWN6SwxvMOGBB+xSGOJesi elEeIncLjFz+dOE6o0IIreZJZlQ0ZTQXqmcSXZHODv1GP+eu9q3LKGf+P6NNvQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733789127; 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=Qx9RUVNhJruYH1l0Z75yTKFPE9M9u01Hd9lcJhn3WrQ=; b=gTjE7KcZZD4aXw7wAGpUoYbo0jrSS2xdPb35t5AnVRa6qQosrVWu2FxZzEfq948xdK1sLB NCoM6aqzBgwzgTNPLFg4atO5nQOpoeh8wUwkMuxHP8FTTEMIIOfy6YLPDLQVzMXntGtXt5 cI3ryg4hit5hAF9VfjO6adU2GLOoFH5GBGhJE2/8Bwc2ydLoBo2kPPsXb3FocdpTxkQ1Ux gCW9TOeIeSiF9RujdKvuXhdNfmL4iPb23EyRU+kbeXgipP1r5LiJyzQai1KzWb7xMvPFfx kkez0UHvmTukXgqwWDRQrkSnkeZYbjFV9eSmsGILUUyVh39pmfiJdZHnCxzwcw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733789127; a=rsa-sha256; cv=none; b=iqZQyjzzJC/zwY3JbzvDiWMUAdVnQ2McCS5yvVMPW2mWLOIQtf97fyLmmCni4bp6x9zRCp 79j1OW731OcANyiuyr6CiwClxrclftvNPh8UgBavyEMYGT+99hEFUUP7WliPRnS5DgVulc okx3MZ0gP9VqxxyFfJPid3E58L9xbC87zfz1xvwm15BHNsSwKD8iaEfY69FSx+F4vtCqDw q+L1masaK87hLszaZYs2iTuLQYW4iMs2EcHd7aMYFMpJ6a0BtH5TX9L9hPLZ3KjFb90C3e O5iU9v7K2YE4UP5j/Sz5yxY3stndNsTqlXWHKlk6RXpqi21JrbMdpESxCw+atg== 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 4Y6fBb1w8bz10HC; Tue, 10 Dec 2024 00:05:27 +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 4BA05Rs0093564; Tue, 10 Dec 2024 00:05:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BA05Rxv093561; Tue, 10 Dec 2024 00:05:27 GMT (envelope-from git) Date: Tue, 10 Dec 2024 00:05:27 GMT Message-Id: <202412100005.4BA05Rxv093561@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: 944f45b8094c - main - Cirrus-CI: Add manual LLVM 19 jobs 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: emaste X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 944f45b8094ce70eef14d07afc333250ad063a49 Auto-Submitted: auto-generated The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=944f45b8094ce70eef14d07afc333250ad063a49 commit 944f45b8094ce70eef14d07afc333250ad063a49 Author: Ed Maste AuthorDate: 2024-12-09 21:27:01 +0000 Commit: Ed Maste CommitDate: 2024-12-10 00:04:32 +0000 Cirrus-CI: Add manual LLVM 19 jobs The base system compiler is now Clang/LLVM 19. Sponsored by: The FreeBSD Foundation --- .cirrus.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/.cirrus.yml b/.cirrus.yml index 45c31c9f07b2..62766904de2b 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -37,6 +37,14 @@ task: TARGET_ARCH: amd64 TOOLCHAIN: llvm18 TOOLCHAIN_PKG: ${TOOLCHAIN}-lite + - name: amd64-llvm19 World and kernel build and boot smoke test + only_if: $CIRRUS_REPO_FULL_NAME != 'freebsd/freebsd-src' + trigger_type: manual + env: + TARGET: amd64 + TARGET_ARCH: amd64 + TOOLCHAIN: llvm19 + TOOLCHAIN_PKG: ${TOOLCHAIN}-lite - name: arm64-llvm16 World and kernel build and boot smoke test only_if: $CIRRUS_REPO_FULL_NAME != 'freebsd/freebsd-src' trigger_type: manual @@ -61,6 +69,14 @@ task: TARGET_ARCH: aarch64 TOOLCHAIN: llvm18 TOOLCHAIN_PKG: ${TOOLCHAIN} + - name: arm64-llvm19 World and kernel build and boot smoke test + only_if: $CIRRUS_REPO_FULL_NAME != 'freebsd/freebsd-src' + trigger_type: manual + env: + TARGET: arm64 + TARGET_ARCH: aarch64 + TOOLCHAIN: llvm19 + TOOLCHAIN_PKG: ${TOOLCHAIN} - name: amd64-gcc12 World and kernel build and boot smoke test (manual) only_if: $CIRRUS_REPO_FULL_NAME != 'freebsd/freebsd-src' trigger_type: manual From nobody Tue Dec 10 01:55:15 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 4Y6hdM5MY7z5h5NH; Tue, 10 Dec 2024 01:55:19 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (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 "smtp.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Y6hdM4QB3z4jvN; Tue, 10 Dec 2024 01:55:19 +0000 (UTC) (envelope-from bz@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733795719; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=9UutusI8e7usStpz2dgq5NrF4F4bmjN95T0mtzH6Jqg=; b=PBeFu60PBxuWk5N/h1TD9vzVk90PNt8pN6SVFbUas8Zo2ZEg16lDZcxEPiYe1dPwAwEcK0 TkjBtDW3Olv3sqwzzul0Wez3PdAkkxTP8hq9oWkUy/rJ7SBe/1+gBx4xSZJeTT4kvP9Qog OwIi/RkwNaGuSuWAzPd2tCfAv1JQcZuh65zaFNp2eDq54ehE8HMiggs99mH4VBLM4QBBlp TyAjnyJ6SauIzv20mF6Siz0iaVlQbbF0ijS0ws9pCsW8GB/NYhWmKlrhAW0ww3ugk0lzYG RhiMp75IJd1Ci+I4MQM+ct8ypG4iEiDcVWQsXAgkKHVyxQ10K0osXTEfdW8cTg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733795719; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=9UutusI8e7usStpz2dgq5NrF4F4bmjN95T0mtzH6Jqg=; b=T5t1oCNAEm6RBIMvWn7fm+PoFwrNdn685v/gK7ubE+yP8QQ2UxEv5Gd5O9zg8HfjRcy8XP V+4fNrdXdMJj813PtRdpE07tccXFHVRiW5KkS2Oz9GMWne+mqUhrxYtcBVmMADwi50D02B zhkHkPYqL0f+XFqHnvzvHu307E9SDsA4uh/pB0L5XolhNjxK+MQzMM3nGJ7VwG73AxBVPt JPejPOdw2nIK97KKFNHRC8qThSiMlt8bDHqePKrV6wa1X6PPkhf4NzoXf9xc5YnWWsTz7R 1vsAy7vyDT3Q4sfgpYfQ3EJMmbhTQ96gPCPp6StCIaMsJcrrZAIh+6IKTM4Muw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733795719; a=rsa-sha256; cv=none; b=g3jwneTUJ/vbm6Zw+KRG6+i+8bUDj9KiWBFoxHhiAm/F9//YoAbVGpH3KtkVlfQkWVDqH0 1NZbB5fhZZMgjHZ8GvBlgZf4ZfeLjOHyTWNifSTUYh0ZaAoCve7AOiWz12cY3dOnwqBf1i BvRfz5I/yud/xhXcBd+8ohQa9ZqYZeOzqBS9zxy26/VtWf+L0DkLLokYQbudYjswSMVp7l KVAyb6NsL0YjjJ/eaIH3HHmnwjwyHiO40xvRXZTDmU2aG3iBCvBzVntd6jZ+e095qd5/7H 7FXCR6JgQN7aJe6G8xq2QQeb/gae2N3QIRPaLgrqXGbYNE8ZFf11jBDTMCMsOQ== Received: from mx-01.divo.sbone.de (mx-01.divo.sbone.de [IPv6:2003:a:140a:2200:6:594:fffe:19]) (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 ECDSA (P-256) client-digest SHA256) (Client CN "mx-01.divo.sbone.de", Issuer "E6" (verified OK)) (Authenticated sender: bz/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4Y6hdM33zhz11XF; Tue, 10 Dec 2024 01:55:19 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from mail.sbone.de (mail.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:1025]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by mx-01.divo.sbone.de (Postfix) with ESMTPS id 5E4A4A64805; Tue, 10 Dec 2024 01:55:11 +0000 (UTC) Received: from content-filter.t4-02.sbone.de (content-filter.t4-02.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:2742]) (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) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPS id 9FFF72D029DC; Tue, 10 Dec 2024 01:55:17 +0000 (UTC) X-Virus-Scanned: amavisd-new at sbone.de Received: from mail.sbone.de ([IPv6:fde9:577b:c1a9:4902:0:7404:2:1025]) by content-filter.t4-02.sbone.de (content-filter.t4-02.sbone.de [IPv6:fde9:577b:c1a9:4902:0:7404:2:2742]) (amavisd-new, port 10024) with ESMTP id 08PL9OtZPdZf; Tue, 10 Dec 2024 01:55:16 +0000 (UTC) Received: from strong-iwl0.sbone.de (strong-iwl0.sbone.de [IPv6:fde9:577b:c1a9:4902:b66b:fcff:fef3:e3d2]) (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) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPSA id 65A712D029D8; Tue, 10 Dec 2024 01:55:16 +0000 (UTC) Date: Tue, 10 Dec 2024 01:55:15 +0000 (UTC) From: "Bjoern A. Zeeb" To: Jessica Clarke cc: "src-committers@freebsd.org" , "dev-commits-src-all@freebsd.org" , "dev-commits-src-main@freebsd.org" Subject: Re: git: 87e140a5c6f8 - main - iwlwifi: avoid (hard) hang on loading module In-Reply-To: <6F9C2C43-A3DD-4CF5-AC27-899FE139E9A6@freebsd.org> Message-ID: <0883q825-802q-2n9q-3s4o-3nq13qpqno71@SerrOFQ.bet> References: <202412091447.4B9ElFBH050286@gitrepo.freebsd.org> <6F9C2C43-A3DD-4CF5-AC27-899FE139E9A6@freebsd.org> X-OpenPGP-Key-Id: 0x14003F198FEFA3E77207EE8D2B58B8F83CCF1842 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: multipart/mixed; boundary="1098556516-515570521-1733795716=:2228" This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --1098556516-515570521-1733795716=:2228 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8BIT On Mon, 9 Dec 2024, Jessica Clarke wrote: > On 9 Dec 2024, at 14:47, Bjoern A. Zeeb wrote: >> >> The branch main has been updated by bz: >> >> URL: https://cgit.FreeBSD.org/src/commit/?id=87e140a5c6f89eea7ea6320d1ae34566492abfc0 >> + if (bootverbose) >> + printf("%s: module '%s' not yet available; will be" >> + "initialized in a moment\n", __func__, op->name); > > Missing a space in the string. Thanks; I'll add that. > Also, why not just have request_module_nowait itself defer the load > until it can be done, at which point it can notice that there’s nothing > to do? Because it's tricky and the (simple) request_module() in LinuxKPI pre-dates me. I think our users currently are a lot happier having working WiFi (or a non-hanging kernel) than to wait some more time. And frankly it's the only place in WiFi this is used and we do not need it, so I'd rather focus on other user-facing problems. /bz -- Bjoern A. Zeeb r15:7 --1098556516-515570521-1733795716=:2228-- From nobody Tue Dec 10 02:39:10 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 4Y6jby5QhMz5h7YQ; Tue, 10 Dec 2024 02:39:10 +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 4Y6jby4WL4z4mRM; Tue, 10 Dec 2024 02:39:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733798350; 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=Vdtc/SR9qpXsZW1UKb1b7ar79PtVCuGUju5kvrd+vXU=; b=NYjyorR590nP53FACOOO2Cb1IR7c/h2/K9Jmx8KrZKnPENcmtOdTCioI7QWAivk9+ZBUjc FZcgY4iWN4MSJ/saoV3z24jFbImJ94daROSY9vQ084zjZy4xX8T6iWT7qoNL0UgTlSByBU /EwXHQGiWM6me5pqFJe1m2z0LfW7COZjllvDXYfJBvELP83wD7GhypdGngNkuWB2TD6uEf YwEx27IwBnv4pB0q6kVPn6fJTxtJGgKIf+QwGEPRiGqz97qA7jvtnfChytNDjIxKxkg08R bYxp92ZFVF4d90v6VO6xUV5trZy0NSmGGc0blpHpU60G/ou+DGDo2ucwvr+5zg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733798350; 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=Vdtc/SR9qpXsZW1UKb1b7ar79PtVCuGUju5kvrd+vXU=; b=DKO7tupXP1W9cS6HmGaQU7YTwq8l7Ahcf28lg+wSyfMoR8X7dg6+oYOds9XjVrfwhO4Tt7 lOJ0Ev2bXfGlCN0p0GUJjx7Oq4UR5kFBrR5H/BvSwV+1/BTk4aYIaMMaIR5GcmWUfhWO96 yqelbFrDI3NJYDP+W6eSZqbxu4H9bcvKB38XSZKOjBDMar1jaPCinbfYPcdzPjNxFcRjhc dlJxNByqNYWD1aFjteGga7l6Ce0P69PQODo5ym0P+NuRL5DW0HX7clJDm1F896+87JXAaW lIRf9FU1kPP4Vzl+OlZLDHSJ7HTROoUb3btrVE95gn2EaVq4gaMSubIrX8VrKA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733798350; a=rsa-sha256; cv=none; b=Vj1MuqUBWgOvDB6nfY3ghyWqF8Wr1DgCjJB5Ycr+0NwbRbUNxYLwRY8D/4X8nqm9JhT9yN urHe0FILupBHVzFTDIE9ZpAbr+vRLf5K/G1s4rGAWyBCyqvxw5WNmtTDPpRF9XfUzn5ujT B09wCiuxwt1ATD6NZQmG2ExS7wVuRqUIgytaPLN5eLqt8f/h0nNwebDc646lBzd+qPKgHo ZKzir6ADsO/UworV7ARU7jZAUBnR8kBOZz7TKt33dbnhG8MPJTX1oy7m8+DcwRqwyLBx8K JR94hh2myi6kTHWYTVROibLOPV2p/e9ziv4FPgEx2Nh1Lipiu6jJvU3+t1Twlg== 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 4Y6jby46tcz14G0; Tue, 10 Dec 2024 02:39:10 +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 4BA2dAH2073342; Tue, 10 Dec 2024 02:39:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BA2dAHp073339; Tue, 10 Dec 2024 02:39:10 GMT (envelope-from git) Date: Tue, 10 Dec 2024 02:39:10 GMT Message-Id: <202412100239.4BA2dAHp073339@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: 8cee8527d09f - main - vm_map(9): grammar corrections 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8cee8527d09f47e503264dbe2a02506aa24de8b9 Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=8cee8527d09f47e503264dbe2a02506aa24de8b9 commit 8cee8527d09f47e503264dbe2a02506aa24de8b9 Author: Konstantin Belousov AuthorDate: 2024-12-10 02:38:23 +0000 Commit: Konstantin Belousov CommitDate: 2024-12-10 02:38:23 +0000 vm_map(9): grammar corrections Noted by: alc Sponsored by: The FreeBSD Foundation --- share/man/man9/vm_map.9 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/man/man9/vm_map.9 b/share/man/man9/vm_map.9 index 39242dd6b2b8..9f41a24541b1 100644 --- a/share/man/man9/vm_map.9 +++ b/share/man/man9/vm_map.9 @@ -104,7 +104,7 @@ There are waiters for the map busy status. Indicates if a thread is waiting for an allocation within the map. Used only by system maps. .It Va MAP_SYSTEM_MAP -If set, ndicates that map is a system map; otherwise, it belongs +If set, indicates that the map is the system map; otherwise, it belongs to a user process. .El .Pp From nobody Tue Dec 10 02:40:41 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 4Y6jdk2647z5h82f; Tue, 10 Dec 2024 02:40:42 +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 4Y6jdj6lP3z4mpk; Tue, 10 Dec 2024 02:40:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733798441; 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=mjSFIptpj7OQZawgeZ8J5Vr8+D/G7Z4GvKJa2otwEnQ=; b=os63BxvdRF9pl1OnehXc2MnBnvFFQ2LA2YiOodQNNOE5bXPy8TJSepERDPf4J6KmQYOBaK a2L6DYTKIH89C+Oz0gJb29KfMx8xw2VuPHTqORld4mXYnXTzBXYLscxd4WSUnPvc9T3h17 Lw5vw9ZzZ8xC7tGowurSZ+86tw4isERrbyYyBYrdTXrewcH11S7Xs+adfpww/NkJa4WzvU 2VPuVlzsF+PmmzINmMjsZI6qO0WSwhCNXYvWqciFKkaCWw6Y48vcdK/ONioiSLzrvrc1Yf dwc5sJcnEESYUM4nDrGBx7jqqogJ+bNkhuPObqoEl6c+PfKmbxmbS9e/7arBLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733798441; 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=mjSFIptpj7OQZawgeZ8J5Vr8+D/G7Z4GvKJa2otwEnQ=; b=jZ6xOPVNi0YQ02TUEbpNKNV29dwL6a4VJNKagvviqcNLXuoRgLBuyiAUSRLUJO1ZVVdkiG MmrsRUtuGt14btMWgXSS5SwJVPPe6g3gn+Y6wBDriRQyPhXGsxlNxarMpS4004cwy8Akum O9yDZVG02IllA8vzAReTF+IpUNCZeQ2Wrekoy7ERbfSs/dFGyt/oDqobr+rUmH7FkeWf6G QUZ5N1bVJiLPuRFvLR4KlGWDOssVKNSgnUdmiKw89jgJPlGhqtMkxMtA6aY0rI3LrtBZv+ hiTDd8BUCWAWmhIecE2NNqTmmzo5lfSGEEaxErQeNYtKbFZElo7GPtbWTX7BzQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733798441; a=rsa-sha256; cv=none; b=W6dhDOb5uJX/TMHrAW4sPtbHveNcMYffRsuPkuoKiX3QGpMvKZYaF6FdhuKjkEaCtoxAl8 s3bSYAGx6Lqt1jBiiy+xhJK/A8b9mGhKJ54WYJXyAkWAtL7KOTNWUuobLg8OBLOXoo0EM3 OSAEiHJ9PegClNYUshMiNIvqD9AZMPtayExFfu0apikur10pzQEzhcs/DqhwtXYzHGFPxK HYY2rXslIyp6IrRC9hI/rNxWuaOZ6O61KQpvyho5Q/bkCEfzS5pCx4pe/zAjKJqU2QBjDu jEOjrvkazQYhAxs9RUb/QIRy7vLMF627yNN/Jvy5rxhu7sRiCf98MsSMDl+wRw== 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 4Y6jdj6Mp3z14G3; Tue, 10 Dec 2024 02:40:41 +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 4BA2efIX083450; Tue, 10 Dec 2024 02:40:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BA2efVp083447; Tue, 10 Dec 2024 02:40:41 GMT (envelope-from git) Date: Tue, 10 Dec 2024 02:40:41 GMT Message-Id: <202412100240.4BA2efVp083447@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: b50851e8ebfa - stable/14 - prison_proc_iterate(): make it work for prison0 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: b50851e8ebfa8acc77607a4ff1095ed6e4a56881 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=b50851e8ebfa8acc77607a4ff1095ed6e4a56881 commit b50851e8ebfa8acc77607a4ff1095ed6e4a56881 Author: Konstantin Belousov AuthorDate: 2024-12-06 17:01:00 +0000 Commit: Konstantin Belousov CommitDate: 2024-12-10 02:40:24 +0000 prison_proc_iterate(): make it work for prison0 PR: 283163 (cherry picked from commit 831531a82e0f1d1d7b97e50c0587639322ed8d2e) --- sys/kern/kern_jail.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sys/kern/kern_jail.c b/sys/kern/kern_jail.c index a4bd27734e8e..c4e89774f18b 100644 --- a/sys/kern/kern_jail.c +++ b/sys/kern/kern_jail.c @@ -3051,8 +3051,7 @@ prison_proc_iterate(struct prison *pr, void (*cb)(struct proc *, void *), FOREACH_PROC_IN_SYSTEM(p) { PROC_LOCK(p); if (p->p_state != PRS_NEW && p->p_ucred != NULL) { - for (ppr = p->p_ucred->cr_prison; - ppr != &prison0; + for (ppr = p->p_ucred->cr_prison; ppr != NULL; ppr = ppr->pr_parent) { if (ppr == pr) { cb(p, cbarg); From nobody Tue Dec 10 02:40:42 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 4Y6jdl2kXBz5h7yV; Tue, 10 Dec 2024 02:40:43 +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 4Y6jdl0wNRz4mQ5; Tue, 10 Dec 2024 02:40:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733798443; 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=2RiIXiAgO8NDjkGF4KGrsLyfvtlLvQbbo4TViwkNLTs=; b=ATkyPtwzOVEP9VVQlkm6PFSJkkdC8zO6AmVmgPF0jgDCevBxcSg5xg7huPXowYTXsw/7PC Q/AaFBr60ZpbdcdGm8zRgK24lq0kaA/WJGto20rMl5/9GgTUmrt+PNvuzHF021PCWtXqK6 tqH/iUpNZIauaZXJ0gjKMpn3d5AVnLRLFv7a9KkUU6E/GG9Ud1QUpRiQ6Eb82N90t+12DE tR+HciMxjTsama0xQTKmvMzb9UX9r14FWRFtStvn45LgPk0EzhZu3zwf/bjJp0VjHIECno l8J8Px6ZVeoep9Z7D8criLh+q3/tD7KgVcIeqIYdhP3FMBTMYGdUX/KA/OQIgQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733798443; 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=2RiIXiAgO8NDjkGF4KGrsLyfvtlLvQbbo4TViwkNLTs=; b=Sr1UUEXjw+45mkkao2iiQaUfNybnneG0aElHuxWQGezFmL1Y27lsxplSdGTjK2Rk8w/Dtj lADIqXEhWXvS3nTV9lfWyeHUSIKmTtvDeWcvwHpM5fHwPLan6sarzUu4Si5JhjcOOMxNJD uecH2dqiE/4k9fZOqiXAImiXREfnyB6dzN0NzeJpDQl9sPBsIrfnCLdt5LrBeFBLiPtUqp M8bfuOoaam9nl1Utq3UOFR/3G3mBMoFpzhUXeScDzr25+znAgYJjA3sogQgSk1AB+7Tjnd 71zzgJ76S5LRoLsvoYThOqzzbgIc+16m/dX0CG2XKFkoltCyfzk++EGxcSKclA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733798443; a=rsa-sha256; cv=none; b=rsmyInxU1trpteDeem+gqmWWZ1rPRt5hNpzSVxwqeDNEoAAogzZjfrB+zEe8oyBBMsfkMn D61L0E75D4KkuovxiQ+qx+aFq0Wz2wZu9+HXJy+R6bXDen4v6U+w1OCNQJ1Lp8GXH00lk0 wNfz53bWXkE7rZJLpFLEHp4ANxwzoQSWWtWVaj1Y68fE0PG4j+XHrmKWnStFDouHYHRPGg O2n2HkuiGSFYCSNYc//6k2HMGV4L4/Q/EvP5D1KNmuV/QZjhqb6ptgpnvHCrh+urvXCUmA zgrmtxwjV+Hw3zSSepl+cTS6Kw88GfwYOk7y5izpaFDyUN6r+6luhVGV1f95lA== 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 4Y6jdl0X8vz14b7; Tue, 10 Dec 2024 02:40:43 +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 4BA2egl5083492; Tue, 10 Dec 2024 02:40:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BA2egt4083489; Tue, 10 Dec 2024 02:40:42 GMT (envelope-from git) Date: Tue, 10 Dec 2024 02:40:42 GMT Message-Id: <202412100240.4BA2egt4083489@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: fff3323694f7 - stable/14 - amdiommu: correctly initialize iommu.unit 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: fff3323694f79e020ea139a020ed047bfeb578e3 Auto-Submitted: auto-generated The branch stable/14 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=fff3323694f79e020ea139a020ed047bfeb578e3 commit fff3323694f79e020ea139a020ed047bfeb578e3 Author: Konstantin Belousov AuthorDate: 2024-12-06 08:06:42 +0000 Commit: Konstantin Belousov CommitDate: 2024-12-10 02:40:24 +0000 amdiommu: correctly initialize iommu.unit (cherry picked from commit 53adc0b898a4d263cad0bdfb687d9f008e5768f3) --- sys/x86/iommu/amd_drv.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sys/x86/iommu/amd_drv.c b/sys/x86/iommu/amd_drv.c index 2ab0213925eb..72aae58334f2 100644 --- a/sys/x86/iommu/amd_drv.c +++ b/sys/x86/iommu/amd_drv.c @@ -176,7 +176,6 @@ ivrs_lookup_ivhd_0x40(ACPI_IVRS_HARDWARE2 *h2, void *arg) return (false); ildp->sc->unit_dom = h2->PciSegmentGroup; - ildp->sc->iommu.unit = ivrs_info_to_unit_id(h2->Info); ildp->sc->efr = h2->EfrRegisterImage; return (true); } @@ -194,7 +193,6 @@ ivrs_lookup_ivhd_0x10(ACPI_IVRS_HARDWARE1 *h1, void *arg) return (false); ildp->sc->unit_dom = h1->PciSegmentGroup; - ildp->sc->iommu.unit = ivrs_info_to_unit_id(h1->Info); return (true); } @@ -456,6 +454,7 @@ amdiommu_attach(device_t dev) bool res; sc = device_get_softc(dev); + sc->iommu.unit = device_get_unit(dev); sc->iommu.dev = dev; error = pci_find_cap(dev, PCIY_SECDEV, &sc->seccap_reg); From nobody Tue Dec 10 08:23:00 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 4Y6sDh5zcfz5fnQC; Tue, 10 Dec 2024 08:23:00 +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 4Y6sDh4N5Pz41Hq; Tue, 10 Dec 2024 08:23:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733818980; 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=FxGjA+cr04N8LZtUtuAtyz827fHJa4ydCLd5cqTOQtI=; b=KDPNrP+0QKPjnqQihfn2uRgc9r9W0x0NtBqoEMhiKW1+SPupgcapPMo8QazRONrR4Vh1f+ KJl0ECCQB91ibOZQVA7UR7JqzvMAI7g4EwD0ZWGlSZnQiBYY8iJzDTucmEunUqmLCMANEC 4JQFu3nERnYnKXgTi1yxItnF0uUuCf90d1tKi2TllGx8Ay/3y4ymYlQFF7vvQLuTrm3jF0 lkxDPVydqQK1aqyMA3NPQsVZv9pGiNg36is28ijwzmEQ68PvxPK7Ul/RM7tLkdHsQz1x3a 52aaiP0S63yaymkX8MbXfA1KgkREGCaTBJoR3oKN3pGr7nKEMQRxZvsG9p9P2w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733818980; 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=FxGjA+cr04N8LZtUtuAtyz827fHJa4ydCLd5cqTOQtI=; b=GsxfYmM91PyS2h1TxLwi9pGT57PTgYwYGVef7+oCSx2rjPcEPeGXioQ5UIRXcmwSeKbTJF HsG12bKs/drADzNekZ5JulmlK3jErw081vOCgEtK+qyfuq60qRSLcswVABraA0gUbnYe8J LUsyST/QWsEDQwyLjbEQ1KYvNE0jho8B8t9GlYLEBmuyC+6N5FVbEnUQIdRgjCpH7LwhPE b4Y0/2oyvT/XCfH8+2jcKA3TV6pVBda16lCwm3+8I8yfvBlXu5+nhO3jFv2zs1/5dZOqiM mrDZeX26H8vUdbEYlbSQDugJ0eM0omYk0anrklePELEld8zHjQ3BlkzQWhIy5w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733818980; a=rsa-sha256; cv=none; b=IUbjkNedpM6FY6R9PY6zCT8y3oJHAPgXXX20u/4y8xP0TALRHT/9dO98rJlqWxZL+8UJ03 bsXIB/jf1UgmC1gaPa6hfaI+r0ZrdmOMDLAYTfWmNkbTIORR7XH92Wk+KdvaqecknmFTMP Rgekolt6FLsD1vQC6SR+cPM0Sv/fgrHDZUii1AZ2I/uVaH29E31HvR4HykHZi6TAPig83L +Ze4DbtxBH+0QwsmgD3wr3Hmr+yZj97qTIe14/GS4Heu13j3LiOGeVeu7es2jQ7a6p/kkH WVTwGVgwc0F9cFNpdCTjmstOwcfaue/3CrNBMFzpfdEMenG6RA5+kEctSN7jkw== 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 4Y6sDh40HrzFV5; Tue, 10 Dec 2024 08:23:00 +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 4BA8N0we024683; Tue, 10 Dec 2024 08:23:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BA8N0XR024680; Tue, 10 Dec 2024 08:23:00 GMT (envelope-from git) Date: Tue, 10 Dec 2024 08:23:00 GMT Message-Id: <202412100823.4BA8N0XR024680@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: 36b39281a666 - main - vmcb.h: fix typo in the comment 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 36b39281a666a4c7269c61f909199131b18783c6 Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=36b39281a666a4c7269c61f909199131b18783c6 commit 36b39281a666a4c7269c61f909199131b18783c6 Author: Konstantin Belousov AuthorDate: 2024-12-10 08:22:01 +0000 Commit: Konstantin Belousov CommitDate: 2024-12-10 08:22:37 +0000 vmcb.h: fix typo in the comment Sponsored by: The FreeBSD Foundation MFC after: 3 days --- sys/amd64/vmm/amd/vmcb.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/amd64/vmm/amd/vmcb.h b/sys/amd64/vmm/amd/vmcb.h index b11dabe5b6de..027e894936bd 100644 --- a/sys/amd64/vmm/amd/vmcb.h +++ b/sys/amd64/vmm/amd/vmcb.h @@ -167,7 +167,7 @@ #define VMCB_NPF_INFO1_GPT BIT(33) /* Guest page table. */ /* - * EXITINTINFO, Interrupt exit info for all intrecepts. + * EXITINTINFO, Interrupt exit info for all interecepts. * Section 15.7.2, Intercepts during IDT Interrupt Delivery. */ #define VMCB_EXITINTINFO_VECTOR(x) ((x) & 0xFF) From nobody Tue Dec 10 08:29:30 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 4Y6sNJ680dz5fnhX; Tue, 10 Dec 2024 08:29:36 +0000 (UTC) (envelope-from cvs-src@yandex.ru) Received: from forward500a.mail.yandex.net (forward500a.mail.yandex.net [IPv6:2a02:6b8:c0e:500:1:45:d181:d500]) (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 mx1.freebsd.org (Postfix) with ESMTPS id 4Y6sNJ0NGJz41vw; Tue, 10 Dec 2024 08:29:35 +0000 (UTC) (envelope-from cvs-src@yandex.ru) Authentication-Results: mx1.freebsd.org; none Received: from mail-nwsmtp-mxback-production-main-30.vla.yp-c.yandex.net (mail-nwsmtp-mxback-production-main-30.vla.yp-c.yandex.net [IPv6:2a02:6b8:c15:351b:0:640:10e8:0]) by forward500a.mail.yandex.net (Yandex) with ESMTPS id 7E50161524; Tue, 10 Dec 2024 11:29:31 +0300 (MSK) Received: from mail.yandex.ru (2a02:6b8:c0d:2a80:0:640:d777:0 [2a02:6b8:c0d:2a80:0:640:d777:0]) by mail-nwsmtp-mxback-production-main-30.vla.yp-c.yandex.net (mxback/Yandex) with HTTPS id SThhCu5O0W20-A0OW8tV5; Tue, 10 Dec 2024 11:29:31 +0300 X-Yandex-Fwd: 1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1733819371; bh=k///ADcAnUB6BI+I1lxONyKwpMWR0PkZNVyagZTfoAg=; h=Message-Id:References:Date:Subject:To:In-Reply-To:From; b=VowmLMmPymFcXw6AYyYgbGeEHlsWxxxfNTmDVo9a9LROLHZX2FIPJEtM069d3G63E 9AI6aI642BaIUGVip5d9ZOmcV6CI2wOnjGm37Ur/+Ig11Y3RAx9pbLDbBEtqivDa+T rznxkUHBfIS+P2lGsVZ5PIdK/lx0H018alsRwBuU= Received: by mail-sendbernar-production-main-55.vla.yp-c.yandex.net with HTTP; Tue, 10 Dec 2024 11:29:30 +0300 From: Ruslan Makhmatkhanov To: Konstantin Belousov , "src-committers@FreeBSD.org" , "dev-commits-src-all@FreeBSD.org" , "dev-commits-src-main@FreeBSD.org" In-Reply-To: <202412100823.4BA8N0XR024680@gitrepo.freebsd.org> References: <202412100823.4BA8N0XR024680@gitrepo.freebsd.org> Subject: Re: git: 36b39281a666 - main - vmcb.h: fix typo in the comment 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 X-Mailer: Yamail [ http://yandex.ru ] 5.0 Date: Tue, 10 Dec 2024 11:29:30 +0300 Message-Id: <2161271733819332@mail.yandex.ru> Content-Transfer-Encoding: base64 Content-Type: text/html; charset=utf-8 X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:13238, ipnet:2a02:6b8::/32, country:RU] X-Rspamd-Queue-Id: 4Y6sNJ0NGJz41vw X-Spamd-Bar: ---- PGRpdj5JdCBzdGlsbCB3cm9uZyBhZnRlciB0aGUgY2hhbmdlIDopPC9kaXY+PGRpdj7CoDwvZGl2 PjxkaXY+LS0tLS0tLS0tLS0tLS0tLTwvZGl2PjxkaXY+0JrQvtC80YM6IHNyYy1jb21taXR0ZXJz QGZyZWVic2Qub3JnIChzcmMtY29tbWl0dGVyc0BmcmVlYnNkLm9yZyksIGRldi1jb21taXRzLXNy Yy1hbGxAZnJlZWJzZC5vcmcgKGRldi1jb21taXRzLXNyYy1hbGxAZnJlZWJzZC5vcmcpLCBkZXYt Y29tbWl0cy1zcmMtbWFpbkBmcmVlYnNkLm9yZyAoZGV2LWNvbW1pdHMtc3JjLW1haW5AZnJlZWJz ZC5vcmcpOzwvZGl2PjxkaXY+0KLQtdC80LA6IGdpdDogMzZiMzkyODFhNjY2IC0gbWFpbiAtIHZt Y2IuaDogZml4IHR5cG8gaW4gdGhlIGNvbW1lbnQ7PC9kaXY+PGRpdj4xMC4xMi4yMDI0LCAxMToy MywgIktvbnN0YW50aW4gQmVsb3Vzb3YiICZsdDtraWJAZnJlZWJzZC5vcmcmZ3Q7OjwvZGl2Pjxi bG9ja3F1b3RlPjxwPlRoZSBicmFuY2ggbWFpbiBoYXMgYmVlbiB1cGRhdGVkIGJ5IGtpYjo8YnIg Lz48YnIgLz5VUkw6IDxhIGhyZWY9Imh0dHBzOi8vY2dpdC5mcmVlYnNkLm9yZy9zcmMvY29tbWl0 Lz9pZD0zNmIzOTI4MWE2NjZhNGM3MjY5YzYxZjkwOTE5OTEzMWIxODc4M2M2IiByZWw9Im5vb3Bl bmVyIG5vcmVmZXJyZXIiPmh0dHBzOi8vY2dpdC5GcmVlQlNELm9yZy9zcmMvY29tbWl0Lz9pZD0z NmIzOTI4MWE2NjZhNGM3MjY5YzYxZjkwOTE5OTEzMWIxODc4M2M2PC9hPjxiciAvPjxiciAvPmNv bW1pdCAzNmIzOTI4MWE2NjZhNGM3MjY5YzYxZjkwOTE5OTEzMWIxODc4M2M2PGJyIC8+QXV0aG9y OiBLb25zdGFudGluIEJlbG91c292ICZsdDs8YSBocmVmPSJtYWlsdG86a2liQEZyZWVCU0Qub3Jn IiByZWw9Im5vb3BlbmVyIG5vcmVmZXJyZXIiPmtpYkBGcmVlQlNELm9yZzwvYT4mZ3Q7PGJyIC8+ QXV0aG9yRGF0ZTogMjAyNC0xMi0xMCAwODoyMjowMSArMDAwMDxiciAvPkNvbW1pdDogS29uc3Rh bnRpbiBCZWxvdXNvdiAmbHQ7PGEgaHJlZj0ibWFpbHRvOmtpYkBGcmVlQlNELm9yZyIgcmVsPSJu b29wZW5lciBub3JlZmVycmVyIj5raWJARnJlZUJTRC5vcmc8L2E+Jmd0OzxiciAvPkNvbW1pdERh dGU6IDIwMjQtMTItMTAgMDg6MjI6MzcgKzAwMDA8YnIgLz48YnIgLz7CoMKgwqDCoHZtY2IuaDog Zml4IHR5cG8gaW4gdGhlIGNvbW1lbnQ8YnIgLz7CoMKgwqDCoDxiciAvPsKgwqDCoMKgU3BvbnNv cmVkIGJ5OiBUaGUgRnJlZUJTRCBGb3VuZGF0aW9uPGJyIC8+wqDCoMKgwqBNRkMgYWZ0ZXI6IDMg ZGF5czxiciAvPi0tLTxiciAvPsKgc3lzL2FtZDY0L3ZtbS9hbWQvdm1jYi5oIHwgMiArLTxiciAv PsKgMSBmaWxlIGNoYW5nZWQsIDEgaW5zZXJ0aW9uKCspLCAxIGRlbGV0aW9uKC0pPGJyIC8+PGJy IC8+ZGlmZiAtLWdpdCBhL3N5cy9hbWQ2NC92bW0vYW1kL3ZtY2IuaCBiL3N5cy9hbWQ2NC92bW0v YW1kL3ZtY2IuaDxiciAvPmluZGV4IGIxMWRhYmU1YjZkZS4uMDI3ZTg5NDkzNmJkIDEwMDY0NDxi ciAvPi0tLSBhL3N5cy9hbWQ2NC92bW0vYW1kL3ZtY2IuaDxiciAvPisrKyBiL3N5cy9hbWQ2NC92 bW0vYW1kL3ZtY2IuaDxiciAvPkBAIC0xNjcsNyArMTY3LDcgQEA8YnIgLz7CoCNkZWZpbmUgVk1D Ql9OUEZfSU5GTzFfR1BUIEJJVCgzMykgLyogR3Vlc3QgcGFnZSB0YWJsZS4gKi88YnIgLz7CoDxi ciAvPsKgLyo8YnIgLz4tICogRVhJVElOVElORk8sIEludGVycnVwdCBleGl0IGluZm8gZm9yIGFs bCBpbnRyZWNlcHRzLjxiciAvPisgKiBFWElUSU5USU5GTywgSW50ZXJydXB0IGV4aXQgaW5mbyBm b3IgYWxsIGludGVyZWNlcHRzLjxiciAvPsKgwqAqIFNlY3Rpb24gMTUuNy4yLCBJbnRlcmNlcHRz IGR1cmluZyBJRFQgSW50ZXJydXB0IERlbGl2ZXJ5LjxiciAvPsKgwqAqLzxiciAvPsKgI2RlZmlu ZSBWTUNCX0VYSVRJTlRJTkZPX1ZFQ1RPUih4KSAoKHgpICZhbXA7IDB4RkYpPGJyIC8+wqA8L3A+ PC9ibG9ja3F1b3RlPjxkaXY+wqA8L2Rpdj48ZGl2PsKgPC9kaXY+PGRpdj4tLcKgPC9kaXY+PGRp dj5SZWdhcmRzLDwvZGl2PjxkaXY+UnVzbGFuPC9kaXY+PGRpdj7CoDwvZGl2Pg== From nobody Tue Dec 10 08:49:44 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 4Y6sqX5DPMz5fptv; Tue, 10 Dec 2024 08:49:44 +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 4Y6sqX2pHsz43Ff; Tue, 10 Dec 2024 08:49:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733820584; 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=WTOMyw5xDfhpmPk2q3Mnv5/f0KmpESMJAIo1vLNdg60=; b=vIsNUeSRAuDxD+npmpWf8izxLgqOlATe4xTN2GGpRxM7YcmluL6CmQhFb+L669gUjEe9bg H+CK5BzNpeCe0hGErisWm/5BREHXbFYAmStb6/W9NT5iFogMU6+0KW+y8U8CssgZxn9wiI aGY78uMEzSftkLt301xl36WhFQl6tt6TZeWJzTiHnlzl2mu9tC43VTiMbd43bJ8T7tY7/v rtaeUhfLlV8Nh6BzaprD8qYjpkSON5hgKjS1KQNl6Wny5bZ68DHc+WiRxRbPD17PHt2pmZ /2UT2AbzBZjWFG8pGW6o8s50dUhUlwduGaB9+X3HGajjZtmz4PEN5mtqHZurpg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733820584; 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=WTOMyw5xDfhpmPk2q3Mnv5/f0KmpESMJAIo1vLNdg60=; b=W91Uih/a0WA69U86JUaBxVhMDfn5Bc0RpSfAzcL8sa9o3EMs1vQTE/5WcfVAOh+0X87Fkz yVw3LCfuJh+zKMhoMhxG+/HhoIMyooz7o8W+n1idu67NWmdQqEqapEvg7bIfj7TnaOvSTd DaH6IDlMptB6PvrHXE1KHj9ncwwKQPO3offHvBS8o22ktP6huiRYghrkj9mESa5jR/Rqpc DL6Fjbw1Jo5sIcj2wuWKzGNG5Rul5FBLGK2G3j8MkptIpf5vXgNCeXRg9DjAqwssh54+8l Md5BWNPjrNIQ6g/jExE8gPFvKFELcjI68WTyiFnab0bkp27q+8t10XFnMj2Wxg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733820584; a=rsa-sha256; cv=none; b=dyCTFM1jJ4zC8LQjg5jCI1ouC/tPlq8zXOU7CLRPX0ea3p/Va1vES/UhFg5Xb8qTvV3VvY Bxx5+lNXOSIfrX8HPazATUkmn97cXWsmrQt9zlgfvQsWU21yF7UReFfD8y1A3E1ykm+H3d bOVezbNQFqGEMkVFruuDr48LD20CABIMVc2obger/3o+NUXsVltLpQb4TpIqsT8uCgkhTi zpRI+rqFxz80Q3n6vfhotPpLd2iBpXD5r0oRKw72vXSP8wCqldKoIhvwHRZ8ssB+3EOpEw jV/Lg1ggMKJW5EgooxkCvZgrp8j/qH/D6SQLWHMvfxrOwIXy/AEsBi790jd5tA== 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 4Y6sqX2Q85zGkx; Tue, 10 Dec 2024 08:49:44 +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 4BA8nioV063606; Tue, 10 Dec 2024 08:49:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BA8niM1063603; Tue, 10 Dec 2024 08:49:44 GMT (envelope-from git) Date: Tue, 10 Dec 2024 08:49:44 GMT Message-Id: <202412100849.4BA8niM1063603@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: e02029e6f487 - main - vmcb.h: fix typo in the comment, try two 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: kib X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e02029e6f48789394f3ad137fd992b5f33e336fc Auto-Submitted: auto-generated The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=e02029e6f48789394f3ad137fd992b5f33e336fc commit e02029e6f48789394f3ad137fd992b5f33e336fc Author: Konstantin Belousov AuthorDate: 2024-12-10 08:48:55 +0000 Commit: Konstantin Belousov CommitDate: 2024-12-10 08:48:55 +0000 vmcb.h: fix typo in the comment, try two Noted by: rm Sponsored by: The FreeBSD Foundation MFC after: 3 days --- sys/amd64/vmm/amd/vmcb.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/amd64/vmm/amd/vmcb.h b/sys/amd64/vmm/amd/vmcb.h index 027e894936bd..09150fc26a72 100644 --- a/sys/amd64/vmm/amd/vmcb.h +++ b/sys/amd64/vmm/amd/vmcb.h @@ -167,7 +167,7 @@ #define VMCB_NPF_INFO1_GPT BIT(33) /* Guest page table. */ /* - * EXITINTINFO, Interrupt exit info for all interecepts. + * EXITINTINFO, Interrupt exit info for all intercepts. * Section 15.7.2, Intercepts during IDT Interrupt Delivery. */ #define VMCB_EXITINTINFO_VECTOR(x) ((x) & 0xFF) From nobody Tue Dec 10 15:09:37 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 4Y72Fs6cwKz5gFlX; Tue, 10 Dec 2024 15:09:37 +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 4Y72Fs65nGz4grc; Tue, 10 Dec 2024 15:09:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733843377; 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=6I0XTQuqoedN6Jv8IMLwhUPdZUvdePT+M12Gco/c7no=; b=fOkQBBSH2c/F5j48GG7CSRchBM7B/h+DjsEKrjlXNudTNx0D6qNpP4ZV+CGMGkt/rwp2+T NsC/7nZDkWPFT/p5PnsxDtvTaPmEjNX/xelLyUvlRrSosE/fjsZT9AxxpWFiAGhYfhkhs4 xJNhBhk2x1cg/ZtuTujOpBGtmip2QGJg2B3GUzOULLFd5mMaoPgbVrt2w/RgnKRewMikl+ rkr4eOnHk0ba/z5dyKmRzWjV2JFvPqEE0b+0KxY2oJj/7lnfLC22DytYqjeHNCPiCLyhFc ct1uIwhzAO+lHW673m4ihufUKUglrOvfFbgo/7KJiN1r751/wBbgWymZXtM8OQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733843377; 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=6I0XTQuqoedN6Jv8IMLwhUPdZUvdePT+M12Gco/c7no=; b=G2zhH0ds2R3pud8QfTCu/TmLx0q3nUf4WXbE5vzVLKKbzWtDVPW4Hi/2k1wTWmG3PEI7bQ 6c02khtA0EO3T3swN0VbddP5WZ4Xv0jee6UhFks7GgrwRj2fo3qIjMyEL5QSZI6QEPKZan nrixWNe4eGkP549qGuNFZnLlWULw+wsquRdSUtGbclCpcVYaOWpJuj7kIc2o55U6XBk0GK /OZDQsoNG1Mcv1Cowrp8jtXykjwRANajTABIjxxpY46maDr/njimYomC2EuajyQW62VKnK WxmUL+k0ABgPB5MxINb7RMxM1M7TBpON8mKlxeAVS73Aopg1phTnfJovxyEQHQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733843377; a=rsa-sha256; cv=none; b=Op/R1R+XCwQbmFlUVhniss3ShhywkTW4vlFRZzkongq1wBBGM8FgXEUSHognwiRc+7B15F qbt9PP+WVssd6VZb1FjcZ2xzLZdz+VpJhbTuAcF5+XbRiMna6hLxGotUjT/MSxye2JIcaK Lc6MOsOvVfc8KEBKsrOjTyaNQ29BwtZ5eF5Vq8l2d3NHMx1DxJkz22d1j+nH7Na2scu1D6 2iWxWNd87c81zrvvPu8PJn0MJN2V+kwkz/+DaNgmx4P0y6kh25/bTqpva2/sK2muNHUm5B Nf1uQ/le+C//2smbyhrBDNi4nEile5sRUNcW3HVB8CXumIw8Hod65R8ztNlztA== 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 4Y72Fs5SMnzSdR; Tue, 10 Dec 2024 15:09:37 +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 4BAF9bRl071513; Tue, 10 Dec 2024 15:09:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BAF9bZI071510; Tue, 10 Dec 2024 15:09:37 GMT (envelope-from git) Date: Tue, 10 Dec 2024 15:09:37 GMT Message-Id: <202412101509.4BAF9bZI071510@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mark Johnston Subject: git: c226f193515c - main - riscv: Permit spurious faults in kernel mode 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c226f193515c8c0665610cb519fe381987f8ee24 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=c226f193515c8c0665610cb519fe381987f8ee24 commit c226f193515c8c0665610cb519fe381987f8ee24 Author: Mark Johnston AuthorDate: 2024-12-10 15:07:28 +0000 Commit: Mark Johnston CommitDate: 2024-12-10 15:07:28 +0000 riscv: Permit spurious faults in kernel mode Right now, pmap_enter() does not issue an sfence.vma after overwriting an invalid PTE, so the kernel can trigger a page fault when accessing a freshly created mapping. In this case, pmap_fault() can handle the exception, but we may panic before that. Move the check; this is consistent with arm64 and serves to ensure that we don't call vm_fault() etc. from a context where that's not permitted. Also fix a related bug: don't enable interrupts if they were disabled in the context where the exception occurred. Reviewed by: br Tested by: br MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D47688 --- sys/riscv/riscv/trap.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/sys/riscv/riscv/trap.c b/sys/riscv/riscv/trap.c index 3bb1fc7f1010..a1a30eb58220 100644 --- a/sys/riscv/riscv/trap.c +++ b/sys/riscv/riscv/trap.c @@ -227,11 +227,6 @@ page_fault_handler(struct trapframe *frame, int usermode) pcb = td->td_pcb; stval = frame->tf_stval; - if (td->td_critnest != 0 || td->td_intr_nesting_level != 0 || - WITNESS_CHECK(WARN_SLEEPOK | WARN_GIANTOK, NULL, - "Kernel page fault") != 0) - goto fatal; - if (usermode) { if (!VIRT_IS_VALID(stval)) { call_trapsignal(td, SIGSEGV, SEGV_MAPERR, (void *)stval, @@ -244,7 +239,8 @@ page_fault_handler(struct trapframe *frame, int usermode) * Enable interrupts for the duration of the page fault. For * user faults this was done already in do_trap_user(). */ - intr_enable(); + if ((frame->tf_sstatus & SSTATUS_SIE) != 0) + intr_enable(); if (stval >= VM_MIN_KERNEL_ADDRESS) { map = kernel_map; @@ -268,6 +264,11 @@ page_fault_handler(struct trapframe *frame, int usermode) if (VIRT_IS_VALID(va) && pmap_fault(map->pmap, va, ftype)) goto done; + if (td->td_critnest != 0 || td->td_intr_nesting_level != 0 || + WITNESS_CHECK(WARN_SLEEPOK | WARN_GIANTOK, NULL, + "Kernel page fault") != 0) + goto fatal; + error = vm_fault_trap(map, va, ftype, VM_FAULT_NORMAL, &sig, &ucode); if (error != KERN_SUCCESS) { if (usermode) { From nobody Tue Dec 10 17:29:05 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 4Y75Ln3rWNz5gNvx; Tue, 10 Dec 2024 17:29:05 +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 4Y75Ln1YnDz3xXd; Tue, 10 Dec 2024 17:29:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733851745; 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=Zig6yT8kLxpmImQhqNmFMMgAeZg8QzFe2VsiodWNl3U=; b=XgdMRzGPX6k+eDQrhiTdM8tTMov1jZBSn9zKfHnVMyA/yEn2KUX8vxoDXt/6waoHCqHkj+ NYiIk1yl+AsHtkTyVJNGpS4SFVuaJ2SryqWbdc0s6SK0DjSKi4HhN4q4P+0ZHCJHNpOjqO orEzyAon8AghuyxaDghV6lQDOIoosRDbAMYX3u3doVP4yTlv/fcKkCbZXYbrNQLK+7qSx7 wsTMgmb0j3HYy8j92IKqRdmjlHPpLitDAS9Y4Bcomhui3c9tlwdN3GDtriUNEB/SGdffpl YVUHcXnzPxzv4UkO+AyuMHrELpVeaLG+WWfUKTJenYAARGuavf8Dz/RGguUZIw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733851745; 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=Zig6yT8kLxpmImQhqNmFMMgAeZg8QzFe2VsiodWNl3U=; b=LgkfeIB+JDIR/oUK9x6f3BMPzyMmOQzsa4oXLUxc3AcXQkY+OnH/do87bJs7fHFn4+Jh9z 7j74wDK3u3hnSdDoqlZozej3f40LQn455P/9aaF47KkqbfRJLkj0U1VlkVvhxMdsneDFko 0FQKwww0YFX+RXM+hF5a3XzfGrwp8gDlI0+guvDuLQjfUI+jiGiom9ob6wFp6G5JSNhD8Z 8Ok6NTVMtcP6HRg1g5nuxjYwNGAdt3yNeIXctGqNUKLzDFfWNq7s++DJfvXBcB5pVklakb IxOxo+2UWZAcEKqiFfVmGdlh0WaYPJY1sNkNeMqUBQijjy6XLOQ9sVFfvJqbiA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733851745; a=rsa-sha256; cv=none; b=egHOPJKsO81Y9OfwZMGHFXNxBlyaKdA2uaGchBU79zAijFaLUJpkgF3SjWcVrKmuGG2DL0 mbMEHp9tXKvMIiaqVBMhR+5pJ+Py6ti7t4YTdNbOG+hKaMIUTbEn3edDzhbiE3g7mYRZyl y6e7Z93iVMnvkV7vvS4TSOW2UC9S1JGKghiNiIs/QAbkHSm4cJMMPASApawygl+1fj78AA YyeKgQUSG/p6nEGxtznaJ8lA1sFNZukez6K3Np0X5PcNxFdRtjDY3yshZMsyB8Mg2A8zrV s0ctnpHtPb8XwvdL23kyG8QoNos9N25ud7TWtILDT6rFz5dJr6dRqg0Lw9kiSA== 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 4Y75Ln0yfRzXnr; Tue, 10 Dec 2024 17:29:05 +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 4BAHT5pR031437; Tue, 10 Dec 2024 17:29:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BAHT5lr031434; Tue, 10 Dec 2024 17:29:05 GMT (envelope-from git) Date: Tue, 10 Dec 2024 17:29:05 GMT Message-Id: <202412101729.4BAHT5lr031434@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Muhammad Moinur Rahman Subject: git: 6dafe8c1e46e - main - Clean pkg cache in release media 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: bofh X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6dafe8c1e46e58097b277ab9babb3ec5336713d7 Auto-Submitted: auto-generated The branch main has been updated by bofh: URL: https://cgit.FreeBSD.org/src/commit/?id=6dafe8c1e46e58097b277ab9babb3ec5336713d7 commit 6dafe8c1e46e58097b277ab9babb3ec5336713d7 Author: Muhammad Moinur Rahman AuthorDate: 2024-12-10 17:24:43 +0000 Commit: Muhammad Moinur Rahman CommitDate: 2024-12-10 17:28:55 +0000 Clean pkg cache in release media Recently wifi-firmware-kmod-release pkgs were added in the release installation media, but unfortunately the pkgs were not cleaned up after the installation. These kept the stale pkgs in the /var/cache. The pkgs should be removed with pkg clean. PR: 283112 Reported by: yanhui.he@broadcom.com Reviewed by: cperciva, emaste Approved by: cperciva, emaste, re (implicit) MFC after: 3 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D47942 --- release/Makefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/release/Makefile b/release/Makefile index a99486ea4b84..ee2f52ad56af 100644 --- a/release/Makefile +++ b/release/Makefile @@ -79,6 +79,7 @@ PKG_ARGS+= -o METALOG=METALOG PKG_ENV+= ASSUME_ALWAYS_YES=yes PKG_ARGS+= -r ${.TARGET} -o REPOS_DIR=${.CURDIR}/pkg_repos PKG_INSTALL= env ${PKG_ENV} ${PKG_CMD} ${PKG_ARGS} install +PKG_CLEAN= env ${PKG_ENV} ${PKG_CMD} ${PKG_ARGS} clean -a .endif .if !defined(VOLUME_LABEL) || empty(VOLUME_LABEL) @@ -194,6 +195,7 @@ disc1: packagesystem .if ${.MAKE.OS} == "FreeBSD" && (!defined(NOPKG) || empty(NOPKG)) # Install packages onto release media. ${PKG_INSTALL} wifi-firmware-kmod-release || true + ${PKG_CLEAN} || true .endif # Set up installation environment ln -fs /tmp/bsdinstall_etc/resolv.conf ${.TARGET}/etc/resolv.conf @@ -270,6 +272,7 @@ dvd: packagesystem .if ${.MAKE.OS} == "FreeBSD" && (!defined(NOPKG) || empty(NOPKG)) # Install packages onto release media. ${PKG_INSTALL} wifi-firmware-kmod-release || true + ${PKG_CLEAN} || true .endif # Set up installation environment ln -fs /tmp/bsdinstall_etc/resolv.conf ${.TARGET}/etc/resolv.conf From nobody Tue Dec 10 18:12:59 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 4Y76KR3scsz5gRYF; Tue, 10 Dec 2024 18:12:59 +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 4Y76KR3FxFz458b; Tue, 10 Dec 2024 18:12:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733854379; 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=Ci2YM4qx9anMYExG1SntxrMDGfmP5FhiZvS0d1//ctM=; b=wHIc3AK6uSRemyp+alVFcexy76FAdFtuhPzjqXdc3tQb7HHRw/TZJsq/cMs+X6p+RKr1dL z82YXeipGrq/DeLuh0LJbMfvpiC+mdVcFpV99/4tZGeTgUrQxxlWB+1yTCIFWlFD/cNMvD CNk2Jsf7GMYQZqU+pIq5I63Hteoh5tQgjp7wUCiwvVInO4nH+dU8ZgKfDhURxLSWXPzgp7 vKxnqeJr0n/KvjG0+egyFCxTEHTI3qBIRiwVUdgeaB8vFA7FiD0AaBPC8ou/I+yxOgT0WO +oEBJoajcuA27g8LG9TBVOH+f+OmMUPkKEtCVq7qEtp8HWRVH4FrB+4SmnUjEQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733854379; 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=Ci2YM4qx9anMYExG1SntxrMDGfmP5FhiZvS0d1//ctM=; b=K5Ep804qtoFDf5fUytzrWmT0/U6NoYrpxB4UAVcbHscEylVHxds2JM2mEKqN4k9PeTbNhM xLbWtRFWgB2+xhgJc+PPO4LkyEzGfjq+Dyg6T0ID+LmO8DlxxPC50QMqv0p+ls8OY3aLKQ VBAxDCF6vJ5AGezPeLYQ0FCzA0kalkFTSLEqzD69PUZCN578+TmCbaxyRZsiYZhnKS6cM2 W1ZFxPDwvD4gqQdEDOoIvpu2FvcfM7mcyejbFm+gbiQPwQHL75SsgBrbXDaCKZC3lcxeuc g03YVqt3yrm1YfXZovj9qIvmX2qBww8QToAR8TSB7Bg6GjTkQbdZ9X6O07QXXQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733854379; a=rsa-sha256; cv=none; b=HOWWzk4/3QXKZY2jxcjkm0nu0/E6iwBPM4j/H+4Llc8p6dRM6JRsFQcpTGIByukLuRNsWJ DWRMv0Xz+8gm4MzrLVzf6RJ7gg5usMzhNrU4mdjmERfcVKzVXjU0uqUh+BlKeBCFNAwyet Q0/Xx8J38ZXaPyxpF7bMB1wVV+pBM7B1YJIbwa2RRjcWc2GJAwXOHTuoVQTf33+snMFgGH 2PxMyF/EjbwZOVVPO6b43dsEarxA4+n0U+5LaVOeUih1dm4C2DN/KfCHpKIgECYEstiH/O J2SHxrOHFUglcpgnMRNPSw3IwPm7ND8VqrFJ6IyFoACszP2HwTw2b8RNGlNPjQ== 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 4Y76KR2sMkzYtG; Tue, 10 Dec 2024 18:12:59 +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 4BAICxc1022678; Tue, 10 Dec 2024 18:12:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BAICxvY022675; Tue, 10 Dec 2024 18:12:59 GMT (envelope-from git) Date: Tue, 10 Dec 2024 18:12:59 GMT Message-Id: <202412101812.4BAICxvY022675@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Popov Subject: git: c7919fb92d20 - main - netlink: Do not cast to int in NLMSG_HDRLEN and _NLMSG_LEN 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: arrowd X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: c7919fb92d201ab1d5bd3ab0c18cbcea961ef761 Auto-Submitted: auto-generated The branch main has been updated by arrowd: URL: https://cgit.FreeBSD.org/src/commit/?id=c7919fb92d201ab1d5bd3ab0c18cbcea961ef761 commit c7919fb92d201ab1d5bd3ab0c18cbcea961ef761 Author: Gleb Popov AuthorDate: 2024-10-29 18:41:34 +0000 Commit: Gleb Popov CommitDate: 2024-12-10 18:11:16 +0000 netlink: Do not cast to int in NLMSG_HDRLEN and _NLMSG_LEN Approved by: melifaro Sponsored by: Future Crew, LLC Differential Revision: https://reviews.freebsd.org/D47333 --- sys/netlink/netlink.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/netlink/netlink.h b/sys/netlink/netlink.h index 5724385271fc..e677365b9a21 100644 --- a/sys/netlink/netlink.h +++ b/sys/netlink/netlink.h @@ -210,11 +210,11 @@ enum nlmsginfo_attrs { /* part of netlink(3) API */ #define NLMSG_ALIGNTO NL_ITEM_ALIGN_SIZE #define NLMSG_ALIGN(_len) NL_ITEM_ALIGN(_len) -#define NLMSG_HDRLEN ((int)sizeof(struct nlmsghdr)) +#define NLMSG_HDRLEN (sizeof(struct nlmsghdr)) #define NLMSG_LENGTH(_len) ((_len) + NLMSG_HDRLEN) #define NLMSG_SPACE(_len) NLMSG_ALIGN(NLMSG_LENGTH(_len)) #define NLMSG_DATA(_hdr) NL_ITEM_DATA(_hdr, NLMSG_HDRLEN) -#define _NLMSG_LEN(_hdr) ((int)(_hdr)->nlmsg_len) +#define _NLMSG_LEN(_hdr) ((_hdr)->nlmsg_len) #define _NLMSG_ALIGNED_LEN(_hdr) NLMSG_ALIGN(_NLMSG_LEN(_hdr)) #define NLMSG_OK(_hdr, _len) NL_ITEM_OK(_hdr, _len, NLMSG_HDRLEN, _NLMSG_LEN) #define NLMSG_PAYLOAD(_hdr,_len) (_NLMSG_LEN(_hdr) - NLMSG_SPACE((_len))) @@ -223,7 +223,7 @@ enum nlmsginfo_attrs { #else #define NLMSG_ALIGNTO 4U #define NLMSG_ALIGN(len) (((len) + NLMSG_ALIGNTO - 1) & ~(NLMSG_ALIGNTO - 1)) -#define NLMSG_HDRLEN ((int)NLMSG_ALIGN(sizeof(struct nlmsghdr))) +#define NLMSG_HDRLEN (NLMSG_ALIGN(sizeof(struct nlmsghdr))) #endif /* From nobody Tue Dec 10 18:13:00 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 4Y76KS4yWZz5gRh3; Tue, 10 Dec 2024 18:13:00 +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 4Y76KS44hLz458c; Tue, 10 Dec 2024 18:13:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733854380; 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=+JY4lo/STjC2Co0kx0HMD7orlpEvrxas6KPgfnZuLUU=; b=BTmtjdongcXefTgonmwCmBEw25A/Fh3+KSRowD2+LQZcG1s2XCqx186HMebQCMBlmLE5ZG iN2L5/1Z1a0fkOSuKa81BqUW10SjtEI9FjYhMoDndMrQSyzRfwj6tv5dYCHQv9aqgHX09B 904OQTlyOgTou+yYYgNNYha5wS9VOhjsueo1cgWq6kRfKUQz03G7eoeonWhrDZskO0YrkG RbgDRT8AFIKegpPnYx7Co946rmk84zTVQidCoLxrj6BviM+HZCJCtd7BpxrwKZbw2qNt0O BCooEFEdLC/ukpJqbnlVeuDY9BU3zYbTwyhXmtarzGIjLB6dKoGvR/YWlGXShA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733854380; 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=+JY4lo/STjC2Co0kx0HMD7orlpEvrxas6KPgfnZuLUU=; b=ct6RkcmtZOdPn9FrEuU7tfsGWNQ1In3bY6AhD+bWKmI5m3MvCw/YzqxFGdgmUUx6JfHuCZ QN808iZ5nw6SoJoRo9P72TQAHZUg2yHq/RCx3oqITsrZELqraqvPBTAnW/ik4TOcqr+Hzl CSKSjbXwPzEcikvev/3/wxtYaSssyrz+F1FKq9hF2c4m/Qr8rKswOj0kWGlI2XAu8NREHa 9RDHlrtRAKMHUjk+/8uk9TqDIaOTLvhdWjE9Wj0AxGi1ECET98rcvRMsjAyuM0N/8Hatpt cA+d19g8zbTkm8ENKEacvlIXNgY2PLJO2yLDF0ZkEjIIIFsH15DE1ZGayFwNDA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733854380; a=rsa-sha256; cv=none; b=vDA9x+vXaHaxFIFelDgxOJ02ls9v2n74JHDfnXYAX5tkcWQ7Gsb5OCOo3jcGKACJQLlZ+t 5rvOvCYWjrzFq8vaEvB0HTUM22bcvT7HA7VJ6WHfAZ948ij4fK6Cl2scmPv6x3u+gox9ob mXEqby+eYFnjZZG3TchzTbYPYJoXCwTkDc/O7VUsEwrNag/8BsRW/1+vyg+mIqrSdW6zQ4 mHkbGQm7YSHDKfFYSyAmWK3Vmf3m+P1FaG68ommWYsQGc1uK/3qYYhc/DSccd4/3IL6aS0 lHDedGJuf0oVZgmDDcUGqTWrUVgMSgTP+tFRkTgTm03v7gBo/AEFBYbAnZjRLQ== 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 4Y76KS3hHczYdh; Tue, 10 Dec 2024 18:13:00 +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 4BAID0Q5022745; Tue, 10 Dec 2024 18:13:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BAID0Xo022742; Tue, 10 Dec 2024 18:13:00 GMT (envelope-from git) Date: Tue, 10 Dec 2024 18:13:00 GMT Message-Id: <202412101813.4BAID0Xo022742@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Popov Subject: git: 9df901c8f8c8 - main - netlink: Pop NLMSG_ALIGNTO and NLMSG_ALIGN out of the #ifndef _KERNEL block 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: arrowd X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9df901c8f8c8f6a0766d87fbc6ef3dc1b73423f8 Auto-Submitted: auto-generated The branch main has been updated by arrowd: URL: https://cgit.FreeBSD.org/src/commit/?id=9df901c8f8c8f6a0766d87fbc6ef3dc1b73423f8 commit 9df901c8f8c8f6a0766d87fbc6ef3dc1b73423f8 Author: Gleb Popov AuthorDate: 2024-10-31 16:23:23 +0000 Commit: Gleb Popov CommitDate: 2024-12-10 18:12:09 +0000 netlink: Pop NLMSG_ALIGNTO and NLMSG_ALIGN out of the #ifndef _KERNEL block Sponsored by: Future Crew, LLC Approved by: melifaro Differential Revision: https://reviews.freebsd.org/D47333 --- sys/netlink/netlink.h | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/sys/netlink/netlink.h b/sys/netlink/netlink.h index e677365b9a21..a87363197187 100644 --- a/sys/netlink/netlink.h +++ b/sys/netlink/netlink.h @@ -205,11 +205,12 @@ enum nlmsginfo_attrs { #define NL_ITEM_ITER(_ptr, _len, _LEN_MACRO) \ ((_len) -= _LEN_MACRO(_ptr), NL_ITEM_NEXT(_ptr, _LEN_MACRO)) - -#ifndef _KERNEL /* part of netlink(3) API */ #define NLMSG_ALIGNTO NL_ITEM_ALIGN_SIZE #define NLMSG_ALIGN(_len) NL_ITEM_ALIGN(_len) + +#ifndef _KERNEL +/* part of netlink(3) API */ #define NLMSG_HDRLEN (sizeof(struct nlmsghdr)) #define NLMSG_LENGTH(_len) ((_len) + NLMSG_HDRLEN) #define NLMSG_SPACE(_len) NLMSG_ALIGN(NLMSG_LENGTH(_len)) @@ -221,8 +222,6 @@ enum nlmsginfo_attrs { #define NLMSG_NEXT(_hdr, _len) NL_ITEM_ITER(_hdr, _len, _NLMSG_ALIGNED_LEN) #else -#define NLMSG_ALIGNTO 4U -#define NLMSG_ALIGN(len) (((len) + NLMSG_ALIGNTO - 1) & ~(NLMSG_ALIGNTO - 1)) #define NLMSG_HDRLEN (NLMSG_ALIGN(sizeof(struct nlmsghdr))) #endif From nobody Tue Dec 10 18:13:02 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 4Y76KW0DFJz5gRYP; Tue, 10 Dec 2024 18:13:03 +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 4Y76KV63Lnz44t5; Tue, 10 Dec 2024 18:13:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733854382; 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=tAEBOX8oMacwdwobmpL4SNn6GPs0mOzx1HGi/kUapiE=; b=jnxgP0i/hM+97ZCQTZ9Ot46dEtZIxnRLTCuZl7d56y2/3U4nh2z5KOsLzJgh1oJnnJemIo EKVWmoRpA6d+HMS3NONh1OuBXB5HbmxPJClrhigJqRepENPm7ldIVklFLy9pZAMPNDxA2W zGIjcY4XtwYnkS1VVeEnw8VyosgWzrcJoGlMybB4Kpd/3Zm72hE4Z2XWUzSbxUfk+UXnCF gjjs5aHkVu2M+Q1wRwCu/z6Q+tNaSHdkWNhluYT6kuDIXX0faYDaWnOQvTxVro8Neelbpa g9VNE/ZgEdZF0HJ4aJTTNPj6d5hUEFB8SRKaF3Q0QNz6agvUcsoKHHlxDcQXfw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733854382; 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=tAEBOX8oMacwdwobmpL4SNn6GPs0mOzx1HGi/kUapiE=; b=LLmUj/+N9dmgkA5bzcZ6VuQ9wqd1jpLhmlQS/WlJxDXIjXF+Fl2pQ72D2oetb/sd52r/4n kJqFg9obD6iQUUN+3sXUQsaNG8LVXLw3d0LUUvHw7zgph8iglJ46FHP8k6TXoHY1suo0Rf UPx44F2+Ds8xrq6hI3g+RitM3ONCsKIpNLxahxf3EbGWP2hKcEo4oT2hLjD15uCzTTsId2 BT0E/3rWpWd7nPT4FugpRnSMCcGGk7zlPsP7OtUixPmZvjpa4wQj1eI8NU82FyIWGKKwpb iisuzab39b0Qt7svEVA8m84jVJ5lzB1G/rKE+fWe9d0eBOgMeJJDLeEUqGVn/w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733854382; a=rsa-sha256; cv=none; b=o60z93DIHOn12geqhxt95F+C51GkK8D2FlO0spdQa936FJINK8eeLtqeymUPAbLHUQIo1D 6R1kXSBwdwc4+uX4S5mOIPMhzEjoiH4s0Rq9NAE2LZdXUjtn2zPYcIo2X0ceMwu29iuTjn JATaInVR6toWywYglz/WhmMwU6wFKeaXRXIVdBLlP8lwtKQAXv38D3KGmSjymijfDmjBc0 ORrLxc0J0pR+B0TeqoHvJVKmOnEXWbvgCowmRJ1yBo8IRDnP8HsebUTBKETQH45D0MIAtv 6BsP2fO1bs5cgu41qdg+YmpvXpK3rR39cWXOhe9tjy4S3o1+Dk9F0/4RuTZzjA== 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 4Y76KV5CQVzZQ1; Tue, 10 Dec 2024 18:13:02 +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 4BAID2V5022848; Tue, 10 Dec 2024 18:13:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BAID2pI022845; Tue, 10 Dec 2024 18:13:02 GMT (envelope-from git) Date: Tue, 10 Dec 2024 18:13:02 GMT Message-Id: <202412101813.4BAID2pI022845@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Popov Subject: git: 33c670c373c0 - main - netlink.h: Align macro declarations with tabs 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: arrowd X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 33c670c373c065064dd8d8a0cc1623db7e556c5a Auto-Submitted: auto-generated The branch main has been updated by arrowd: URL: https://cgit.FreeBSD.org/src/commit/?id=33c670c373c065064dd8d8a0cc1623db7e556c5a commit 33c670c373c065064dd8d8a0cc1623db7e556c5a Author: Gleb Popov AuthorDate: 2024-10-31 16:56:51 +0000 Commit: Gleb Popov CommitDate: 2024-12-10 18:12:38 +0000 netlink.h: Align macro declarations with tabs Sponsored by: Future Crew, LLC Approved by: melifaro Differential Revision: https://reviews.freebsd.org/D47333 --- sys/netlink/netlink.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/sys/netlink/netlink.h b/sys/netlink/netlink.h index d8cf1401fcd0..2395726e7455 100644 --- a/sys/netlink/netlink.h +++ b/sys/netlink/netlink.h @@ -206,15 +206,15 @@ enum nlmsginfo_attrs { ((_len) -= _LEN_MACRO(_ptr), NL_ITEM_NEXT(_ptr, _LEN_MACRO)) /* part of netlink(3) API */ -#define NLMSG_ALIGNTO NL_ITEM_ALIGN_SIZE -#define NLMSG_ALIGN(_len) NL_ITEM_ALIGN(_len) +#define NLMSG_ALIGNTO NL_ITEM_ALIGN_SIZE +#define NLMSG_ALIGN(_len) NL_ITEM_ALIGN(_len) #ifndef _KERNEL /* part of netlink(3) API */ -#define NLMSG_HDRLEN (sizeof(struct nlmsghdr)) -#define NLMSG_LENGTH(_len) ((_len) + NLMSG_HDRLEN) -#define NLMSG_SPACE(_len) NLMSG_ALIGN(NLMSG_LENGTH(_len)) -#define NLMSG_DATA(_hdr) NL_ITEM_DATA(_hdr, NLMSG_HDRLEN) +#define NLMSG_HDRLEN (sizeof(struct nlmsghdr)) +#define NLMSG_LENGTH(_len) ((_len) + NLMSG_HDRLEN) +#define NLMSG_SPACE(_len) NLMSG_ALIGN(NLMSG_LENGTH(_len)) +#define NLMSG_DATA(_hdr) NL_ITEM_DATA(_hdr, NLMSG_HDRLEN) #define _NLMSG_LEN(_hdr) ((_hdr)->nlmsg_len) #define _NLMSG_ALIGNED_LEN(_hdr) NLMSG_ALIGN(_NLMSG_LEN(_hdr)) #define NLMSG_OK(_hdr, _len) NL_ITEM_OK(_hdr, _len, NLMSG_HDRLEN, _NLMSG_LEN) @@ -222,7 +222,7 @@ enum nlmsginfo_attrs { #define NLMSG_NEXT(_hdr, _len) NL_ITEM_ITER(_hdr, _len, _NLMSG_ALIGNED_LEN) #else -#define NLMSG_HDRLEN (NLMSG_ALIGN(sizeof(struct nlmsghdr))) +#define NLMSG_HDRLEN (NLMSG_ALIGN(sizeof(struct nlmsghdr))) #endif /* From nobody Tue Dec 10 20:03:18 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 4Y78mk5KFFz5gYks; Tue, 10 Dec 2024 20:03:18 +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 4Y78mk4HJyz4Nr1; Tue, 10 Dec 2024 20:03:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733860998; 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=AmERC/ROs/cXMyLlNp4Q2uRho8WZUx1rm4A2n+Rn2x0=; b=eCEQ+SBNFwnJVB/YUV2mKrfnV2PReu+fFMOzTC91A/KUncqnJtqpWGHUIkTzfmTLkx9Weg 35RWGPoqXQuiBYmcrgmJWox6MRyZJZY0jfb3Z5zoCaWWfW3aXFxM9D4DyDENI2aSUk+OmW bD4KGKXoRyz0TXTLo3XTabEvl8QEXoZyRjvUYoRO3FxJM34tOmosoxVJXBSPtS89SGRPPk 4HkzqV/DBS/owR3E62K+/cTIp5qPGDZIOWHkM5xuISb0a3ts1YlHDgIqJ6h3FPMjCbUWib WYU2n3HBB6PUj+f8UjlkTXNPP5SpG/ZOFFhEXDVTFK9LrDsiw2VmVEg/obfIKw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733860998; 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=AmERC/ROs/cXMyLlNp4Q2uRho8WZUx1rm4A2n+Rn2x0=; b=YscHf7GQUmd/dZtoJwgK09uVBrVTNrKBJTyVvF+L9MMP3fNu8Tt0Yr0j0Ia+LDHiprOS7I UTIXe9zirQB7E82a5R7kii1rskBDCoDRHzBKAfCM8sk9h5AfWlxgsGqrDRMzmAnBj30mb5 FOVrhYwTlSle+u4z7Elqbpapi/zCAMwJXcUFE54FbuGSuenFop/FJ0YKt7LpZwjYcYMnEw zO51BNZmirmh403dIJzGCO+pAQalQvVSi4jiMhcA2ENeic+kYViE01cM1iEDSsNkBPcdkN RuOUQZsFFnUVMhHsOSQHwaCOkJOzS1VMdNKlubQsqJ3I8mgzRsEXpEYqfWasTw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733860998; a=rsa-sha256; cv=none; b=R80paqqstYfVe6vOH5bh4aO0qcemAy7tNocyhiZbnn9qXa8W5n0/Iu7umr5n0VyKjEf1DK nlhG1jLx8XvZVrgxSGixibqu6ty4GS1vpd4tSnvalZlsx9P0cZIGlo7Ei6Qiqf/an54AAG a73P+Ae9L7N2iKtydWBhr75x97I7OXOUomttTjwXqFAfN4rFh75qwP97CjxRuT5Rh0Ko+Y iGrnzLuF00/PTv4QspkGmsuHEakFKeV9PDod8ch+UtRlMMbnCeAGdcsnGqgGzhnrkeXXHG 2CDMdPdVZIRfb9nhNa/lAicHtXo9HBLpsBLoPm03GFHu+usm+xjJBk7Mc/EiZg== 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 4Y78mk3ts0zd9M; Tue, 10 Dec 2024 20:03:18 +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 4BAK3IBP028334; Tue, 10 Dec 2024 20:03:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BAK3IB7028331; Tue, 10 Dec 2024 20:03:18 GMT (envelope-from git) Date: Tue, 10 Dec 2024 20:03:18 GMT Message-Id: <202412102003.4BAK3IB7028331@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: c4290f346662 - stable/14 - kern: restore signal mask before ast() for pselect/ppoll 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c4290f3466624f8e26af83f3090c3b0f62512ca1 Auto-Submitted: auto-generated The branch stable/14 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=c4290f3466624f8e26af83f3090c3b0f62512ca1 commit c4290f3466624f8e26af83f3090c3b0f62512ca1 Author: Kyle Evans AuthorDate: 2024-11-26 04:04:48 +0000 Commit: Kyle Evans CommitDate: 2024-12-10 20:02:52 +0000 kern: restore signal mask before ast() for pselect/ppoll It's possible to take a signal after pselect/ppoll have set their return value, but before we actually return to userland. This results in taking a signal without reflecting it in the return value, which weakens the guarantees provided by these functions. Switch both to restore the signal mask before we would deliver signals on return to userland. If a signal was received after the wait was over, then we'll just have the signal queued up for the next time it comes unblocked. The modified signal mask is retained if we were interrupted so that ast() actually handles the signal, at which point the signal mask is restored. des@ has a test case demonstrating the issue in D47738 which will follow. Reported by: des Reviewed by: des (earlier version), kib Sponsored by: Klara, Inc. Sponsored by: NetApp, Inc. (cherry picked from commit ccb973da1f1b65879eade8e65cdd2885e125f90e) --- sys/kern/sys_generic.c | 53 +++++++++++++++++++++++++++++++++++++++----------- 1 file changed, 42 insertions(+), 11 deletions(-) diff --git a/sys/kern/sys_generic.c b/sys/kern/sys_generic.c index 77e4c13d4390..6a80ddbe86ed 100644 --- a/sys/kern/sys_generic.c +++ b/sys/kern/sys_generic.c @@ -1050,15 +1050,31 @@ kern_pselect(struct thread *td, int nd, fd_set *in, fd_set *ou, fd_set *ex, &td->td_oldsigmask, 0); if (error != 0) return (error); - td->td_pflags |= TDP_OLDMASK; + } + error = kern_select(td, nd, in, ou, ex, tvp, abi_nfdbits); + if (uset != NULL) { /* * Make sure that ast() is called on return to * usermode and TDP_OLDMASK is cleared, restoring old - * sigmask. + * sigmask. If we didn't get interrupted, then the caller is + * likely not expecting a signal to hit that should normally be + * blocked by its signal mask, so we restore the mask before + * any signals could be delivered. */ - ast_sched(td, TDA_SIGSUSPEND); + if (error == EINTR) { + td->td_pflags |= TDP_OLDMASK; + ast_sched(td, TDA_SIGSUSPEND); + } else { + int serror __diagused; + + /* *select(2) should never restart. */ + MPASS(error != ERESTART); + serror = kern_sigprocmask(td, SIG_SETMASK, + &td->td_oldsigmask, NULL, 0); + MPASS(serror == 0); + } } - error = kern_select(td, nd, in, ou, ex, tvp, abi_nfdbits); + return (error); } @@ -1529,13 +1545,6 @@ kern_poll_kfds(struct thread *td, struct pollfd *kfds, u_int nfds, &td->td_oldsigmask, 0); if (error) return (error); - td->td_pflags |= TDP_OLDMASK; - /* - * Make sure that ast() is called on return to - * usermode and TDP_OLDMASK is cleared, restoring old - * sigmask. - */ - ast_sched(td, TDA_SIGSUSPEND); } seltdinit(td); @@ -1558,6 +1567,28 @@ kern_poll_kfds(struct thread *td, struct pollfd *kfds, u_int nfds, error = EINTR; if (error == EWOULDBLOCK) error = 0; + + if (uset != NULL) { + /* + * Make sure that ast() is called on return to + * usermode and TDP_OLDMASK is cleared, restoring old + * sigmask. If we didn't get interrupted, then the caller is + * likely not expecting a signal to hit that should normally be + * blocked by its signal mask, so we restore the mask before + * any signals could be delivered. + */ + if (error == EINTR) { + td->td_pflags |= TDP_OLDMASK; + ast_sched(td, TDA_SIGSUSPEND); + } else { + int serror __diagused; + + serror = kern_sigprocmask(td, SIG_SETMASK, + &td->td_oldsigmask, NULL, 0); + MPASS(serror == 0); + } + } + return (error); } From nobody Tue Dec 10 20:03:23 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 4Y78mq2qccz5gYWR; Tue, 10 Dec 2024 20:03:23 +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 4Y78mq25Lvz4P7c; Tue, 10 Dec 2024 20:03:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733861003; 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=IWtf46lo6/oLuGbqgo5ba+aYdhHU9f9ZH5anuVwHsDs=; b=DsaXRDxiJINBrDM0sInh//G3Hou/nhdqZ0jDho1vQ86uRrd9qoF+IMUEyEWvn50IXm6dsF XMnwhShxH6HC5vNlX2BQBx9qqVDmXAD6QYzkI5CuUOdY1HN6kS0m4idOQcvL8lPqySPKlq lW+ZnQ6DO+nvANv4suTupDzt6lyFaScsxQGc8QRmtd6xKAYvclrjtZg0xwjtLQBzfJfw++ HSP/U6RiJEnGxZu5gb77JKHFGvcvyUMLOBGr8U8b9IMkp5OSrfHuUAx2pFYDwLY5TvjdB0 gAWN0V5e9A87CekFLp9j5mfYvEqjZeVrDLCVu3v99RoWh5g8LHMGXOhTRrtiog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733861003; 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=IWtf46lo6/oLuGbqgo5ba+aYdhHU9f9ZH5anuVwHsDs=; b=wfsPvUDuVczQvpJ2vtFKh5THCs0Ml7XcuSlmIv4v44l+ZwgTIujPYqW9zDPHybjzpCtNyV zqn9SpUK3jgdC+pjtIYKVV2HDUbG4ruOGJkJTQ8pBB4ikK/TN0wjWLYSWvSIL5q9J8FqFo RqFtEZLEWgMT3SLw0biYJSBN0wwic6d14HSHkDLLMNvxuTZ/pKU3DW1uLnCW2WoWn2UWYb o2U0lB2LzJhtKdr1h7lEW/Ru/0YhuqP+fsKh85ezOTGDMqfnTs0bhb65K0IAfnqr+yYCYQ zYNA4FAeNpLcaYdl4SEHry4yPHyWUWO3E5gPqogo04LLVI7nabWJUY7G2vvi6w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733861003; a=rsa-sha256; cv=none; b=UHs5Vpn6mEx9f2dn6uEr5RmsjzkSDg3dzxDv2c4vO73nfNYX3p7ESVAJLjf0lfuIrpd5lm eNMZmVial/Q778rR7iMiIytK4rD6LfLzr92tx5/+1fVgD4HFJKO1nWtg/xR9kbgPmvxLbJ CFr0ClzjWlFizMooqi/IUlgmVsjbkJd+JORZBZrvK1hdtevQCYiTj4REp6EarTzWwNLd14 nnlbkPd3bFxxebvQlWl7LW+tgPaaztmTMC0Njk33yoQha9jerAzLzvuY1TLJZiPJmJVp57 YqCA6kh5P3+lLKKA7gA8/y1XzoL7Vo9Sl7nGpowsbWNzLQ4cSM9+aw8bqvB+Dw== 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 4Y78mq1c4DzdCV; Tue, 10 Dec 2024 20:03:23 +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 4BAK3NZ3028504; Tue, 10 Dec 2024 20:03:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BAK3NFm028499; Tue, 10 Dec 2024 20:03:23 GMT (envelope-from git) Date: Tue, 10 Dec 2024 20:03:23 GMT Message-Id: <202412102003.4BAK3NFm028499@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: e5e44726d5af - stable/13 - kern: restore signal mask before ast() for pselect/ppoll 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: e5e44726d5afdb260893a3b4e0be025f6dd74bd4 Auto-Submitted: auto-generated The branch stable/13 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=e5e44726d5afdb260893a3b4e0be025f6dd74bd4 commit e5e44726d5afdb260893a3b4e0be025f6dd74bd4 Author: Kyle Evans AuthorDate: 2024-11-26 04:04:48 +0000 Commit: Kyle Evans CommitDate: 2024-12-10 20:03:14 +0000 kern: restore signal mask before ast() for pselect/ppoll It's possible to take a signal after pselect/ppoll have set their return value, but before we actually return to userland. This results in taking a signal without reflecting it in the return value, which weakens the guarantees provided by these functions. Switch both to restore the signal mask before we would deliver signals on return to userland. If a signal was received after the wait was over, then we'll just have the signal queued up for the next time it comes unblocked. The modified signal mask is retained if we were interrupted so that ast() actually handles the signal, at which point the signal mask is restored. des@ has a test case demonstrating the issue in D47738 which will follow. Reported by: des Reviewed by: des (earlier version), kib Sponsored by: Klara, Inc. Sponsored by: NetApp, Inc. Differential Revision: https://reviews.freebsd.org/D47741 (cherry picked from commit ccb973da1f1b65879eade8e65cdd2885e125f90e) --- sys/kern/sys_generic.c | 61 +++++++++++++++++++++++++++++++++++++------------- 1 file changed, 46 insertions(+), 15 deletions(-) diff --git a/sys/kern/sys_generic.c b/sys/kern/sys_generic.c index a0a13e77131b..c605e3f00fdd 100644 --- a/sys/kern/sys_generic.c +++ b/sys/kern/sys_generic.c @@ -975,17 +975,33 @@ kern_pselect(struct thread *td, int nd, fd_set *in, fd_set *ou, fd_set *ex, &td->td_oldsigmask, 0); if (error != 0) return (error); - td->td_pflags |= TDP_OLDMASK; + } + error = kern_select(td, nd, in, ou, ex, tvp, abi_nfdbits); + if (uset != NULL) { /* * Make sure that ast() is called on return to * usermode and TDP_OLDMASK is cleared, restoring old - * sigmask. + * sigmask. If we didn't get interrupted, then the caller is + * likely not expecting a signal to hit that should normally be + * blocked by its signal mask, so we restore the mask before + * any signals could be delivered. */ - thread_lock(td); - td->td_flags |= TDF_ASTPENDING; - thread_unlock(td); + if (error == EINTR) { + td->td_pflags |= TDP_OLDMASK; + thread_lock(td); + td->td_flags |= TDF_ASTPENDING; + thread_unlock(td); + } else { + int serror __diagused; + + /* *select(2) should never restart. */ + MPASS(error != ERESTART); + serror = kern_sigprocmask(td, SIG_SETMASK, + &td->td_oldsigmask, NULL, 0); + MPASS(serror == 0); + } } - error = kern_select(td, nd, in, ou, ex, tvp, abi_nfdbits); + return (error); } @@ -1456,15 +1472,6 @@ kern_poll_kfds(struct thread *td, struct pollfd *kfds, u_int nfds, &td->td_oldsigmask, 0); if (error) return (error); - td->td_pflags |= TDP_OLDMASK; - /* - * Make sure that ast() is called on return to - * usermode and TDP_OLDMASK is cleared, restoring old - * sigmask. - */ - thread_lock(td); - td->td_flags |= TDF_ASTPENDING; - thread_unlock(td); } seltdinit(td); @@ -1487,6 +1494,30 @@ kern_poll_kfds(struct thread *td, struct pollfd *kfds, u_int nfds, error = EINTR; if (error == EWOULDBLOCK) error = 0; + + if (uset != NULL) { + /* + * Make sure that ast() is called on return to + * usermode and TDP_OLDMASK is cleared, restoring old + * sigmask. If we didn't get interrupted, then the caller is + * likely not expecting a signal to hit that should normally be + * blocked by its signal mask, so we restore the mask before + * any signals could be delivered. + */ + if (error == EINTR) { + td->td_pflags |= TDP_OLDMASK; + thread_lock(td); + td->td_flags |= TDF_ASTPENDING; + thread_unlock(td); + } else { + int serror __diagused; + + serror = kern_sigprocmask(td, SIG_SETMASK, + &td->td_oldsigmask, NULL, 0); + MPASS(serror == 0); + } + } + return (error); } From nobody Tue Dec 10 20:27:48 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 4Y79K03LySz5gZtH; Tue, 10 Dec 2024 20:27:48 +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 4Y79K02ZFMz4Qx4; Tue, 10 Dec 2024 20:27:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733862468; 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=ywv+EpO3MGJ2B/2wh3nKktLQhH0PcEuEAWw0sqIZV50=; b=WULRu7YuSfYQuivA+9qGTdG2dqry7VUWCTB7Vbwh80hOGYZhPBZgm4MexqfMSOCo8Q1f0z BUOLsmucgWN2eCpdl+jUjCK8A4GWwfcGXKw1z0rrZjBqO6q7+Z3t0As3kOAs+FjtbwhE+1 rhXEANHiav6HZA+WUX38R9iEokYN3ZbDSAbUpGBywxGlbKwHp4C+SRhIYgpHlR7TGFdpig ktq6Lbtx+pzJzAkkvloAytpOGxcH5SourK/QV8SdHb5Sk07ekye0J5oyuEjKm+E08Q8u9c nitVA2lTfHlHFsk4PCO7JbVTRDSqAwjsPIj5ltygOsSEUwlibLuuuS4zSmN+xw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733862468; 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=ywv+EpO3MGJ2B/2wh3nKktLQhH0PcEuEAWw0sqIZV50=; b=AKPCcFJuo6Z+5vH1nRGN7zmfiqkzUmlXthWQOlq/rrsm5Btwz2oyhM++fulDt2UnQ8BSbR TaPQDQ11IuM6p7GDYkhEZA11Kvzm8hIxQY8QnOf4I6fgjfrK7y2UoiZeoSgLysDnfWBu9P ejeFpWf8rD6GXBFMGxjwrso/mZkOI6G7iW3CGXmBM5NVkDSCN57Nm+sUiX0llsrWEvTZnj J7Yag6Kkr/4d9mOexb6XK2VwoUJVDETABfMrYvvdko+k9yD/fUqrbfrV/tJ8jH9+oDQw09 sULSZ83wiDZw6cqVYf0VbRthELjgnllO19PoEEIBZc5jWliUY3MxTpkvuY0mSg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733862468; a=rsa-sha256; cv=none; b=c1ntL4zvTWaugpXwSq885vYwPoM25SyoYTrVQGJpO/RndVjEsc5VKL7NZV1n3Z9REBCYq9 rVcTZwMhsZ/FLGPcWuVPrARo90qK8nUuCyIzp3DkY5kBRylwxqM3GjomJGBk3zc+w0RDhG TXdbPy11iGUX0tqGZYDh79OCMd+Zdv2BeNLspodW0hZfvo6SAA+QU7Y1EGAWYeeYqRRRqi 8fPzWE+jrTyMYLVT2/7HhtVN+zDMDH0VEzxP32vNhcV7o3jskm4VGJB9ADPiKa3E+O+sTM Nxe8SyxoW67qJEYAcOmfoMPMafOoTR+X0NRoFN/aNRwoAmUR9as0n+toO9k3TA== 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 4Y79K01wD5zdjV; Tue, 10 Dec 2024 20:27:48 +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 4BAKRmBY066555; Tue, 10 Dec 2024 20:27:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BAKRm9H066552; Tue, 10 Dec 2024 20:27:48 GMT (envelope-from git) Date: Tue, 10 Dec 2024 20:27:48 GMT Message-Id: <202412102027.4BAKRm9H066552@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Juraj Lutter Subject: git: 15a8e7d51c15 - main - isp(4): Correct nomenclature for L_Port 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: otis X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 15a8e7d51c156cba47742d7be1be52a327867955 Auto-Submitted: auto-generated The branch main has been updated by otis: URL: https://cgit.FreeBSD.org/src/commit/?id=15a8e7d51c156cba47742d7be1be52a327867955 commit 15a8e7d51c156cba47742d7be1be52a327867955 Author: Juraj Lutter AuthorDate: 2024-12-10 09:31:43 +0000 Commit: Juraj Lutter CommitDate: 2024-12-10 20:27:18 +0000 isp(4): Correct nomenclature for L_Port L_Port is "Arbitrated loop" port type, not "Loopback", correct this in the manual page. Reviewed by: mav Approved by: mav Differential Revision: https://reviews.freebsd.org/D48014 --- share/man/man4/isp.4 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/share/man/man4/isp.4 b/share/man/man4/isp.4 index dc6a6dbd5d2b..17c83a2e46d9 100644 --- a/share/man/man4/isp.4 +++ b/share/man/man4/isp.4 @@ -24,7 +24,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd June 24, 2024 +.Dd December 10, 2024 .Dt ISP 4 .Os .Sh NAME @@ -167,11 +167,11 @@ Supported values are: .Pp .Bl -tag -width ".Li lport-only" -compact .It Li lport -Prefer loopback and fallback to point to point. +Prefer arbitrated loop and fallback to point to point. .It Li nport -Prefer point to point and fallback to loopback. +Prefer point to point and fallback to arbitrated loop. .It Li lport-only -Loopback only. +Arbitrated loop only. .It Li nport-only Point to point only. .El From nobody Tue Dec 10 20:34:51 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 4Y79T76HkGz5gbLY; Tue, 10 Dec 2024 20:34:51 +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 4Y79T75kGRz4Rgq; Tue, 10 Dec 2024 20:34:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733862891; 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=8h2fZN/7uo+475vwLIJfx16Hnw4mvbw9PUQfxl68244=; b=UjTpYufiE6kCQRcmeovfoAORjoPSII84llRhQn+0qn2G9lsw6+NeKdizY8145k+4gFSQIk oAZEqvDbbj8HS6VahOZaF+Cl4AsEi5Q8ymzDJNfpGTIR2hBkXBb7IoXMpGZJ4/EpAC8UWp S2sT8WzCwa3VOOvZsWti5hliX0NheOYNz6oBpRwrujtzH8U/fkmtUlAgvjUaBzKV2TNHZA vW14HBMsn7Ov3ZpwCCNpqah5HQbNRqNuw+VrHOZXdsZ2rFd+3FlP0DqD2962Khi56RWIgm tnjJbNuEkxPpmQaekX2iWkSnTExd/X8FkG9gXNcG8rrdKJHcgfPIJTzeWHxcPA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733862891; 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=8h2fZN/7uo+475vwLIJfx16Hnw4mvbw9PUQfxl68244=; b=cOUxcqSDmBaDvSI55jvwy3b22ktzxLdMP9X6BWqFzvYdSuDw0xrgwXjCTXQsg0DPAVqrsQ DVX5j4FskdfpMIXghZvVajVivvUjX1+9e9VD0YOUqqd9OMC3KafTf6lqdzDJIYbNd7ldth ECkZtITFsAj39wRfylzwPmhOhETBVftYGPR5/MM8at6xV6mQqtTkKcriqTVY0ZJIJjx7S2 tdB/a7auCO/Fq409k2BDpDJv77dCVaa4sD5T02Y1LnjP3vn4I/LAHXoWSLFHgidD1E5YRL iC75j6qjN8T1pV/YWkGUyn5wTUyVILGKhCsMYKZxgy3hkDGbLYN6+BsKebAJGw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733862891; a=rsa-sha256; cv=none; b=dOxOfygOcFIVS7J+dpmAGdqQ1ZdEBF5XsnrSHH9NWBoaQryPh/TrGMbuUHhDtuTyHptoSo 09mk403osRJfyGImDDl61mLSWks4hA2CYzkxOY1/EKcFHZETffaqf140j6cmt+hmTtuyqx HoVQ5TjvRj/VJy6cbvxADk3aen8uIBLWEAaF1LjCpD6heFCGlqg/ymZChVJqytMRnc5bdP wtHFZNGMfAPJPezlfhN2GuhoXj7zLoh8J2UhttQrnkYFl6j0yfqWG3f4Ot8RY0xbDW++fg izXw1bHq6TN4T6R+cyLrtKSEHnxeE9MZkprsuf/c+ld2PeaY7AO2e2b3Bj6SUg== 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 4Y79T75GT7zdTQ; Tue, 10 Dec 2024 20:34:51 +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 4BAKYp7K083983; Tue, 10 Dec 2024 20:34:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BAKYple083980; Tue, 10 Dec 2024 20:34:51 GMT (envelope-from git) Date: Tue, 10 Dec 2024 20:34:51 GMT Message-Id: <202412102034.4BAKYple083980@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 8b1788118a1a - main - cxgbe tom: Enable TLS offload support by default 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: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8b1788118a1af586ed056a00b32a287c41095e7a Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=8b1788118a1af586ed056a00b32a287c41095e7a commit 8b1788118a1af586ed056a00b32a287c41095e7a Author: John Baldwin AuthorDate: 2024-12-10 20:30:11 +0000 Commit: John Baldwin CommitDate: 2024-12-10 20:31:07 +0000 cxgbe tom: Enable TLS offload support by default Reviewed by: np Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D47764 --- sys/dev/cxgbe/t4_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index cb7f091f93ca..8c7d1ad4487a 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -7786,7 +7786,7 @@ t4_sysctls(struct adapter *sc) SYSCTL_ADD_INT(ctx, children, OID_AUTO, "rx_coalesce", CTLFLAG_RW, &sc->tt.rx_coalesce, 0, "receive coalescing"); - sc->tt.tls = 0; + sc->tt.tls = 1; SYSCTL_ADD_PROC(ctx, children, OID_AUTO, "tls", CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_MPSAFE, sc, 0, sysctl_tls, "I", "Inline TLS allowed"); From nobody Tue Dec 10 20:34:52 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 4Y79T90fwvz5gZjX; Tue, 10 Dec 2024 20:34:53 +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 4Y79T9086rz4RkB; Tue, 10 Dec 2024 20:34:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733862893; 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=V3ZjtYZX6pk8Y2eAtiWgXTv2DWvCl5WXNSgoMj+dD2o=; b=hS+UfNeGGZK/Qyf4hZhjl3AcuX6nMJDgNYl9DVrvrw+96pSWZe10PqNA4eYY9JOFmfR4Cw DNy/PLEFJzkYhmpobYYqrCtbfTDH62ixB7fFqkZzdAEbwCw8c3MgzrXYklzQorolxXOUb+ oE8+MCRnBy7F4JY24s2jkRLN6+nerKWNJ2YV4yPvSAtex7vCLf5TA5AYjAieMcA0KajDGb V6QmiY2EreC0Zi64THt9gTet07u2NsxPPHy5XdzIzmVB96GERwr3rSbv/5q3q0YUTkEvvY FC59DygsuBc8o5MXmK36BIuTEK/kG4kZmPUw6wXv0VbBFNKarIETTPVO2IzgUw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733862893; 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=V3ZjtYZX6pk8Y2eAtiWgXTv2DWvCl5WXNSgoMj+dD2o=; b=KtLKbBO/ACGe0bNY6c513Cek3En6BA/eJ5VQARnfVcv7Ux6mbuIB6rQbUv90xoCT7bpoEn D7Ll1sNwSwyEdn8K3kO39RmRMxDBoB90bnblVlr4gp6Ju6pTeN1jz3U08atPF8bcGnfJXS 4gheCybETFTRLJzLynK1jMeu7x74xLaA9SL5HJ5yfCtTlRRWV51IhULucEJ4QFJlqBGnNQ COpYrSdG+JkZVQ0jFCLLYDbmW4MxwxlN66CHraeIytzMSHR6eA1oRRN6PBPy+pLTe/x0D2 9/8icmXmMD7sC7AYBO0wuih7iUUDtMP8vLmG0Szgu4Sq2whuTfCByQhglkQz8Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733862893; a=rsa-sha256; cv=none; b=SasRkHxnvuUtPF4+uYrpi0z44Q/GbZnsEYg0tjK5ze2ACdcKPTkL8u4Q0MsH1RBzWjcnNf mJetps+/lejZ1+93WyoRYnOkuK0jnKLtKdRx92NUK4qYHMlI1uQj5ob0cWJj2cbLYOBMqD WRfqRTZB9gPm+APg5/lbHhVTF4BQVAisxqnWHiHvvdMKHvYvl1xTRXgn+FeE62CpRMYEJ8 EeYN+0DVLOL4Sv/sRsS+T5TcY6eyWSGmVsG25k/OrHM4UvMPermlzdB9FMkg+fVj7YPBW4 lv4x1Qns9ocjqYPw0EDhZoUAVGKaZ0RR5Z86twCSHzzZWsg2ZsdX/VPlGSZ69g== 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 4Y79T85zDJzd3V; Tue, 10 Dec 2024 20:34:52 +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 4BAKYqDe084054; Tue, 10 Dec 2024 20:34:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BAKYquO084050; Tue, 10 Dec 2024 20:34:52 GMT (envelope-from git) Date: Tue, 10 Dec 2024 20:34:52 GMT Message-Id: <202412102034.4BAKYquO084050@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 906521882324 - main - cxgbe: Tidy TOE tunables under hw.cxgbe 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: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 90652188232458891a2922fb5a542971aa58055d Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=90652188232458891a2922fb5a542971aa58055d commit 90652188232458891a2922fb5a542971aa58055d Author: John Baldwin AuthorDate: 2024-12-10 20:30:30 +0000 Commit: John Baldwin CommitDate: 2024-12-10 20:32:07 +0000 cxgbe: Tidy TOE tunables under hw.cxgbe - Only two of these tunables are used for RATELIMIT without TCP_OFFLOAD. - Mark t4_tmr_idx_ofld and t4_pktc_idx_ofld static. - Move hw.cxgbe.cop_managed_offloading under hw.cxgbe.toe since it is specific to TOE. Reviewed by: np Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D47765 --- sys/dev/cxgbe/t4_main.c | 19 +++++++++++-------- usr.sbin/cxgbetool/cxgbetool.8 | 4 ++-- 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/sys/dev/cxgbe/t4_main.c b/sys/dev/cxgbe/t4_main.c index 8c7d1ad4487a..25d5dee8b781 100644 --- a/sys/dev/cxgbe/t4_main.c +++ b/sys/dev/cxgbe/t4_main.c @@ -318,15 +318,17 @@ static int t4_nofldtxq = -NOFLDTXQ; SYSCTL_INT(_hw_cxgbe, OID_AUTO, nofldtxq, CTLFLAG_RDTUN, &t4_nofldtxq, 0, "Number of offload TX queues per port"); -#define NOFLDRXQ 2 -static int t4_nofldrxq = -NOFLDRXQ; -SYSCTL_INT(_hw_cxgbe, OID_AUTO, nofldrxq, CTLFLAG_RDTUN, &t4_nofldrxq, 0, - "Number of offload RX queues per port"); - #define NOFLDTXQ_VI 1 static int t4_nofldtxq_vi = -NOFLDTXQ_VI; SYSCTL_INT(_hw_cxgbe, OID_AUTO, nofldtxq_vi, CTLFLAG_RDTUN, &t4_nofldtxq_vi, 0, "Number of offload TX queues per VI"); +#endif + +#if defined(TCP_OFFLOAD) +#define NOFLDRXQ 2 +static int t4_nofldrxq = -NOFLDRXQ; +SYSCTL_INT(_hw_cxgbe, OID_AUTO, nofldrxq, CTLFLAG_RDTUN, &t4_nofldrxq, 0, + "Number of offload RX queues per port"); #define NOFLDRXQ_VI 1 static int t4_nofldrxq_vi = -NOFLDRXQ_VI; @@ -334,12 +336,12 @@ SYSCTL_INT(_hw_cxgbe, OID_AUTO, nofldrxq_vi, CTLFLAG_RDTUN, &t4_nofldrxq_vi, 0, "Number of offload RX queues per VI"); #define TMR_IDX_OFLD 1 -int t4_tmr_idx_ofld = TMR_IDX_OFLD; +static int t4_tmr_idx_ofld = TMR_IDX_OFLD; SYSCTL_INT(_hw_cxgbe, OID_AUTO, holdoff_timer_idx_ofld, CTLFLAG_RDTUN, &t4_tmr_idx_ofld, 0, "Holdoff timer index for offload queues"); #define PKTC_IDX_OFLD (-1) -int t4_pktc_idx_ofld = PKTC_IDX_OFLD; +static int t4_pktc_idx_ofld = PKTC_IDX_OFLD; SYSCTL_INT(_hw_cxgbe, OID_AUTO, holdoff_pktc_idx_ofld, CTLFLAG_RDTUN, &t4_pktc_idx_ofld, 0, "holdoff packet counter index for offload queues"); @@ -686,9 +688,10 @@ SYSCTL_INT(_hw_cxgbe, OID_AUTO, drop_pkts_with_l4_errors, CTLFLAG_RDTUN, * TOE tunables. */ static int t4_cop_managed_offloading = 0; -SYSCTL_INT(_hw_cxgbe, OID_AUTO, cop_managed_offloading, CTLFLAG_RDTUN, +SYSCTL_INT(_hw_cxgbe_toe, OID_AUTO, cop_managed_offloading, CTLFLAG_RDTUN, &t4_cop_managed_offloading, 0, "COP (Connection Offload Policy) controls all TOE offload"); +TUNABLE_INT("hw.cxgbe.cop_managed_offloading", &t4_cop_managed_offloading); #endif #ifdef KERN_TLS diff --git a/usr.sbin/cxgbetool/cxgbetool.8 b/usr.sbin/cxgbetool/cxgbetool.8 index a25a227669ed..995a4146deb3 100644 --- a/usr.sbin/cxgbetool/cxgbetool.8 +++ b/usr.sbin/cxgbetool/cxgbetool.8 @@ -29,7 +29,7 @@ .\" .\" * Other names and brands may be claimed as the property of others. .\" -.Dd April 14, 2022 +.Dd December 10, 2024 .Dt CXGBETOOL 8 .Os .Sh NAME @@ -553,7 +553,7 @@ Install the Connection Offload Policy (COP) in A COP offers fine-grained control over which connections get offloaded and with what parameters. Set -.Cm hw.cxgbe.cop_managed_offloading="1" +.Cm hw.cxgbe.toe.cop_managed_offloading="1" in loader.conf to ensure that t4_tom will not offload any connection before a COP is installed. Note that t4_tom must be loaded and operational (IFCAP_TOE enabled) as always From nobody Tue Dec 10 20:34:53 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 4Y79TB25t0z5gb5j; Tue, 10 Dec 2024 20: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 "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Y79TB0HRRz4RpJ; Tue, 10 Dec 2024 20: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=1733862894; 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=00s69XaFLbXJFH7FQ7sqy2gN2pPTrXKYdqFqEm10L2E=; b=X3WvdttOIM/YrEuJcw9cRV7MxZVUqo7KvKwenoru3QUM1EjCjtEasoeUOaDzPyjrEN4H9A pHWB4B+E5089EV+GUUojP8HM2Ny6OkdkfdFcHZII1BEDu784x01bNyxdYZO7ho9dxNGTA2 MS6SujQ6Jmj2sL0AzEgE4a09l4u4lm1eUQE2ZlGp1ghaVWtdt/JNI5SyibM8IwOXGIWBF3 UdwQg9qArjakU/z3IE5KC8nACHRebfAHAmq2/BXX5YeLgQn5U0di9MpwzGaquTNU1uhXto gsT2rBlCwUlhPIGhnnuTJHcdEfD5HdSAk20SOJjzIPt9XRvsJpQoUE/kZ1WtEA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733862894; 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=00s69XaFLbXJFH7FQ7sqy2gN2pPTrXKYdqFqEm10L2E=; b=sakUpJPg5VawKF7Mq8byvX0DQ1yXjKmH/1A1L2LVtedwwjfTz4RGAkQjSiyq4DYqtZAcPC RIjJIrXyDqipPAvuBMOa1KqMs7aO/VE4AXd0WeqZpA6jJEQbpKFCh/RTk3JhgfY8SIJQcx JiElBhl0rdF6XXwMu3UJOsOniQtTUsbs915hV5KxUMzn5Gd0PfGL7fy9Z+UdmU4qOeSSx1 P/B2Enyg/6qt5bDxWNj7eII+uIaJ6EmvQoNpWd0tOHNOBr+xRqu3j6TJjXOYROxHbMbVwP Rzese40pl2gnScPEAYHvJaX68YKfcthjXwmo/dcXRlCRI79b+j2LJppjF5PyzQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733862894; a=rsa-sha256; cv=none; b=Xvf+zNMPoHS7bmzd6EG8/02zFqMtu5ZGKpgxrQdNs7KN650EQI7DLSJZU742+FK5HRpEzR gHVt+Dj19z7rTWHyFISapdKv0RF8R8pl3qJIux6YNNVq66uOQYkK64KuvwgQal+Dg0ZEIH ibsU/LqFsmDbnLJynuwu617pIB/2X/20RNB/k1Io0+NPj+gwauqTRBRhKE2rwxwOO4HqKi mfzq+rByhbro3DruekfNNUwpnFZtxFZwVnz9yN6yYPYgw6yV+MfM9MMr926rg8UyxX6xJs o2mn9N3o/jrp+rhIinFB2Nhn+wObE6wIwdg1jF7VWeN9yY0X3bNKVjtimx1kfQ== 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 4Y79T96qC7zf63; Tue, 10 Dec 2024 20:34:53 +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 4BAKYrvf084141; Tue, 10 Dec 2024 20:34:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BAKYrqP084137; Tue, 10 Dec 2024 20:34:53 GMT (envelope-from git) Date: Tue, 10 Dec 2024 20:34:53 GMT Message-Id: <202412102034.4BAKYrqP084137@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 34fbc9e421e7 - main - cxgbetool.8: Consistently use .Cm for loader tunables 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: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 34fbc9e421e7fbb382a644d8d289311455681734 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=34fbc9e421e7fbb382a644d8d289311455681734 commit 34fbc9e421e7fbb382a644d8d289311455681734 Author: John Baldwin AuthorDate: 2024-12-10 20:34:10 +0000 Commit: John Baldwin CommitDate: 2024-12-10 20:34:10 +0000 cxgbetool.8: Consistently use .Cm for loader tunables Sponsored by: Chelsio Communications --- usr.sbin/cxgbetool/cxgbetool.8 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/usr.sbin/cxgbetool/cxgbetool.8 b/usr.sbin/cxgbetool/cxgbetool.8 index 995a4146deb3..a5f345c6b781 100644 --- a/usr.sbin/cxgbetool/cxgbetool.8 +++ b/usr.sbin/cxgbetool/cxgbetool.8 @@ -531,7 +531,9 @@ List all filters programmed into the hardware. Install the firmware configuration file contained in .Ar fw-config.txt to the card. -Set hw.cxgbe.config_file="flash" in loader.conf to get +Set +.Cm hw.cxgbe.config_file="flash" +in loader.conf to get .Xr cxgbe 4 to use the on-flash configuration. .It Cm loadcfg Cm clear From nobody Tue Dec 10 20:48:30 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 4Y79mv27pLz5gbn4; Tue, 10 Dec 2024 20:48:31 +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 4Y79mv1hfpz4VXX; Tue, 10 Dec 2024 20:48:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733863711; 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=Sk5dtdP3A4yRBN+AmVJN9itGZhRxG8cdn4lnXwX1qrU=; b=ptP7SMcGa/fq4VHQFhLeSgb71kpl+Zx7qD3pOq/rdvN8LjMBz4be+Wwqs16SCSkyCSYdVC iZgZyt34317/iM8jG8E16pA68eM4W8q5WuhfPI9D8DuTQg208nPvilE0oxP25jxVzP4e21 p2apsDVoNbUP3qiL98pCIQawak0tSplbL8824/2+SgdwpuJ26hsQRVKJQo8Os7HbUK2N5w TB/7o68see++ndGlyqX99aF24iz34nsaXGm1BHuwpLI4OzQM68Vj00qGrAVQh6+5+4KPFK lP5l3JwB6wSF+GM/UrxILKzIVLSS7mJezDwwrO+E+0rr8ixdI3z0+2SVVrrjyg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733863711; 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=Sk5dtdP3A4yRBN+AmVJN9itGZhRxG8cdn4lnXwX1qrU=; b=dTsg73shivjLFAC5jKQUgDtu5YcGnUvmnFYd0GCCS9zhELcMukeI3HZr06jbqVvk04xGqj H2Bdi2xM5sPvHBCnngPo8DQihVv9MNO8/kMq6zEDZ/fHYhZv0tW2ssxm6KvV5VT2dOGHzC YWCaX/N1E1W+lc4Nvg2Zq8uQQBOnHXpu7Z+e6m4PLTwTv2jGHA6oFLpSyzeVn/SllcSL9Q IIQMvPZ83f7oH9lTwPM+VehSh8eJiMQpfteS88HIeeIeSukKN1F+PyAy2zwmel368Lrgp1 nkdDf/KI2So5cbk1yKauuIY4gmDswm8+pdjyVR02A9EIDvqG0d7mWgJZ8FOGVg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733863711; a=rsa-sha256; cv=none; b=uHbyhR0yW+bZNy8aLB6NMN9v8NNpIQli0FXKdIsDPFxj/0xlEfDgWb7lvbhFVG7oKYBQDd k/e5K+dCm4PBHwHafehXA3sK06Gn62A4wuewMNHhvUuslVnoyrr8mo1c14K4aSMr/lYaOZ EB5Fg0wQjP2XGAIofrB3sjQg0/lAKt8fdlvqtrM4dRVXfQRzbuhqWYsZdwUlnKE6L7q9Tc 8cwRg+Ze12OsBSC2lvNL/R7WxmvfQvjMXvkM3ofvxgj1aZRLGl0sZXcHplSHpyrjbUGICi 5xX+fvzitfOrOGL5YQ6kjTx/2Exj7XeRhYyfyCe8r5eaxHmxkOoZfUxaEu1KiQ== 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 4Y79mv0v8vzdvp; Tue, 10 Dec 2024 20:48:31 +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 4BAKmUBF005056; Tue, 10 Dec 2024 20:48:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BAKmU7Z005053; Tue, 10 Dec 2024 20:48:30 GMT (envelope-from git) Date: Tue, 10 Dec 2024 20:48:30 GMT Message-Id: <202412102048.4BAKmU7Z005053@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Colin Percival Subject: git: 35623ccc3758 - main - release: Standardize on *-${FS}.* VM image naming 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: cperciva X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 35623ccc375846648f4dcdfc47c7e84fc9db4852 Auto-Submitted: auto-generated The branch main has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=35623ccc375846648f4dcdfc47c7e84fc9db4852 commit 35623ccc375846648f4dcdfc47c7e84fc9db4852 Author: Colin Percival AuthorDate: 2024-12-10 19:57:52 +0000 Commit: Colin Percival CommitDate: 2024-12-10 20:48:17 +0000 release: Standardize on *-${FS}.* VM image naming We publish three sets of VM images on download.freebsd.org: * Generic VM images * BASIC-CLOUDINIT VM images * BASIC-CI VM images Of these, the first had names like FreeBSD-14.2-RELEASE-amd64-ufs.raw.xz, the second had names like FreeBSD-14.2-RELEASE-amd64-BASIC-CLOUDINIT.ufs.qcow2.xz, and the third had names like FreeBSD-14.2-RELEASE-amd64-BASIC-CI.ufs.raw.xz but were listed in the CHECKSUM files with names like FreeBSD-14.2-RELEASE-amd64-BASIC-CI-ufs.raw.xz Standardize these to consistently use a hyphen before the filesystem type rather than a period. Note: On FreeBSD 14 we ship images without the -${FS} component in their names; these are hardlinks to the -ufs images for compatibility purposes. On FreeBSD 13 we only have UFS images and don't include the filesystem in the name. MFC after: 1 week Reported by: jmg Sponsored by: Amazon --- release/Makefile.mirrors | 28 ++++++++++++++-------------- release/Makefile.vm | 4 ++-- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/release/Makefile.mirrors b/release/Makefile.mirrors index 7f7c34e21077..5e65bfbe8b3f 100644 --- a/release/Makefile.mirrors +++ b/release/Makefile.mirrors @@ -212,13 +212,13 @@ vm-images-stage: . for VMFORMAT in ${${CW}_FORMAT} . for FS in ${${CW}_FSLIST} cd ${RELEASEDIR}/vmimages && \ - mv ${OSRELEASE}-${CW}.${FS}.${VMFORMAT}.xz \ - ${OSRELEASE}-${CW}-${SNAP_SUFFIX}.${FS}.${VMFORMAT}.xz - cp -p ${RELEASEDIR}/vmimages/${OSRELEASE}-${CW}-${SNAP_SUFFIX}.${FS}.${VMFORMAT}.xz \ - ${VM_DIR}/${BUILDDATE}/${OSRELEASE}-${CW}-${SNAP_SUFFIX}.${FS}.${VMFORMAT}.xz + mv ${OSRELEASE}-${CW}-${FS}.${VMFORMAT}.xz \ + ${OSRELEASE}-${CW}-${SNAP_SUFFIX}-${FS}.${VMFORMAT}.xz + cp -p ${RELEASEDIR}/vmimages/${OSRELEASE}-${CW}-${SNAP_SUFFIX}-${FS}.${VMFORMAT}.xz \ + ${VM_DIR}/${BUILDDATE}/${OSRELEASE}-${CW}-${SNAP_SUFFIX}-${FS}.${VMFORMAT}.xz cd ${VM_DIR}/Latest && \ - ln -s ../${BUILDDATE}/${OSRELEASE}-${CW}-${SNAP_SUFFIX}.${FS}.${VMFORMAT}.xz \ - ${OSRELEASE}-${CW}.${FS}.${VMFORMAT}.xz + ln -s ../${BUILDDATE}/${OSRELEASE}-${CW}-${SNAP_SUFFIX}-${FS}.${VMFORMAT}.xz \ + ${OSRELEASE}-${CW}-${FS}.${VMFORMAT}.xz . endfor . endfor . endif @@ -250,8 +250,8 @@ vm-images-stage: . if ${CW} == BASIC-CLOUDINIT . for VMFORMAT in ${${CW}_FORMAT} . for FS in ${${CW}_FSLIST} - cp -p ${RELEASEDIR}/vmimages/${OSRELEASE}-${CW}.${FS}.${VMFORMAT}.xz \ - ${VM_DIR}/Latest/${OSRELEASE}-${CW}.${FS}.${VMFORMAT}.xz + cp -p ${RELEASEDIR}/vmimages/${OSRELEASE}-${CW}-${FS}.${VMFORMAT}.xz \ + ${VM_DIR}/Latest/${OSRELEASE}-${CW}-${FS}.${VMFORMAT}.xz . endfor . endfor . endif @@ -277,12 +277,12 @@ ci-images-stage: . for FS in ${${CW}_FSLIST} cd ${RELEASEDIR}/ciimages && \ mv ${OSRELEASE}-${CW}-${FS}.${VMFORMAT}.xz \ - ${OSRELEASE}-${CW}-${SNAP_SUFFIX}.${FS}.${VMFORMAT}.xz - cp -p ${RELEASEDIR}/ciimages/${OSRELEASE}-${CW}-${SNAP_SUFFIX}.${FS}.${VMFORMAT}.xz \ - ${CI_DIR}/${BUILDDATE}/${OSRELEASE}-${CW}-${SNAP_SUFFIX}.${FS}.${VMFORMAT}.xz + ${OSRELEASE}-${CW}-${SNAP_SUFFIX}-${FS}.${VMFORMAT}.xz + cp -p ${RELEASEDIR}/ciimages/${OSRELEASE}-${CW}-${SNAP_SUFFIX}-${FS}.${VMFORMAT}.xz \ + ${CI_DIR}/${BUILDDATE}/${OSRELEASE}-${CW}-${SNAP_SUFFIX}-${FS}.${VMFORMAT}.xz cd ${CI_DIR}/Latest && \ - ln -s ../${BUILDDATE}/${OSRELEASE}-${CW}-${SNAP_SUFFIX}.${FS}.${VMFORMAT}.xz \ - ${OSRELEASE}-${CW}.${FS}.${VMFORMAT}.xz + ln -s ../${BUILDDATE}/${OSRELEASE}-${CW}-${SNAP_SUFFIX}-${FS}.${VMFORMAT}.xz \ + ${OSRELEASE}-${CW}-${FS}.${VMFORMAT}.xz . endfor . endfor . endif @@ -307,7 +307,7 @@ ci-images-stage: . for VMFORMAT in ${${CW}_FORMAT} . for FS in ${${CW}_FSLIST} cp -p ${RELEASEDIR}/ciimages/${OSRELEASE}-${CW}-${FS}.${VMFORMAT}.xz \ - ${CI_DIR}/Latest/${OSRELEASE}-${CW}.${FS}.${VMFORMAT}.xz + ${CI_DIR}/Latest/${OSRELEASE}-${CW}-${FS}.${VMFORMAT}.xz . endfor . endfor . endif diff --git a/release/Makefile.vm b/release/Makefile.vm index 5ae603b05983..5aa506ff6787 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -239,8 +239,8 @@ cloud-install-BASIC-CLOUDINIT: .for _FS in ${BASIC-CLOUDINIT_FSLIST} . for _FMT in ${BASIC-CLOUDINIT_FORMAT} cp -p ${.OBJDIR}/${BASIC-CLOUDINIT${_FS:tu}${_FMT:tu}IMAGE} \ - ${DESTDIR}/vmimages/${OSRELEASE}-BASIC-CLOUDINIT.${_FS}.${_FMT} - ${XZ_CMD} ${DESTDIR}/vmimages/${OSRELEASE}-BASIC-CLOUDINIT.${_FS}.${_FMT} + ${DESTDIR}/vmimages/${OSRELEASE}-BASIC-CLOUDINIT-${_FS}.${_FMT} + ${XZ_CMD} ${DESTDIR}/vmimages/${OSRELEASE}-BASIC-CLOUDINIT-${_FS}.${_FMT} . endfor .endfor cd ${DESTDIR}/vmimages && sha512 ${OSRELEASE}* > \ From nobody Tue Dec 10 21:21:56 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 4Y7BWS4bkQz5gdmR; Tue, 10 Dec 2024 21:21:56 +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 4Y7BWS430lz4Y5T; Tue, 10 Dec 2024 21:21:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733865716; 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=xRyWo5WV9eu6THFbbKHV/RrCRorcZEIQnS6ImMswOTs=; b=uVPTSG9BUgAzmMCuV+ljnfKemY0asPYvalmsDxxKl2jgkETQXwBDwxjMVkobRWRKampMrU jd9PW1T0kchZnYdgFWFymPhg1aukfU6pdpexQqA3At+4bbyY8MmhwmxbNS99Yf2zQAnojd g79HPTleO2UmZBiYhs2yox59OmURmdcV33UQpsUIUB7mHooSAefOSrItRXmLIDeZfk5UGQ LZCgKdF3DwderzHt24VxJqGJi8IXOqGrYRh1mC4BxlJuC5SAnXlKYRlNSQzq3mOMK/qfCv PqVqnqPSrgj67/1iT7oZLfcyd6WGnjNDWBGAUtJyppEh0vckigDOTSd8ZL7LkA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733865716; 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=xRyWo5WV9eu6THFbbKHV/RrCRorcZEIQnS6ImMswOTs=; b=A55Np0EUJC4mMO4tOhlVHJt3TrNCU7MT8PHepeGCDWSzXdHuS7x2yHS+mvr1MVHvtP0YAd r45kIDuQ51rwJpToKjUshhZAcHRHWkTuda0NC5uF4pxgD46rWz+F6NhzmRP6NG3nHiZi2g 57fKvOR9Alho/XGNyRZVXznailLxMjqlx6hzB5zwNWi4JrFWfRB8UQIlFBncPIiyu4JdQx btXKce39yT7ocAKRbMNo3ipu7PUjoHbZiP05dZ4t/AAO5HXbL02QTiF8xmr1o0eMhSKjyj 6H7nbxA0idQPaSlVX6tIIW1f4DRmEoOz2nFspsA0R5AyJUBYIDN1GSIXRBjIeg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733865716; a=rsa-sha256; cv=none; b=uk9lZlvHeS86Oj6/eKy9dWVTLtvz1wxlqQNwApHPkobTOZXXGcvodiVaFET2XEiFMOoXxc 8Mtzh31ElaeSmoNwdMN5Fj9phaBTypFCz/+zMtHoGNK5VQOQNuqD1D8oq+PWt25WSL/oXE agkZ2sPMDr+hhQgcbuIOXRR6Fm6lZVfDEEl58Ws2SNBgT6LVkEHAYAhqI3Q8ucLhCUtJ32 J10Ys+C4AS1USacd3M3167izgjMWaXakyZ6IF87IA/RA66SkiVqNXdkyPmcfbhiR+LTWOB bC5LTDxK0mRoXSaVkV3VnVYqzSJ2y3Lc431dFYShSRjZa6VVYmiVQWILV7lfyQ== 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 4Y7BWS3fnDzfGr; Tue, 10 Dec 2024 21:21:56 +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 4BALLuVv074551; Tue, 10 Dec 2024 21:21:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BALLuXK074548; Tue, 10 Dec 2024 21:21:56 GMT (envelope-from git) Date: Tue, 10 Dec 2024 21:21:56 GMT Message-Id: <202412102121.4BALLuXK074548@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Juraj Lutter Subject: git: f8f999c1ecf4 - main - Streamline synopsis for real-time clock (RTC) drivers 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: otis X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f8f999c1ecf4910fbf5a472bc4dd40eb3f8acfe9 Auto-Submitted: auto-generated The branch main has been updated by otis: URL: https://cgit.FreeBSD.org/src/commit/?id=f8f999c1ecf4910fbf5a472bc4dd40eb3f8acfe9 commit f8f999c1ecf4910fbf5a472bc4dd40eb3f8acfe9 Author: Juraj Lutter AuthorDate: 2024-12-10 19:11:24 +0000 Commit: Juraj Lutter CommitDate: 2024-12-10 21:18:37 +0000 Streamline synopsis for real-time clock (RTC) drivers To make it easier to find RTC drivers, include both "real-time clock" and "RTC" in their synopsis. Reviewed by: mhorne Approved by: mhorne Differential Revision: https://reviews.freebsd.org/D48021 --- share/man/man4/ds1307.4 | 4 ++-- share/man/man4/ds3231.4 | 4 ++-- share/man/man4/man4.arm/aw_rtc.4 | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/share/man/man4/ds1307.4 b/share/man/man4/ds1307.4 index ae8884934f09..46d22663e50c 100644 --- a/share/man/man4/ds1307.4 +++ b/share/man/man4/ds1307.4 @@ -22,12 +22,12 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd March 7, 2015 +.Dd December 10, 2024 .Dt DS1307 4 .Os .Sh NAME .Nm ds1307 -.Nd 64 x 8, serial, i2c real-time clock +.Nd 64 x 8, serial, i2c real-time clock (RTC) .Sh SYNOPSIS .Cd "device iic" .Cd "device iicbus" diff --git a/share/man/man4/ds3231.4 b/share/man/man4/ds3231.4 index 8734e82b4e69..52322eec6eb9 100644 --- a/share/man/man4/ds3231.4 +++ b/share/man/man4/ds3231.4 @@ -22,12 +22,12 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd February 12, 2016 +.Dd December 10, 2024 .Dt DS3231 4 .Os .Sh NAME .Nm ds3231 -.Nd Extremely Accurate i2c-integrated RTC/TCXO/Crystal +.Nd Extremely Accurate i2c-integrated real-time clock (RTC)/TCXO/Crystal .Sh SYNOPSIS .Cd "device iic" .Cd "device iicbus" diff --git a/share/man/man4/man4.arm/aw_rtc.4 b/share/man/man4/man4.arm/aw_rtc.4 index 5b656ec679e4..12e14dd52bee 100644 --- a/share/man/man4/man4.arm/aw_rtc.4 +++ b/share/man/man4/man4.arm/aw_rtc.4 @@ -22,12 +22,12 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd Dec 25, 2017 +.Dd December 10, 2024 .Dt AW_RTC 4 .Os .Sh NAME .Nm aw_rtc -.Nd driver for the RTC controller in Allwinner SoC +.Nd driver for the real-time clock (RTC) controller in Allwinner SoC .Sh DESCRIPTION The .Nm From nobody Tue Dec 10 21:31:15 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 4Y7BkD0zmdz5gf7f; Tue, 10 Dec 2024 21:31:16 +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 4Y7BkD0Rwdz4Z16; Tue, 10 Dec 2024 21:31:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733866276; 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=GeFTPdRdI59CaqYktVNLEzcTM27D9yb5FuDQsFtvVHs=; b=KIA84XE9a7b3DgiFaIwelAfhdlxHHxhBJTJfN1rH+6MTjyghzqEb1T0yxkCZIEDIwEt5mF 6NqwXVr/tiOHpN/Dh2Qx/vctGfkEK/reM+LKFn0Rl5Bz9777KS16GIGdykMMLi7ZICjxVa Vj9q90cK0dDaqq9rLWjRtH86NYXrzsbXpH8j/jLPtMDnAgB+LPlukUoSUWxugJWu+JdBM1 taVtI+BBTmt2TsJUfo8gi5dxzzftqRU6SeWYCtAMsm+79+S3v2HCmh5PtM00OttpvBONM9 aVIKyBGe5M7XXB2jRSS+Gj2A49AAIFcNPEVKUreNfa5A4Gafgu2nki7j6tp9Aw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733866276; 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=GeFTPdRdI59CaqYktVNLEzcTM27D9yb5FuDQsFtvVHs=; b=dZHcMQftpoPRHvSNYjGu0w/+eJ8rUDn4xBikXfZodU7mTZdjblr5ZjzUG13vBSWjHkPfiO ewy2XHdPnzcbM2dl2sV6H9Ry9NVsaDVEd/ew3ZpdMaH+PIP7XLZamv+ts4/jnCPQ3SgZxj 1EdZCa9JnhufYwdILyocXFjjkQgiaKYTM8pRuSTpNvgDlx/NG9rM4dUTpthioXcDuHwWOD XOx5uFzFyu85aNj5djTSrY3MBNp14JTYbxUqspeDItk1z9vEhJ1Eijpb8GPN+3zZMYvWW8 m3GKWClzQYAJpG3T5CosPpRnByw8zMBFdBVyhd+9SFzu/Mvyq9Z87dpb0J4gYw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733866276; a=rsa-sha256; cv=none; b=CI0HwDio9l/bg5EfkWO0UhtPUymO3WffkQxoXs55WVBDO91gPIJkH/1qPxESzwkqPNyScF mZ2Ph4dMrR09VJBCC+WAZ+VX4fYDobd3sM1+oJXDGuZcW/ZH/Sjc8aLIBJrZ+C0vM0vqnu yDcsTIciZIzM9GANiW6F8yjygmCWSvotXbY4hrG9UxgOn66cuJ1ibfKDFi2blmSi5YVhXk y1x0YFY4MkfMrqnTWSavY6WwgHfKqgPGBFhb0JtBvM/phOhH7gF0eMwnbkGzmvGGpNALTp HfhN++YSCDFT16mlqn4vlm7AvwIhBqF/Y8wm4tMWupA9GnH+fkGIa8gqHd5Azw== 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 4Y7BkD03jtzgQJ; Tue, 10 Dec 2024 21:31:16 +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 4BALVFet094309; Tue, 10 Dec 2024 21:31:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BALVFLp094306; Tue, 10 Dec 2024 21:31:15 GMT (envelope-from git) Date: Tue, 10 Dec 2024 21:31:15 GMT Message-Id: <202412102131.4BALVFLp094306@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mitchell Horne Subject: git: 85471971305d - main - riscv: enable Allwinner if_awg 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: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 85471971305d3c13ef5f2894b44cdf93b5e80f12 Auto-Submitted: auto-generated The branch main has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=85471971305d3c13ef5f2894b44cdf93b5e80f12 commit 85471971305d3c13ef5f2894b44cdf93b5e80f12 Author: Mitchell Horne AuthorDate: 2024-12-10 20:43:59 +0000 Commit: Mitchell Horne CommitDate: 2024-12-10 21:28:38 +0000 riscv: enable Allwinner if_awg Enable the driver and dependencies (aw_sid, nvmem). Add compat strings, etc. Found on the Allwinner D1. Reviewed by: manu Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D47923 --- share/man/man4/man4.arm/aw_sid.4 | 6 +++++- sys/arm/allwinner/aw_sid.c | 27 +++++++++++++++++++++++++++ sys/arm/allwinner/if_awg.c | 2 ++ sys/riscv/allwinner/files.allwinner | 2 ++ sys/riscv/conf/GENERIC | 1 + sys/riscv/conf/std.allwinner | 2 ++ 6 files changed, 39 insertions(+), 1 deletion(-) diff --git a/share/man/man4/man4.arm/aw_sid.4 b/share/man/man4/man4.arm/aw_sid.4 index be441033d242..5cd2f3d5e072 100644 --- a/share/man/man4/man4.arm/aw_sid.4 +++ b/share/man/man4/man4.arm/aw_sid.4 @@ -24,7 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd January 6, 2018 +.Dd October 8, 2024 .Dt AW_SID 4 .Os .Sh NAME @@ -53,6 +53,10 @@ allwinner,sun50i-a64-sid allwinner,sun8i-a83t-sid .It allwinner,sun8i-h3-sid +.It +allwinner,sun50i-h5-sid +.It +allwinner,sun20i-d1-sid .El .Sh SYSCTL VARIABLES The following read-only variables are available via diff --git a/sys/arm/allwinner/aw_sid.c b/sys/arm/allwinner/aw_sid.c index a333eadc20aa..ba5faca33c5e 100644 --- a/sys/arm/allwinner/aw_sid.c +++ b/sys/arm/allwinner/aw_sid.c @@ -169,6 +169,27 @@ static struct aw_sid_efuse h5_efuses[] = { }, }; +static struct aw_sid_efuse d1_efuses[] = { + { + .name = "rootkey", + .desc = "Root Key or ChipID", + .base = EFUSE_OFFSET, + .offset = 0x00, + .size = 16, + .id = AW_SID_FUSE_ROOTKEY, + .public = true, + }, + { + .name = "calibration", + .desc = "Thermal Sensor Calibration Data", + .base = EFUSE_OFFSET, + .offset = 0x34, + .size = 4, + .id = AW_SID_FUSE_THSSENSOR, + .public = true, + }, +}; + struct aw_sid_conf { struct aw_sid_efuse *efuses; size_t nfuses; @@ -204,6 +225,11 @@ static const struct aw_sid_conf h5_conf = { .nfuses = nitems(h5_efuses), }; +static const struct aw_sid_conf d1_conf = { + .efuses = d1_efuses, + .nfuses = nitems(d1_efuses), +}; + static struct ofw_compat_data compat_data[] = { { "allwinner,sun4i-a10-sid", (uintptr_t)&a10_conf}, { "allwinner,sun7i-a20-sid", (uintptr_t)&a20_conf}, @@ -211,6 +237,7 @@ static struct ofw_compat_data compat_data[] = { { "allwinner,sun8i-a83t-sid", (uintptr_t)&a83t_conf}, { "allwinner,sun8i-h3-sid", (uintptr_t)&h3_conf}, { "allwinner,sun50i-h5-sid", (uintptr_t)&h5_conf}, + { "allwinner,sun20i-d1-sid", (uintptr_t)&d1_conf}, { NULL, 0 } }; diff --git a/sys/arm/allwinner/if_awg.c b/sys/arm/allwinner/if_awg.c index 29a75e5a4d9b..98e879d22d3d 100644 --- a/sys/arm/allwinner/if_awg.c +++ b/sys/arm/allwinner/if_awg.c @@ -143,12 +143,14 @@ enum awg_type { EMAC_A83T = 1, EMAC_H3, EMAC_A64, + EMAC_D1, }; static struct ofw_compat_data compat_data[] = { { "allwinner,sun8i-a83t-emac", EMAC_A83T }, { "allwinner,sun8i-h3-emac", EMAC_H3 }, { "allwinner,sun50i-a64-emac", EMAC_A64 }, + { "allwinner,sun20i-d1-emac", EMAC_D1 }, { NULL, 0 } }; diff --git a/sys/riscv/allwinner/files.allwinner b/sys/riscv/allwinner/files.allwinner index e29300c627a1..f6be2cf97e57 100644 --- a/sys/riscv/allwinner/files.allwinner +++ b/sys/riscv/allwinner/files.allwinner @@ -1,7 +1,9 @@ arm/allwinner/aw_rtc.c optional aw_rtc fdt arm/allwinner/aw_syscon.c optional syscon +arm/allwinner/aw_sid.c optional aw_sid nvmem arm/allwinner/aw_wdog.c optional aw_wdog +arm/allwinner/if_awg.c optional awg syscon # Allwinner clock drivers dev/clk/allwinner/aw_ccung.c optional aw_ccu fdt diff --git a/sys/riscv/conf/GENERIC b/sys/riscv/conf/GENERIC index 4e01c39bc008..4fdb1bdd6403 100644 --- a/sys/riscv/conf/GENERIC +++ b/sys/riscv/conf/GENERIC @@ -83,6 +83,7 @@ device rcons # pseudo devices device clk device hwreset +device nvmem device phy device regulator device syscon diff --git a/sys/riscv/conf/std.allwinner b/sys/riscv/conf/std.allwinner index f04e88c98b5b..4f3d98250cc5 100644 --- a/sys/riscv/conf/std.allwinner +++ b/sys/riscv/conf/std.allwinner @@ -7,6 +7,8 @@ options SOC_ALLWINNER_D1 device aw_ccu # Allwinner clock controller device aw_rtc # Allwinner Real-time Clock +device aw_sid # Allwinner Secure ID EFUSE device aw_wdog # Allwinner Watchdog +device awg # Allwinner EMAC Gigabit Ethernet files "../allwinner/files.allwinner" From nobody Tue Dec 10 21:31:17 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 4Y7BkF1cxLz5gfGZ; Tue, 10 Dec 2024 21:31:17 +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 4Y7BkF1CSsz4Z5V; Tue, 10 Dec 2024 21:31:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733866277; 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=aVu8ZoJFC28Qw57RKvyWuwT78XkhipZugbrQPEWH72E=; b=BmZZyPkB3B6i/kpZi+K2d6bQNhbCHhg9ZNHwQ7AgabJN8SDk/upJh9zInt7DyQ7CI1Zc2O iMj5le89aAnclR66fvup7Ikw/mdqPkyMPu0ExThlWCM0HhIjUHNtJronDUmTgk9ZV2RlzJ lgBNiwrDyMrqIca+T1y1kfs44QlsRntYSlbbigG4uDgTws96LyAV8PKMF9GprOLHinRnkS ISFuH8cQ4BmrPD1fmyu2/IT3oj4O+39Ur0z/zh9O2CqSDgXKw4qqcz2X3/+Zkb2AxLj9FX pLIR2PIiCDaloW1TOq8EfxtvxQSBEtGDqSsBdXZQQl4XQ0F5uDKlM6BuSGGVMQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733866277; 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=aVu8ZoJFC28Qw57RKvyWuwT78XkhipZugbrQPEWH72E=; b=HkE8vyHSHsW78mgJ7YUVLNZa1GiBCnkFSlTkWdLfsN1RyHuEITXpN7Z6VnQahA5FpyQgEv Dk+bFlLel05yMsLBphFbDabM6q2f0siyX302ZjKwwzRiTZTsu7FHZPWpvOhPJuHlWycCUR Vr+ELs+YVIdUAw4awCaLWmLnm2SF+G0oOY4YzsFlilsP3nnhww2+WS5/KYY0Mu+Rrk6wwl Vt8YuN9cZK11Wfrg8Q95gGgpYs6DKlw0uzk5qLjbsvvmAGoJ6UCKSe0UxulvCMvQ2yuyzK jDmwoxM8/Hc0Cz2yQ76Sfv3ywJXesgOBGsOdBAp4+1ij3ePTbvYJQ9gg2Bqq0g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733866277; a=rsa-sha256; cv=none; b=AhURtDQZxZBFl/WJTMK8SqT9utv3VX5Xx0UqT4xFHcr4SsW4/03zsvKYC4eg7lON3w8//b /u8voqMIuw1MUO2X4Ba0t287xxBLMDhbjwxX7QkKyu9hMVgf9HR1w+0ZgAbEimURZC93m7 RudCfQoI0fFjeIMPwIx/t4UiOdYTRt0i4d/JTbn9dUoiR5vFg1gvcD3DSocUg2D6S96YSv fnfNq2LZ41rpTePO0mV11DHRD6/AkAgXEx/53SxLzh2gcF8BUF88D353/AX8Oy8xVLdx0E zQ/2RrGyCjMEjr081LuPRI2z0w9pam/W1NXn7uECdJhKLEfxuSXgE/1QoJ2PMA== 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 4Y7BkF0qFmzf9w; Tue, 10 Dec 2024 21:31:17 +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 4BALVHDA094351; Tue, 10 Dec 2024 21:31:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BALVHnd094348; Tue, 10 Dec 2024 21:31:17 GMT (envelope-from git) Date: Tue, 10 Dec 2024 21:31:17 GMT Message-Id: <202412102131.4BALVHnd094348@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mitchell Horne Subject: git: 719245455853 - main - aw_gpio: support Allwinner D1 GPIO 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: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7192454558532101229629a8575d161013f3a7cb Auto-Submitted: auto-generated The branch main has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=7192454558532101229629a8575d161013f3a7cb commit 7192454558532101229629a8575d161013f3a7cb Author: Julien Cassette AuthorDate: 2024-12-10 21:22:40 +0000 Commit: Mitchell Horne CommitDate: 2024-12-10 21:30:13 +0000 aw_gpio: support Allwinner D1 GPIO The GPIO controls the multiplexing of the D1 pins to its peripherals, so this adds the definitions needed by the aw_gpio driver to support the D1. Also, this modifies the aw_gpio driver to support the differences of the D1 controller: - pins can have up to 15 functions - each port is mapped with an alignment of 0x30 - CFG registers have 4 bits per pin - DRV registers have 4 bits per pin - the offset of PULL registers is 0x24 Signed-off-by: Julien Cassette Reviewed by: mhorne Differential Revision: https://reviews.freebsd.org/D35593 --- share/man/man4/man4.arm/aw_gpio.4 | 5 +- sys/arm/allwinner/allwinner_pinctrl.h | 4 +- sys/arm/allwinner/aw_gpio.c | 136 ++++++++++++++++++++++++++-------- sys/riscv/allwinner/d1_padconf.c | 129 ++++++++++++++++++++++++++++++++ sys/riscv/allwinner/files.allwinner | 3 + sys/riscv/conf/GENERIC | 1 + sys/riscv/conf/std.allwinner | 1 + 7 files changed, 247 insertions(+), 32 deletions(-) diff --git a/share/man/man4/man4.arm/aw_gpio.4 b/share/man/man4/man4.arm/aw_gpio.4 index 3d72e82b3efc..5cbc7562d9bd 100644 --- a/share/man/man4/man4.arm/aw_gpio.4 +++ b/share/man/man4/man4.arm/aw_gpio.4 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd Dec 25, 2017 +.Dd October 8, 2024 .Dt AW_GPIO 4 .Os .Sh NAME @@ -41,6 +41,7 @@ .Cd "options SOC_ALLWINNER_H3" .Cd "options SOC_ALLWINNER_A64" .Cd "options SOC_ALLWINNER_H5" +.Cd "options SOC_ALLWINNER_D1" .Sh DESCRIPTION The .Nm @@ -81,6 +82,8 @@ allwinner,sun8i-h3-r-pinctrl allwinner,sun50i-a64-pinctrl .It allwinner,sun50i-a64-r-pinctrl +.It +allwinner,sun20i-d1-pinctrl .El .Sh SEE ALSO .Xr fdt 4 , diff --git a/sys/arm/allwinner/allwinner_pinctrl.h b/sys/arm/allwinner/allwinner_pinctrl.h index 4eaa2d84146c..67fd13683a46 100644 --- a/sys/arm/allwinner/allwinner_pinctrl.h +++ b/sys/arm/allwinner/allwinner_pinctrl.h @@ -26,13 +26,13 @@ #ifndef _ALLWINNER_PINCTRL_H_ #define _ALLWINNER_PINCTRL_H_ -#define AW_MAX_FUNC_BY_PIN 8 +#define AW_MAX_FUNC_BY_PIN 15 struct allwinner_pins { const char *name; uint8_t port; uint8_t pin; - const char *functions[8]; + const char *functions[AW_MAX_FUNC_BY_PIN]; uint8_t eint_func; uint8_t eint_num; uint8_t eint_bank; diff --git a/sys/arm/allwinner/aw_gpio.c b/sys/arm/allwinner/aw_gpio.c index 6ff0516acb3f..b469a7fb453d 100644 --- a/sys/arm/allwinner/aw_gpio.c +++ b/sys/arm/allwinner/aw_gpio.c @@ -4,6 +4,7 @@ * Copyright (c) 2013 Ganbold Tsagaankhuu * Copyright (c) 2012 Oleksandr Tymoshenko * Copyright (c) 2012 Luiz Otavio O Souza. + * Copyright (c) 2022 Julien Cassette * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -56,7 +57,7 @@ #include #include -#if defined(__aarch64__) +#if defined(__aarch64__) || defined(__riscv) #include "opt_soc.h" #endif @@ -82,9 +83,18 @@ #define AW_PINCTRL 1 #define AW_R_PINCTRL 2 +#if defined(__arm__) || defined(__aarch64__) +#define IRQ_MEMORY_BARRIER(x) arm_irq_memory_barrier(x) +#else +#define IRQ_MEMORY_BARRIER(x) fence() +#endif + struct aw_gpio_conf { struct allwinner_padconf *padconf; const char *banks; + uint32_t bank_size; + uint32_t drv_pin_shift; + uint32_t pul_offset; }; /* Defined in aw_padconf.c */ @@ -93,6 +103,9 @@ extern struct allwinner_padconf a10_padconf; struct aw_gpio_conf a10_gpio_conf = { .padconf = &a10_padconf, .banks = "abcdefghi", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; #endif @@ -102,6 +115,9 @@ extern struct allwinner_padconf a13_padconf; struct aw_gpio_conf a13_gpio_conf = { .padconf = &a13_padconf, .banks = "bcdefg", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; #endif @@ -111,6 +127,9 @@ extern struct allwinner_padconf a20_padconf; struct aw_gpio_conf a20_gpio_conf = { .padconf = &a20_padconf, .banks = "abcdefghi", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; #endif @@ -120,6 +139,9 @@ extern struct allwinner_padconf a31_padconf; struct aw_gpio_conf a31_gpio_conf = { .padconf = &a31_padconf, .banks = "abcdefgh", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; #endif @@ -129,6 +151,9 @@ extern struct allwinner_padconf a31s_padconf; struct aw_gpio_conf a31s_gpio_conf = { .padconf = &a31s_padconf, .banks = "abcdefgh", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; #endif @@ -137,6 +162,9 @@ extern struct allwinner_padconf a31_r_padconf; struct aw_gpio_conf a31_r_gpio_conf = { .padconf = &a31_r_padconf, .banks = "lm", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; #endif @@ -146,6 +174,9 @@ extern struct allwinner_padconf a33_padconf; struct aw_gpio_conf a33_gpio_conf = { .padconf = &a33_padconf, .banks = "bcdefgh", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; #endif @@ -156,10 +187,16 @@ extern struct allwinner_padconf h3_r_padconf; struct aw_gpio_conf h3_gpio_conf = { .padconf = &h3_padconf, .banks = "acdefg", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; struct aw_gpio_conf h3_r_gpio_conf = { .padconf = &h3_r_padconf, .banks = "l", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; #endif @@ -170,10 +207,16 @@ extern struct allwinner_padconf a83t_r_padconf; struct aw_gpio_conf a83t_gpio_conf = { .padconf = &a83t_padconf, .banks = "bcdefgh" + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; struct aw_gpio_conf a83t_r_gpio_conf = { .padconf = &a83t_r_padconf, .banks = "l", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; #endif @@ -184,10 +227,28 @@ extern struct allwinner_padconf a64_r_padconf; struct aw_gpio_conf a64_gpio_conf = { .padconf = &a64_padconf, .banks = "bcdefgh", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; struct aw_gpio_conf a64_r_gpio_conf = { .padconf = &a64_r_padconf, .banks = "l", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, +}; +#endif + +/* Defined in d1_padconf.c */ +#ifdef SOC_ALLWINNER_D1 +extern struct allwinner_padconf d1_padconf; +struct aw_gpio_conf d1_gpio_conf = { + .padconf = &d1_padconf, + .banks = "bcdefg", + .bank_size = 0x30, + .drv_pin_shift = 2, + .pul_offset = 0x24, }; #endif @@ -198,10 +259,16 @@ extern struct allwinner_padconf h6_r_padconf; struct aw_gpio_conf h6_gpio_conf = { .padconf = &h6_padconf, .banks = "cdfgh", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; struct aw_gpio_conf h6_r_gpio_conf = { .padconf = &h6_r_padconf, .banks = "lm", + .bank_size = 0x24, + .drv_pin_shift = 1, + .pul_offset = 0x1C, }; #endif @@ -240,6 +307,9 @@ static struct ofw_compat_data compat_data[] = { {"allwinner,sun50i-a64-pinctrl", (uintptr_t)&a64_gpio_conf}, {"allwinner,sun50i-a64-r-pinctrl", (uintptr_t)&a64_r_gpio_conf}, #endif +#ifdef SOC_ALLWINNER_D1 + {"allwinner,sun20i-d1-pinctrl", (uintptr_t)&d1_gpio_conf}, +#endif #ifdef SOC_ALLWINNER_H6 {"allwinner,sun50i-h6-pinctrl", (uintptr_t)&h6_gpio_conf}, {"allwinner,sun50i-h6-r-pinctrl", (uintptr_t)&h6_r_gpio_conf}, @@ -293,10 +363,16 @@ static struct resource_spec aw_gpio_res_spec[] = { #define AW_GPIO_UNLOCK(_sc) mtx_unlock_spin(&(_sc)->sc_mtx) #define AW_GPIO_LOCK_ASSERT(_sc) mtx_assert(&(_sc)->sc_mtx, MA_OWNED) -#define AW_GPIO_GP_CFG(_bank, _idx) 0x00 + ((_bank) * 0x24) + ((_idx) << 2) -#define AW_GPIO_GP_DAT(_bank) 0x10 + ((_bank) * 0x24) -#define AW_GPIO_GP_DRV(_bank, _idx) 0x14 + ((_bank) * 0x24) + ((_idx) << 2) -#define AW_GPIO_GP_PUL(_bank, _idx) 0x1c + ((_bank) * 0x24) + ((_idx) << 2) +#define AW_GPIO_GP_BASE(_sc, _bank) ((_sc)->conf->bank_size * (_bank)) + +#define AW_GPIO_GP_CFG(_sc, _bank, _idx) \ + (AW_GPIO_GP_BASE(_sc, _bank) + 0x00 + ((_idx) << 2)) +#define AW_GPIO_GP_DAT(_sc, _bank) \ + (AW_GPIO_GP_BASE(_sc, _bank) + 0x10) +#define AW_GPIO_GP_DRV(_sc, _bank, _idx) \ + (AW_GPIO_GP_BASE(_sc, _bank) + 0x14 + ((_idx) << 2)) +#define AW_GPIO_GP_PUL(_sc, _bank, _idx) \ + (AW_GPIO_GP_BASE(_sc, _bank) + (_sc)->conf->pul_offset + ((_idx) << 2)) #define AW_GPIO_GP_INT_BASE(_bank) (0x200 + 0x20 * _bank) @@ -346,9 +422,9 @@ aw_gpio_get_function(struct aw_gpio_softc *sc, uint32_t pin) pin = sc->conf->padconf->pins[pin].pin; offset = ((pin & 0x07) << 2); - func = AW_GPIO_READ(sc, AW_GPIO_GP_CFG(bank, pin >> 3)); + func = AW_GPIO_READ(sc, AW_GPIO_GP_CFG(sc, bank, pin >> 3)); - return ((func >> offset) & 0x7); + return ((func >> offset) & 0xF); } static int @@ -367,10 +443,10 @@ aw_gpio_set_function(struct aw_gpio_softc *sc, uint32_t pin, uint32_t f) pin = sc->conf->padconf->pins[pin].pin; offset = ((pin & 0x07) << 2); - data = AW_GPIO_READ(sc, AW_GPIO_GP_CFG(bank, pin >> 3)); - data &= ~(7 << offset); + data = AW_GPIO_READ(sc, AW_GPIO_GP_CFG(sc, bank, pin >> 3)); + data &= ~(0xF << offset); data |= (f << offset); - AW_GPIO_WRITE(sc, AW_GPIO_GP_CFG(bank, pin >> 3), data); + AW_GPIO_WRITE(sc, AW_GPIO_GP_CFG(sc, bank, pin >> 3), data); return (0); } @@ -387,7 +463,7 @@ aw_gpio_get_pud(struct aw_gpio_softc *sc, uint32_t pin) pin = sc->conf->padconf->pins[pin].pin; offset = ((pin & 0x0f) << 1); - val = AW_GPIO_READ(sc, AW_GPIO_GP_PUL(bank, pin >> 4)); + val = AW_GPIO_READ(sc, AW_GPIO_GP_PUL(sc, bank, pin >> 4)); return ((val >> offset) & AW_GPIO_PUD_MASK); } @@ -407,25 +483,26 @@ aw_gpio_set_pud(struct aw_gpio_softc *sc, uint32_t pin, uint32_t state) pin = sc->conf->padconf->pins[pin].pin; offset = ((pin & 0x0f) << 1); - val = AW_GPIO_READ(sc, AW_GPIO_GP_PUL(bank, pin >> 4)); + val = AW_GPIO_READ(sc, AW_GPIO_GP_PUL(sc, bank, pin >> 4)); val &= ~(AW_GPIO_PUD_MASK << offset); val |= (state << offset); - AW_GPIO_WRITE(sc, AW_GPIO_GP_PUL(bank, pin >> 4), val); + AW_GPIO_WRITE(sc, AW_GPIO_GP_PUL(sc, bank, pin >> 4), val); } static uint32_t aw_gpio_get_drv(struct aw_gpio_softc *sc, uint32_t pin) { - uint32_t bank, offset, val; + uint32_t bank, idx, offset, val; /* Must be called with lock held. */ AW_GPIO_LOCK_ASSERT(sc); bank = sc->conf->padconf->pins[pin].port; pin = sc->conf->padconf->pins[pin].pin; - offset = ((pin & 0x0f) << 1); + offset = (pin << sc->conf->drv_pin_shift) & 0x1F; + idx = (pin << sc->conf->drv_pin_shift) >> 5; - val = AW_GPIO_READ(sc, AW_GPIO_GP_DRV(bank, pin >> 4)); + val = AW_GPIO_READ(sc, AW_GPIO_GP_DRV(sc, bank, idx)); return ((val >> offset) & AW_GPIO_DRV_MASK); } @@ -433,7 +510,7 @@ aw_gpio_get_drv(struct aw_gpio_softc *sc, uint32_t pin) static void aw_gpio_set_drv(struct aw_gpio_softc *sc, uint32_t pin, uint32_t drive) { - uint32_t bank, offset, val; + uint32_t bank, idx, offset, val; if (aw_gpio_get_drv(sc, pin) == drive) return; @@ -443,12 +520,13 @@ aw_gpio_set_drv(struct aw_gpio_softc *sc, uint32_t pin, uint32_t drive) bank = sc->conf->padconf->pins[pin].port; pin = sc->conf->padconf->pins[pin].pin; - offset = ((pin & 0x0f) << 1); + offset = (pin << sc->conf->drv_pin_shift) & 0x1F; + idx = (pin << sc->conf->drv_pin_shift) >> 5; - val = AW_GPIO_READ(sc, AW_GPIO_GP_DRV(bank, pin >> 4)); + val = AW_GPIO_READ(sc, AW_GPIO_GP_DRV(sc, bank, idx)); val &= ~(AW_GPIO_DRV_MASK << offset); val |= (drive << offset); - AW_GPIO_WRITE(sc, AW_GPIO_GP_DRV(bank, pin >> 4), val); + AW_GPIO_WRITE(sc, AW_GPIO_GP_DRV(sc, bank, idx), val); } static int @@ -624,12 +702,12 @@ aw_gpio_pin_set_locked(struct aw_gpio_softc *sc, uint32_t pin, bank = sc->conf->padconf->pins[pin].port; pin = sc->conf->padconf->pins[pin].pin; - data = AW_GPIO_READ(sc, AW_GPIO_GP_DAT(bank)); + data = AW_GPIO_READ(sc, AW_GPIO_GP_DAT(sc, bank)); if (value) data |= (1 << pin); else data &= ~(1 << pin); - AW_GPIO_WRITE(sc, AW_GPIO_GP_DAT(bank), data); + AW_GPIO_WRITE(sc, AW_GPIO_GP_DAT(sc, bank), data); return (0); } @@ -672,7 +750,7 @@ aw_gpio_pin_get_locked(struct aw_gpio_softc *sc,uint32_t pin, bank = sc->conf->padconf->pins[pin].port; pin = sc->conf->padconf->pins[pin].pin; - reg_data = AW_GPIO_READ(sc, AW_GPIO_GP_DAT(bank)); + reg_data = AW_GPIO_READ(sc, AW_GPIO_GP_DAT(sc, bank)); *val = (reg_data & (1 << pin)) ? 1 : 0; if (func == sc->conf->padconf->pins[pin].eint_func) @@ -779,12 +857,12 @@ aw_gpio_pin_toggle(device_t dev, uint32_t pin) pin = sc->conf->padconf->pins[pin].pin; AW_GPIO_LOCK(sc); - data = AW_GPIO_READ(sc, AW_GPIO_GP_DAT(bank)); + data = AW_GPIO_READ(sc, AW_GPIO_GP_DAT(sc, bank)); if (data & (1 << pin)) data &= ~(1 << pin); else data |= (1 << pin); - AW_GPIO_WRITE(sc, AW_GPIO_GP_DAT(bank), data); + AW_GPIO_WRITE(sc, AW_GPIO_GP_DAT(sc, bank), data); AW_GPIO_UNLOCK(sc); return (0); @@ -813,9 +891,9 @@ aw_gpio_pin_access_32(device_t dev, uint32_t first_pin, uint32_t clear_pins, return (EINVAL); AW_GPIO_LOCK(sc); - data = AW_GPIO_READ(sc, AW_GPIO_GP_DAT(bank)); + data = AW_GPIO_READ(sc, AW_GPIO_GP_DAT(sc, bank)); if ((clear_pins | change_pins) != 0) - AW_GPIO_WRITE(sc, AW_GPIO_GP_DAT(bank), + AW_GPIO_WRITE(sc, AW_GPIO_GP_DAT(sc, bank), (data & ~clear_pins) ^ change_pins); AW_GPIO_UNLOCK(sc); @@ -1408,7 +1486,7 @@ aw_gpio_pic_post_filter(device_t dev, struct intr_irqsrc *isrc) sc = device_get_softc(dev); gi = (struct gpio_irqsrc *)isrc; - arm_irq_memory_barrier(0); + IRQ_MEMORY_BARRIER(0); AW_GPIO_WRITE(sc, AW_GPIO_GP_INT_STA(gi->bank), 1 << gi->intnum); } @@ -1421,7 +1499,7 @@ aw_gpio_pic_post_ithread(device_t dev, struct intr_irqsrc *isrc) sc = device_get_softc(dev); gi = (struct gpio_irqsrc *)isrc; - arm_irq_memory_barrier(0); + IRQ_MEMORY_BARRIER(0); AW_GPIO_WRITE(sc, AW_GPIO_GP_INT_STA(gi->bank), 1 << gi->intnum); aw_gpio_pic_enable_intr(dev, isrc); } diff --git a/sys/riscv/allwinner/d1_padconf.c b/sys/riscv/allwinner/d1_padconf.c new file mode 100644 index 000000000000..7a429d216051 --- /dev/null +++ b/sys/riscv/allwinner/d1_padconf.c @@ -0,0 +1,129 @@ +/*- + * Copyright (c) 2022 Julien Cassette + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + */ +#include +#include +#include +#include + +#include + +#include "opt_soc.h" + +static const struct allwinner_pins d1_pins[] = { + { "PB0", 1, 0, { "gpio_in", "gpio_out", "pwm3", "ir", "i2c2", "spi1", "uart0", "uart2", "spdif", [14] = "pb_eint0" }, 14, 0, 1 }, + { "PB1", 1, 1, { "gpio_in", "gpio_out", "pwm4", "i2s2", "i2c2", "i2s2", "uart0", "uart2", "ir", [14] = "pb_eint1" }, 14, 1, 1 }, + { "PB2", 1, 2, { "gpio_in", "gpio_out", "lcd0", "i2s2", "i2c0", "i2s2", "lcd0", "uart4", NULL, [14] = "pb_eint2" }, 14, 2, 1 }, + { "PB3", 1, 3, { "gpio_in", "gpio_out", "lcd0", "i2s2", "i2c0", "i2s2", "lcd0", "uart4", NULL, [14] = "pb_eint3" }, 14, 3, 1 }, + { "PB4", 1, 4, { "gpio_in", "gpio_out", "lcd0", "i2s2", "i2c1", "i2s2", "lcd0", "uart5", NULL, [14] = "pb_eint4" }, 14, 4, 1 }, + { "PB5", 1, 5, { "gpio_in", "gpio_out", "lcd0", "i2s2", "i2c1", "pwm0", "lcd0", "uart5", NULL, [14] = "pb_eint5" }, 14, 5, 1 }, + { "PB6", 1, 6, { "gpio_in", "gpio_out", "lcd0", "i2s2", "i2c3", "pwm1", "lcd0", "uart3", "cpu", [14] = "pb_eint6" }, 14, 6, 1 }, + { "PB7", 1, 7, { "gpio_in", "gpio_out", "lcd0", "i2s2", "i2c3", "ir", "lcd0", "uart3", "cpu", [14] = "pb_eint7" }, 14, 7, 1 }, + { "PB8", 1, 8, { "gpio_in", "gpio_out", "dmic", "pwm5", "i2c2", "spi1", "uart0", "uart1", NULL, [14] = "pb_eint8" }, 14, 8, 1 }, + { "PB9", 1, 9, { "gpio_in", "gpio_out", "dmic", "pwm6", "i2c2", "spi1", "uart0", "uart1", NULL, [14] = "pb_eint9" }, 14, 9, 1 }, + { "PB10", 1, 10, { "gpio_in", "gpio_out", "dmic", "pwm7", "i2c0", "spi1", "clk", "uart1", NULL, [14] = "pb_eint10" }, 14, 10, 1 }, + { "PB11", 1, 11, { "gpio_in", "gpio_out", "dmic", "pwm2", "i2c0", "spi1", "clk", "uart1", NULL, [14] = "pb_eint11" }, 14, 11, 1 }, + { "PB12", 1, 12, { "gpio_in", "gpio_out", "dmic", "pwm0", "spdif", "spi1", "clk", "ir", NULL, [14] = "pb_eint12" }, 14, 12, 1 }, + { "PC0", 2, 0, { "gpio_in", "gpio_out", "uart2", "i2c2", "ledc", NULL, NULL, NULL, NULL, [14] = "pc_eint0" }, 14, 0, 2 }, + { "PC1", 2, 1, { "gpio_in", "gpio_out", "uart2", "i2c2", NULL, NULL, NULL, NULL, NULL, [14] = "pc_eint1" }, 14, 1, 2 }, + { "PC2", 2, 2, { "gpio_in", "gpio_out", "spi0", "mmc2", NULL, NULL, NULL, NULL, NULL, [14] = "pc_eint2" }, 14, 2, 2 }, + { "PC3", 2, 3, { "gpio_in", "gpio_out", "spi0", "mmc2", NULL, NULL, NULL, NULL, NULL, [14] = "pc_eint3" }, 14, 3, 2 }, + { "PC4", 2, 4, { "gpio_in", "gpio_out", "spi0", "mmc2", "boot", NULL, NULL, NULL, NULL, [14] = "pc_eint4" }, 14, 4, 2 }, + { "PC5", 2, 5, { "gpio_in", "gpio_out", "spi0", "mmc2", "boot", NULL, NULL, NULL, NULL, [14] = "pc_eint5" }, 14, 5, 2 }, + { "PC6", 2, 6, { "gpio_in", "gpio_out", "spi0", "mmc2", "uart3", "i2c3", "dbg", NULL, NULL, [14] = "pc_eint6" }, 14, 6, 2 }, + { "PC7", 2, 7, { "gpio_in", "gpio_out", "spi0", "mmc2", "uart3", "i2c3", "tcon", NULL, NULL, [14] = "pc_eint7" }, 14, 7, 2 }, + { "PD0", 3, 0, { "gpio_in", "gpio_out", "lcd0", "lvds0", "dsi", "i2c0", NULL, NULL, NULL, [14] = "pd_eint0" }, 14, 0, 3 }, + { "PD1", 3, 1, { "gpio_in", "gpio_out", "lcd0", "lvds0", "dsi", "uart2", NULL, NULL, NULL, [14] = "pd_eint1" }, 14, 1, 3 }, + { "PD2", 3, 2, { "gpio_in", "gpio_out", "lcd0", "lvds0", "dsi", "uart2", NULL, NULL, NULL, [14] = "pd_eint2" }, 14, 2, 3 }, + { "PD3", 3, 3, { "gpio_in", "gpio_out", "lcd0", "lvds0", "dsi", "uart2", NULL, NULL, NULL, [14] = "pd_eint3" }, 14, 3, 3 }, + { "PD4", 3, 4, { "gpio_in", "gpio_out", "lcd0", "lvds0", "dsi", "uart2", NULL, NULL, NULL, [14] = "pd_eint4" }, 14, 4, 3 }, + { "PD5", 3, 5, { "gpio_in", "gpio_out", "lcd0", "lvds0", "dsi", "uart5", NULL, NULL, NULL, [14] = "pd_eint5" }, 14, 5, 3 }, + { "PD6", 3, 6, { "gpio_in", "gpio_out", "lcd0", "lvds0", "dsi", "uart5", NULL, NULL, NULL, [14] = "pd_eint6" }, 14, 6, 3 }, + { "PD7", 3, 7, { "gpio_in", "gpio_out", "lcd0", "lvds0", "dsi", "uart4", NULL, NULL, NULL, [14] = "pd_eint7" }, 14, 7, 3 }, + { "PD8", 3, 8, { "gpio_in", "gpio_out", "lcd0", "lvds0", "dsi", "uart4", NULL, NULL, NULL, [14] = "pd_eint8" }, 14, 8, 3 }, + { "PD9", 3, 9, { "gpio_in", "gpio_out", "lcd0", "lvds0", "dsi", "pwm6", NULL, NULL, NULL, [14] = "pd_eint9" }, 14, 9, 3 }, + { "PD10", 3, 10, { "gpio_in", "gpio_out", "lcd0", "lvds1", "spi1", "uart3", NULL, NULL, NULL, [14] = "pd_eint10" }, 14, 10, 3 }, + { "PD11", 3, 11, { "gpio_in", "gpio_out", "lcd0", "lvds1", "spi1", "uart3", NULL, NULL, NULL, [14] = "pd_eint11" }, 14, 11, 3 }, + { "PD12", 3, 12, { "gpio_in", "gpio_out", "lcd0", "lvds1", "spi1", "i2c0", NULL, NULL, NULL, [14] = "pd_eint12" }, 14, 12, 3 }, + { "PD13", 3, 13, { "gpio_in", "gpio_out", "lcd0", "lvds1", "spi1", "uart3", NULL, NULL, NULL, [14] = "pd_eint13" }, 14, 13, 3 }, + { "PD14", 3, 14, { "gpio_in", "gpio_out", "lcd0", "lvds1", "spi1", "uart3", NULL, NULL, NULL, [14] = "pd_eint14" }, 14, 14, 3 }, + { "PD15", 3, 15, { "gpio_in", "gpio_out", "lcd0", "lvds1", "spi1", "ir", NULL, NULL, NULL, [14] = "pd_eint15" }, 14, 15, 3 }, + { "PD16", 3, 16, { "gpio_in", "gpio_out", "lcd0", "lvds1", "dmic", "pwm0", NULL, NULL, NULL, [14] = "pd_eint16" }, 14, 16, 3 }, + { "PD17", 3, 17, { "gpio_in", "gpio_out", "lcd0", "lvds1", "dmic", "pwm1", NULL, NULL, NULL, [14] = "pd_eint17" }, 14, 17, 3 }, + { "PD18", 3, 18, { "gpio_in", "gpio_out", "lcd0", "lvds1", "dmic", "pwm2", NULL, NULL, NULL, [14] = "pd_eint18" }, 14, 18, 3 }, + { "PD19", 3, 19, { "gpio_in", "gpio_out", "lcd0", "lvds1", "dmic", "pwm3", NULL, NULL, NULL, [14] = "pd_eint19" }, 14, 19, 3 }, + { "PD20", 3, 20, { "gpio_in", "gpio_out", "lcd0", "i2c2", "dmic", "pwm4", NULL, NULL, NULL, [14] = "pd_eint20" }, 14, 20, 3 }, + { "PD21", 3, 21, { "gpio_in", "gpio_out", "lcd0", "i2c2", "uart1", "pwm5", NULL, NULL, NULL, [14] = "pd_eint21" }, 14, 21, 3 }, + { "PD22", 3, 22, { "gpio_in", "gpio_out", "spdif", "ir", "uart1", "pwm7", NULL, NULL, NULL, [14] = "pd_eint22" }, 14, 22, 3 }, + { "PE0", 4, 0, { "gpio_in", "gpio_out", "ncsi0", "uart2", "i2c1", "lcd0", NULL, NULL, "emac", [14] = "pe_eint0" }, 14, 0, 4 }, + { "PE1", 4, 1, { "gpio_in", "gpio_out", "ncsi0", "uart2", "i2c1", "lcd0", NULL, NULL, "emac", [14] = "pe_eint1" }, 14, 1, 4 }, + { "PE2", 4, 2, { "gpio_in", "gpio_out", "ncsi0", "uart2", "i2c0", "clk", "uart0", NULL, "emac", [14] = "pe_eint2" }, 14, 2, 4 }, + { "PE3", 4, 3, { "gpio_in", "gpio_out", "ncsi0", "uart2", "i2c0", "clk", "uart0", NULL, "emac", [14] = "pe_eint3" }, 14, 3, 4 }, + { "PE4", 4, 4, { "gpio_in", "gpio_out", "ncsi0", "uart4", "i2c2", "clk", "jtag", "jtag", "emac", [14] = "pe_eint4" }, 14, 4, 4 }, + { "PE5", 4, 5, { "gpio_in", "gpio_out", "ncsi0", "uart4", "i2c2", "ledc", "jtag", "jtag", "emac", [14] = "pe_eint5" }, 14, 5, 4 }, + { "PE6", 4, 6, { "gpio_in", "gpio_out", "ncsi0", "uart5", "i2c3", "spdif", "jtag", "jtag", "emac", [14] = "pe_eint6" }, 14, 6, 4 }, + { "PE7", 4, 7, { "gpio_in", "gpio_out", "ncsi0", "uart5", "i2c3", "spdif", "jtag", "jtag", "emac", [14] = "pe_eint7" }, 14, 7, 4 }, + { "PE8", 4, 8, { "gpio_in", "gpio_out", "ncsi0", "uart1", "pwm2", "uart3", "jtag", NULL, "emac", [14] = "pe_eint8" }, 14, 8, 4 }, + { "PE9", 4, 9, { "gpio_in", "gpio_out", "ncsi0", "uart1", "pwm3", "uart3", "jtag", NULL, "emac", [14] = "pe_eint9" }, 14, 9, 4 }, + { "PE10", 4, 10, { "gpio_in", "gpio_out", "ncsi0", "uart1", "pwm4", "ir", "jtag", NULL, "emac", [14] = "pe_eint10" }, 14, 10, 4 }, + { "PE11", 4, 11, { "gpio_in", "gpio_out", "ncsi0", "uart1", "i2s0", "i2s0", "jtag", NULL, "emac", [14] = "pe_eint11" }, 14, 11, 4 }, + { "PE12", 4, 12, { "gpio_in", "gpio_out", "i2c2", "ncsi0", "i2s0", "i2s0", NULL, NULL, "emac", [14] = "pe_eint12" }, 14, 12, 4 }, + { "PE13", 4, 13, { "gpio_in", "gpio_out", "i2c2", "pwm5", "i2s0", "i2s0", "dmic", NULL, "emac", [14] = "pe_eint13" }, 14, 13, 4 }, + { "PE14", 4, 14, { "gpio_in", "gpio_out", "i2c1", "jtag", "i2s0", "i2s0", "dmic", NULL, "emac", [14] = "pe_eint14" }, 14, 14, 4 }, + { "PE15", 4, 15, { "gpio_in", "gpio_out", "i2c1", "jtag", "pwm6", "i2s0", "dmic", NULL, "emac", [14] = "pe_eint15" }, 14, 15, 4 }, + { "PE16", 4, 16, { "gpio_in", "gpio_out", "i2c3", "jtag", "pwm7", "i2s0", "dmic", NULL, NULL, [14] = "pe_eint16" }, 14, 16, 4 }, + { "PE17", 4, 17, { "gpio_in", "gpio_out", "i2c3", "jtag", "ir", "i2s0", "dmic", NULL, NULL, [14] = "pe_eint17" }, 14, 17, 4 }, + { "PF0", 5, 0, { "gpio_in", "gpio_out", "mmc0", NULL, "jtag", "i2s2", "i2s2", NULL, NULL, [14] = "pf_eint0" }, 14, 0, 5 }, + { "PF1", 5, 1, { "gpio_in", "gpio_out", "mmc0", NULL, "jtag", "i2s2", "i2s2", NULL, NULL, [14] = "pf_eint1" }, 14, 1, 5 }, + { "PF2", 5, 2, { "gpio_in", "gpio_out", "mmc0", "uart0", "i2c0", "ledc", "spdif", NULL, NULL, [14] = "pf_eint2" }, 14, 2, 5 }, + { "PF3", 5, 3, { "gpio_in", "gpio_out", "mmc0", NULL, "jtag", "i2s2", NULL, NULL, NULL, [14] = "pf_eint3" }, 14, 3, 5 }, + { "PF4", 5, 4, { "gpio_in", "gpio_out", "mmc0", "uart0", "i2c0", "pwm6", "ir", NULL, NULL, [14] = "pf_eint4" }, 14, 4, 5 }, + { "PF5", 5, 5, { "gpio_in", "gpio_out", "mmc0", NULL, "jtag", "i2s2", NULL, NULL, NULL, [14] = "pf_eint5" }, 14, 5, 5 }, + { "PF6", 5, 6, { "gpio_in", "gpio_out", NULL, "spdif", "ir", "i2s2", "pwm5", NULL, NULL, [14] = "pf_eint6" }, 14, 6, 5 }, + { "PG0", 6, 0, { "gpio_in", "gpio_out", "mmc1", "uart3", "emac", "pwm7", NULL, NULL, NULL, [14] = "pg_eint0" }, 14, 0, 6 }, + { "PG1", 6, 1, { "gpio_in", "gpio_out", "mmc1", "uart3", "emac", "pwm6", NULL, NULL, NULL, [14] = "pg_eint1" }, 14, 1, 6 }, + { "PG2", 6, 2, { "gpio_in", "gpio_out", "mmc1", "uart3", "emac", "uart4", NULL, NULL, NULL, [14] = "pg_eint2" }, 14, 2, 6 }, + { "PG3", 6, 3, { "gpio_in", "gpio_out", "mmc1", "uart3", "emac", "uart4", NULL, NULL, NULL, [14] = "pg_eint3" }, 14, 3, 6 }, + { "PG4", 6, 4, { "gpio_in", "gpio_out", "mmc1", "uart5", "emac", "pwm5", NULL, NULL, NULL, [14] = "pg_eint4" }, 14, 4, 6 }, + { "PG5", 6, 5, { "gpio_in", "gpio_out", "mmc1", "uart5", "emac", "pwm4", NULL, NULL, NULL, [14] = "pg_eint5" }, 14, 5, 6 }, + { "PG6", 6, 6, { "gpio_in", "gpio_out", "uart1", "i2c2", "emac", "pwm1", NULL, NULL, NULL, [14] = "pg_eint6" }, 14, 6, 6 }, + { "PG7", 6, 7, { "gpio_in", "gpio_out", "uart1", "i2c2", "emac", "spdif", NULL, NULL, NULL, [14] = "pg_eint7" }, 14, 7, 6 }, + { "PG8", 6, 8, { "gpio_in", "gpio_out", "uart1", "i2c1", "emac", "uart3", NULL, NULL, NULL, [14] = "pg_eint8" }, 14, 8, 6 }, + { "PG9", 6, 9, { "gpio_in", "gpio_out", "uart1", "i2c1", "emac", "uart3", NULL, NULL, NULL, [14] = "pg_eint9" }, 14, 9, 6 }, + { "PG10", 6, 10, { "gpio_in", "gpio_out", "pwm3", "i2c3", "emac", "clk", "ir", NULL, NULL, [14] = "pg_eint10" }, 14, 10, 6 }, + { "PG11", 6, 11, { "gpio_in", "gpio_out", "i2s1", "i2c3", "emac", "clk", "tcon", NULL, NULL, [14] = "pg_eint11" }, 14, 11, 6 }, + { "PG12", 6, 12, { "gpio_in", "gpio_out", "i2s1", "i2c0", "emac", "clk", "pwm0", "uart1", NULL, [14] = "pg_eint12" }, 14, 12, 6 }, + { "PG13", 6, 13, { "gpio_in", "gpio_out", "i2s1", "i2c0", "emac", "pwm2", "ledc", "uart1", NULL, [14] = "pg_eint13" }, 14, 13, 6 }, + { "PG14", 6, 14, { "gpio_in", "gpio_out", "i2s1", "i2c2", "emac", "i2s1", "spi0", "uart1", NULL, [14] = "pg_eint14" }, 14, 14, 6 }, + { "PG15", 6, 15, { "gpio_in", "gpio_out", "i2s1", "i2c2", "emac", "i2s1", "spi0", "uart1", NULL, [14] = "pg_eint15" }, 14, 15, 6 }, + { "PG16", 6, 16, { "gpio_in", "gpio_out", "ir", "tcon", "pwm5", "clk", "spdif", "ledc", NULL, [14] = "pg_eint16" }, 14, 16, 6 }, + { "PG17", 6, 17, { "gpio_in", "gpio_out", "uart2", "i2c3", "pwm7", "clk", "ir", "uart0", NULL, [14] = "pg_eint17" }, 14, 17, 6 }, + { "PG18", 6, 18, { "gpio_in", "gpio_out", "uart2", "i2c3", "pwm6", "clk", "spdif", "uart0", NULL, [14] = "pg_eint18" }, 14, 18, 6 }, +}; + +const struct allwinner_padconf d1_padconf = { + .npins = nitems(d1_pins), + .pins = d1_pins, +}; diff --git a/sys/riscv/allwinner/files.allwinner b/sys/riscv/allwinner/files.allwinner index f6be2cf97e57..f55d883abf57 100644 --- a/sys/riscv/allwinner/files.allwinner +++ b/sys/riscv/allwinner/files.allwinner @@ -1,4 +1,5 @@ +arm/allwinner/aw_gpio.c optional gpio aw_gpio fdt arm/allwinner/aw_rtc.c optional aw_rtc fdt arm/allwinner/aw_syscon.c optional syscon arm/allwinner/aw_sid.c optional aw_sid nvmem @@ -16,3 +17,5 @@ dev/clk/allwinner/aw_clk_nmm.c optional aw_ccu fdt dev/clk/allwinner/aw_clk_np.c optional aw_ccu fdt dev/clk/allwinner/aw_clk_prediv_mux.c optional aw_ccu fdt dev/clk/allwinner/ccu_d1.c optional soc_allwinner_d1 aw_ccu fdt + +riscv/allwinner/d1_padconf.c optional soc_allwinner_d1 aw_gpio fdt diff --git a/sys/riscv/conf/GENERIC b/sys/riscv/conf/GENERIC index 4fdb1bdd6403..5dfc624c9dfe 100644 --- a/sys/riscv/conf/GENERIC +++ b/sys/riscv/conf/GENERIC @@ -152,6 +152,7 @@ device axidma # Xilinx AXI DMA Controller # GPIO device gpio +device fdt_pinctrl # SPI device spibus diff --git a/sys/riscv/conf/std.allwinner b/sys/riscv/conf/std.allwinner index 4f3d98250cc5..a888e4d5d370 100644 --- a/sys/riscv/conf/std.allwinner +++ b/sys/riscv/conf/std.allwinner @@ -6,6 +6,7 @@ options SOC_ALLWINNER_D1 device aw_ccu # Allwinner clock controller +device aw_gpio # Allwinner GPIO controller device aw_rtc # Allwinner Real-time Clock device aw_sid # Allwinner Secure ID EFUSE device aw_wdog # Allwinner Watchdog From nobody Tue Dec 10 21:31:18 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 4Y7BkG3sk5z5gdhY; Tue, 10 Dec 2024 21:31:18 +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 4Y7BkG2sssz4YmX; Tue, 10 Dec 2024 21:31:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733866278; 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=aaWstTVIeIsI37T/WxdGJxVuTMOKsISV4gLKiuIHLxA=; b=fWLRzhVbswnaup2nJpQpLzF9Dc8p/7K5FQNH6A4gS2JNWPc2QtT62Y9xHu7vmZRuU4O83h JYs+H45QpfflQO9vin7MI9ZJqPS8WlF2BgqF13CaHw4Eor6K1bHjX0au20q6X3QJXuT8na 8skX0hkbVYW1l5wwaAU2YMClYIhTu1Cipj8FEdsuTTApsN7POVce3waMn7MEoGwAx3O9hh HYs7iv30zxgrXnD3HRxPcgdYrjsaBGAzdUzFbF9L3awd/PrrHCSbjSs4NVEmHkZK/Ism1k fZw4k8LIlksh4N4Hd8s3/KLCMv37RIVYo8drA9CF0mu7Rnt0lXUmZSAIq7CO7g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733866278; 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=aaWstTVIeIsI37T/WxdGJxVuTMOKsISV4gLKiuIHLxA=; b=fboHz+q7U9VRE57ht6kIh+MLzrpPsSBsKpStvBkzbOyFb+1ydiVJSt5M2m0WnkXWRziqoZ zsBarsyzh1MAx1/WDLUqLRT7gCmLYPX8GmuzUaEGjBEv02OtqDG/tyssDMRM/BbK1dKB6K qCyPaCJv7Exx7Qp+GdKjumejmgXqHe2i2VCBKiE20L0VeXU1uEJCToWWwAKqssxO/SoTog CogpyyEmhP76PvJxW+EoRonqFKnjxikPXEIJh0c+/hFZZK5tCEitSsN3/xS6Wx0D4IP83r XIb3w0Yi4DcrPfqmw+Ro469u3CexVpq2zmWmlqV7qAdlKXRKPWjuRgSxo7VmyQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733866278; a=rsa-sha256; cv=none; b=pdUyIBsiRXn/JNgDAYjpY0lp8CD8I2sM9nFhZNRsUE2UvdUMUJmW+F9kISBbP9S8W5oSQF aQkr76a5lqStlZ292vRcV21b7CTCXhrBzMkHUgfA2MVttqKs6ax2n98NYDPgLAwsrjNRD7 ND2SlVi/EXd18dZLk5pfnVYU6A0cE8ohzRkesvirfhmZmLP1hz9bwFjkRDc2KhFx97I50E ZNTJbrdelCn8qBT+wc7LeAHJIGUP0Cz4XURKlVF+R7tN/vE4XVnwDthJICH5ljRjXucV0R d3+7uyv0Qs50CauoUEP7Zc3xFwkRshvD8TWJ/W+9z1onuw4FQlmKjoeRKURYPg== 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 4Y7BkG1q68zgBX; Tue, 10 Dec 2024 21:31:18 +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 4BALVIcD094397; Tue, 10 Dec 2024 21:31:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BALVILh094394; Tue, 10 Dec 2024 21:31:18 GMT (envelope-from git) Date: Tue, 10 Dec 2024 21:31:18 GMT Message-Id: <202412102131.4BALVILh094394@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mitchell Horne Subject: git: b94b51d59973 - main - aw_rtc(4): update man page compatible list 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: mhorne X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b94b51d59973b0f74194ae9ea2d8a295c36ea5d6 Auto-Submitted: auto-generated The branch main has been updated by mhorne: URL: https://cgit.FreeBSD.org/src/commit/?id=b94b51d59973b0f74194ae9ea2d8a295c36ea5d6 commit b94b51d59973b0f74194ae9ea2d8a295c36ea5d6 Author: Mitchell Horne AuthorDate: 2024-12-10 20:50:26 +0000 Commit: Mitchell Horne CommitDate: 2024-12-10 21:30:39 +0000 aw_rtc(4): update man page compatible list After recently enabling for the Allwinner D1. Add this and other missing strings. Sponsored by: The FreeBSD Foundation --- share/man/man4/man4.arm/aw_rtc.4 | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/share/man/man4/man4.arm/aw_rtc.4 b/share/man/man4/man4.arm/aw_rtc.4 index 12e14dd52bee..1296cd41da68 100644 --- a/share/man/man4/man4.arm/aw_rtc.4 +++ b/share/man/man4/man4.arm/aw_rtc.4 @@ -35,8 +35,8 @@ device driver provides support for the Allwinner RTC controller. .Sh HARDWARE The current version of the .Nm -driver supports the RTC controller with one of the following compatible -strings : +driver supports the RTC controller with any of the following compatible +strings: .Pp .Bl -bullet -compact .It @@ -45,6 +45,14 @@ allwinner,sun4i-a10-rtc allwinner,sun7i-a20-rtc .It allwinner,sun6i-a31-rtc +.It +allwinner,sun8i-h3-rtc +.It +allwinner,sun20i-d1-rtc +.It +allwinner,sun50i-h5-rtc +.It +allwinner,sun50i-h6-rtc .El .Sh HISTORY The From nobody Tue Dec 10 22:09:38 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 4Y7CZk641yz5ggtm; Tue, 10 Dec 2024 22:09:50 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-io1-f53.google.com (mail-io1-f53.google.com [209.85.166.53]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Y7CZk47z3z4cpx; Tue, 10 Dec 2024 22:09:50 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-io1-f53.google.com with SMTP id ca18e2360f4ac-844c4ff559cso32713039f.3; Tue, 10 Dec 2024 14:09:50 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1733868589; x=1734473389; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=Ef8uZR0vUHerAH/qTeBJq5vHWVCp83m0TtcKV0aGY+Q=; b=B+lxc7nkgAd3xx/kox6yoifKXO9uyGxSWfPV8a44kNxuHvnCUb8SLwPY9o9XOUGpuc pVIi7/If3IbVE4gUJllcTm/2MXfpWVMhH+moiGmZq+GKpLvsNIA+EvqjGIX1ZidKIBwC 3pCyGB5ePYFtCAM6myn+sRWT5i6l9okdSwrHLLrR+j3Pnfy2lnZ5UXvw//98CTAFzVLb iVqoDFCoOVXloRCnMjPbTt4rojEhGxNUDTR3oo2uiF6D4XpPiJbMQaAGzjNmUbxQ3vA+ JaD5Zexpv/LkP3dcaOtkXFEuEpUEl+Ekt8g1F76MIxGSg/tEYdMZh9QC6bBzxLznCv3u RQoA== X-Forwarded-Encrypted: i=1; AJvYcCUxXa1FInlo3pzAOCtDlXZkta2zmgFlzLug3BADeSm6esztVO0BLe4hVtET0FVip1xJhotLMilZysYQS4w45uyEpRcg@freebsd.org, AJvYcCVB2iL2Pwe4Z/mCQUq6EuwK9x7Ev+4H2CjWBSje95rSsv04L+4DOb3Zk09DAYXJIn415B316PfUJ5vVGt86Fp00pDwk1G8=@freebsd.org, AJvYcCXlRy3YtiBAjgVjys2/TBha81w0w86UrRqtlR/NIZiX4lrvdUFmSUCbOczVu7JPmcVou6zAK/BUXm9QlzIzusg=@freebsd.org X-Gm-Message-State: AOJu0Yw+UkdftfMjHxlsWomrUppgPlRnH0QNfJO8KpZNsX9P2xBrUe02 MU0o4gPAmDBkyskhB50+1KrLyzd+QLhG9aDEYBg8xHNqMqX3FRKWNoKUMysug7NFiscGrTtAl2q +VcVsoKusMRKp/mrJDsp91UGucFJ+dQ== X-Gm-Gg: ASbGncvBi79lT+Miq6LiMmzNbImg9NV/0i3TMX6odi5wrYGa3wB+VSVu0sq0fMBAJR6 IGJN47lj24usrvBrsuol1zVA6ePgwExyxpd3rvZRpPEL37ChU2SSdRC8gbUncvQTIQTYecw== X-Google-Smtp-Source: AGHT+IHkZkNqMiWH1YyUGmwiQknKIIoGlvBUdgBzFMNnv/++6cTsdlge1Ecci2O0HwbtYNIh3bDI4O+uAwMeJxkQ/Lw= X-Received: by 2002:a05:6602:140c:b0:83a:b43b:da89 with SMTP id ca18e2360f4ac-844cb630557mr116756339f.10.1733868589053; Tue, 10 Dec 2024 14:09:49 -0800 (PST) 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 References: <202412091447.4B9ElFBH050286@gitrepo.freebsd.org> <6F9C2C43-A3DD-4CF5-AC27-899FE139E9A6@freebsd.org> <0883q825-802q-2n9q-3s4o-3nq13qpqno71@SerrOFQ.bet> In-Reply-To: <0883q825-802q-2n9q-3s4o-3nq13qpqno71@SerrOFQ.bet> From: Ed Maste Date: Tue, 10 Dec 2024 17:09:38 -0500 Message-ID: Subject: Re: git: 87e140a5c6f8 - main - iwlwifi: avoid (hard) hang on loading module To: "Bjoern A. Zeeb" Cc: Jessica Clarke , "src-committers@freebsd.org" , "dev-commits-src-all@freebsd.org" , "dev-commits-src-main@freebsd.org" Content-Type: text/plain; charset="UTF-8" X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:15169, ipnet:209.85.128.0/17, country:US] X-Rspamd-Queue-Id: 4Y7CZk47z3z4cpx X-Spamd-Bar: ---- On Mon, 9 Dec 2024 at 20:55, Bjoern A. Zeeb wrote: > > On Mon, 9 Dec 2024, Jessica Clarke wrote: > > > On 9 Dec 2024, at 14:47, Bjoern A. Zeeb wrote: > >> > >> The branch main has been updated by bz: > >> > >> URL: https://cgit.FreeBSD.org/src/commit/?id=87e140a5c6f89eea7ea6320d1ae34566492abfc0 > >> + if (bootverbose) > >> + printf("%s: module '%s' not yet available; will be" > >> + "initialized in a moment\n", __func__, op->name); > > > > Missing a space in the string. > > Thanks; I'll add that. Or just allow the line to go beyond 80 columns, allowing someone to grep for "will be initialized in a moment" to find the source of this string. From nobody Tue Dec 10 22:50:02 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 4Y7DTN4ncJz5gk19 for ; Tue, 10 Dec 2024 22:50:16 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-pj1-x1031.google.com (mail-pj1-x1031.google.com [IPv6:2607:f8b0:4864:20::1031]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Y7DTN33wSz4gpP for ; Tue, 10 Dec 2024 22:50:16 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-pj1-x1031.google.com with SMTP id 98e67ed59e1d1-2ee50ffcf14so93763a91.0 for ; Tue, 10 Dec 2024 14:50:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20230601.gappssmtp.com; s=20230601; t=1733871014; x=1734475814; darn=freebsd.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=LzYAaosPG2tTYy7HcFqfYoiKW4lOHDQnwXatPQ23NRk=; b=XTD2kMP70lN0/Q8FJMZBwR6eSWO80ocb1fjDluS6kcI266MvJne2325T8/kPavob9c GQ6tV1EZmX4ftNIokoXqPq//dvDEfCww4ya/j5EMVl3ze9ljfzdtWJ3PGQMKPIyPok7R 7ydt27VzL1XSoyufzdUGiER8zZgaUKOX5MgJaC9uRocCtdDlQ4vYMVp8U6WRx3Hln+GZ 4Y+E3aHpgsNu1sCiIy49N0jjOiPFyzDSJhJtQ23TduhfL4dUDtFdWc0rT1CePV/w8Gix flNcIjE84b5UamTzLhMSYNg0vCkv7lTXVcMKWCN3fS0+3SKlBspN4LWnY15mIhgW6p+C kacA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1733871014; x=1734475814; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=LzYAaosPG2tTYy7HcFqfYoiKW4lOHDQnwXatPQ23NRk=; b=PZ1AY8/4FVSQlBR+zW+MHwjJsQUPzDcUHh6ciBhSrkzR2ZRKfz9I7h1KRJAigfKTz0 Fszv8ABXGIr9vFftvaYmCBpFgYX9MJlsZBHVcQUXDT1J5SQ8yDhkOVlGDQhdR9BnLM/h qkSkr92q+RS/DHYdXnL3ZObts+X1mnDO46Ku9wviiBc4R1RM2VEqS6KBCDCil75ZhmyO 3t5iLxHPtZh4UmNiERAQoAHFQGay35MKA/ueG19au9NkLqZma8j+chLR76cYye+Cg2Ak oS0jmEMFtf8gQlt7mlr9Bc9YHSnIO9qXLnkq8VuEfWFx5RPRLDDldKp+iLO9+UsfPPUX ycHg== X-Forwarded-Encrypted: i=1; AJvYcCVP2JTwSu3eHiVUmahA4RVGwqZSo+aXCUghvziJfOKrwRSiK8aOkli5oEcHc7fbOzYUwIOOmuEghNVoFJm186YzJ+ZV@freebsd.org X-Gm-Message-State: AOJu0YzYubh+MWMh/3gSr9awpfT/Izbfi5z9gqhTPUqLj1VzZV92mtB9 JopbseJTLBYypS3gLXXP4qqgBSo9RuvmmHSZNcpLlKz+qGPk+52YgzcQJZhhuwNPdkm8hqxhUCF Rr2jDcDZVIeMh0vkkX+nCt3RBWUkJRur7FlisXLG9nkyca0LwKyE= X-Gm-Gg: ASbGncu5jCD4umbikMBjlm9htx1TBt7ACV/jVmA7HEK3pHzGDggZwxzQUtWyHw1bjQi f3M0Llyk1Ja2MGYVEMTU3f3gNHvl3iWhNnseM+IOQlWFWTI0/fCVeTE+DyuiLN/bg0A== X-Google-Smtp-Source: AGHT+IGonA3Xqz/+c8ebrd0wToRMdw5xrC/hxMiGA0hS7An8/RKdxZzmym/uDMa60UXGb9WAWo6wEDaBqRkjHpLdluQ= X-Received: by 2002:a17:90b:1347:b0:2ee:5c9b:35c0 with SMTP id 98e67ed59e1d1-2f1287ab9b9mr789437a91.9.1733871014422; Tue, 10 Dec 2024 14:50:14 -0800 (PST) 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 References: <202412091447.4B9ElFBH050286@gitrepo.freebsd.org> <6F9C2C43-A3DD-4CF5-AC27-899FE139E9A6@freebsd.org> <0883q825-802q-2n9q-3s4o-3nq13qpqno71@SerrOFQ.bet> In-Reply-To: From: Warner Losh Date: Tue, 10 Dec 2024 15:50:02 -0700 Message-ID: Subject: Re: git: 87e140a5c6f8 - main - iwlwifi: avoid (hard) hang on loading module To: Ed Maste Cc: "Bjoern A. Zeeb" , Jessica Clarke , src-committers , "" , "" Content-Type: multipart/alternative; boundary="000000000000e6cca30628f24d1b" X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US] X-Rspamd-Queue-Id: 4Y7DTN33wSz4gpP X-Spamd-Bar: ---- --000000000000e6cca30628f24d1b Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Tue, Dec 10, 2024, 3:09=E2=80=AFPM Ed Maste wrote: > On Mon, 9 Dec 2024 at 20:55, Bjoern A. Zeeb wrote: > > > > On Mon, 9 Dec 2024, Jessica Clarke wrote: > > > > > On 9 Dec 2024, at 14:47, Bjoern A. Zeeb wrote: > > >> > > >> The branch main has been updated by bz: > > >> > > >> URL: > https://cgit.FreeBSD.org/src/commit/?id=3D87e140a5c6f89eea7ea6320d1ae3456= 6492abfc0 > > >> + if (bootverbose) > > >> + printf("%s: module '%s' not yet available; will be" > > >> + "initialized in a moment\n", __func__, op->name); > > > > > > Missing a space in the string. > > > > Thanks; I'll add that. > > Or just allow the line to go beyond 80 columns, allowing someone to > grep for "will be initialized in a moment" to find the source of this > string. > It's either in style.9 as a length exception or is in a review somewhere... it make it easier to grep the error messages... Warner > --000000000000e6cca30628f24d1b Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Tue, Dec 10, 2024, 3:09=E2=80=AFPM Ed Maste <emaste@freebsd.org> wrote:
On Mon, 9 Dec 2024 at 20:55, Bjoern A. Ze= eb <bz@freebsd.org> wrote:
>
> On Mon, 9 Dec 2024, Jessica Clarke wrote:
>
> > On 9 Dec 2024, at 14:47, Bjoern A. Zeeb <bz@FreeBSD.org> wr= ote:
> >>
> >> The branch main has been updated by bz:
> >>
> >> URL: https://cgit.FreeBSD.org/src/commit/?id=3D87e140a5c6f89eea7ea63= 20d1ae34566492abfc0
> >> + if (bootverbose)
> >> +=C2=A0 =C2=A0 =C2=A0 =C2=A0printf("%s: module '%s&#= 39; not yet available; will be"
> >> +=C2=A0 =C2=A0"initialized in a moment\n", __func__= , op->name);
> >
> > Missing a space in the string.
>
> Thanks; I'll add that.

Or just allow the line to go beyond 80 columns, allowing someone to
grep for "will be initialized in a moment" to find the source of = this
string.

It's either in style.9 as a length exception or is in a review s= omewhere...=C2=A0 it make it easier to grep the error messages...

Warner=C2=A0
--000000000000e6cca30628f24d1b-- From nobody Tue Dec 10 23:37:58 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 4Y7FXR18mFz5g34C; Tue, 10 Dec 2024 23:37:59 +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 4Y7FXR0KFqz4l2g; Tue, 10 Dec 2024 23:37:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873879; 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=W8Nh0LRK7owKcgIL6Kq4LS0tPNv0FOHNMJe8cKBT7V8=; b=t9HFHkB8zt1dTX8wTT9Lr4teexUxC2bxPX0mhoDDxyWC6vo6E76OtYBCc+NzWdnrrYpvh2 DFqWKvMsCcQeZyhMLuq4w8Patwh0rkLyNQ37vjxTJ34vVFH3Ywys/zjE02TI4ElcRuWjaO u9TMylkgF/1BgP7d///PeEMSwsPFVSO5k42shrMlSCzu/Uv9mdIGElQWKmiUujT0E62qWb gC/+QKBsr/E7bZIsyBH5tbWSEdEkKvBXl1eRh9QobfPP7RbZp4dP7r5KksZ4ctGIcbTuJX gW1fGcHjDG2+1es5JgcPPqKSKb9VtiFGkuIES6KVLgMFXMCUDp3AtGlBIhFWpg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873879; 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=W8Nh0LRK7owKcgIL6Kq4LS0tPNv0FOHNMJe8cKBT7V8=; b=SJjsq1qW4t8nANP9V71CxWsUQi9ec8AeQtSqSjP/fB0RaFcDynAs6HZnc3eW8tcilCzcmm Jn8XlzJZus5Fyd3lsgaA5RfWPheCG5oNNChBszHxoO6uguZuBnPG5i+BxUkYePccv2JPZF kSn8WJoYYCz0aJQzOIRGCSmdHYvpeinVLh+73a8jGnWzwpcQ8OaylgxPznmHmJjGZ+6p/u n+3kaOQLxV+bbigxlFB2l8C9nKZR0VW3OTXuIZaPcCWbNoT0cMaRj9O0wCCuLG4MWGOPiU v5gvor+jLOoPnQaOdT+3OCyrLWbFa32oBAvgAOl5cJU1LFCd0tDJ9XayMmtyNg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733873879; a=rsa-sha256; cv=none; b=ITv00ls2PmMsqNn2mI5nNVOgSyZ8aH7U2TnKjdYaOxuYGB9eaDSF9yV6M4f1LozQdajJ/X Jv5QTqhE++91NVgEbdoyfETXtjPC+Q7cSohR8oA/Vp2hEbNJAcjVq3DILP9wpYnHvOE68V PnfWeYFIYAwcd7bmUUszTJy31e2dCmFyW5mtvMHgcviqKbVtgRFj56VvkoP+MWBvwejE8K S1jI7tV5c/tOuGzY79qWdR/nPpdmmNaXGC99EJY81x0SwT/bSWiMjMczfs5+A6Wy/bmrIk Pvk9H2GoOMl43t9eb6h2i660gY++OLxvTv4j2RASPTGUFn7pYE+zGelpBCVohg== 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 4Y7FXQ6hr9zkk7; Tue, 10 Dec 2024 23:37:58 +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 4BANbwX2019711; Tue, 10 Dec 2024 23:37:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BANbwJ5019708; Tue, 10 Dec 2024 23:37:58 GMT (envelope-from git) Date: Tue, 10 Dec 2024 23:37:58 GMT Message-Id: <202412102337.4BANbwJ5019708@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: aee794942130 - stable/14 - daemon: truncate the pidfile when we're waiting to restart child 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: aee794942130e684dd6cfe9c989e8a43c95a3ff3 Auto-Submitted: auto-generated The branch stable/14 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=aee794942130e684dd6cfe9c989e8a43c95a3ff3 commit aee794942130e684dd6cfe9c989e8a43c95a3ff3 Author: Kyle Evans AuthorDate: 2024-11-19 19:51:26 +0000 Commit: Kyle Evans CommitDate: 2024-12-10 22:59:58 +0000 daemon: truncate the pidfile when we're waiting to restart child We need to be able to test some more restart behavior that depends on knowing specifically where we're at (inside the event loop or outside of the event loop). Truncate the pidfile until the process is restarted to give the test a clean marker rather than having to add arbitrary delays and hoping for the best. Reviewed by: des, markj (cherry picked from commit aa8722cc18e4620ea5e7b0a4917207ed1508393d) --- usr.sbin/daemon/daemon.c | 30 ++++++++++++++++++++++++++++++ usr.sbin/daemon/tests/daemon_test.sh | 7 +++++-- 2 files changed, 35 insertions(+), 2 deletions(-) diff --git a/usr.sbin/daemon/daemon.c b/usr.sbin/daemon/daemon.c index 52fbfca1dcd2..6d0ce2cc10e6 100644 --- a/usr.sbin/daemon/daemon.c +++ b/usr.sbin/daemon/daemon.c @@ -105,6 +105,8 @@ static void daemon_exec(struct daemon_state *); static bool daemon_is_child_dead(struct daemon_state *); static void daemon_set_child_pipe(struct daemon_state *); +static int pidfile_truncate(struct pidfh *); + static const char shortopts[] = "+cfHSp:P:ru:o:s:l:t:m:R:T:h"; static const struct option longopts[] = { @@ -497,6 +499,15 @@ daemon_eventloop(struct daemon_state *state) close(kq); close(state->pipe_fd[0]); state->pipe_fd[0] = -1; + + /* + * We don't have to truncate the pidfile, but it's easier to test + * daemon(8) behavior in some respects if we do. We won't bother if + * the child won't be restarted. + */ + if (state->child_pidfh != NULL && state->restart_enabled) { + pidfile_truncate(state->child_pidfh); + } } static void @@ -788,3 +799,22 @@ daemon_set_child_pipe(struct daemon_state *state) /* The child gets dup'd pipes. */ close(state->pipe_fd[0]); } + +static int +pidfile_truncate(struct pidfh *pfh) +{ + int pfd = pidfile_fileno(pfh); + + assert(pfd >= 0); + + if (ftruncate(pfd, 0) == -1) + return (-1); + + /* + * pidfile_write(3) will always pwrite(..., 0) today, but let's assume + * it may not always and do a best-effort reset of the position just to + * set a good example. + */ + (void)lseek(pfd, 0, SEEK_SET); + return (0); +} diff --git a/usr.sbin/daemon/tests/daemon_test.sh b/usr.sbin/daemon/tests/daemon_test.sh index 948a9f6a8a57..2ad0803842b7 100644 --- a/usr.sbin/daemon/tests/daemon_test.sh +++ b/usr.sbin/daemon/tests/daemon_test.sh @@ -139,8 +139,11 @@ restart_child_body() { kill $orig_sleep_pid # Wait up to 10s for the daemon to restart the child. for t in `seq 0 0.1 10`; do - new_sleep_pid=`cat sleep.pid` - [ "$orig_sleep_pid" -ne "$new_sleep_pid" ] && break + if [ -s "sleep.pid" ]; then + new_sleep_pid=`cat sleep.pid` + [ "$orig_sleep_pid" -ne "$new_sleep_pid" ] && break + fi + sleep 0.1 done [ "$orig_sleep_pid" -ne "$new_sleep_pid" ] || \ From nobody Tue Dec 10 23:37:59 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 4Y7FXS4HWqz5g2W0; Tue, 10 Dec 2024 23:38:00 +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 4Y7FXS1qnDz4l7K; Tue, 10 Dec 2024 23:38:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873880; 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=xtTUh3U4MO0KJ/LFR3GTIcSEvpqX0V3PHFwNUrhJonQ=; b=nfLny+VqO3/0NPkrGCitRzHMN+iEWZuQDwtDFyP33VXS7JNHs+69v1Kg0ycwH3zKQyMplY 4fLHkebpB2tyP+H9LlmfpN8Wq9q5T/2WT/HmqNJE8Ir+fLKgHjZF2iIvw7Ay42iv+nqrkf hmI4XGittBB1P1PwBijzFJyFd2idSJfBexNOlmVqUiw/VeIqiL7rXiGejCELG+ikABVwMr 9UUmvHLQfi458f7irvQyCx1BV/z1H2HEexIX6e5bkvaej53Z9IhcjxQQQMf+jWW/8b5KAJ uCMBwmGddaV7zL1zCAaRBVtvEW4XYHR4IIh01Nj2ZtdgMWSpmapFVi3Ij0ORfA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873880; 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=xtTUh3U4MO0KJ/LFR3GTIcSEvpqX0V3PHFwNUrhJonQ=; b=Eba8EQnyT05VUHBfm0kRgYpubfTIFQbmK3Gcjr5WsgDNdb/GOTRyCdyIv9FjZ9aKA+t9cU kd9dup1dm4Hiqd/dBizDvRZju7RpENSfq547RJCvwoMu0j6TVvwGqZb7iz/q/+i97E9TTP u7usj3GIvUC7WdRb78SmNHz6c1c0JLmwsn4+p01XSyZW0DUxzVyoAFeThyJcBDMkLwQqxU 5baq9yGNxzr+fIPTbgul89NSJ1gMAB+nHVmsc1pDagLY/GWHuBNZV85YBHSpkLsBvtYolp iEvVW8SCBBNTbqFPrkQXthLT8WZ38HZ7pCulNPIEw0GK/P+vEhqfDOlW5U2NqQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733873880; a=rsa-sha256; cv=none; b=dmN2SUKSGUuHUn87EehrHGQB0HD0WAMbsykqzk3ZBQJrh0CZ3YJgY0KXim6ZywuIV8KwIw HT3GNA5Q6tVofhzUPD+dy8AhF3D/yLvljCVcx12A/M1GSvPGjdKV2niXXz/UALq+BL5HSx z+Tx5cSrLBPPz5IDgr/AxZe15jKcCj+x6OS3uC7Ltl0aLlg1So/FfGVDuimLyd07mOQyN2 m5vyLw4qGts5+TCo62kJuytoQHNr8Zo4uTYRvRkvWRWG4Ncc9jWI/1MtzoWiWajlRoi0oe /FbI3He5gpcFjcQYELFCq/aAp3PN4qza2BHK2xHwmx21xwYJwjxCySGIJJLylw== 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 4Y7FXS12L2zkWX; Tue, 10 Dec 2024 23:38:00 +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 4BANbxK5019763; Tue, 10 Dec 2024 23:37:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BANbxeX019760; Tue, 10 Dec 2024 23:37:59 GMT (envelope-from git) Date: Tue, 10 Dec 2024 23:37:59 GMT Message-Id: <202412102337.4BANbxeX019760@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: e310a825c933 - stable/14 - daemon: tests: add a test for missed SIGTERM 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: e310a825c933182a5b29261b741467f649951ff1 Auto-Submitted: auto-generated The branch stable/14 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=e310a825c933182a5b29261b741467f649951ff1 commit e310a825c933182a5b29261b741467f649951ff1 Author: Kyle Evans AuthorDate: 2024-11-19 19:51:27 +0000 Commit: Kyle Evans CommitDate: 2024-12-10 23:00:03 +0000 daemon: tests: add a test for missed SIGTERM This is somewhaht hard to test reliably, but we'll give it a shot. Startup a sleep(1) daemon with a hefty restart delay. In refactoring of daemon(8), we inadvertently started dropping SIGTERMs that came in while we were waiting to restart the child, so we employ the strategy: - Pop the child sleep(1) first - Wait for sleep(1) to exit (pid file truncated) - Pop the daemon(8) with a SIGTERM - Wait for daemon(8) to exit The pidfile is specifically truncated outside of the event loop so that we don't have a kqueue to catch it in the current model. PR: 277959 Reviewed by: des, markj (cherry picked from commit 9ab59e900c1dd693b4d14285389a035e81341789) --- usr.sbin/daemon/tests/daemon_test.sh | 38 ++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/usr.sbin/daemon/tests/daemon_test.sh b/usr.sbin/daemon/tests/daemon_test.sh index 2ad0803842b7..ec94d30bc1c3 100644 --- a/usr.sbin/daemon/tests/daemon_test.sh +++ b/usr.sbin/daemon/tests/daemon_test.sh @@ -154,6 +154,43 @@ restart_child_cleanup() { [ -f daemon.pid ] && kill `cat daemon.pid` } +atf_test_case restart_hang cleanup +restart_hang_head() { + atf_set "descr" "daemon should terminate with SIGTERM even pending child restart" +} +restart_hang_body() { + daemon -rP daemon.pid -R 10 -p sleep.pid sleep 300 + atf_check -s exit:0 test -f daemon.pid + atf_check -s exit:0 test -f sleep.pid + read sleep_pid < sleep.pid + 1>&2 echo "$sleep_pid" + kill "$sleep_pid" + + # Wait up to 5s for the child to exit + for t in `seq 0 0.1 5`; do + [ ! -s "sleep.pid" ] && break + sleep 0.1 + done + + atf_check test ! -s "sleep.pid" + + read daemon_pid < daemon.pid + kill -TERM "$daemon_pid" + + # Wait up to 10s for the daemon to terminate + for t in `seq 0 0.1 10`; do + [ ! -f "daemon.pid" ] && break + sleep 0.1 + done + + atf_check test ! -f "daemon.pid" + atf_check test ! -f "sleep.pid" +} +restart_hang_cleanup() { + [ -s daemon.pid ] && kill -9 `cat daemon.pid` + true +} + atf_test_case supervisor_pidfile cleanup supervisor_pidfile_head() { atf_set "descr" "daemon should write its own pid to a pidfile" @@ -218,6 +255,7 @@ atf_init_test_cases() { atf_add_test_case newsyslog atf_add_test_case output_file atf_add_test_case restart_child + atf_add_test_case restart_hang atf_add_test_case supervisor_pidfile atf_add_test_case supervisor_pidfile_lock atf_add_test_case title From nobody Tue Dec 10 23:38:01 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 4Y7FXT3hzXz5g2yN; Tue, 10 Dec 2024 23:38:01 +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 4Y7FXT2KwFz4lZc; Tue, 10 Dec 2024 23:38:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873881; 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=BMa7bon8cqtsItyGlVVuUaw0Ggje2t+nuwNRdrOpHVI=; b=M4UXULhkDhM2szE67Rn7sJiq0b+J6LqM+ja6ZVEzjoP00hV8xwT0ncql21Cztf0XvfPz83 B9zdfxrFyufxjNOZTZ1bz9WZJL48fNoiM2SxETTIqgONy4R6dusVLVAYvskGJ1NRBc6wir u0vmLY7cgk/43CYsIlOd/FHsRNLrMwVoj+qi6CT8BS1I20oYuMzEDU/kvcssF0raq8G+BL IMRekUiMo/N8wjZJj1MwKszeEXjM5MyRzSDo1iN+APmkehynZM19PKu1F1yNl7c9uT6ZcW 4q4C3slp85ud+UK/3kVGKgR7lGUB5DZMos17tnR4AVfom6T8ZyymoGH8nPTlzQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873881; 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=BMa7bon8cqtsItyGlVVuUaw0Ggje2t+nuwNRdrOpHVI=; b=CU/Dx3tBfvZmY7gkU6maLaGijEjIdPrI9bQxbAIsb3XnYI8f0GOnxeOeeI2xKKwvE+q7UL tgq6x5XRehIddUKvQV7VccJOuVKh4ECs0uXs+zIHMhnVVgcZFmvAO2qYh7mvrHZjw2vSQb zLQEsfKlrhJa5vGh5pyIkf/5FOurPjMaRIj+/41yiiz3uuqypngtdAQzv3bsjzwWLZoXNC /n9DNwgGHE/rPhorSyJY5EVrodzLtjB446ITdy4UwQTW50/zAz/zvFvI8XzBzHO0QMoee7 jtZwNZeeW3H4wdZM6XK84F0L55m+xLQpxm6USfaQ8NUCSvF5JEX3+sUwUVKoCQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733873881; a=rsa-sha256; cv=none; b=U+Twbw2ssvp06Wu1CsuH+hMXxIkHt0Iqrc0799JwUnuqe3ZcfuI92BHVIpt4u+UKacQSr9 cLrf0K1EL+/WR5UBgw7RL+wLFXX9FjW3BD0KgERrEsZv9Mh6NsyYhBbUZEISUPxf987VUy QaMVKCrGeRy8MKxlOUzW80ZfNnu9uzXzQDsNtUSiMFuItZlNPG5Bn/uu+tCNbfzeu67V+1 mP24Vc/QyNci5pr84LG2uz101WON9TIpJyArN45AV+xYsV/7zcVRr3LQwSZoRB2kgl9IMn qKcqI1x2zrU+hla912/u2pBF3odckhhZM9VtmHDy3dAEAaJL3CwaBKFoK2bvPA== 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 4Y7FXT1ddLzkQk; Tue, 10 Dec 2024 23:38:01 +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 4BANc1db019833; Tue, 10 Dec 2024 23:38:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BANc19s019830; Tue, 10 Dec 2024 23:38:01 GMT (envelope-from git) Date: Tue, 10 Dec 2024 23:38:01 GMT Message-Id: <202412102338.4BANc19s019830@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: 7ea2874eadf9 - stable/14 - daemon: stop rebuilding the kqueue every restart of the child 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7ea2874eadf901b1187772670169b6fc3a44d917 Auto-Submitted: auto-generated The branch stable/14 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=7ea2874eadf901b1187772670169b6fc3a44d917 commit 7ea2874eadf901b1187772670169b6fc3a44d917 Author: Kyle Evans AuthorDate: 2024-11-19 19:51:27 +0000 Commit: Kyle Evans CommitDate: 2024-12-10 23:05:46 +0000 daemon: stop rebuilding the kqueue every restart of the child We populate the kqueue with all of four kevents: three signal handlers and one for read of the child pipe. Every time we start the child, we rebuild this kqueue from scratch for the child and tear it down before we exit and check if we need to restart the child. As a consequence, we effectively drop any of the signals we're interested in between restarts. Push the kqueue out into the daemon state to avoid losing any signal events in the process, and reimplement the restart timer in terms of kqueue timers. The pipe read event will be automatically deleted upon last close, which leaves us with only the signal events that really get retained between restarts of the child. PR: 277959 Reviewed by: des, markj (cherry picked from commit bc1dfc316a2bba97773a14b96f5e976a52524be4) --- usr.sbin/daemon/daemon.c | 121 +++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 101 insertions(+), 20 deletions(-) diff --git a/usr.sbin/daemon/daemon.c b/usr.sbin/daemon/daemon.c index 6d0ce2cc10e6..73524e3bd286 100644 --- a/usr.sbin/daemon/daemon.c +++ b/usr.sbin/daemon/daemon.c @@ -79,6 +79,7 @@ struct daemon_state { enum daemon_mode mode; int pid; int keep_cur_workdir; + int kqueue_fd; int restart_delay; int stdmask; int syslog_priority; @@ -104,6 +105,7 @@ static void daemon_terminate(struct daemon_state *); static void daemon_exec(struct daemon_state *); static bool daemon_is_child_dead(struct daemon_state *); static void daemon_set_child_pipe(struct daemon_state *); +static int daemon_setup_kqueue(void); static int pidfile_truncate(struct pidfh *); @@ -324,6 +326,8 @@ main(int argc, char *argv[]) /* Write out parent pidfile if needed. */ pidfile_write(state.parent_pidfh); + state.kqueue_fd = daemon_setup_kqueue(); + do { state.mode = MODE_SUPERVISE; daemon_eventloop(&state); @@ -379,27 +383,13 @@ daemon_eventloop(struct daemon_state *state) err(1, "pipe"); } - kq = kqueuex(KQUEUE_CLOEXEC); + kq = state->kqueue_fd; EV_SET(&event, state->pipe_fd[0], EVFILT_READ, EV_ADD|EV_CLEAR, 0, 0, NULL); if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { err(EXIT_FAILURE, "failed to register kevent"); } - EV_SET(&event, SIGHUP, EVFILT_SIGNAL, EV_ADD, 0, 0, NULL); - if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { - err(EXIT_FAILURE, "failed to register kevent"); - } - - EV_SET(&event, SIGTERM, EVFILT_SIGNAL, EV_ADD, 0, 0, NULL); - if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { - err(EXIT_FAILURE, "failed to register kevent"); - } - - EV_SET(&event, SIGCHLD, EVFILT_SIGNAL, EV_ADD, 0, 0, NULL); - if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { - err(EXIT_FAILURE, "failed to register kevent"); - } memset(&event, 0, sizeof(struct kevent)); /* Spawn a child to exec the command. */ @@ -492,11 +482,12 @@ daemon_eventloop(struct daemon_state *state) } continue; default: + assert(0 && "Unexpected kevent filter type"); continue; } } - close(kq); + /* EVFILT_READ kqueue filter goes away here. */ close(state->pipe_fd[0]); state->pipe_fd[0] = -1; @@ -510,19 +501,76 @@ daemon_eventloop(struct daemon_state *state) } } +/* + * Note that daemon_sleep() should not be called with anything but the signal + * events in the kqueue without further consideration. + */ static void daemon_sleep(struct daemon_state *state) { - struct timespec ts = { state->restart_delay, 0 }; + struct kevent event = { 0 }; + int ret; + + assert(state->pipe_fd[0] == -1); + assert(state->pipe_fd[1] == -1); if (!state->restart_enabled) { return; } - while (nanosleep(&ts, &ts) == -1) { - if (errno != EINTR) { - err(1, "nanosleep"); + + EV_SET(&event, 0, EVFILT_TIMER, EV_ADD|EV_ONESHOT, NOTE_SECONDS, + state->restart_delay, NULL); + if (kevent(state->kqueue_fd, &event, 1, NULL, 0, NULL) == -1) { + err(1, "failed to register timer"); + } + + for (;;) { + ret = kevent(state->kqueue_fd, NULL, 0, &event, 1, NULL); + if (ret == -1) { + if (errno != EINTR) { + err(1, "kevent"); + } + + continue; + } + + /* + * Any other events being raised are indicative of a problem + * that we need to investigate. Most likely being that + * something was not cleaned up from the eventloop. + */ + assert(event.filter == EVFILT_TIMER || + event.filter == EVFILT_SIGNAL); + + if (event.filter == EVFILT_TIMER) { + /* Break's over, back to work. */ + break; + } + + /* Process any pending signals. */ + switch (event.ident) { + case SIGTERM: + /* + * We could disarm the timer, but we'll be terminating + * promptly anyways. + */ + state->restart_enabled = false; + return; + case SIGHUP: + if (state->log_reopen && state->output_fd >= 0) { + reopen_log(state); + } + + break; + case SIGCHLD: + default: + /* Discard */ + break; } } + + /* SIGTERM should've returned immediately. */ + assert(state->restart_enabled); } static void @@ -712,6 +760,7 @@ daemon_state_init(struct daemon_state *state) .restart_enabled = false, .pid = 0, .keep_cur_workdir = 1, + .kqueue_fd = -1, .restart_delay = 1, .stdmask = STDOUT_FILENO | STDERR_FILENO, .syslog_enabled = false, @@ -730,6 +779,9 @@ daemon_terminate(struct daemon_state *state) { assert(state != NULL); + if (state->kqueue_fd >= 0) { + close(state->kqueue_fd); + } if (state->output_fd >= 0) { close(state->output_fd); } @@ -800,6 +852,35 @@ daemon_set_child_pipe(struct daemon_state *state) close(state->pipe_fd[0]); } +static int +daemon_setup_kqueue(void) +{ + int kq; + struct kevent event = { 0 }; + + kq = kqueuex(KQUEUE_CLOEXEC); + if (kq == -1) { + err(EXIT_FAILURE, "kqueue"); + } + + EV_SET(&event, SIGHUP, EVFILT_SIGNAL, EV_ADD, 0, 0, NULL); + if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { + err(EXIT_FAILURE, "failed to register kevent"); + } + + EV_SET(&event, SIGTERM, EVFILT_SIGNAL, EV_ADD, 0, 0, NULL); + if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { + err(EXIT_FAILURE, "failed to register kevent"); + } + + EV_SET(&event, SIGCHLD, EVFILT_SIGNAL, EV_ADD, 0, 0, NULL); + if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { + err(EXIT_FAILURE, "failed to register kevent"); + } + + return (kq); +} + static int pidfile_truncate(struct pidfh *pfh) { From nobody Tue Dec 10 23:38:02 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 4Y7FXW0Tdwz5g2bf; Tue, 10 Dec 2024 23:38:03 +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 4Y7FXV31mWz4lRm; Tue, 10 Dec 2024 23:38:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873882; 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=kBaZWhKZox0QwYQ2Mogf7deny8PZR5BgTlLzpdEGJtY=; b=Jo+25cKQs9ixaG72/rD4dixzXhiZSrsxzQHJW5OlkAqxyjUjCbH3KoF563gkLIENr9om6g 5rAgX1ZHDB482fliy3p/druo7kr7qgxt+LS7Q/Zi9Ppv8zPHaspWE5TRVJV3cztzkuQtkz 5cS1NdPuxm0DzQdzuygYKUtNkmvk/j926+hGoj+eZYJmORkPZRugcMLVi1jMemhoVARSUP floisji7IhWQ/fsJjRcicmX04H8xBhevGDPlDQXHjMZM/H+aQeJwtDo8LhXx7R3Y2cIMV5 XSmlAXqLkRViU+IRKy/QD3RmIIKaptSobIKQpfWsv0tZ19OPQXEe4kaGTFyP5Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873882; 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=kBaZWhKZox0QwYQ2Mogf7deny8PZR5BgTlLzpdEGJtY=; b=vxMZuCUZWJBXyU6tM4m/4V4dOOKMq7H/PyqmGLPt/ng8UbPy2dLKmNDhzXLx9YDgAJdJz/ VKLmsBwp66WlluHbdRwU1Vrt8MaIG2dpn0KNaFM3xVKi68z6uqarSs+ntQZeCWTu+Mgz81 5ibwu/VxsZZQ/KUgaCo8teN1R1rdoV8sWLaHCciQ4s6kAVSyNwaKKdQ8znJev02gJDNPoD SlPkLPbM0UedmibvMSoUfT62ApnrVszLs4ScFDUwzwpHUere/Tvv1QJfcPpS7YlemL8FWH BhqRok5bZxOgn4ZsAukzmVG5o+M4CeMKqW8Zg7cnlRvPdz83KyFQU3YMF8oKgw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733873882; a=rsa-sha256; cv=none; b=vtbhNqhXMjVcOtwSB0I2YBIH529GU94+4i7SXji/v3gAzu/FxR8x5R388DVxgGVlJnFsg+ 7VH5Uy4YhTKL5l7OLWjVwn0TJqZXmDHVP+x0GzK/oSEzaC8MHNpswmR4LF3VsNOvILUlMH N0qa2reIT3TLFLUzFEAH5QmK70DgYMvSokbjDVyf6ryGhhTWvIl6SX0vSlLYxNhlg1vXH9 e+6aA0kEHXPlgI/q6/68fgeJOMijHjzKwMIPlWf8CZ66ApgfdO2idhcFNl17w35ZFIqNMp rVC/grvgAewXNIiKPRaOCayMnx5sdXB8b4KjeHjXibkNt7nIatZRw795QRx60Q== 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 4Y7FXV2bV1zkWY; Tue, 10 Dec 2024 23:38:02 +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 4BANc2If019890; Tue, 10 Dec 2024 23:38:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BANc2dB019887; Tue, 10 Dec 2024 23:38:02 GMT (envelope-from git) Date: Tue, 10 Dec 2024 23:38:02 GMT Message-Id: <202412102338.4BANc2dB019887@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: b50d2127d971 - stable/14 - pw: set the user's home directory mode if it existed 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: b50d2127d9718e54b68ffead90e9de8b5cee72f5 Auto-Submitted: auto-generated The branch stable/14 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=b50d2127d9718e54b68ffead90e9de8b5cee72f5 commit b50d2127d9718e54b68ffead90e9de8b5cee72f5 Author: Kyle Evans AuthorDate: 2024-12-01 19:05:57 +0000 Commit: Kyle Evans CommitDate: 2024-12-10 23:05:51 +0000 pw: set the user's home directory mode if it existed The adduser(8) prompt allows one to set the mode of a new home directory, but pw(8) doesn't honor the -M mode if the home directory already exists at creation time. It doesn't seem to make sense to ignore the mode (which may lead to a security issue on the system being configured) when we'll happily chown an existing directory, so fix the inconsistency. PR: 280099 Reviewed by: des, jlduran (previous version) (cherry picked from commit 6a7238fd7c60f35191eadaa026d3d395c6140c47) --- usr.sbin/adduser/adduser.8 | 6 ++++-- usr.sbin/pw/cpdir.c | 27 +++++++++++++++++++++------ 2 files changed, 25 insertions(+), 8 deletions(-) diff --git a/usr.sbin/adduser/adduser.8 b/usr.sbin/adduser/adduser.8 index 8ba623fedd9d..e21a7653f250 100644 --- a/usr.sbin/adduser/adduser.8 +++ b/usr.sbin/adduser/adduser.8 @@ -27,7 +27,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd April 11, 2024 +.Dd December 1, 2024 .Dt ADDUSER 8 .Os .Sh NAME @@ -246,7 +246,9 @@ file can reference the internal variables of the script. .It Fl M Ar mode Create the home directory with permissions set to -.Ar mode . +.Ar mode , +modified by the current +.Xr umask 2 . .It Fl N Do not read the default configuration file. .It Fl q diff --git a/usr.sbin/pw/cpdir.c b/usr.sbin/pw/cpdir.c index 504933ab88af..3dee8f7c43ac 100644 --- a/usr.sbin/pw/cpdir.c +++ b/usr.sbin/pw/cpdir.c @@ -49,13 +49,28 @@ copymkdir(int rootfd, char const * dir, int skelfd, mode_t mode, uid_t uid, if (*dir == '/') dir++; - if (mkdirat(rootfd, dir, mode) != 0 && errno != EEXIST) { - warn("mkdir(%s)", dir); - return; + if (mkdirat(rootfd, dir, mode) != 0) { + mode_t pumask; + + if (errno != EEXIST) { + warn("mkdir(%s)", dir); + return; + } + + pumask = umask(0); + umask(pumask); + + if (fchmodat(rootfd, dir, mode & ~pumask, + AT_SYMLINK_NOFOLLOW) == -1) + warn("chmod(%s)", dir); } - fchownat(rootfd, dir, uid, gid, AT_SYMLINK_NOFOLLOW); - if (flags > 0) - chflagsat(rootfd, dir, flags, AT_SYMLINK_NOFOLLOW); + + if (fchownat(rootfd, dir, uid, gid, AT_SYMLINK_NOFOLLOW) == -1) + warn("chown(%s)", dir); + + if (flags > 0 && chflagsat(rootfd, dir, flags, + AT_SYMLINK_NOFOLLOW) == -1) + warn("chflags(%s)", dir); if (skelfd == -1) return; From nobody Tue Dec 10 23:38:03 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 4Y7FXX4cXtz5g2yS; Tue, 10 Dec 2024 23:38:04 +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 4Y7FXW5wspz4lb7; Tue, 10 Dec 2024 23:38:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873883; 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=gCdlSbiWwtV4C8Wa9/305CixJ+08RN6sqZIkwtwDFvI=; b=UEa9IX5e6jJFvPQoKJ8uIMX8v7I16mTSlvVx/fpPvoz6Pl+XSBa8xber9lP1it3Yser6TN Q6VC6Mus9tRdYp2aa8igKyldcu1uKS09OoOIOVe/tsL+o7mSfHH1yWNOK1kP0eRGfADEKa d1c5U/VQx7gK+qgk3CzC7B7aEo3FWb8StSvdxlDi2APVlF1jpr2ZfQygCNaxSs6LX4kUug Dc1lpSq8SI5Iv7M/bFf8rpp5cHK9+Re52rxtIV+ngBsRwaaP30Mqw+jYnc7ogKgWenuZwL lMzJqog3CVGYvMqYfxDGaMmTDEmnbJYC/emhrMwlSfoLxFsW9vKpIRm8A5arcw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873883; 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=gCdlSbiWwtV4C8Wa9/305CixJ+08RN6sqZIkwtwDFvI=; b=LAnTGAwwS18jG2XQDMlo4JvCjqOs3U7JdFNkWIJAZ72yk42daVHQc7d1zWMpMZiQoUZZA5 TsGo7ri6KPG1dTDToPj5FNmqmgDpq9ZqfIgILFFZZmZzXdnWynlLzUjgUzaDi9MiH+ZfLC V8flwbmKH3OQ7hPAJtd4EhYde6heJr8iz547YsWldGRlcXyKYIJU9MGr8oD0S96+/Y5bXo Qe27HQojyHWFvhsrxxpG8R/fd7OwF99A5UoiH9OSC3teMejYy20L1xAFwFtwtaVk1Ftv1m WmAYG0OSS4kE10Onb45dOa6RfuURW+fw/RWnDPxDRRNlLNBQ/YzLAP0hH7hJLA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733873883; a=rsa-sha256; cv=none; b=hrthf2rYJZk1UHkAA3O3jSLlvdpW12uovbdnLwHtacoP+HiCx8hFCo4rWt4E4nE7V5Qhza R/5me70HIdm3mccBD77MAW9O7o81G7T5INNw3a5cO/2QbDED8OI2LKMgQlC+bI5JzF06EQ l788l/KyXunBEgvJx4vLcja4W2tmbE5PF8RMYIgoo3K4h7bfnRL6BIqx75NemkiCaLhsiq aISyNMR47TcV7ZtgXI1G/h8IgOmJ5U78bu9fJJcUJ7BMEFWf/ygkRFMA+pXSe4DTcOkdI2 Tmo5FAaZq/wdTQYWArKUGvDf+q6aMPO6O6fU0MmwYdIzgFHf+Y79dV3kh+sM1w== 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 4Y7FXW4b7TzkT9; Tue, 10 Dec 2024 23:38:03 +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 4BANc3X8019962; Tue, 10 Dec 2024 23:38:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BANc336019957; Tue, 10 Dec 2024 23:38:03 GMT (envelope-from git) Date: Tue, 10 Dec 2024 23:38:03 GMT Message-Id: <202412102338.4BANc336019957@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: 9aac1584c846 - stable/14 - pw: tests: add a test for -M with a pre-existing home directory 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 9aac1584c846cbb1dce638222ffc239ed712eb9b Auto-Submitted: auto-generated The branch stable/14 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=9aac1584c846cbb1dce638222ffc239ed712eb9b commit 9aac1584c846cbb1dce638222ffc239ed712eb9b Author: Jose Luis Duran AuthorDate: 2024-12-01 19:05:58 +0000 Commit: Kyle Evans CommitDate: 2024-12-10 23:05:51 +0000 pw: tests: add a test for -M with a pre-existing home directory Previous versions of pw(8) wouldn't chmod the home directory if it already existed prior to user creation, rendering adduser(8) -M ineffective in some cases. Add a test to cover that situation. PR: 280099 Reviewed by: kevans (cherry picked from commit f7cf62cf728a942e494a5b58438600998606617a) --- usr.sbin/pw/tests/pw_useradd_test.sh | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/usr.sbin/pw/tests/pw_useradd_test.sh b/usr.sbin/pw/tests/pw_useradd_test.sh index b4efa42bada7..6413c063d482 100755 --- a/usr.sbin/pw/tests/pw_useradd_test.sh +++ b/usr.sbin/pw/tests/pw_useradd_test.sh @@ -329,6 +329,21 @@ user_add_dir_body() { stat -f '%p' ${HOME}/home/foo } +atf_test_case user_add_existing_dir +user_add_existing_dir_body() { + populate_root_etc_skel + + mkdir -p -m 0777 ${HOME}/home/foo + atf_check -o inline:"40777\n" \ + stat -f '%p' ${HOME}/home/foo + + atf_check -s exit:0 ${RPW} useradd foo -M 0705 -m + atf_check grep -q '^foo:' $HOME/etc/master.passwd + atf_check test -d ${HOME}/home/foo + atf_check -o inline:"40705\n" \ + stat -f '%p' ${HOME}/home/foo +} + atf_test_case user_add_skel user_add_skel_body() { populate_root_etc_skel @@ -528,6 +543,7 @@ atf_init_test_cases() { atf_add_test_case user_add_R_no_symlink atf_add_test_case user_add_R_intermed atf_add_test_case user_add_dir + atf_add_test_case user_add_existing_dir atf_add_test_case user_add_skel atf_add_test_case user_add_uid0 atf_add_test_case user_add_uid_too_large From nobody Tue Dec 10 23:38:06 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 4Y7FXZ64sMz5g2bn; Tue, 10 Dec 2024 23:38:06 +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 4Y7FXZ45jSz4lk6; Tue, 10 Dec 2024 23:38:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873886; 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=X3/tOjJZUXYE5u4wRa4iSuU+XgsSrnV2w2y+BjzXROo=; b=ZY21EITw9Tctnc5ScfWy5h+GDq5/TcDyFXoAxA79B7O2UzhAn/72xch0Xr5r8cYo6KciQM W89Wyi4+eXjCcoVJRvBCu8P0Wa3314EzcCzJOxb4olRV23Mkng1idu/j2Mj6lR4Hm6/j3F SZSkAe2YBKzSe3tNe/LdiMWeXva/u7UjPlYG58DC0WWabfc4n42yRDkF1RuSWdCeUpIEEx mPJzjufv23irLjKaaIKTYidfKC+EAOeLSgPZ9XQg7s6jGEZ+FJzjkjv7GMvjpfZxvYzJ/H ehIIRFWfZ68iPizhEePvSLWqsoyC6XCX5MTp7Lnr6CaX6eTHpmylkLuZEJILBw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873886; 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=X3/tOjJZUXYE5u4wRa4iSuU+XgsSrnV2w2y+BjzXROo=; b=bkeRejs/SQzu3MehSoyxKRrCpEghCmhxGJLAwTn9V4Kzz9+O/dDpL9P0YgKc6AGncXQY7P no18KbW2Zk7UoB7KX283/oIap3Ifni67tTNEyrf+nqiHRiAzgTTCVPy9YHHxicTmWohAyG GDM24Ag2ZZVj6FCSmLfhhNpS6ABOgXe6fVOOsh3hHZOliPI6O2u9s16dvLlt/N7/G0gi2e kvwaCu0gOlKUeEy7v2hkrkwesRClQFpMvodGnAAJw7a1jWO79HDQSIFuvywye7A4P8Brlt nkWOpzQgyeckiicRM+8nRyVED3AB6SlcJDhegTlJdlERy3f2mYQZ11Cy1x8K5Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733873886; a=rsa-sha256; cv=none; b=Atrl/dCXWSlIljTKxje3YN7TgPpMiToYZlfyNiqSOu1yaodpyExAt5p6QiLmsy0LFQajLF mauoW+aNGYvIY7kRBtUlW06kJDwbKws1PYgV1+9YRW8OqvAiviIeEw72LE54vy8g8YR59g V5+lM5oQcd+idErlbYrIrYQDtQq8l8W/0q+HQoIhUYZcuIlski+wMGhJPcRH0QZUDG3cSH FNyrQL/TMdREvKuV7OrNPUpid9H0/hJX4zfM952HNmWAVmdl/1MQ40Vztd9PAFBTtAuv98 D7JH1ewd7czL9mOlbaOS32bvP7Oqskqb5njUEt9nTJ55jSskhDcaOzjOSnbXKA== 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 4Y7FXZ27gszkTC; Tue, 10 Dec 2024 23:38:06 +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 4BANc6HP020184; Tue, 10 Dec 2024 23:38:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BANc6qL020181; Tue, 10 Dec 2024 23:38:06 GMT (envelope-from git) Date: Tue, 10 Dec 2024 23:38:06 GMT Message-Id: <202412102338.4BANc6qL020181@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: 067e3791d615 - stable/13 - daemon: truncate the pidfile when we're waiting to restart child 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 067e3791d6151973eaae70ab767ce5f53fbef3f6 Auto-Submitted: auto-generated The branch stable/13 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=067e3791d6151973eaae70ab767ce5f53fbef3f6 commit 067e3791d6151973eaae70ab767ce5f53fbef3f6 Author: Kyle Evans AuthorDate: 2024-11-19 19:51:26 +0000 Commit: Kyle Evans CommitDate: 2024-12-10 23:02:36 +0000 daemon: truncate the pidfile when we're waiting to restart child We need to be able to test some more restart behavior that depends on knowing specifically where we're at (inside the event loop or outside of the event loop). Truncate the pidfile until the process is restarted to give the test a clean marker rather than having to add arbitrary delays and hoping for the best. Reviewed by: des, markj (cherry picked from commit aa8722cc18e4620ea5e7b0a4917207ed1508393d) --- usr.sbin/daemon/daemon.c | 30 ++++++++++++++++++++++++++++++ usr.sbin/daemon/tests/daemon_test.sh | 7 +++++-- 2 files changed, 35 insertions(+), 2 deletions(-) diff --git a/usr.sbin/daemon/daemon.c b/usr.sbin/daemon/daemon.c index 52fbfca1dcd2..6d0ce2cc10e6 100644 --- a/usr.sbin/daemon/daemon.c +++ b/usr.sbin/daemon/daemon.c @@ -105,6 +105,8 @@ static void daemon_exec(struct daemon_state *); static bool daemon_is_child_dead(struct daemon_state *); static void daemon_set_child_pipe(struct daemon_state *); +static int pidfile_truncate(struct pidfh *); + static const char shortopts[] = "+cfHSp:P:ru:o:s:l:t:m:R:T:h"; static const struct option longopts[] = { @@ -497,6 +499,15 @@ daemon_eventloop(struct daemon_state *state) close(kq); close(state->pipe_fd[0]); state->pipe_fd[0] = -1; + + /* + * We don't have to truncate the pidfile, but it's easier to test + * daemon(8) behavior in some respects if we do. We won't bother if + * the child won't be restarted. + */ + if (state->child_pidfh != NULL && state->restart_enabled) { + pidfile_truncate(state->child_pidfh); + } } static void @@ -788,3 +799,22 @@ daemon_set_child_pipe(struct daemon_state *state) /* The child gets dup'd pipes. */ close(state->pipe_fd[0]); } + +static int +pidfile_truncate(struct pidfh *pfh) +{ + int pfd = pidfile_fileno(pfh); + + assert(pfd >= 0); + + if (ftruncate(pfd, 0) == -1) + return (-1); + + /* + * pidfile_write(3) will always pwrite(..., 0) today, but let's assume + * it may not always and do a best-effort reset of the position just to + * set a good example. + */ + (void)lseek(pfd, 0, SEEK_SET); + return (0); +} diff --git a/usr.sbin/daemon/tests/daemon_test.sh b/usr.sbin/daemon/tests/daemon_test.sh index 948a9f6a8a57..2ad0803842b7 100644 --- a/usr.sbin/daemon/tests/daemon_test.sh +++ b/usr.sbin/daemon/tests/daemon_test.sh @@ -139,8 +139,11 @@ restart_child_body() { kill $orig_sleep_pid # Wait up to 10s for the daemon to restart the child. for t in `seq 0 0.1 10`; do - new_sleep_pid=`cat sleep.pid` - [ "$orig_sleep_pid" -ne "$new_sleep_pid" ] && break + if [ -s "sleep.pid" ]; then + new_sleep_pid=`cat sleep.pid` + [ "$orig_sleep_pid" -ne "$new_sleep_pid" ] && break + fi + sleep 0.1 done [ "$orig_sleep_pid" -ne "$new_sleep_pid" ] || \ From nobody Tue Dec 10 23:38:07 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 4Y7FXb6kg7z5g2W9; Tue, 10 Dec 2024 23:38:07 +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 4Y7FXb3Q2Gz4lkD; Tue, 10 Dec 2024 23:38:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873887; 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=6wMJkaphPjXhBtiiK8eFw612icE2HNg7GTFy3cVzfpg=; b=qRaQWftd8rV0vQXcFIXcaQW5V+nn9n3SPBg8bOyx6p0iuaWH6KmtxeV1Gtfp+kZdCZE2d9 DXqfZSLYD9a8dpf3nalU3JWXhMOZhaxov1NhsRJ9GvWV0XC1dR0+K8tsD/e02fVNr9XSYp azK4oczxHlIEG+wr2eJ6bl3AssbBz0OSdnuETho+58+zB9dLIZAb/UAQ9Dwca1/6bj3ivH okqSdDOxCSLPBmf3WVAnu/O4MGVQVax4aHdZ3F7Nn+iUIuIlJnyxsnkRXvbtx/KFSFV8dl rNYPgDoeKZOHqTrT0CinpQl6QrIo4XCE6zaQKbAkv2Yin4JykXwhGQ0Hb4Z5eA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873887; 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=6wMJkaphPjXhBtiiK8eFw612icE2HNg7GTFy3cVzfpg=; b=KFdmcmsbvKJRgWg8ZN19y7C/weWxrxVB97MZ4+Wj/Q+gTh6gdgVZDX7vOtlCprDb/fK9o0 giv06zKM8ouph6iprshNpKJZIdK+RQesRJb6dneEHZV/xd7h9M+hBWmsk+EEDVdE4QlXpk jjocxvOln7+Y2UghLyA5WWVS8nxS+azRUHGCN8ae2yrtRUc9Uj3oO7NyoPmyLyXic/5fHg ICVwIGHwBvZAeTI+hzKoeKKIn+LyRd3mLdUsnO2xhXUSXBQmzUIUyw1kRV0ISFUeED/GOO /uX1XZCtEFXfVQk9S1lS+dzE8kTZZru1pFXvRsnoXMR78eyWwmNFonRtAmVlGA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733873887; a=rsa-sha256; cv=none; b=MwObqqNKJS+NPiWOS2yOgQloOcNi0o3bGviL1vesKzIzCFehkB3ONPFTsxKQU/K/ajWmqF Cn1HVK4Di+oxqkEr3dLa8t7fSfhqIJmQ7wsU6Z+pLV4Scwczyd+RTF/wbfYvBNmf80OIGL Rtrl2dXIM2ESWCZRro3mtHnA0Sl2N2mzujhP/JzD6YvBxSE00MSH4bkM99GXSIdpn53D3V j+YlBQGTzpt9OFK/5DGfecstFgYhSzfM7WrgwrsPQhtCBLoEW/GErNCYpWqrPJTx9Pl49o bEFog3dEILXBetkjKDf70Rg+2Q9s1p/W5EORtHDRyZ+PZm4uOKVqZFfMVLs+eQ== 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 4Y7FXb2szBzkm0; Tue, 10 Dec 2024 23:38:07 +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 4BANc7kn020239; Tue, 10 Dec 2024 23:38:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BANc7gB020236; Tue, 10 Dec 2024 23:38:07 GMT (envelope-from git) Date: Tue, 10 Dec 2024 23:38:07 GMT Message-Id: <202412102338.4BANc7gB020236@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: 57c60ec86246 - stable/13 - daemon: tests: add a test for missed SIGTERM 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 57c60ec86246804a3df5c50ecfd921b39febcfd2 Auto-Submitted: auto-generated The branch stable/13 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=57c60ec86246804a3df5c50ecfd921b39febcfd2 commit 57c60ec86246804a3df5c50ecfd921b39febcfd2 Author: Kyle Evans AuthorDate: 2024-11-19 19:51:27 +0000 Commit: Kyle Evans CommitDate: 2024-12-10 23:02:40 +0000 daemon: tests: add a test for missed SIGTERM This is somewhaht hard to test reliably, but we'll give it a shot. Startup a sleep(1) daemon with a hefty restart delay. In refactoring of daemon(8), we inadvertently started dropping SIGTERMs that came in while we were waiting to restart the child, so we employ the strategy: - Pop the child sleep(1) first - Wait for sleep(1) to exit (pid file truncated) - Pop the daemon(8) with a SIGTERM - Wait for daemon(8) to exit The pidfile is specifically truncated outside of the event loop so that we don't have a kqueue to catch it in the current model. PR: 277959 Reviewed by: des, markj (cherry picked from commit 9ab59e900c1dd693b4d14285389a035e81341789) --- usr.sbin/daemon/tests/daemon_test.sh | 38 ++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/usr.sbin/daemon/tests/daemon_test.sh b/usr.sbin/daemon/tests/daemon_test.sh index 2ad0803842b7..ec94d30bc1c3 100644 --- a/usr.sbin/daemon/tests/daemon_test.sh +++ b/usr.sbin/daemon/tests/daemon_test.sh @@ -154,6 +154,43 @@ restart_child_cleanup() { [ -f daemon.pid ] && kill `cat daemon.pid` } +atf_test_case restart_hang cleanup +restart_hang_head() { + atf_set "descr" "daemon should terminate with SIGTERM even pending child restart" +} +restart_hang_body() { + daemon -rP daemon.pid -R 10 -p sleep.pid sleep 300 + atf_check -s exit:0 test -f daemon.pid + atf_check -s exit:0 test -f sleep.pid + read sleep_pid < sleep.pid + 1>&2 echo "$sleep_pid" + kill "$sleep_pid" + + # Wait up to 5s for the child to exit + for t in `seq 0 0.1 5`; do + [ ! -s "sleep.pid" ] && break + sleep 0.1 + done + + atf_check test ! -s "sleep.pid" + + read daemon_pid < daemon.pid + kill -TERM "$daemon_pid" + + # Wait up to 10s for the daemon to terminate + for t in `seq 0 0.1 10`; do + [ ! -f "daemon.pid" ] && break + sleep 0.1 + done + + atf_check test ! -f "daemon.pid" + atf_check test ! -f "sleep.pid" +} +restart_hang_cleanup() { + [ -s daemon.pid ] && kill -9 `cat daemon.pid` + true +} + atf_test_case supervisor_pidfile cleanup supervisor_pidfile_head() { atf_set "descr" "daemon should write its own pid to a pidfile" @@ -218,6 +255,7 @@ atf_init_test_cases() { atf_add_test_case newsyslog atf_add_test_case output_file atf_add_test_case restart_child + atf_add_test_case restart_hang atf_add_test_case supervisor_pidfile atf_add_test_case supervisor_pidfile_lock atf_add_test_case title From nobody Tue Dec 10 23:38:08 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 4Y7FXd1rCbz5g34G; Tue, 10 Dec 2024 23:38:09 +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 4Y7FXc5SNSz4lYD; Tue, 10 Dec 2024 23:38:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873888; 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=EPu2Akwdaf+meavOfgF5HapupG4Pqs90nwA0DoI7qzs=; b=Txw0ezXSci5baynKZAhXyCgeYHIUdvz9mQqaH+eMg7lGFjZxJXEfRMErzAO2fPqMFi1mZh 1OcZOo7Gi71NCRcnnsnG6ADg1bJYSM4aMfmbo8SEmKJfMJrJwTfRuOD+XrTmj92T+q+44C MbYuR5FGCqo0QJLP6t5D2GzggdbPF1qlWIqbgcuykoZibzdXWmbGqvDmk5hCPX7RdIOwEd t7S207S+EtVGyGStmUxbU1KTV5Ryg0xd1Rgg95aVHcncV9cnGx5aGdlQL2WSUmtGxp4oTl vQNbB22opr+4G2qkpPs0LcCg+YNe6gMVTV45NX3qS5nHpWKsmnqRa+NpJPt6/g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873888; 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=EPu2Akwdaf+meavOfgF5HapupG4Pqs90nwA0DoI7qzs=; b=to8nhM8TwKq8gI6knQfMxddHFwEhp8hzSwlYr3Wuum7rBklKgvSZMP+rU+xuNaxiveFHGB 9HmR+JNfGdIwARlrxddnN8U2Mlm7ahc44DHrQ83pJbvMx/dFQDpjhuhSBxUDOksn94yOVV FzDivNm3Xb/2uhheFSu8S2CwS9qXnpCUCDcLI1Yw9N9++K1Tt/ajR8K9rjjJ6XLZMPZ6ZL Pj0MkTyJ+6B51Q2+sjbTLxlToP10kfvOVWc241B93zDwSBMpMb50JuNf6BXBNnG3ESuqcv s3fvT8B92EhmOLfa2C0wMtWUQmFIA4/6f0tMlg9Ufh3RQtnvrFCH+tBzAWm1Jw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733873888; a=rsa-sha256; cv=none; b=DRBknWKOJK9rvNgctcIgCH7ufOAuQryx4SMekW0fDqlgjYHkWcEkTqhrKZyPIp/+2MZoHG eXjnUBJjHVxWCMA7e8pIqZREhpBS7KVLhs6HUGWqM1M/Nf2rcfAHKzJmKhbyKjkarrKFBE oGdauNefjg2tAVEtexB6cCheJ57jFhUgK8QngwvLy+MLJv4pnyMW0fH23TgAFHs48etyAa GsVLisb2PQ1kba+HGDmCP1zE6iZ0eWJSt0yKhRnspYTvpH2gnLMIFUhi5mHvlxPgmsEwJd acwwIUhln8nKQ1TZ7uNmk7YYGjdhn+slODSGOD2zYPuAaeKfjSYzk4ZIVeTR9Q== 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 4Y7FXc4HN0zkKl; Tue, 10 Dec 2024 23:38:08 +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 4BANc89k020305; Tue, 10 Dec 2024 23:38:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BANc8RH020302; Tue, 10 Dec 2024 23:38:08 GMT (envelope-from git) Date: Tue, 10 Dec 2024 23:38:08 GMT Message-Id: <202412102338.4BANc8RH020302@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: 4bb1a558a281 - stable/13 - daemon: stop rebuilding the kqueue every restart of the child 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4bb1a558a2811a27b1211579cb257a11df49c0e1 Auto-Submitted: auto-generated The branch stable/13 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=4bb1a558a2811a27b1211579cb257a11df49c0e1 commit 4bb1a558a2811a27b1211579cb257a11df49c0e1 Author: Kyle Evans AuthorDate: 2024-11-19 19:51:27 +0000 Commit: Kyle Evans CommitDate: 2024-12-10 23:06:11 +0000 daemon: stop rebuilding the kqueue every restart of the child We populate the kqueue with all of four kevents: three signal handlers and one for read of the child pipe. Every time we start the child, we rebuild this kqueue from scratch for the child and tear it down before we exit and check if we need to restart the child. As a consequence, we effectively drop any of the signals we're interested in between restarts. Push the kqueue out into the daemon state to avoid losing any signal events in the process, and reimplement the restart timer in terms of kqueue timers. The pipe read event will be automatically deleted upon last close, which leaves us with only the signal events that really get retained between restarts of the child. PR: 277959 Reviewed by: des, markj (cherry picked from commit bc1dfc316a2bba97773a14b96f5e976a52524be4) --- usr.sbin/daemon/daemon.c | 121 +++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 101 insertions(+), 20 deletions(-) diff --git a/usr.sbin/daemon/daemon.c b/usr.sbin/daemon/daemon.c index 6d0ce2cc10e6..73524e3bd286 100644 --- a/usr.sbin/daemon/daemon.c +++ b/usr.sbin/daemon/daemon.c @@ -79,6 +79,7 @@ struct daemon_state { enum daemon_mode mode; int pid; int keep_cur_workdir; + int kqueue_fd; int restart_delay; int stdmask; int syslog_priority; @@ -104,6 +105,7 @@ static void daemon_terminate(struct daemon_state *); static void daemon_exec(struct daemon_state *); static bool daemon_is_child_dead(struct daemon_state *); static void daemon_set_child_pipe(struct daemon_state *); +static int daemon_setup_kqueue(void); static int pidfile_truncate(struct pidfh *); @@ -324,6 +326,8 @@ main(int argc, char *argv[]) /* Write out parent pidfile if needed. */ pidfile_write(state.parent_pidfh); + state.kqueue_fd = daemon_setup_kqueue(); + do { state.mode = MODE_SUPERVISE; daemon_eventloop(&state); @@ -379,27 +383,13 @@ daemon_eventloop(struct daemon_state *state) err(1, "pipe"); } - kq = kqueuex(KQUEUE_CLOEXEC); + kq = state->kqueue_fd; EV_SET(&event, state->pipe_fd[0], EVFILT_READ, EV_ADD|EV_CLEAR, 0, 0, NULL); if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { err(EXIT_FAILURE, "failed to register kevent"); } - EV_SET(&event, SIGHUP, EVFILT_SIGNAL, EV_ADD, 0, 0, NULL); - if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { - err(EXIT_FAILURE, "failed to register kevent"); - } - - EV_SET(&event, SIGTERM, EVFILT_SIGNAL, EV_ADD, 0, 0, NULL); - if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { - err(EXIT_FAILURE, "failed to register kevent"); - } - - EV_SET(&event, SIGCHLD, EVFILT_SIGNAL, EV_ADD, 0, 0, NULL); - if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { - err(EXIT_FAILURE, "failed to register kevent"); - } memset(&event, 0, sizeof(struct kevent)); /* Spawn a child to exec the command. */ @@ -492,11 +482,12 @@ daemon_eventloop(struct daemon_state *state) } continue; default: + assert(0 && "Unexpected kevent filter type"); continue; } } - close(kq); + /* EVFILT_READ kqueue filter goes away here. */ close(state->pipe_fd[0]); state->pipe_fd[0] = -1; @@ -510,19 +501,76 @@ daemon_eventloop(struct daemon_state *state) } } +/* + * Note that daemon_sleep() should not be called with anything but the signal + * events in the kqueue without further consideration. + */ static void daemon_sleep(struct daemon_state *state) { - struct timespec ts = { state->restart_delay, 0 }; + struct kevent event = { 0 }; + int ret; + + assert(state->pipe_fd[0] == -1); + assert(state->pipe_fd[1] == -1); if (!state->restart_enabled) { return; } - while (nanosleep(&ts, &ts) == -1) { - if (errno != EINTR) { - err(1, "nanosleep"); + + EV_SET(&event, 0, EVFILT_TIMER, EV_ADD|EV_ONESHOT, NOTE_SECONDS, + state->restart_delay, NULL); + if (kevent(state->kqueue_fd, &event, 1, NULL, 0, NULL) == -1) { + err(1, "failed to register timer"); + } + + for (;;) { + ret = kevent(state->kqueue_fd, NULL, 0, &event, 1, NULL); + if (ret == -1) { + if (errno != EINTR) { + err(1, "kevent"); + } + + continue; + } + + /* + * Any other events being raised are indicative of a problem + * that we need to investigate. Most likely being that + * something was not cleaned up from the eventloop. + */ + assert(event.filter == EVFILT_TIMER || + event.filter == EVFILT_SIGNAL); + + if (event.filter == EVFILT_TIMER) { + /* Break's over, back to work. */ + break; + } + + /* Process any pending signals. */ + switch (event.ident) { + case SIGTERM: + /* + * We could disarm the timer, but we'll be terminating + * promptly anyways. + */ + state->restart_enabled = false; + return; + case SIGHUP: + if (state->log_reopen && state->output_fd >= 0) { + reopen_log(state); + } + + break; + case SIGCHLD: + default: + /* Discard */ + break; } } + + /* SIGTERM should've returned immediately. */ + assert(state->restart_enabled); } static void @@ -712,6 +760,7 @@ daemon_state_init(struct daemon_state *state) .restart_enabled = false, .pid = 0, .keep_cur_workdir = 1, + .kqueue_fd = -1, .restart_delay = 1, .stdmask = STDOUT_FILENO | STDERR_FILENO, .syslog_enabled = false, @@ -730,6 +779,9 @@ daemon_terminate(struct daemon_state *state) { assert(state != NULL); + if (state->kqueue_fd >= 0) { + close(state->kqueue_fd); + } if (state->output_fd >= 0) { close(state->output_fd); } @@ -800,6 +852,35 @@ daemon_set_child_pipe(struct daemon_state *state) close(state->pipe_fd[0]); } +static int +daemon_setup_kqueue(void) +{ + int kq; + struct kevent event = { 0 }; + + kq = kqueuex(KQUEUE_CLOEXEC); + if (kq == -1) { + err(EXIT_FAILURE, "kqueue"); + } + + EV_SET(&event, SIGHUP, EVFILT_SIGNAL, EV_ADD, 0, 0, NULL); + if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { + err(EXIT_FAILURE, "failed to register kevent"); + } + + EV_SET(&event, SIGTERM, EVFILT_SIGNAL, EV_ADD, 0, 0, NULL); + if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { + err(EXIT_FAILURE, "failed to register kevent"); + } + + EV_SET(&event, SIGCHLD, EVFILT_SIGNAL, EV_ADD, 0, 0, NULL); + if (kevent(kq, &event, 1, NULL, 0, NULL) == -1) { + err(EXIT_FAILURE, "failed to register kevent"); + } + + return (kq); +} + static int pidfile_truncate(struct pidfh *pfh) { From nobody Tue Dec 10 23:38:09 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 4Y7FXf0JSrz5g2xn; Tue, 10 Dec 2024 23:38:10 +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 4Y7FXd5hQSz4lfP; Tue, 10 Dec 2024 23:38:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873889; 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=nCNtepRdnIR/Ss7Ll99OEfhxVOVjUfyomtSkEdjBS1E=; b=jEJkvo1oLn9oBxRtOMjyM5691Z7NDk7mSrgJrZpppxA69gFAl6zQPGbHtmMrXhGwz4pNdD a4RDtYSDx6mMLin7vVqJ1ULVUxtvKfB1qrXrgJD+Sv7s5fVzpRU85Gwk9SnpsUFFw4PimW TS2FkzTN2XLpJxJ1tQXUb3CR9/T+OCjyFvNi+jNiGsPhsHY3O7v9HPwBWBY8pvdWKkpZvx kHMKiEHxZP5BxN6f/YTQTVLx1sa2aF7YyU2+NSb/LQIMksYkTCIATT1EzQBeqAjs+B34Nm /mNaeVx9+A+I710ECUlfC5l2U5x3vSfvSngEDlv3WGsVd53AE7wTnQGUaFtxFw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873889; 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=nCNtepRdnIR/Ss7Ll99OEfhxVOVjUfyomtSkEdjBS1E=; b=MLZhmbAxeTvrGOhnJ7F+ACveeaRJlLq+zfg9VtV4suNkXtQC3MSa1fT3am8kjfBeedBOxI KbxFVGzkGAKaLYhlyWaGhvlnnOCW07fXJIuAnGspLIMi/JUuwK1OkrS4tRCqUwwY4XY7vI zM7bEexKMurCH4+GGvcA9fAywp3/+tAYlYZIrpCjKMWUBpix/rF7KW/6IFOQ6t71D1VpDr KG99MVPZae9e8WEW8oto6WVjtgeTfexs/EiiXvIPSoffAA4sMHLJJJEnK82+6eqaCEAmVi 97uLr1+5UMx9aH8m4KfNFEM5uk7EMWOTLPu8MjNxHmda7YYWvhPeXSid4Z/OTw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733873889; a=rsa-sha256; cv=none; b=CXTDDMjTnTvsIAeaRm9Xqh15VZJB1M7jm6dsLOlKF97JXydAgPcaYqORzr7t+hO7jwulsy zLowNQO4UcKxxHk/o3wV8GGqZ6GzxEAKzSpAybN8dEenGp+T8Sht043GB9yLJKs9UHB4t0 9uVdItB0WxoirOio12XdBk7fZRWafOtky2kuqyhew2wMD7cbi46dRMOI0UKlKGNy5Ot1S5 5gvYeHY1Ghqr83PKQbQSGbqrhAfSM50/eC6nxttfIx/lRz/KaO+8dTMErZNBn5/fTofQZL WRWq5Rr3XSfvqdGs9KWdRjUlMsWAUPVgWIHg2oD8B9YPWYUvXYkGlmdUyea4mw== 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 4Y7FXd52r5zkm1; Tue, 10 Dec 2024 23:38:09 +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 4BANc9JF020362; Tue, 10 Dec 2024 23:38:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BANc9jS020359; Tue, 10 Dec 2024 23:38:09 GMT (envelope-from git) Date: Tue, 10 Dec 2024 23:38:09 GMT Message-Id: <202412102338.4BANc9jS020359@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: 1eaaa55f2ba9 - stable/13 - pw: set the user's home directory mode if it existed 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 1eaaa55f2ba9b45dfd955743a9bc5cbe7a6437f3 Auto-Submitted: auto-generated The branch stable/13 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=1eaaa55f2ba9b45dfd955743a9bc5cbe7a6437f3 commit 1eaaa55f2ba9b45dfd955743a9bc5cbe7a6437f3 Author: Kyle Evans AuthorDate: 2024-12-01 19:05:57 +0000 Commit: Kyle Evans CommitDate: 2024-12-10 23:06:15 +0000 pw: set the user's home directory mode if it existed The adduser(8) prompt allows one to set the mode of a new home directory, but pw(8) doesn't honor the -M mode if the home directory already exists at creation time. It doesn't seem to make sense to ignore the mode (which may lead to a security issue on the system being configured) when we'll happily chown an existing directory, so fix the inconsistency. PR: 280099 Reviewed by: des, jlduran (previous version) (cherry picked from commit 6a7238fd7c60f35191eadaa026d3d395c6140c47) --- usr.sbin/adduser/adduser.8 | 6 ++++-- usr.sbin/pw/cpdir.c | 27 +++++++++++++++++++++------ 2 files changed, 25 insertions(+), 8 deletions(-) diff --git a/usr.sbin/adduser/adduser.8 b/usr.sbin/adduser/adduser.8 index ed67e21f9430..1c4785cd56a6 100644 --- a/usr.sbin/adduser/adduser.8 +++ b/usr.sbin/adduser/adduser.8 @@ -24,7 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd April 11, 2024 +.Dd December 1, 2024 .Dt ADDUSER 8 .Os .Sh NAME @@ -243,7 +243,9 @@ file can reference the internal variables of the script. .It Fl M Ar mode Create the home directory with permissions set to -.Ar mode . +.Ar mode , +modified by the current +.Xr umask 2 . .It Fl N Do not read the default configuration file. .It Fl q diff --git a/usr.sbin/pw/cpdir.c b/usr.sbin/pw/cpdir.c index 504933ab88af..3dee8f7c43ac 100644 --- a/usr.sbin/pw/cpdir.c +++ b/usr.sbin/pw/cpdir.c @@ -49,13 +49,28 @@ copymkdir(int rootfd, char const * dir, int skelfd, mode_t mode, uid_t uid, if (*dir == '/') dir++; - if (mkdirat(rootfd, dir, mode) != 0 && errno != EEXIST) { - warn("mkdir(%s)", dir); - return; + if (mkdirat(rootfd, dir, mode) != 0) { + mode_t pumask; + + if (errno != EEXIST) { + warn("mkdir(%s)", dir); + return; + } + + pumask = umask(0); + umask(pumask); + + if (fchmodat(rootfd, dir, mode & ~pumask, + AT_SYMLINK_NOFOLLOW) == -1) + warn("chmod(%s)", dir); } - fchownat(rootfd, dir, uid, gid, AT_SYMLINK_NOFOLLOW); - if (flags > 0) - chflagsat(rootfd, dir, flags, AT_SYMLINK_NOFOLLOW); + + if (fchownat(rootfd, dir, uid, gid, AT_SYMLINK_NOFOLLOW) == -1) + warn("chown(%s)", dir); + + if (flags > 0 && chflagsat(rootfd, dir, flags, + AT_SYMLINK_NOFOLLOW) == -1) + warn("chflags(%s)", dir); if (skelfd == -1) return; From nobody Tue Dec 10 23:38:10 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 4Y7FXg18wWz5g2yZ; Tue, 10 Dec 2024 23:38:11 +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 4Y7FXf6Cwcz4lH4; Tue, 10 Dec 2024 23:38:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873890; 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=qtGQU/49NTs1Um3QWjhF2AH6I9qgGAMncLlmqrRE6eo=; b=bgghvrlFAfsJWAY37bvs1/qHPuVAfucNAS8KoN7Fkwm57ZoTniVlJoCEBlGR8lEXyxQ14B ZEdTLybDOXRu4B/iWwKRWVPRaZjK31aR+QlSsR+yfn771EyDFlehF+HgtYXqva7T5qYk0V nGNwvrUGbroGAekFZDQ0BLfWJpY2uU4GIwiMI1wE9bVxOMRTMqygtVAys2pfF2P71icj0V TvdCB4HSBh4PXpZdUatbVsmddyQAQ2e3L/tkpStAedVfx9C9dtRKljQ0vClI/p+44FBwRN +281kYVlEgovONAo39J2MVspWlP6WGN9gCt32Ge04IGr7UbtK1M3X/JOb13+nw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733873890; 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=qtGQU/49NTs1Um3QWjhF2AH6I9qgGAMncLlmqrRE6eo=; b=NF3CHfg31cTdXGsmceZIPKEfhAnykuPk85xbzfIaFqRD+a0EOBhPj4qa26ZFRNFw5HEwJ5 +aNjsAsSGspBqhulTsgeIpt+TM/ZTLqDBw/u9DGEWAYdfX6IU2IWcEzhsUXGWI1EGaYMga etkFNTLxN5g+o7Yf2Z9AwxZ6XJUkCPi+IMoN8GAAsAE6lj60TLACIUT2oSAQ8x9LlIgzj1 Y7Vp77TYY7jW0Np4KVwO5jsC+nu4v35RWPulMQQiLSDPUW2g+xFCyeMn1b3kIZCmmFAjLh ypIT88rqVYpakYuJ/3C7Dn1Wh7/BbKGeSgOb/J/mYKI9h6IZDQLs0rmqqfl6Bg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733873890; a=rsa-sha256; cv=none; b=ebKZaaPVukAprSmAZ1vu4zSdJKtnNPzDcqbxwIKooBZ4qBXVGw79Th5qXDi0diQxkSNH0B jy+rsBoKAeYUfrK3zc6RhCGtOc47u9QSLl4SjZEQr0K8mL4h+XnC/kJJxmwbfe0uPcVRd+ V3tRbclZCidy3SsQmqcbO1zspAFXbbAwLADYQ2h0tiEqUOlfZ1/WBIOfXAkEzXGPPP2RiQ AlhKpy3DrYVpWpLEiF4a5pzVQB2M6VUPgA9OsY3Can1+HAnSK89SSj59BibjLu+f8b7I0R INgKWnjQcybyBrmuXunOLRpWZIIJVl5hQ8v7WLVnX/Mm8beUJIGY9XpPnija5A== 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 4Y7FXf5r9hzkQm; Tue, 10 Dec 2024 23:38:10 +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 4BANcAUH020429; Tue, 10 Dec 2024 23:38:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BANcAEw020424; Tue, 10 Dec 2024 23:38:10 GMT (envelope-from git) Date: Tue, 10 Dec 2024 23:38:10 GMT Message-Id: <202412102338.4BANcAEw020424@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kyle Evans Subject: git: 9d8a178b38ed - stable/13 - pw: tests: add a test for -M with a pre-existing home directory 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 9d8a178b38ed0953f2beaa49c0dd3981cce56179 Auto-Submitted: auto-generated The branch stable/13 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=9d8a178b38ed0953f2beaa49c0dd3981cce56179 commit 9d8a178b38ed0953f2beaa49c0dd3981cce56179 Author: Jose Luis Duran AuthorDate: 2024-12-01 19:05:58 +0000 Commit: Kyle Evans CommitDate: 2024-12-10 23:06:16 +0000 pw: tests: add a test for -M with a pre-existing home directory Previous versions of pw(8) wouldn't chmod the home directory if it already existed prior to user creation, rendering adduser(8) -M ineffective in some cases. Add a test to cover that situation. PR: 280099 Reviewed by: kevans (cherry picked from commit f7cf62cf728a942e494a5b58438600998606617a) --- usr.sbin/pw/tests/pw_useradd_test.sh | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/usr.sbin/pw/tests/pw_useradd_test.sh b/usr.sbin/pw/tests/pw_useradd_test.sh index 93a192c59409..0da1877c3283 100755 --- a/usr.sbin/pw/tests/pw_useradd_test.sh +++ b/usr.sbin/pw/tests/pw_useradd_test.sh @@ -321,6 +321,21 @@ user_add_dir_body() { stat -f '%p' ${HOME}/home/foo } +atf_test_case user_add_existing_dir +user_add_existing_dir_body() { + populate_root_etc_skel + + mkdir -p -m 0777 ${HOME}/home/foo + atf_check -o inline:"40777\n" \ + stat -f '%p' ${HOME}/home/foo + + atf_check -s exit:0 ${RPW} useradd foo -M 0705 -m + atf_check grep -q '^foo:' $HOME/etc/master.passwd + atf_check test -d ${HOME}/home/foo + atf_check -o inline:"40705\n" \ + stat -f '%p' ${HOME}/home/foo +} + atf_test_case user_add_skel user_add_skel_body() { populate_root_etc_skel @@ -496,6 +511,7 @@ atf_init_test_cases() { atf_add_test_case user_add_R atf_add_test_case user_add_R_symlink atf_add_test_case user_add_dir + atf_add_test_case user_add_existing_dir atf_add_test_case user_add_skel atf_add_test_case user_add_uid0 atf_add_test_case user_add_uid_too_large From nobody Wed Dec 11 00:37:25 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 4Y7Gs14JLlz5g674; Wed, 11 Dec 2024 00:37:25 +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 4Y7Gs13pRkz4tk1; Wed, 11 Dec 2024 00:37:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733877445; 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=TAkzZLUp16OITE46265TT5VKaYidMwbtAtFKB/Am+I4=; b=kET8d6bH46H9pVOfalQ0icHQ5OOI8/6Z9nM0sM7So2DkkjYp5r8hHvc0uTimfk69F9v0fo Saeh9EQ3ZDGtqEsHaqZpOFDuPW+UAweMNsblDkCECv5qeVAkKCbUJ4XLAqVQfVHa0j5DSY vWvkhLiSM6EECqRRlnQgEN3k2gg/poTPd8vsSKeXJauRE5c9A6MDvSkcn0fvx0AC7Ubi3T Fgd1qQxVUpYI+e/i31Ik+UU6Bi77BjMAuxE1myoptRHlWl63U79DHa6CNukRZ6dc0kuCMC S8frzi+txDJk+EVv+1DWFPAzXrOzCaiTfcwzBDaSQAYsVzgFGxdNAu8fuOVQ4g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733877445; 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=TAkzZLUp16OITE46265TT5VKaYidMwbtAtFKB/Am+I4=; b=MZNqpfFuQ09g/CjSeDoaUV7e/r8Cmd2zIfNcBW1Soq8b73jXWXeubH707olPU5J4s2LqZw 8EDT483O+FMW7+ohgSPEjKqzVi0EvIdk8EHSl8xNL9rL2/SrqyUE4ReY4qAnTXZWsfOnyf HbIVzOl40uyCMxxVTTMf5LyGuyw36sF16GZjVT7VXMwmfW7dDI+XNyqtADTwBK/rmBePkW JKeKAfkuNmgcb+dBnX8AeE5+9U/dTNmJXgJBDK4VpqLOLz7UYaEQT4SeFjAp6IrfyEqgex 4D+2jmfeC91XYMyWSt6pMe63LN+EiFgfWTQdi2fQHEeeuhbqxETBpBXloBBbRA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733877445; a=rsa-sha256; cv=none; b=jqU+DX9ctb546TaEdSFARtPkpBMMPH4iKE8+vnzODnp6osgUB1D8duEKjAo30p+iawdNFJ BeHHWbRWZoeqRVEQ32XiD7wV2daNWeKL0bKGcNW1vdlQeE4KLbH7D2P4A1ghTgoRGDDB08 Nfak7R39J0ktYQRFWJJBB0u0cuW00BFM1XB3HqvZfeabcoAEWa/UdEKM+AGq4T8dA3CtSl v058N19S9ZnKeGF+xrVhRpg8OIcXNedqacAIYeIlsCJcm9/TiVuKOGLjVZ9ngOOvZoZsdJ 7r97XkYVmJ7ArM0d8PUvxV8Yf86/n9sgqO35bmqP3NzBRc9B2iTho2N75hTinA== 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 4Y7Gs13HXrzlVG; Wed, 11 Dec 2024 00:37:25 +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 4BB0bP9l032090; Wed, 11 Dec 2024 00:37:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BB0bPc2032086; Wed, 11 Dec 2024 00:37:25 GMT (envelope-from git) Date: Wed, 11 Dec 2024 00:37:25 GMT Message-Id: <202412110037.4BB0bPc2032086@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: b10b9523f616 - main - kern: fix naming for some AST-handler bits 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b10b9523f616bbb3eb993af98ac2742e10025e84 Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=b10b9523f616bbb3eb993af98ac2742e10025e84 commit b10b9523f616bbb3eb993af98ac2742e10025e84 Author: Kyle Evans AuthorDate: 2024-12-11 00:33:54 +0000 Commit: Kyle Evans CommitDate: 2024-12-11 00:37:17 +0000 kern: fix naming for some AST-handler bits These were typo'd at creation, and they should've used the common TDA_ prefix. Switch them now. No compat shims because these are niche enough that it seems unlikely that they've seen large adoption under the wrong name. OK'd by: kib Fixes: c6d31b83 ("AST: rework") --- sys/sys/proc.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/sys/proc.h b/sys/sys/proc.h index 3422f75172f0..df7ce6de91d9 100644 --- a/sys/sys/proc.h +++ b/sys/sys/proc.h @@ -493,14 +493,14 @@ enum { TDA_KQUEUE, TDA_RACCT, TDA_MOD1, /* For third party use, before signals are */ - TAD_MOD2, /* processed .. */ + TDA_MOD2, /* processed .. */ TDA_PSELECT, /* For discarding temporary signal mask */ TDA_SIG, TDA_KTRACE, TDA_SUSPEND, TDA_SIGSUSPEND, TDA_MOD3, /* .. and after */ - TAD_MOD4, + TDA_MOD4, TDA_MAX, }; #define TDAI(tda) (1U << (tda)) From nobody Wed Dec 11 01:19:23 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 4Y7HnR43Wbz5g8HX; Wed, 11 Dec 2024 01:19:23 +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 4Y7HnR3P0Wz3xFl; Wed, 11 Dec 2024 01:19:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733879963; 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=ppq4Ooj5X2s91MOPC4GrmNolg5NbgwQk6D5Od1QYKQQ=; b=Kv0zISvA3d/kqqPI96sH2z2b1r+qJKfO1jIen3kNfhf3sHd8/7/0pLppRIZwN2YjWT8nR6 nl9469pRbw3Ikyj1XAc2PFoFP9gD4nnMrilW0WYG3tScz799nWSd8i35Yer7sl4FZQJLXE /5GrZJmR7yiSWgmmBaenDKa5Ru9OMGkTmYazK83ucGVPtIQ9zmYMopkkm4Xei7r02jQPPJ aD+l7hN1u7YoVcVbEbAgDUJ3PxmW5BinKAdNnJmafUPHgiHl8w+DSx8uu0hxMHRlrV9r4f CLFg7xqfKYVCRz2ka5nCdzUJuE361sxquDNfKkcSzcyQ3ScFR7WwEEH6iYy01w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733879963; 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=ppq4Ooj5X2s91MOPC4GrmNolg5NbgwQk6D5Od1QYKQQ=; b=uSxq0XGr+9UGm6UsryGPokOsdeHfLYWwd5ndRSELMB0WPxMsNsrO8JIXKkDyL6DYsjpuBe xttimPrVP54tRWwXj/gbZjYkAl/vQ2mAAPsQT/xFNzzW9tMiR5npv8deQLLeQCfn82uWlV ez8Z1vcsgSGsCcw+hRHqFW6YqsVNJcQuTj2X0wShWpF9lZ8rD+nEImWOWCcrVwJdsgWOh3 6WddxB/GlvmimQsLOsTjmigq8FNImv8N0H+CItmOkvhPbH9a8RtewUCiZmVOekkB056p/O /GV5slDSyll261lCG3phUlJZx6wbRzjlcYG4MVzyEu7HfsyZJDWktytNZcOeXA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733879963; a=rsa-sha256; cv=none; b=YlYC/FLckKYTMCkh2ILrOslsqa19J70aBTRlmiXlTNl0VFATxXqGpHwC39rUqfRcn4jMaC r6PIvGMgeYH1i1ShkDEWSx0MfCM/kyWMAtt8M+7d576UKyEAICdDkkTqjXXvi7FarDA1eP GlYazbc9njZmwd6PwfT8z3xu0vZ2LSuMdaZG0zusb9jQdtSHx0XdyEdlMC5SmeH2MPfD/u ucEJpHqk9T4gC2c0/5xsnIPDO8z3jDFtMXYUZdbsJWY7A7mJqP8X93MgPtV3EJ1x0BAnNH v7Qzm11NzEAkUoN+PrPAqA2GwsIMZqKD4OoR1oTfwLkiFogCS2acrlfc9MDu0g== 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 4Y7HnR2mCmzmnc; Wed, 11 Dec 2024 01:19:23 +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 4BB1JN3H007323; Wed, 11 Dec 2024 01:19:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BB1JNlV007320; Wed, 11 Dec 2024 01:19:23 GMT (envelope-from git) Date: Wed, 11 Dec 2024 01:19:23 GMT Message-Id: <202412110119.4BB1JNlV007320@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: 636d377264f5 - main - release: vmimage: setup the default BE properly 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 636d377264f51e3dd33bd7f33ebf03e2e148d40d Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=636d377264f51e3dd33bd7f33ebf03e2e148d40d commit 636d377264f51e3dd33bd7f33ebf03e2e148d40d Author: Kyle Evans AuthorDate: 2024-12-11 01:19:08 +0000 Commit: Kyle Evans CommitDate: 2024-12-11 01:19:08 +0000 release: vmimage: setup the default BE properly All of the BE datasets need to be set canmount=noauto so that creating a new BE and switching to it can actually work. With the current setup, the zfs rc script will mount the `default` BE over whichever new BE is activated once it runs. Reported by: andrew Reviewed by: andrew, re (cperciva), imp, markj Differential Revision: https://reviews.freebsd.org/D48017 --- release/tools/vmimage.subr | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/tools/vmimage.subr b/release/tools/vmimage.subr index 5d98b8990705..223ef928e83c 100644 --- a/release/tools/vmimage.subr +++ b/release/tools/vmimage.subr @@ -187,7 +187,7 @@ buildfs() { -o poolname=zroot -o bootfs=zroot/ROOT/default -o rootpath=/ \ -o fs=zroot\;mountpoint=none \ -o fs=zroot/ROOT\;mountpoint=none \ - -o fs=zroot/ROOT/default\;mountpoint=/ \ + -o fs=zroot/ROOT/default\;mountpoint=/\;canmount=noauto \ -o fs=zroot/home\;mountpoint=/home \ -o fs=zroot/tmp\;mountpoint=/tmp\;exec=on\;setuid=off \ -o fs=zroot/usr\;mountpoint=/usr\;canmount=off \ From nobody Wed Dec 11 01:24:46 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 4Y7Hvg1bLwz5g8MS; Wed, 11 Dec 2024 01:24:47 +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 4Y7Hvg0zM4z3y0B; Wed, 11 Dec 2024 01:24:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733880287; 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=vnNz7sP0HSxn+pBv9WWslwWXrOaDJB4ADJQYJnKEr7s=; b=d4f2pg2DqzZKbS/0voNcx+eZ8Lm2nHbhNzpHAm9Pzl9KQlwC4k1l9TQBM52MW+A3ZwWVMs DEX4Cc11E5hLLhHxNqCOHb9HKk3Nqgnm0U65kDo+xCnc4p1fF2R4iW6mk0a1CwhcgOtIzQ flFYbiGhq5tvAjh6lcx55xbXd1VoLZ0zp+RrFDwUh3ept+oUQktiQN5dXhHhV2jvrpjbmJ N403gcXa2YRpMkGrvo//HZqxHrtl+2DZ1u/0FHZxJcWoxh2Cn92msAhT5V8eGGtXtSf+CL U/d19tlxY4QX1MnQ9VruWx3FbBsue6N2z0lbgkeefWBoif/zSxMuWfeGlT++ww== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733880287; 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=vnNz7sP0HSxn+pBv9WWslwWXrOaDJB4ADJQYJnKEr7s=; b=N6esEntRORruA4KqdMQqhYxPzy4pvLQUDXijHdXE4ky6R3Evh/cA/Gi6tq2xzmB3couXZX ZyUHNvoVpMFCXSiwM2gyeY0UPmr2LzR6FLw7yUtpg5+IeFvhDA5c/TUNjeVODlucu6YeJK s7zy0kUnuDfmcKBgOvDQCGYY7yCg+tn33enOVJFiSK0M/MOYFvafBoTXQm6iVUskF73mNA KlP2l8RVrFwmCxmWt8wYv/iT1J+O5//MmqHsEha1bbM9M1UnD/w/SgJgcGJdad0bg+2Xi5 FrB9kFlaI2Dr25oIMp6LF5LnImGs863Xvh10nfQmJVTsARvgLsrZ3uCkuSypKw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733880287; a=rsa-sha256; cv=none; b=gZmvnQqolL3jktaPaIzCqFnkBYKGLVvzSH7XdUJ5O7MVPo1yJc5wqR/fk0udLFcIZMxaLM FpkNz1x4rU5p5ZcfYMl6H2OvC8IhrfLtd49kmje908GkzAgIDnoKiOmvUXxINqSgWyu2eu KxLgk71hd0BQnSSiSALZ5YpN9LyUIst6Zt82qQ4tHziGWYIu6fTu/b5rtKcFy+8wH6XVcb aYPh6QA+b9vDeecTeYNfe4xHaoB5NZotBb16zm2E7gqOOS7KXk+rJSAL1fdb9CPf3GR4LO Ji93L7BEfug8VaEX6/moCswIvImbG5zX+mxn2wNRxzELhREJy46siPtCgAeG+A== 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 4Y7Hvg0LGsznHB; Wed, 11 Dec 2024 01:24:47 +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 4BB1OkaP024214; Wed, 11 Dec 2024 01:24:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BB1OkEh024211; Wed, 11 Dec 2024 01:24:46 GMT (envelope-from git) Date: Wed, 11 Dec 2024 01:24:46 GMT Message-Id: <202412110124.4BB1OkEh024211@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: 51f3d0874f62 - main - usb: serial: propagate errors from ucom_queue_command() 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 51f3d0874f6216907c8971c4af9d6be6c93edf7b Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=51f3d0874f6216907c8971c4af9d6be6c93edf7b commit 51f3d0874f6216907c8971c4af9d6be6c93edf7b Author: Kyle Evans AuthorDate: 2024-12-11 01:23:10 +0000 Commit: Kyle Evans CommitDate: 2024-12-11 01:23:10 +0000 usb: serial: propagate errors from ucom_queue_command() There's only one error that we can get back right now, but future changes will add some more cases that we need to watch out for. Start by returning errors and propagating them back. Reviewed by: kib Differential Revision: https://reviews.freebsd.org/D47950 --- sys/dev/usb/serial/usb_serial.c | 49 ++++++++++++++++++++++++++--------------- 1 file changed, 31 insertions(+), 18 deletions(-) diff --git a/sys/dev/usb/serial/usb_serial.c b/sys/dev/usb/serial/usb_serial.c index 300438010c05..11a2e1078a67 100644 --- a/sys/dev/usb/serial/usb_serial.c +++ b/sys/dev/usb/serial/usb_serial.c @@ -151,7 +151,7 @@ static int ucom_unit_alloc(void); static void ucom_unit_free(int); static int ucom_attach_tty(struct ucom_super_softc *, struct ucom_softc *); static void ucom_detach_tty(struct ucom_super_softc *, struct ucom_softc *); -static void ucom_queue_command(struct ucom_softc *, +static int ucom_queue_command(struct ucom_softc *, usb_proc_callback_t *, struct termios *pt, struct usb_proc_msg *t0, struct usb_proc_msg *t1); static void ucom_shutdown(struct ucom_softc *); @@ -592,7 +592,7 @@ ucom_set_usb_mode(struct ucom_super_softc *ssc, enum usb_hc_mode usb_mode) } } -static void +static int ucom_queue_command(struct ucom_softc *sc, usb_proc_callback_t *fn, struct termios *pt, struct usb_proc_msg *t0, struct usb_proc_msg *t1) @@ -604,7 +604,7 @@ ucom_queue_command(struct ucom_softc *sc, if (usb_proc_is_gone(&ssc->sc_tq)) { DPRINTF("proc is gone\n"); - return; /* nothing to do */ + return (ENXIO); /* nothing to do */ } /* * NOTE: The task cannot get executed before we drop the @@ -637,6 +637,8 @@ ucom_queue_command(struct ucom_softc *sc, */ if (fn == ucom_cfg_start_transfers) sc->sc_last_start_xfer = &task->hdr; + + return (0); } static void @@ -760,9 +762,8 @@ ucom_open(struct tty *tp) * example if the device is not present: */ error = (sc->sc_callback->ucom_pre_open) (sc); - if (error) { - return (error); - } + if (error != 0) + goto out; } sc->sc_flag |= UCOM_FLAG_HL_READY; @@ -782,14 +783,18 @@ ucom_open(struct tty *tp) sc->sc_jitterbuf_in = 0; sc->sc_jitterbuf_out = 0; - ucom_queue_command(sc, ucom_cfg_open, NULL, + error = ucom_queue_command(sc, ucom_cfg_open, NULL, &sc->sc_open_task[0].hdr, &sc->sc_open_task[1].hdr); + if (error != 0) + goto out; /* Queue transfer enable command last */ - ucom_queue_command(sc, ucom_cfg_start_transfers, NULL, - &sc->sc_start_task[0].hdr, + error = ucom_queue_command(sc, ucom_cfg_start_transfers, NULL, + &sc->sc_start_task[0].hdr, &sc->sc_start_task[1].hdr); + if (error != 0) + goto out; if (sc->sc_tty == NULL || (sc->sc_tty->t_termios.c_cflag & CNO_RTSDTR) == 0) ucom_modem(tp, SER_DTR | SER_RTS, 0); @@ -800,7 +805,8 @@ ucom_open(struct tty *tp) ucom_status_change(sc); - return (0); +out: + return (error); } static void @@ -836,7 +842,7 @@ ucom_close(struct tty *tp) } ucom_shutdown(sc); - ucom_queue_command(sc, ucom_cfg_close, NULL, + (void)ucom_queue_command(sc, ucom_cfg_close, NULL, &sc->sc_close_task[0].hdr, &sc->sc_close_task[1].hdr); @@ -1077,9 +1083,12 @@ ucom_line_state(struct ucom_softc *sc, sc->sc_pls_set |= set_bits; sc->sc_pls_clr |= clear_bits; - /* defer driver programming */ - ucom_queue_command(sc, ucom_cfg_line_state, NULL, - &sc->sc_line_state_task[0].hdr, + /* + * defer driver programming - we don't propagate any error from + * this call because we'll catch such errors further up the call stack. + */ + (void)ucom_queue_command(sc, ucom_cfg_line_state, NULL, + &sc->sc_line_state_task[0].hdr, &sc->sc_line_state_task[1].hdr); } @@ -1236,7 +1245,7 @@ ucom_status_change(struct ucom_softc *sc) } DPRINTF("\n"); - ucom_queue_command(sc, ucom_cfg_status_change, NULL, + (void)ucom_queue_command(sc, ucom_cfg_status_change, NULL, &sc->sc_status_task[0].hdr, &sc->sc_status_task[1].hdr); } @@ -1310,14 +1319,18 @@ ucom_param(struct tty *tp, struct termios *t) sc->sc_flag &= ~UCOM_FLAG_GP_DATA; /* Queue baud rate programming command first */ - ucom_queue_command(sc, ucom_cfg_param, t, + error = ucom_queue_command(sc, ucom_cfg_param, t, &sc->sc_param_task[0].hdr, &sc->sc_param_task[1].hdr); + if (error != 0) + goto done; /* Queue transfer enable command last */ - ucom_queue_command(sc, ucom_cfg_start_transfers, NULL, - &sc->sc_start_task[0].hdr, + error = ucom_queue_command(sc, ucom_cfg_start_transfers, NULL, + &sc->sc_start_task[0].hdr, &sc->sc_start_task[1].hdr); + if (error != 0) + goto done; if (t->c_cflag & CRTS_IFLOW) { sc->sc_flag |= UCOM_FLAG_RTS_IFLOW; From nobody Wed Dec 11 01:24:48 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 4Y7Hvh2fW8z5g8VY; Wed, 11 Dec 2024 01:24:48 +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 4Y7Hvh1gpRz3y56; Wed, 11 Dec 2024 01:24:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733880288; 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=KBC4NR0OAygqDBRYRdjnlgu2pgV84rzBZ4UFb0eKgcY=; b=R2J0prx2RXTqs8DZlllNX2qu3aCc2gDueKm9+n3pYDlV++WbEQ0L2D/CkXJqXR09AUhGnD T+im4HK3VoMuDp+aDWour9LSqxGX1r4sJqXlna45xfJQF98QQuYydnpyM+t10oX4JCvuqb 6Hc1ow5+iElFcjzxLRTLwIjkALO9m8WuzTG+gjAp4v61e2eBsNoDVXKjIp3QCtyvMZrLUa 4km885fIRnwDF5pm2iiRpyzZ17nA9dueiEql/TClZ5FcMgX92/75D6J1ry75p6kGpwolHl L17U5b5Sg69wbuy5RkHykyL9eh13CB3RIBtVmCUsvEsigGPx460H3LldUk/EsQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733880288; 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=KBC4NR0OAygqDBRYRdjnlgu2pgV84rzBZ4UFb0eKgcY=; b=yU6wXa1vt5Z7GRtfH5/v1uDkVjCg0fN4kY5jMynUxCv56sQWLpNhlJvwlJl+HOsWGG4U9V p+zf1AdjRWuPb2cJ8l0EIIJeL/hfF3knoYAkuhZrdozkr5aDLGQ53X7sWvzJ6mDqo2mU19 NXBdE0OqZ44aLUCUOovfKoWEtkJ70VG0Awm710qFaJG8zzankGfr3jO9oxVMEfVSoKKB06 0XRAu4IIqTFl4H2VXLuJN7UBHTTjfjYC50aMz+OxUHy1I1IKiypxLDTKlh+gefaLcFf0n0 8nAbkGIPj6xSSvhVoJ0WXmACfDCTQtw3PrXSNcn/R2EOQpUhE2puXX+4KNUDOQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733880288; a=rsa-sha256; cv=none; b=N16TWLWpX/0QmINSWQ07uaNcpgwgDj+JpnsgbT35yddNxdYkg5rbjLqtbFfgnRoheBfKty xWAh6+UiCLOh4Dlz1coYMoMgLq/JDNkV5zUGgoBF7rjnblDxZt/DM4UKY/2vHtzm9m2qtb mqqAMZkB+0OVriItqQv39aWDGR9+K+418n6xUW3OtiC6e6p3udSsNsf8dfDlfiTAeyLi78 gXEjVUgCMh3xXN8vfTARG4wAyZTbXyrP8rqT6JVDpbXe6EkpUlc2mnzsVXNtbIINXHrJas BdM4USdLB0diu05ke9Gyg0kzwAQaml0G1rCHL8o2/0eH+S3iZv81rClJ8W7UaA== 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 4Y7Hvh1HmGznHC; Wed, 11 Dec 2024 01:24:48 +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 4BB1Omph024268; Wed, 11 Dec 2024 01:24:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BB1OmRK024265; Wed, 11 Dec 2024 01:24:48 GMT (envelope-from git) Date: Wed, 11 Dec 2024 01:24:48 GMT Message-Id: <202412110124.4BB1OmRK024265@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: 729eb176a465 - main - usb: serial: allow the open/close sleep to be interruptible 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 729eb176a465cedc55c5980f116d87be592421f1 Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=729eb176a465cedc55c5980f116d87be592421f1 commit 729eb176a465cedc55c5980f116d87be592421f1 Author: Kyle Evans AuthorDate: 2024-12-11 01:23:10 +0000 Commit: Kyle Evans CommitDate: 2024-12-11 01:23:10 +0000 usb: serial: allow the open/close sleep to be interruptible ucom_queue_command will issue commands for open/close, then wait on them to be finished. In the spirit of playing it safe, allow ucom_queue_command's wait to be interrupted in case the usb process gets jammed up waiting on the hardware -- we can at least recover the user thread that initiated it, even if we can't recover the usb process. Reviewed by: imp, kib Differential Revision: https://reviews.freebsd.org/D47951 --- sys/dev/usb/serial/usb_serial.c | 14 +++++++-- sys/dev/usb/usb_process.c | 69 ++++++++++++++++++++++++++++++++--------- sys/dev/usb/usb_process.h | 1 + sys/dev/usb/usbdi.h | 2 ++ 4 files changed, 69 insertions(+), 17 deletions(-) diff --git a/sys/dev/usb/serial/usb_serial.c b/sys/dev/usb/serial/usb_serial.c index 11a2e1078a67..30a0c6203086 100644 --- a/sys/dev/usb/serial/usb_serial.c +++ b/sys/dev/usb/serial/usb_serial.c @@ -599,6 +599,7 @@ ucom_queue_command(struct ucom_softc *sc, { struct ucom_super_softc *ssc = sc->sc_super; struct ucom_param_task *task; + int error; UCOM_MTX_ASSERT(sc, MA_OWNED); @@ -628,8 +629,15 @@ ucom_queue_command(struct ucom_softc *sc, /* * Closing or opening the device should be synchronous. */ - if (fn == ucom_cfg_close || fn == ucom_cfg_open) - usb_proc_mwait(&ssc->sc_tq, t0, t1); + if (fn == ucom_cfg_close || fn == ucom_cfg_open) { + error = usb_proc_mwait_sig(&ssc->sc_tq, t0, t1); + + /* usb_proc_mwait_sig may have dropped the tty lock. */ + if (error == 0 && sc->sc_tty != NULL && tty_gone(sc->sc_tty)) + error = ENXIO; + } else { + error = 0; + } /* * In case of multiple configure requests, @@ -638,7 +646,7 @@ ucom_queue_command(struct ucom_softc *sc, if (fn == ucom_cfg_start_transfers) sc->sc_last_start_xfer = &task->hdr; - return (0); + return (error); } static void diff --git a/sys/dev/usb/usb_process.c b/sys/dev/usb/usb_process.c index d88de92336f2..4507c999f50a 100644 --- a/sys/dev/usb/usb_process.c +++ b/sys/dev/usb/usb_process.c @@ -361,25 +361,21 @@ usb_proc_is_gone(struct usb_process *up) return (0); } -/*------------------------------------------------------------------------* - * usb_proc_mwait - * - * This function will return when the USB process message pointed to - * by "pm" is no longer on a queue. This function must be called - * having "up->up_mtx" locked. - *------------------------------------------------------------------------*/ -void -usb_proc_mwait(struct usb_process *up, void *_pm0, void *_pm1) +static int +usb_proc_mwait_impl(struct usb_process *up, void *_pm0, void *_pm1, + bool interruptible) { struct usb_proc_msg *pm0 = _pm0; struct usb_proc_msg *pm1 = _pm1; + int error; /* check if gone */ if (up->up_gone) - return; + return (ENXIO); USB_MTX_ASSERT(up->up_mtx, MA_OWNED); + error = 0; if (up->up_curtd == curthread) { /* Just remove the messages from the queue. */ if (pm0->pm_qentry.tqe_prev) { @@ -391,14 +387,59 @@ usb_proc_mwait(struct usb_process *up, void *_pm0, void *_pm1) pm1->pm_qentry.tqe_prev = NULL; } } else - while (pm0->pm_qentry.tqe_prev || - pm1->pm_qentry.tqe_prev) { + while (error == 0 && (pm0->pm_qentry.tqe_prev || + pm1->pm_qentry.tqe_prev)) { /* check if config thread is gone */ if (up->up_gone) - break; + return (ENXIO); up->up_dsleep = 1; - cv_wait(&up->up_drain, up->up_mtx); + if (interruptible) { + error = cv_wait_sig(&up->up_drain, up->up_mtx); + + /* + * The fact that we were interrupted doesn't + * matter if our goal was accomplished anyways. + */ + if (error != 0 && !USB_PROC_MSG_ENQUEUED(pm0) && + !USB_PROC_MSG_ENQUEUED(pm1)) + error = 0; + } else { + cv_wait(&up->up_drain, up->up_mtx); + } } + + if (error == ERESTART) + error = EINTR; + return (error); +} + +/*------------------------------------------------------------------------* + * usb_proc_mwait + * + * This function will return when the USB process message pointed to + * by "pm" is no longer on a queue. This function must be called + * having "up->up_mtx" locked. + *------------------------------------------------------------------------*/ +void +usb_proc_mwait(struct usb_process *up, void *_pm0, void *_pm1) +{ + + (void)usb_proc_mwait_impl(up, _pm0, _pm1, false); +} + +/*------------------------------------------------------------------------* + * usb_proc_mwait_sig + * + * This function will return when the USB process message pointed to + * by "pm" is no longer on a queue. This function must be called + * having "up->up_mtx" locked. This version of usb_proc_mwait is + * interruptible. + *------------------------------------------------------------------------*/ +int +usb_proc_mwait_sig(struct usb_process *up, void *_pm0, void *_pm1) +{ + + return (usb_proc_mwait_impl(up, _pm0, _pm1, true)); } /*------------------------------------------------------------------------* diff --git a/sys/dev/usb/usb_process.h b/sys/dev/usb/usb_process.h index 6a8ac0acda33..745d214d2106 100644 --- a/sys/dev/usb/usb_process.h +++ b/sys/dev/usb/usb_process.h @@ -76,6 +76,7 @@ int usb_proc_create(struct usb_process *up, struct mtx *p_mtx, const char *pmesg, uint8_t prio); void usb_proc_drain(struct usb_process *up); void usb_proc_mwait(struct usb_process *up, void *pm0, void *pm1); +int usb_proc_mwait_sig(struct usb_process *up, void *pm0, void *pm1); void usb_proc_free(struct usb_process *up); void *usb_proc_msignal(struct usb_process *up, void *pm0, void *pm1); void usb_proc_rewakeup(struct usb_process *up); diff --git a/sys/dev/usb/usbdi.h b/sys/dev/usb/usbdi.h index 5192591281f4..08d130aa2868 100644 --- a/sys/dev/usb/usbdi.h +++ b/sys/dev/usb/usbdi.h @@ -525,6 +525,8 @@ struct usb_proc_msg { usb_size_t pm_num; }; +#define USB_PROC_MSG_ENQUEUED(msg) ((msg)->pm_qentry.tqe_prev != NULL) + #define USB_FIFO_TX 0 #define USB_FIFO_RX 1 From nobody Wed Dec 11 01:24: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 4Y7Hvj4wzCz5g8MW; Wed, 11 Dec 2024 01:24: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 4Y7Hvj3WH5z3xcV; Wed, 11 Dec 2024 01:24:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733880289; 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=aUiweBJLG0+TaHKPCfXYryh4ImCJv8jduWpl+MWioso=; b=LPST/vz8AckybF2qTs64ziIO65nrgMGzVgvIzOpsh2rnu0JfDvrJ/Rfv12cc0ZHFCc/T26 Po4Bjj30a72mkrE8FIic3SF4x83o9vEUr4sQKA3UUVB4QAYaET1xQT6jHTQpDADbzxSW5i IWbcCd+zrHEBfTSlywIz3QjgtQjFKeiPmHYrDj3SRzSzFV8LUd3Kpm96TaVJKv5fPK6wL4 claFUzjJr0Tv/NdZrt45vVUwXbQUAa5rMdxzRUX2540v6KkZ+dDdVMX5v6CFNiTzS+bksi I2HPsbVL6cHLea27r+AB8ga/Cle0nSbP3FyVT3RMnBnuPkvvKmGkcYspZ5wuNA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733880289; 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=aUiweBJLG0+TaHKPCfXYryh4ImCJv8jduWpl+MWioso=; b=Gt0ZyLAskgwmHaTcr8zpOIKxQrIvOmqLSjEF2dLaKnxqPhQOeif5mjRMet44TltFY7LdzT dr3bT0D2+6QkpCvi4eJVim0Gbz3eNdDAlVFw+D9xUMyGweBYbV2QQARXETen0bKBDbcxNJ 02i1SRmZiAB+p95EAbUkkXto9zVgDddgYs2ogv08eDY2TnBazXNHncLA7pwzyqW8xBuclI kBoSICigNUGBSPtOugGbCrKQJC+Nlg4DssLQ+JhvewrO8hlb+8qH0Bzz419H1A3qtSEEXD 8CrQdDwxnhLnSkVaJ47b4w2nSdGjqdnfiq4yOYaTPshhncYRZcPvz/U8JRpHdA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733880289; a=rsa-sha256; cv=none; b=H3D1HeX5icsfVwF926cNCIfeF8FIldZa/giQe5Lnd69gTDejmVXrIvolGZ3AhOtn6IAo2Y tSQMIYGal5MfoPQ7anRXYAVPSDe5G7Y+4B60rFThvprRlOV3D6E0O7QTHHA7WVgBGMawa2 TPQq3v18Hd/K7cgsNkdTPgvSTc+cyVf7Jjwac7iQWMw0T13TBalfytI55rLMqWyD0T4xBO KA54XPGcHVq0QCrnjESY2b8jtpQu1Jgxbp/DNs+zsD2f3o24XU7DaH3zekQ4FdBTiaegmg s2Ux4RelrV1lFt9ggriPVYTRUWDuriI8Wqyqph9+tMfgGXp87n5qB7TqbFlm+w== 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 4Y7Hvj2LWtznVN; Wed, 11 Dec 2024 01:24: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 4BB1OnsT024329; Wed, 11 Dec 2024 01:24:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BB1OnwP024326; Wed, 11 Dec 2024 01:24:49 GMT (envelope-from git) Date: Wed, 11 Dec 2024 01:24:49 GMT Message-Id: <202412110124.4BB1OnwP024326@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: 36a80f426435 - main - usb: serial: make more commands execute synchronously 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: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 36a80f4264350a2f4f0686eb91ae7f5943d40327 Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=36a80f4264350a2f4f0686eb91ae7f5943d40327 commit 36a80f4264350a2f4f0686eb91ae7f5943d40327 Author: Kyle Evans AuthorDate: 2024-12-11 01:23:10 +0000 Commit: Kyle Evans CommitDate: 2024-12-11 01:23:41 +0000 usb: serial: make more commands execute synchronously The termios layer wants some level of guarantee that we've actually submitted param changes to the hardware when our functions return, so we need to do a little more waiting to avoid violating those guarantees. This is especially important as some hardware has some minimum timing specifications around this stuff, and without being less asynchronous the software dealing with these devices can't reasonably operate the hardware without more excessive delays than they should need. More specifically, we make sure that: - The command to start transfers is finished before we toggle DTR/RTS - The status_change command finishes before we return, which may change some fields in the softc that we need for a subsequent call into usb_serial - cfg_param finishes before we re-enable transfers, and we ensure that RTS is appropriately toggled before we return to userland This has been observed to fix some flakiness in connecting to some ESP32 devices. Tested by: kenrap from Libera Reviewed by: imp, kib Differential Revision: https://reviews.freebsd.org/D47952 --- sys/dev/usb/serial/usb_serial.c | 69 +++++++++++++++++++++++++++++++++-------- 1 file changed, 56 insertions(+), 13 deletions(-) diff --git a/sys/dev/usb/serial/usb_serial.c b/sys/dev/usb/serial/usb_serial.c index 30a0c6203086..dfae051ecfd6 100644 --- a/sys/dev/usb/serial/usb_serial.c +++ b/sys/dev/usb/serial/usb_serial.c @@ -153,7 +153,7 @@ static int ucom_attach_tty(struct ucom_super_softc *, struct ucom_softc *); static void ucom_detach_tty(struct ucom_super_softc *, struct ucom_softc *); static int ucom_queue_command(struct ucom_softc *, usb_proc_callback_t *, struct termios *pt, - struct usb_proc_msg *t0, struct usb_proc_msg *t1); + struct usb_proc_msg *t0, struct usb_proc_msg *t1, bool wait); static void ucom_shutdown(struct ucom_softc *); static void ucom_ring(struct ucom_softc *, uint8_t); static void ucom_break(struct ucom_softc *, uint8_t); @@ -592,10 +592,43 @@ ucom_set_usb_mode(struct ucom_super_softc *ssc, enum usb_hc_mode usb_mode) } } +static void +ucom_command_barrier_cb(struct usb_proc_msg *msg __unused) +{ + /* NOP */ +} + +/* + * ucom_command_barrier inserts a dummy task and waits for it so that we can be + * certain that previously enqueued tasks are finished before returning back to + * the tty layer. + */ +static int +ucom_command_barrier(struct ucom_softc *sc) +{ + struct ucom_super_softc *ssc = sc->sc_super; + struct usb_proc_msg dummy = { .pm_callback = ucom_command_barrier_cb }; + struct usb_proc_msg *task; + int error; + + UCOM_MTX_ASSERT(sc, MA_OWNED); + + if (usb_proc_is_gone(&ssc->sc_tq)) { + DPRINTF("proc is gone\n"); + return (ENXIO); /* nothing to do */ + } + + task = usb_proc_msignal(&ssc->sc_tq, &dummy, &dummy); + error = usb_proc_mwait_sig(&ssc->sc_tq, task, task); + if (error == 0 && sc->sc_tty != NULL && tty_gone(sc->sc_tty)) + error = ENXIO; + return (error); +} + static int ucom_queue_command(struct ucom_softc *sc, usb_proc_callback_t *fn, struct termios *pt, - struct usb_proc_msg *t0, struct usb_proc_msg *t1) + struct usb_proc_msg *t0, struct usb_proc_msg *t1, bool wait) { struct ucom_super_softc *ssc = sc->sc_super; struct ucom_param_task *task; @@ -629,7 +662,7 @@ ucom_queue_command(struct ucom_softc *sc, /* * Closing or opening the device should be synchronous. */ - if (fn == ucom_cfg_close || fn == ucom_cfg_open) { + if (wait) { error = usb_proc_mwait_sig(&ssc->sc_tq, t0, t1); /* usb_proc_mwait_sig may have dropped the tty lock. */ @@ -793,14 +826,17 @@ ucom_open(struct tty *tp) error = ucom_queue_command(sc, ucom_cfg_open, NULL, &sc->sc_open_task[0].hdr, - &sc->sc_open_task[1].hdr); + &sc->sc_open_task[1].hdr, true); if (error != 0) goto out; - /* Queue transfer enable command last */ + /* + * Queue transfer enable command last, we'll have a barrier later so we + * don't need to wait on this to complete specifically. + */ error = ucom_queue_command(sc, ucom_cfg_start_transfers, NULL, &sc->sc_start_task[0].hdr, - &sc->sc_start_task[1].hdr); + &sc->sc_start_task[1].hdr, true); if (error != 0) goto out; @@ -813,6 +849,7 @@ ucom_open(struct tty *tp) ucom_status_change(sc); + error = ucom_command_barrier(sc); out: return (error); } @@ -852,7 +889,7 @@ ucom_close(struct tty *tp) (void)ucom_queue_command(sc, ucom_cfg_close, NULL, &sc->sc_close_task[0].hdr, - &sc->sc_close_task[1].hdr); + &sc->sc_close_task[1].hdr, true); sc->sc_flag &= ~(UCOM_FLAG_HL_READY | UCOM_FLAG_RTS_IFLOW); @@ -933,11 +970,15 @@ ucom_ioctl(struct tty *tp, u_long cmd, caddr_t data, struct thread *td) #endif case TIOCSBRK: ucom_break(sc, 1); - error = 0; + error = ucom_command_barrier(sc); + if (error == ENXIO) + error = ENODEV; break; case TIOCCBRK: ucom_break(sc, 0); - error = 0; + error = ucom_command_barrier(sc); + if (error == ENXIO) + error = ENODEV; break; default: if (sc->sc_callback->ucom_ioctl) { @@ -1097,7 +1138,7 @@ ucom_line_state(struct ucom_softc *sc, */ (void)ucom_queue_command(sc, ucom_cfg_line_state, NULL, &sc->sc_line_state_task[0].hdr, - &sc->sc_line_state_task[1].hdr); + &sc->sc_line_state_task[1].hdr, false); } static void @@ -1255,7 +1296,7 @@ ucom_status_change(struct ucom_softc *sc) (void)ucom_queue_command(sc, ucom_cfg_status_change, NULL, &sc->sc_status_task[0].hdr, - &sc->sc_status_task[1].hdr); + &sc->sc_status_task[1].hdr, true); } static void @@ -1329,14 +1370,14 @@ ucom_param(struct tty *tp, struct termios *t) /* Queue baud rate programming command first */ error = ucom_queue_command(sc, ucom_cfg_param, t, &sc->sc_param_task[0].hdr, - &sc->sc_param_task[1].hdr); + &sc->sc_param_task[1].hdr, true); if (error != 0) goto done; /* Queue transfer enable command last */ error = ucom_queue_command(sc, ucom_cfg_start_transfers, NULL, &sc->sc_start_task[0].hdr, - &sc->sc_start_task[1].hdr); + &sc->sc_start_task[1].hdr, true); if (error != 0) goto done; @@ -1346,6 +1387,8 @@ ucom_param(struct tty *tp, struct termios *t) sc->sc_flag &= ~UCOM_FLAG_RTS_IFLOW; ucom_modem(tp, SER_RTS, 0); } + + error = ucom_command_barrier(sc); done: if (error) { if (opened) { From nobody Wed Dec 11 02:24:10 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 4Y7KDB4Lqdz5gD5g; Wed, 11 Dec 2024 02:24:10 +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 4Y7KDB3NRCz44pQ; Wed, 11 Dec 2024 02:24:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733883850; 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=i2J57g32Bbqv+m7O6p5SNxw2DKWfUUiZ4VG6+KkM3Vk=; b=ttn0fG+khayFLjJBWEnhoRYn07+1GznEyilud8YaagrEeH+QY3x+H0TUNGhz2smPvSX7qA Ngdc/qhcBMwimPlJWLCJImLClPIe1bckcj8ABWJPv1xlrDpw0WBiTetQ7n1VVvjNJnfYmW YGOBjSPhJefkud93+Z2B09V1ok77fVHkIWM9A/Pb+Cabk0MNgJJQV2p/+ABZEsMOme2uSM mvGnb1AdAHauOx9392mwJYBmH2EzdkuDMuoblMHyrW5M90VvxqT5wygJ42vOehhLl4m6H9 nWK5KDjz4RKJ76p1GsyKadQA/CdhP19TFGz49+9O5gw6yvd8WKOPU+VIj8Nr0A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733883850; 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=i2J57g32Bbqv+m7O6p5SNxw2DKWfUUiZ4VG6+KkM3Vk=; b=duWnzGOsLR5Fm2LblT6EfhqlHTSJ+4tGbejcpaV2KAG9nSY5h9fyi+vJ57h3DK7dE/YZEF 6aDM2QMyPJV95GtJZet3dixbiNByaCetzcDww4AEiGtPqFEmf5ngFoiBM1v745r5tNzCgu sgfYfxPKHAKc/ej0UuldR7zxxBA+NXowQpLKEMQWmVzEo+OzAQk9WO6IQ35ZAO5VslcuSr GfihTcWcOsgaz/5pmxNa2wHSXW0r3Xf8+445CbsgJZ8rnfN3iVUgfDaynZ4FpigBo87iBo wpKIVS5RJ5CDgWBTsZrPbw1vbUtZlVjseAQzFCG1zR6uZj85I2/Oo8MshF4e6A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733883850; a=rsa-sha256; cv=none; b=W6R/ONul/rh2173LJRgyV/vCYyv4DU3rmecmaYWO19fYF8O2CYY1RniLGj53vShto1Rhcd GuZrAYqbcFyJgrGQuRD616cziviMsktzqpSAbG6fd/N4oeotKASiAPgqoPXkLb+pFmmXE6 0H1WvxEKKXh1ge5mR+KfOP6UmP6VmVvhjSVYo7Mm6RiRYmdH+ozWEVxe7nxh03C/duWATR vlU6IR/mdZqXXoRNJy0o+IgZG9HUpiZy0Be7s9dvtDZic/5zi/uI6pMOLGz9kApgjXvv3z rv+MOqh6XmzVy86xvCfSeXV9hIw9Wtl6rXSNn/ynbAzQBuvWTxVIF8i8QgM7pA== 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 4Y7KDB2hG3zpmY; Wed, 11 Dec 2024 02:24:10 +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 4BB2OAuY035552; Wed, 11 Dec 2024 02:24:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BB2OA3O035549; Wed, 11 Dec 2024 02:24:10 GMT (envelope-from git) Date: Wed, 11 Dec 2024 02:24:10 GMT Message-Id: <202412110224.4BB2OA3O035549@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: 70693a45381b - main - cxgbe tom: Restore support for zerocopy TCP receive for aio_read() 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: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 70693a45381b687e40ea30710aa38cb9f24b6b02 Auto-Submitted: auto-generated The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=70693a45381b687e40ea30710aa38cb9f24b6b02 commit 70693a45381b687e40ea30710aa38cb9f24b6b02 Author: John Baldwin AuthorDate: 2024-12-11 02:13:51 +0000 Commit: John Baldwin CommitDate: 2024-12-11 02:23:47 +0000 cxgbe tom: Restore support for zerocopy TCP receive for aio_read() The commit to introduce TCP_USE_DDP support had a couple of bugs that broke support for zerocopy receive via aio_read(). First, the length and offset arguments to mk_update_tcb_for_ddp() were reversed which prevented DDP from working. Second, the AIO state in the toep was initialized too late when the first aio_read() request was queued. Reported by: Harshavardhan Tanneru @ Chelsio Fixes: eba13bbc37ab cxgbe: Support TCP_USE_DDP on offloaded TOE connections MFC after: 1 week Sponsored by: Chelsio Communications --- sys/dev/cxgbe/tom/t4_ddp.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/sys/dev/cxgbe/tom/t4_ddp.c b/sys/dev/cxgbe/tom/t4_ddp.c index 529fc2a5b825..2fee8fa91dac 100644 --- a/sys/dev/cxgbe/tom/t4_ddp.c +++ b/sys/dev/cxgbe/tom/t4_ddp.c @@ -2653,8 +2653,8 @@ sbcopy: * which will keep it open and keep the TCP PCB attached until * after the job is completed. */ - wr = mk_update_tcb_for_ddp(sc, toep, db_idx, &ps->prsv, ps->len, - job->aio_received, ddp_flags, ddp_flags_mask); + wr = mk_update_tcb_for_ddp(sc, toep, db_idx, &ps->prsv, + job->aio_received, ps->len, ddp_flags, ddp_flags_mask); if (wr == NULL) { recycle_pageset(toep, ps); aio_ddp_requeue_one(toep, job); @@ -2820,6 +2820,14 @@ t4_aio_queue_ddp(struct socket *so, struct kaiocb *job) return (EOPNOTSUPP); } + if ((toep->ddp.flags & DDP_AIO) == 0) { + toep->ddp.flags |= DDP_AIO; + TAILQ_INIT(&toep->ddp.cached_pagesets); + TAILQ_INIT(&toep->ddp.aiojobq); + TASK_INIT(&toep->ddp.requeue_task, 0, aio_ddp_requeue_task, + toep); + } + /* * XXX: Think about possibly returning errors for ENOTCONN, * etc. Perhaps the caller would only queue the request @@ -2834,14 +2842,6 @@ t4_aio_queue_ddp(struct socket *so, struct kaiocb *job) TAILQ_INSERT_TAIL(&toep->ddp.aiojobq, job, list); toep->ddp.waiting_count++; - if ((toep->ddp.flags & DDP_AIO) == 0) { - toep->ddp.flags |= DDP_AIO; - TAILQ_INIT(&toep->ddp.cached_pagesets); - TAILQ_INIT(&toep->ddp.aiojobq); - TASK_INIT(&toep->ddp.requeue_task, 0, aio_ddp_requeue_task, - toep); - } - /* * Try to handle this request synchronously. If this has * to block because the task is running, it will just bail From nobody Wed Dec 11 08:17:28 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 4Y7T3r38srz5gbtx; Wed, 11 Dec 2024 08:17:28 +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 4Y7T3r2kzlz4c4g; Wed, 11 Dec 2024 08:17:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733905048; 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=/boujf6lk4ggu8hfwCtxADZSqsNh1i+3G7DM36XI9Zs=; b=Rir/RXvrFqALHlkb2eFL5G5mzF9CicpWHwhUeNOPfSXrF46StQNLvOwNJ+jKh1Vf/DYH7w Vh89drHc7+vWgUaEz2p4ksvwtAWwVOHh0Uj0TID/LvZk9VxSOdgPCNRdnNDKN3NodnHUM5 bt+PDvbeJ9D9zjBsth+ZwNxEUN8V1Sn2Wl2SiGO2//V+kpRfUZGDbK2DA5r7IayRlWIGWC Rcv+8wbR64wLOXVmJgIlOJx8ePDlbBGjXS29Dcdp0yi2l3kvYn0JB3OKgTmtWA2WN/M+q+ 5bY7Tm3nL18YTrJdKI0WX/ub9jOrTnPoR1q54NZ/VRDDCz/MCqvQ8/BbU434hA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733905048; 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=/boujf6lk4ggu8hfwCtxADZSqsNh1i+3G7DM36XI9Zs=; b=omh9oohhK2UbyTokyIseKc3OmCDhLTYUtCKfFVmTc7/HJTFtwa3QU9PSr6Rrd79zsaqOUH t1nd6t4XoxcfRuIwiIGAzBh2WBSVokzbZUyQbRP31om9AIv5IxPQYg/F2AblxEnS7ioGJb GXnuPqvqwWIziveI7xzVVbML0P3cbRxf7F+ou5M0ACA71JfJKS1ok0F4afkDkEZPiFfOr3 R7/lnWMNSv2ebZsRHp5GljCYtg9NA8sZuR4txD6rx9u+ry7g62uwuogWPceGvDOMIxc+qf ixaGVgsRGcPx1T+7sg5YezSxSXYv/ZiaRuTYwv+B6ZcgnTonskSDVrLKQCqjyw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733905048; a=rsa-sha256; cv=none; b=kQhHAFWQKDRdbdKJtz5bM/kd7WMszMLPXA/fzRfylynvzhwvHElWYqpJxn8L6tbm50sX57 6/2YzMrOMQq19AU/wtZ45pLv4p098fbBVm+lRmawhVGzBzsehfTbu6lQ5164ms289R+X+W tEeUgqE3397EoFfc4vBO1VZbax0faxgYwOeOjUGOdOsw/oxZVYs8EcViftddfqeNxS5tI8 AGEi9NlrXIFWk2SEXwbzVsvgwXlLOVYYqElAWoyPsk7yxp/Xj/srhjWCMJjb0hI7nckeP8 P8TyGIAnahQMEco0bv/fY76od8IQKzDkXvLQPB+Sro4fZrz7HKNuQqFb2HUstg== 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 4Y7T3r2CgGz10d3; Wed, 11 Dec 2024 08:17:28 +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 4BB8HSTn087433; Wed, 11 Dec 2024 08:17:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BB8HS3i087430; Wed, 11 Dec 2024 08:17:28 GMT (envelope-from git) Date: Wed, 11 Dec 2024 08:17:28 GMT Message-Id: <202412110817.4BB8HS3i087430@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dimitry Andric Subject: git: 4db4ed368037 - stable/14 - Merge llvm-project release/19.x llvmorg-19.1.5-0-gab4b5a2db582 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: dim X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 4db4ed368037a5faa6cd51c5aca9784ecb619042 Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=4db4ed368037a5faa6cd51c5aca9784ecb619042 commit 4db4ed368037a5faa6cd51c5aca9784ecb619042 Author: Dimitry Andric AuthorDate: 2024-12-06 17:26:41 +0000 Commit: Dimitry Andric CommitDate: 2024-12-11 08:16:53 +0000 Merge llvm-project release/19.x llvmorg-19.1.5-0-gab4b5a2db582 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/19.x llvmorg-19.1.5-0-gab4b5a2db582, a.k.a. 19.1.5 release. PR: 280562 MFC after: 3 days (cherry picked from commit 71ac745d76c3ba442e753daff1870893f272b29d) --- .../clang/lib/Driver/ToolChains/Hexagon.cpp | 7 ++- .../clang/lib/Interpreter/IncrementalExecutor.h | 2 +- .../clang/lib/Interpreter/Interpreter.cpp | 2 +- .../llvm-project/clang/lib/Interpreter/Wasm.cpp | 65 +++++++++++++++++----- contrib/llvm-project/clang/lib/Interpreter/Wasm.h | 1 + contrib/llvm-project/libcxx/include/__config | 2 +- contrib/llvm-project/lld/ELF/Arch/Hexagon.cpp | 2 +- .../llvm/include/llvm/Analysis/MemorySSAUpdater.h | 5 ++ .../llvm/lib/Analysis/MemorySSAUpdater.cpp | 13 ++++- .../llvm/lib/Analysis/ScalarEvolution.cpp | 4 +- .../llvm-project/llvm/lib/CodeGen/MachineLICM.cpp | 2 +- .../lib/Target/AArch64/AArch64FrameLowering.cpp | 34 ++++++----- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 19 ++++--- .../LoongArch/LoongArchExpandPseudoInsts.cpp | 2 +- .../lib/Target/LoongArch/LoongArchLSXInstrInfo.td | 6 +- .../MCTargetDesc/LoongArchMCTargetDesc.cpp | 2 +- .../llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp | 4 ++ .../llvm/lib/Target/Mips/MipsISelDAGToDAG.h | 3 + .../llvm/lib/Target/Mips/MipsMSAInstrInfo.td | 59 +++++++------------- .../llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp | 12 ++++ .../llvm/lib/Target/Mips/MipsSEISelDAGToDAG.h | 3 + .../llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp | 4 ++ .../Transforms/InstCombine/InstCombineCalls.cpp | 4 +- .../InstCombine/InstCombineSimplifyDemanded.cpp | 2 +- .../Transforms/Scalar/ConstraintElimination.cpp | 13 +++-- .../llvm/lib/Transforms/Scalar/LICM.cpp | 5 +- .../llvm/lib/Transforms/Utils/Local.cpp | 10 +++- .../lib/Transforms/Vectorize/SLPVectorizer.cpp | 16 ++++++ .../utils/TableGen/Common/CodeGenDAGPatterns.cpp | 8 +++ lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/clang/Basic/Version.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/lldb/Version/Version.inc | 6 +- lib/clang/include/llvm/Config/config.h | 4 +- lib/clang/include/llvm/Config/llvm-config.h | 4 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- 36 files changed, 225 insertions(+), 116 deletions(-) diff --git a/contrib/llvm-project/clang/lib/Driver/ToolChains/Hexagon.cpp b/contrib/llvm-project/clang/lib/Driver/ToolChains/Hexagon.cpp index 29781399cbab..be7851adecea 100644 --- a/contrib/llvm-project/clang/lib/Driver/ToolChains/Hexagon.cpp +++ b/contrib/llvm-project/clang/lib/Driver/ToolChains/Hexagon.cpp @@ -294,9 +294,10 @@ constructHexagonLinkArgs(Compilation &C, const JobAction &JA, bool IncStartFiles = !Args.hasArg(options::OPT_nostartfiles); bool IncDefLibs = !Args.hasArg(options::OPT_nodefaultlibs); bool UseG0 = false; - const char *Exec = Args.MakeArgString(HTC.GetLinkerPath()); - bool UseLLD = (llvm::sys::path::filename(Exec).equals_insensitive("ld.lld") || - llvm::sys::path::stem(Exec).equals_insensitive("ld.lld")); + bool UseLLD = false; + const char *Exec = Args.MakeArgString(HTC.GetLinkerPath(&UseLLD)); + UseLLD = UseLLD || llvm::sys::path::filename(Exec).ends_with("ld.lld") || + llvm::sys::path::stem(Exec).ends_with("ld.lld"); bool UseShared = IsShared && !IsStatic; StringRef CpuVer = toolchains::HexagonToolChain::GetTargetCPUVersion(Args); diff --git a/contrib/llvm-project/clang/lib/Interpreter/IncrementalExecutor.h b/contrib/llvm-project/clang/lib/Interpreter/IncrementalExecutor.h index 7954cde36588..dbd61f0b8b1e 100644 --- a/contrib/llvm-project/clang/lib/Interpreter/IncrementalExecutor.h +++ b/contrib/llvm-project/clang/lib/Interpreter/IncrementalExecutor.h @@ -56,7 +56,7 @@ public: virtual llvm::Error addModule(PartialTranslationUnit &PTU); virtual llvm::Error removeModule(PartialTranslationUnit &PTU); virtual llvm::Error runCtors() const; - llvm::Error cleanUp(); + virtual llvm::Error cleanUp(); llvm::Expected getSymbolAddress(llvm::StringRef Name, SymbolNameKind NameKind) const; diff --git a/contrib/llvm-project/clang/lib/Interpreter/Interpreter.cpp b/contrib/llvm-project/clang/lib/Interpreter/Interpreter.cpp index b4882ab5d223..985d0b7c0ef3 100644 --- a/contrib/llvm-project/clang/lib/Interpreter/Interpreter.cpp +++ b/contrib/llvm-project/clang/lib/Interpreter/Interpreter.cpp @@ -192,8 +192,8 @@ IncrementalCompilerBuilder::CreateCpp() { #ifdef __EMSCRIPTEN__ Argv.push_back("-target"); Argv.push_back("wasm32-unknown-emscripten"); - Argv.push_back("-pie"); Argv.push_back("-shared"); + Argv.push_back("-fvisibility=default"); #endif Argv.insert(Argv.end(), UserArgs.begin(), UserArgs.end()); diff --git a/contrib/llvm-project/clang/lib/Interpreter/Wasm.cpp b/contrib/llvm-project/clang/lib/Interpreter/Wasm.cpp index 1001410aa0f2..aa10b160ccf8 100644 --- a/contrib/llvm-project/clang/lib/Interpreter/Wasm.cpp +++ b/contrib/llvm-project/clang/lib/Interpreter/Wasm.cpp @@ -23,6 +23,31 @@ #include namespace lld { +enum Flavor { + Invalid, + Gnu, // -flavor gnu + MinGW, // -flavor gnu MinGW + WinLink, // -flavor link + Darwin, // -flavor darwin + Wasm, // -flavor wasm +}; + +using Driver = bool (*)(llvm::ArrayRef, llvm::raw_ostream &, + llvm::raw_ostream &, bool, bool); + +struct DriverDef { + Flavor f; + Driver d; +}; + +struct Result { + int retCode; + bool canRunAgain; +}; + +Result lldMain(llvm::ArrayRef args, llvm::raw_ostream &stdoutOS, + llvm::raw_ostream &stderrOS, llvm::ArrayRef drivers); + namespace wasm { bool link(llvm::ArrayRef args, llvm::raw_ostream &stdoutOS, llvm::raw_ostream &stderrOS, bool exitEarly, bool disableOutput); @@ -51,13 +76,14 @@ llvm::Error WasmIncrementalExecutor::addModule(PartialTranslationUnit &PTU) { llvm::TargetMachine *TargetMachine = Target->createTargetMachine( PTU.TheModule->getTargetTriple(), "", "", TO, llvm::Reloc::Model::PIC_); PTU.TheModule->setDataLayout(TargetMachine->createDataLayout()); - std::string OutputFileName = PTU.TheModule->getName().str() + ".wasm"; + std::string ObjectFileName = PTU.TheModule->getName().str() + ".o"; + std::string BinaryFileName = PTU.TheModule->getName().str() + ".wasm"; std::error_code Error; - llvm::raw_fd_ostream OutputFile(llvm::StringRef(OutputFileName), Error); + llvm::raw_fd_ostream ObjectFileOutput(llvm::StringRef(ObjectFileName), Error); llvm::legacy::PassManager PM; - if (TargetMachine->addPassesToEmitFile(PM, OutputFile, nullptr, + if (TargetMachine->addPassesToEmitFile(PM, ObjectFileOutput, nullptr, llvm::CodeGenFileType::ObjectFile)) { return llvm::make_error( "Wasm backend cannot produce object.", llvm::inconvertibleErrorCode()); @@ -69,27 +95,30 @@ llvm::Error WasmIncrementalExecutor::addModule(PartialTranslationUnit &PTU) { llvm::inconvertibleErrorCode()); } - OutputFile.close(); + ObjectFileOutput.close(); std::vector LinkerArgs = {"wasm-ld", - "-pie", + "-shared", "--import-memory", - "--no-entry", - "--export-all", "--experimental-pic", - "--no-export-dynamic", "--stack-first", - OutputFileName.c_str(), + "--allow-undefined", + ObjectFileName.c_str(), "-o", - OutputFileName.c_str()}; - int Result = - lld::wasm::link(LinkerArgs, llvm::outs(), llvm::errs(), false, false); - if (!Result) + BinaryFileName.c_str()}; + + const lld::DriverDef WasmDriver = {lld::Flavor::Wasm, &lld::wasm::link}; + std::vector WasmDriverArgs; + WasmDriverArgs.push_back(WasmDriver); + lld::Result Result = + lld::lldMain(LinkerArgs, llvm::outs(), llvm::errs(), WasmDriverArgs); + + if (Result.retCode) return llvm::make_error( "Failed to link incremental module", llvm::inconvertibleErrorCode()); void *LoadedLibModule = - dlopen(OutputFileName.c_str(), RTLD_NOW | RTLD_GLOBAL); + dlopen(BinaryFileName.c_str(), RTLD_NOW | RTLD_GLOBAL); if (LoadedLibModule == nullptr) { llvm::errs() << dlerror() << '\n'; return llvm::make_error( @@ -109,6 +138,12 @@ llvm::Error WasmIncrementalExecutor::runCtors() const { return llvm::Error::success(); } +llvm::Error WasmIncrementalExecutor::cleanUp() { + // Can't call cleanUp through IncrementalExecutor as it + // tries to deinitialize JIT which hasn't been initialized + return llvm::Error::success(); +} + WasmIncrementalExecutor::~WasmIncrementalExecutor() = default; -} // namespace clang +} // namespace clang \ No newline at end of file diff --git a/contrib/llvm-project/clang/lib/Interpreter/Wasm.h b/contrib/llvm-project/clang/lib/Interpreter/Wasm.h index b1fd88024f14..4632613326d3 100644 --- a/contrib/llvm-project/clang/lib/Interpreter/Wasm.h +++ b/contrib/llvm-project/clang/lib/Interpreter/Wasm.h @@ -28,6 +28,7 @@ public: llvm::Error addModule(PartialTranslationUnit &PTU) override; llvm::Error removeModule(PartialTranslationUnit &PTU) override; llvm::Error runCtors() const override; + llvm::Error cleanUp() override; ~WasmIncrementalExecutor() override; }; diff --git a/contrib/llvm-project/libcxx/include/__config b/contrib/llvm-project/libcxx/include/__config index 8b49c6b309a6..458910d6139e 100644 --- a/contrib/llvm-project/libcxx/include/__config +++ b/contrib/llvm-project/libcxx/include/__config @@ -27,7 +27,7 @@ // _LIBCPP_VERSION represents the version of libc++, which matches the version of LLVM. // Given a LLVM release LLVM XX.YY.ZZ (e.g. LLVM 17.0.1 == 17.00.01), _LIBCPP_VERSION is // defined to XXYYZZ. -# define _LIBCPP_VERSION 190104 +# define _LIBCPP_VERSION 190105 # define _LIBCPP_CONCAT_IMPL(_X, _Y) _X##_Y # define _LIBCPP_CONCAT(_X, _Y) _LIBCPP_CONCAT_IMPL(_X, _Y) diff --git a/contrib/llvm-project/lld/ELF/Arch/Hexagon.cpp b/contrib/llvm-project/lld/ELF/Arch/Hexagon.cpp index 56cf96fd1770..8bcd28309f8b 100644 --- a/contrib/llvm-project/lld/ELF/Arch/Hexagon.cpp +++ b/contrib/llvm-project/lld/ELF/Arch/Hexagon.cpp @@ -329,7 +329,7 @@ void Hexagon::relocate(uint8_t *loc, const Relocation &rel, case R_HEX_B22_PCREL: case R_HEX_GD_PLT_B22_PCREL: case R_HEX_PLT_B22_PCREL: - checkInt(loc, val, 22, rel); + checkInt(loc, val, 24, rel); or32le(loc, applyMask(0x1ff3ffe, val >> 2)); break; case R_HEX_B22_PCREL_X: diff --git a/contrib/llvm-project/llvm/include/llvm/Analysis/MemorySSAUpdater.h b/contrib/llvm-project/llvm/include/llvm/Analysis/MemorySSAUpdater.h index d4da3ef1146d..f598dedea75f 100644 --- a/contrib/llvm-project/llvm/include/llvm/Analysis/MemorySSAUpdater.h +++ b/contrib/llvm-project/llvm/include/llvm/Analysis/MemorySSAUpdater.h @@ -192,6 +192,11 @@ public: const BasicBlock *BB, MemorySSA::InsertionPlace Point); + MemoryAccess *createMemoryAccessInBB(Instruction *I, MemoryAccess *Definition, + const BasicBlock *BB, + MemorySSA::InsertionPlace Point, + bool CreationMustSucceed); + /// Create a MemoryAccess in MemorySSA before an existing MemoryAccess. /// /// See createMemoryAccessInBB() for usage details. diff --git a/contrib/llvm-project/llvm/lib/Analysis/MemorySSAUpdater.cpp b/contrib/llvm-project/llvm/lib/Analysis/MemorySSAUpdater.cpp index aa550f0b6a7b..94061c949b7f 100644 --- a/contrib/llvm-project/llvm/lib/Analysis/MemorySSAUpdater.cpp +++ b/contrib/llvm-project/llvm/lib/Analysis/MemorySSAUpdater.cpp @@ -1404,8 +1404,17 @@ void MemorySSAUpdater::changeToUnreachable(const Instruction *I) { MemoryAccess *MemorySSAUpdater::createMemoryAccessInBB( Instruction *I, MemoryAccess *Definition, const BasicBlock *BB, MemorySSA::InsertionPlace Point) { - MemoryUseOrDef *NewAccess = MSSA->createDefinedAccess(I, Definition); - MSSA->insertIntoListsForBlock(NewAccess, BB, Point); + return createMemoryAccessInBB(I, Definition, BB, Point, + /*CreationMustSucceed=*/true); +} + +MemoryAccess *MemorySSAUpdater::createMemoryAccessInBB( + Instruction *I, MemoryAccess *Definition, const BasicBlock *BB, + MemorySSA::InsertionPlace Point, bool CreationMustSucceed) { + MemoryUseOrDef *NewAccess = MSSA->createDefinedAccess( + I, Definition, /*Template=*/nullptr, CreationMustSucceed); + if (NewAccess) + MSSA->insertIntoListsForBlock(NewAccess, BB, Point); return NewAccess; } diff --git a/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp b/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp index 51cffac80876..412cfe73d3e5 100644 --- a/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp +++ b/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp @@ -6313,8 +6313,10 @@ APInt ScalarEvolution::getConstantMultipleImpl(const SCEV *S) { return getConstantMultiple(Z->getOperand()).zext(BitWidth); } case scSignExtend: { + // Only multiples that are a power of 2 will hold after sext. const SCEVSignExtendExpr *E = cast(S); - return getConstantMultiple(E->getOperand()).sext(BitWidth); + uint32_t TZ = getMinTrailingZeros(E->getOperand()); + return GetShiftedByZeros(TZ); } case scMulExpr: { const SCEVMulExpr *M = cast(S); diff --git a/contrib/llvm-project/llvm/lib/CodeGen/MachineLICM.cpp b/contrib/llvm-project/llvm/lib/CodeGen/MachineLICM.cpp index f24ab187ef40..21a02a6f0947 100644 --- a/contrib/llvm-project/llvm/lib/CodeGen/MachineLICM.cpp +++ b/contrib/llvm-project/llvm/lib/CodeGen/MachineLICM.cpp @@ -1474,7 +1474,7 @@ void MachineLICMBase::InitializeLoadsHoistableLoops() { if (!AllowedToHoistLoads[Loop]) continue; for (auto &MI : *MBB) { - if (!MI.mayStore() && !MI.isCall() && + if (!MI.isLoadFoldBarrier() && !MI.mayStore() && !MI.isCall() && !(MI.mayLoad() && MI.hasOrderedMemoryRef())) continue; for (MachineLoop *L = Loop; L != nullptr; L = L->getParentLoop()) diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp index 87e057a468af..c183ffd384c2 100644 --- a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp @@ -1394,6 +1394,18 @@ bool requiresGetVGCall(MachineFunction &MF) { !MF.getSubtarget().hasSVE(); } +static bool requiresSaveVG(MachineFunction &MF) { + AArch64FunctionInfo *AFI = MF.getInfo(); + // For Darwin platforms we don't save VG for non-SVE functions, even if SME + // is enabled with streaming mode changes. + if (!AFI->hasStreamingModeChanges()) + return false; + auto &ST = MF.getSubtarget(); + if (ST.isTargetDarwin()) + return ST.hasSVE(); + return true; +} + bool isVGInstruction(MachineBasicBlock::iterator MBBI) { unsigned Opc = MBBI->getOpcode(); if (Opc == AArch64::CNTD_XPiI || Opc == AArch64::RDSVLI_XI || @@ -1430,8 +1442,7 @@ static MachineBasicBlock::iterator convertCalleeSaveRestoreToSPPrePostIncDec( // functions, we need to do this for both the streaming and non-streaming // vector length. Move past these instructions if necessary. MachineFunction &MF = *MBB.getParent(); - AArch64FunctionInfo *AFI = MF.getInfo(); - if (AFI->hasStreamingModeChanges()) + if (requiresSaveVG(MF)) while (isVGInstruction(MBBI)) ++MBBI; @@ -1936,12 +1947,9 @@ void AArch64FrameLowering::emitPrologue(MachineFunction &MF, // pointer bump above. while (MBBI != End && MBBI->getFlag(MachineInstr::FrameSetup) && !IsSVECalleeSave(MBBI)) { - // Move past instructions generated to calculate VG - if (AFI->hasStreamingModeChanges()) - while (isVGInstruction(MBBI)) - ++MBBI; - - if (CombineSPBump) + if (CombineSPBump && + // Only fix-up frame-setup load/store instructions. + (!requiresSaveVG(MF) || !isVGInstruction(MBBI))) fixupCalleeSaveRestoreStackOffset(*MBBI, AFI->getLocalStackSize(), NeedsWinCFI, &HasWinCFI); ++MBBI; @@ -2848,7 +2856,8 @@ static bool produceCompactUnwindFrame(MachineFunction &MF) { return Subtarget.isTargetMachO() && !(Subtarget.getTargetLowering()->supportSwiftError() && Attrs.hasAttrSomewhere(Attribute::SwiftError)) && - MF.getFunction().getCallingConv() != CallingConv::SwiftTail; + MF.getFunction().getCallingConv() != CallingConv::SwiftTail && + !requiresSaveVG(MF); } static bool invalidateWindowsRegisterPairing(unsigned Reg1, unsigned Reg2, @@ -3720,7 +3729,7 @@ void AArch64FrameLowering::determineCalleeSaves(MachineFunction &MF, // non-streaming VG value. const Function &F = MF.getFunction(); SMEAttrs Attrs(F); - if (AFI->hasStreamingModeChanges()) { + if (requiresSaveVG(MF)) { if (Attrs.hasStreamingBody() && !Attrs.hasStreamingInterface()) CSStackSize += 16; else @@ -3873,7 +3882,7 @@ bool AArch64FrameLowering::assignCalleeSavedSpillSlots( } // Insert VG into the list of CSRs, immediately before LR if saved. - if (AFI->hasStreamingModeChanges()) { + if (requiresSaveVG(MF)) { std::vector VGSaves; SMEAttrs Attrs(MF.getFunction()); @@ -4602,10 +4611,9 @@ MachineBasicBlock::iterator emitVGSaveRestore(MachineBasicBlock::iterator II, void AArch64FrameLowering::processFunctionBeforeFrameIndicesReplaced( MachineFunction &MF, RegScavenger *RS = nullptr) const { - AArch64FunctionInfo *AFI = MF.getInfo(); for (auto &BB : MF) for (MachineBasicBlock::iterator II = BB.begin(); II != BB.end();) { - if (AFI->hasStreamingModeChanges()) + if (requiresSaveVG(MF)) II = emitVGSaveRestore(II, this); if (StackTaggingMergeSetTag) II = tryMergeAdjacentSTG(II, this, RS); diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp index 62078822c89b..ef2789e96213 100644 --- a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp @@ -8732,10 +8732,11 @@ AArch64TargetLowering::LowerCall(CallLoweringInfo &CLI, SDValue InGlue; if (RequiresSMChange) { - - Chain = DAG.getNode(AArch64ISD::VG_SAVE, DL, - DAG.getVTList(MVT::Other, MVT::Glue), Chain); - InGlue = Chain.getValue(1); + if (!Subtarget->isTargetDarwin() || Subtarget->hasSVE()) { + Chain = DAG.getNode(AArch64ISD::VG_SAVE, DL, + DAG.getVTList(MVT::Other, MVT::Glue), Chain); + InGlue = Chain.getValue(1); + } SDValue NewChain = changeStreamingMode( DAG, DL, CalleeAttrs.hasStreamingInterface(), Chain, InGlue, @@ -8914,11 +8915,13 @@ AArch64TargetLowering::LowerCall(CallLoweringInfo &CLI, Result = changeStreamingMode( DAG, DL, !CalleeAttrs.hasStreamingInterface(), Result, InGlue, getSMCondition(CallerAttrs, CalleeAttrs), PStateSM); - InGlue = Result.getValue(1); - Result = - DAG.getNode(AArch64ISD::VG_RESTORE, DL, - DAG.getVTList(MVT::Other, MVT::Glue), {Result, InGlue}); + if (!Subtarget->isTargetDarwin() || Subtarget->hasSVE()) { + InGlue = Result.getValue(1); + Result = + DAG.getNode(AArch64ISD::VG_RESTORE, DL, + DAG.getVTList(MVT::Other, MVT::Glue), {Result, InGlue}); + } } if (CallerAttrs.requiresEnablingZAAfterCall(CalleeAttrs)) diff --git a/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchExpandPseudoInsts.cpp b/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchExpandPseudoInsts.cpp index c136f5b3e515..e680dda7374d 100644 --- a/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchExpandPseudoInsts.cpp +++ b/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchExpandPseudoInsts.cpp @@ -721,7 +721,7 @@ bool LoongArchExpandPseudo::expandFunctionCALL( IsTailCall ? LoongArch::PseudoJIRL_TAIL : LoongArch::PseudoJIRL_CALL; Register AddrReg = IsTailCall ? LoongArch::R19 : LoongArch::R1; - bool UseGOT = Func.isGlobal() && !Func.getGlobal()->isDSOLocal(); + bool UseGOT = Func.getTargetFlags() == LoongArchII::MO_CALL_PLT; unsigned MO = UseGOT ? LoongArchII::MO_GOT_PC_HI : LoongArchII::MO_PCREL_LO; unsigned LAOpcode = UseGOT ? LoongArch::LDX_D : LoongArch::ADD_D; expandLargeAddressLoad(MBB, MBBI, NextMBBI, LAOpcode, MO, Func, AddrReg, diff --git a/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchLSXInstrInfo.td b/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchLSXInstrInfo.td index 0580683c3ce3..0233baecf6dd 100644 --- a/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchLSXInstrInfo.td +++ b/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchLSXInstrInfo.td @@ -67,8 +67,7 @@ class VecCondgetValueType(0).getVectorElementType(); @@ -109,8 +108,7 @@ def vsplati32_imm_eq_31 : PatFrags<(ops), [(build_vector)], [{ return selectVSplat(N, Imm, EltTy.getSizeInBits()) && Imm.getBitWidth() == EltTy.getSizeInBits() && Imm == 31; }]>; -def vsplati64_imm_eq_63 : PatFrags<(ops), [(build_vector), - (bitconvert (v4i32 (build_vector)))], [{ +def vsplati64_imm_eq_63 : PatFrags<(ops), [(build_vector)], [{ APInt Imm; EVT EltTy = N->getValueType(0).getVectorElementType(); diff --git a/contrib/llvm-project/llvm/lib/Target/LoongArch/MCTargetDesc/LoongArchMCTargetDesc.cpp b/contrib/llvm-project/llvm/lib/Target/LoongArch/MCTargetDesc/LoongArchMCTargetDesc.cpp index e40981f5b5cd..0712cc01ea03 100644 --- a/contrib/llvm-project/llvm/lib/Target/LoongArch/MCTargetDesc/LoongArchMCTargetDesc.cpp +++ b/contrib/llvm-project/llvm/lib/Target/LoongArch/MCTargetDesc/LoongArchMCTargetDesc.cpp @@ -55,7 +55,7 @@ static MCInstrInfo *createLoongArchMCInstrInfo() { static MCSubtargetInfo * createLoongArchMCSubtargetInfo(const Triple &TT, StringRef CPU, StringRef FS) { if (CPU.empty() || CPU == "generic") - CPU = TT.isArch64Bit() ? "la464" : "generic-la32"; + CPU = TT.isArch64Bit() ? "generic-la64" : "generic-la32"; return createLoongArchMCSubtargetInfoImpl(TT, CPU, /*TuneCPU*/ CPU, FS); } diff --git a/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp b/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp index f6f32fde3b77..a9ffd2bedf21 100644 --- a/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp +++ b/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp @@ -220,6 +220,10 @@ bool MipsDAGToDAGISel::selectVSplatMaskR(SDValue N, SDValue &Imm) const { return false; } +bool MipsDAGToDAGISel::selectVSplatImmEq1(SDValue N) const { + llvm_unreachable("Unimplemented function."); +} + /// Convert vector addition with vector subtraction if that allows to encode /// constant as an immediate and thus avoid extra 'ldi' instruction. /// add X, <-1, -1...> --> sub X, <1, 1...> diff --git a/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.h b/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.h index 6135f9680785..3485300a782c 100644 --- a/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.h +++ b/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.h @@ -120,6 +120,9 @@ private: /// starting at bit zero. virtual bool selectVSplatMaskR(SDValue N, SDValue &Imm) const; + /// Select constant vector splats whose value is 1. + virtual bool selectVSplatImmEq1(SDValue N) const; + /// Convert vector addition with vector subtraction if that allows to encode /// constant as an immediate and thus avoid extra 'ldi' instruction. /// add X, <-1, -1...> --> sub X, <1, 1...> diff --git a/contrib/llvm-project/llvm/lib/Target/Mips/MipsMSAInstrInfo.td b/contrib/llvm-project/llvm/lib/Target/Mips/MipsMSAInstrInfo.td index c4abccb24c6f..f4c32c9dcd42 100644 --- a/contrib/llvm-project/llvm/lib/Target/Mips/MipsMSAInstrInfo.td +++ b/contrib/llvm-project/llvm/lib/Target/Mips/MipsMSAInstrInfo.td @@ -198,14 +198,8 @@ def vsplati32 : PatFrag<(ops node:$e0), (v4i32 (build_vector node:$e0, node:$e0, node:$e0, node:$e0))>; -def vsplati64_imm_eq_1 : PatLeaf<(bitconvert (v4i32 (build_vector))), [{ - APInt Imm; - SDNode *BV = N->getOperand(0).getNode(); - EVT EltTy = N->getValueType(0).getVectorElementType(); - - return selectVSplat(BV, Imm, EltTy.getSizeInBits()) && - Imm.getBitWidth() == EltTy.getSizeInBits() && Imm == 1; -}]>; +// Any build_vector that is a constant splat with a value that equals 1 +def vsplat_imm_eq_1 : ComplexPattern; def vsplati64 : PatFrag<(ops node:$e0), (v2i64 (build_vector node:$e0, node:$e0))>; @@ -217,7 +211,7 @@ def vsplati64_splat_d : PatFrag<(ops node:$e0), node:$e0, node:$e0, node:$e0)), - vsplati64_imm_eq_1))))>; + (vsplat_imm_eq_1)))))>; def vsplatf32 : PatFrag<(ops node:$e0), (v4f32 (build_vector node:$e0, node:$e0, @@ -352,46 +346,35 @@ def vsplat_maskr_bits_uimm6 : SplatComplexPattern; -// Any build_vector that is a constant splat with a value that equals 1 -// FIXME: These should be a ComplexPattern but we can't use them because the -// ISel generator requires the uses to have a name, but providing a name -// causes other errors ("used in pattern but not operand list") -def vsplat_imm_eq_1 : PatLeaf<(build_vector), [{ - APInt Imm; - EVT EltTy = N->getValueType(0).getVectorElementType(); - - return selectVSplat(N, Imm, EltTy.getSizeInBits()) && - Imm.getBitWidth() == EltTy.getSizeInBits() && Imm == 1; -}]>; def vbclr_b : PatFrag<(ops node:$ws, node:$wt), - (and node:$ws, (vnot (shl vsplat_imm_eq_1, node:$wt)))>; + (and node:$ws, (vnot (shl (vsplat_imm_eq_1), node:$wt)))>; def vbclr_h : PatFrag<(ops node:$ws, node:$wt), - (and node:$ws, (vnot (shl vsplat_imm_eq_1, node:$wt)))>; + (and node:$ws, (vnot (shl (vsplat_imm_eq_1), node:$wt)))>; def vbclr_w : PatFrag<(ops node:$ws, node:$wt), - (and node:$ws, (vnot (shl vsplat_imm_eq_1, node:$wt)))>; + (and node:$ws, (vnot (shl (vsplat_imm_eq_1), node:$wt)))>; def vbclr_d : PatFrag<(ops node:$ws, node:$wt), - (and node:$ws, (vnot (shl (v2i64 vsplati64_imm_eq_1), + (and node:$ws, (vnot (shl (v2i64 (vsplat_imm_eq_1)), node:$wt)))>; def vbneg_b : PatFrag<(ops node:$ws, node:$wt), - (xor node:$ws, (shl vsplat_imm_eq_1, node:$wt))>; + (xor node:$ws, (shl (vsplat_imm_eq_1), node:$wt))>; def vbneg_h : PatFrag<(ops node:$ws, node:$wt), - (xor node:$ws, (shl vsplat_imm_eq_1, node:$wt))>; + (xor node:$ws, (shl (vsplat_imm_eq_1), node:$wt))>; def vbneg_w : PatFrag<(ops node:$ws, node:$wt), - (xor node:$ws, (shl vsplat_imm_eq_1, node:$wt))>; + (xor node:$ws, (shl (vsplat_imm_eq_1), node:$wt))>; def vbneg_d : PatFrag<(ops node:$ws, node:$wt), - (xor node:$ws, (shl (v2i64 vsplati64_imm_eq_1), + (xor node:$ws, (shl (v2i64 (vsplat_imm_eq_1)), node:$wt))>; def vbset_b : PatFrag<(ops node:$ws, node:$wt), - (or node:$ws, (shl vsplat_imm_eq_1, node:$wt))>; + (or node:$ws, (shl (vsplat_imm_eq_1), node:$wt))>; def vbset_h : PatFrag<(ops node:$ws, node:$wt), - (or node:$ws, (shl vsplat_imm_eq_1, node:$wt))>; + (or node:$ws, (shl (vsplat_imm_eq_1), node:$wt))>; def vbset_w : PatFrag<(ops node:$ws, node:$wt), - (or node:$ws, (shl vsplat_imm_eq_1, node:$wt))>; + (or node:$ws, (shl (vsplat_imm_eq_1), node:$wt))>; def vbset_d : PatFrag<(ops node:$ws, node:$wt), - (or node:$ws, (shl (v2i64 vsplati64_imm_eq_1), + (or node:$ws, (shl (v2i64 (vsplat_imm_eq_1)), node:$wt))>; def muladd : PatFrag<(ops node:$wd, node:$ws, node:$wt), @@ -3842,7 +3825,7 @@ class MSAShiftPat : (VT (Insn VT:$ws, VT:$wt))>; class MSABitPat : - MSAPat<(VT (Node VT:$ws, (shl vsplat_imm_eq_1, (Frag VT:$wt)))), + MSAPat<(VT (Node VT:$ws, (shl (vsplat_imm_eq_1), (Frag VT:$wt)))), (VT (Insn VT:$ws, VT:$wt))>; multiclass MSAShiftPats { @@ -3861,7 +3844,7 @@ multiclass MSABitPats { def : MSABitPat(Insn#_B), vsplati8imm7>; def : MSABitPat(Insn#_H), vsplati16imm15>; def : MSABitPat(Insn#_W), vsplati32imm31>; - def : MSAPat<(Node v2i64:$ws, (shl (v2i64 vsplati64_imm_eq_1), + def : MSAPat<(Node v2i64:$ws, (shl (v2i64 (vsplat_imm_eq_1)), (vsplati64imm63 v2i64:$wt))), (v2i64 (!cast(Insn#_D) v2i64:$ws, v2i64:$wt))>; } @@ -3872,16 +3855,16 @@ defm : MSAShiftPats; defm : MSABitPats; defm : MSABitPats; -def : MSAPat<(and v16i8:$ws, (vnot (shl vsplat_imm_eq_1, +def : MSAPat<(and v16i8:$ws, (vnot (shl (vsplat_imm_eq_1), (vsplati8imm7 v16i8:$wt)))), (v16i8 (BCLR_B v16i8:$ws, v16i8:$wt))>; -def : MSAPat<(and v8i16:$ws, (vnot (shl vsplat_imm_eq_1, +def : MSAPat<(and v8i16:$ws, (vnot (shl (vsplat_imm_eq_1), (vsplati16imm15 v8i16:$wt)))), (v8i16 (BCLR_H v8i16:$ws, v8i16:$wt))>; -def : MSAPat<(and v4i32:$ws, (vnot (shl vsplat_imm_eq_1, +def : MSAPat<(and v4i32:$ws, (vnot (shl (vsplat_imm_eq_1), (vsplati32imm31 v4i32:$wt)))), (v4i32 (BCLR_W v4i32:$ws, v4i32:$wt))>; -def : MSAPat<(and v2i64:$ws, (vnot (shl (v2i64 vsplati64_imm_eq_1), +def : MSAPat<(and v2i64:$ws, (vnot (shl (v2i64 (vsplat_imm_eq_1)), (vsplati64imm63 v2i64:$wt)))), (v2i64 (BCLR_D v2i64:$ws, v2i64:$wt))>; diff --git a/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp b/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp index 7ad300c6cccd..66c034a889c6 100644 --- a/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp +++ b/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp @@ -730,6 +730,18 @@ bool MipsSEDAGToDAGISel::selectVSplatUimmInvPow2(SDValue N, return false; } +// Select const vector splat of 1. +bool MipsSEDAGToDAGISel::selectVSplatImmEq1(SDValue N) const { + APInt ImmValue; + EVT EltTy = N->getValueType(0).getVectorElementType(); + + if (N->getOpcode() == ISD::BITCAST) + N = N->getOperand(0); + + return selectVSplat(N.getNode(), ImmValue, EltTy.getSizeInBits()) && + ImmValue.getBitWidth() == EltTy.getSizeInBits() && ImmValue == 1; +} + bool MipsSEDAGToDAGISel::trySelect(SDNode *Node) { unsigned Opcode = Node->getOpcode(); SDLoc DL(Node); diff --git a/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.h b/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.h index 7b843b0e0b25..22d8e924ac53 100644 --- a/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.h +++ b/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.h @@ -124,6 +124,9 @@ private: /// starting at bit zero. bool selectVSplatMaskR(SDValue N, SDValue &Imm) const override; + /// Select constant vector splats whose value is 1. + bool selectVSplatImmEq1(SDValue N) const override; + bool trySelect(SDNode *Node) override; // Emits proper ABI for _mcount profiling calls. diff --git a/contrib/llvm-project/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp b/contrib/llvm-project/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp index 6975412ce5d3..b2153a7afe73 100644 --- a/contrib/llvm-project/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp +++ b/contrib/llvm-project/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp @@ -229,6 +229,10 @@ static void ComputePTXValueVTs(const TargetLowering &TLI, const DataLayout &DL, // v*i8 are formally lowered as v4i8 EltVT = MVT::v4i8; NumElts = (NumElts + 3) / 4; + } else if (EltVT.getSimpleVT() == MVT::i8 && NumElts == 2) { + // v2i8 is promoted to v2i16 + NumElts = 1; + EltVT = MVT::v2i16; } for (unsigned j = 0; j != NumElts; ++j) { ValueVTs.push_back(EltVT); diff --git a/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp b/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp index 9d2990c98ce2..3223fccbcf49 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp @@ -506,8 +506,10 @@ static Instruction *foldCttzCtlz(IntrinsicInst &II, InstCombinerImpl &IC) { // If ctlz/cttz is only used as a shift amount, set is_zero_poison to true. if (II.hasOneUse() && match(Op1, m_Zero()) && - match(II.user_back(), m_Shift(m_Value(), m_Specific(&II)))) + match(II.user_back(), m_Shift(m_Value(), m_Specific(&II)))) { + II.dropUBImplyingAttrsAndMetadata(); return IC.replaceOperand(II, 1, IC.Builder.getTrue()); + } Constant *C; diff --git a/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp b/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp index 8a6ec3076ac6..b9d06b593685 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp @@ -1004,7 +1004,7 @@ Value *InstCombinerImpl::SimplifyDemandedUseBits(Instruction *I, uint64_t MaskedGEPIndex = HighBitsGEPIndex | MaskedLowBitsGEPIndex; if (MaskedGEPIndex != GEPIndex) { - auto *GEP = cast(II->getArgOperand(0)); + auto *GEP = cast(II->getArgOperand(0)); Builder.SetInsertPoint(I); Type *GEPIndexType = DL.getIndexType(GEP->getPointerOperand()->getType()); diff --git a/contrib/llvm-project/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp b/contrib/llvm-project/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp index 37022104d0a9..d1c80aa67124 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp @@ -1033,9 +1033,9 @@ void State::addInfoForInductions(BasicBlock &BB) { DTN, CmpInst::ICMP_SLT, PN, B, ConditionTy(CmpInst::ICMP_SLE, StartValue, B))); - // Try to add condition from header to the exit blocks. When exiting either - // with EQ or NE in the header, we know that the induction value must be u<= - // B, as other exits may only exit earlier. + // Try to add condition from header to the dedicated exit blocks. When exiting + // either with EQ or NE in the header, we know that the induction value must + // be u<= B, as other exits may only exit earlier. assert(!StepOffset.isNegative() && "induction must be increasing"); assert((Pred == CmpInst::ICMP_EQ || Pred == CmpInst::ICMP_NE) && "unsupported predicate"); @@ -1043,8 +1043,11 @@ void State::addInfoForInductions(BasicBlock &BB) { SmallVector ExitBBs; L->getExitBlocks(ExitBBs); for (BasicBlock *EB : ExitBBs) { - WorkList.emplace_back(FactOrCheck::getConditionFact( - DT.getNode(EB), CmpInst::ICMP_ULE, A, B, Precond)); + // Bail out on non-dedicated exits. + if (DT.dominates(&BB, EB)) { + WorkList.emplace_back(FactOrCheck::getConditionFact( + DT.getNode(EB), CmpInst::ICMP_ULE, A, B, Precond)); + } } } diff --git a/contrib/llvm-project/llvm/lib/Transforms/Scalar/LICM.cpp b/contrib/llvm-project/llvm/lib/Transforms/Scalar/LICM.cpp index 91ef2b4b7c18..ca03eff7a4e2 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Scalar/LICM.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Scalar/LICM.cpp @@ -1464,8 +1464,11 @@ static Instruction *cloneInstructionInExitBlock( if (MSSAU.getMemorySSA()->getMemoryAccess(&I)) { // Create a new MemoryAccess and let MemorySSA set its defining access. + // After running some passes, MemorySSA might be outdated, and the + // instruction `I` may have become a non-memory touching instruction. MemoryAccess *NewMemAcc = MSSAU.createMemoryAccessInBB( - New, nullptr, New->getParent(), MemorySSA::Beginning); + New, nullptr, New->getParent(), MemorySSA::Beginning, + /*CreationMustSucceed=*/false); if (NewMemAcc) { if (auto *MemDef = dyn_cast(NewMemAcc)) MSSAU.insertDef(MemDef, /*RenameUses=*/true); diff --git a/contrib/llvm-project/llvm/lib/Transforms/Utils/Local.cpp b/contrib/llvm-project/llvm/lib/Transforms/Utils/Local.cpp index 7192efe3f16b..f68cbf62b982 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Utils/Local.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Utils/Local.cpp @@ -1028,7 +1028,13 @@ CanRedirectPredsOfEmptyBBToSucc(BasicBlock *BB, BasicBlock *Succ, if (!BB->hasNPredecessorsOrMore(2)) return false; - // Get single common predecessors of both BB and Succ + if (any_of(BBPreds, [](const BasicBlock *Pred) { + return isa(Pred->getTerminator()); + })) + return false; + + // Get the single common predecessor of both BB and Succ. Return false + // when there are more than one common predecessors. for (BasicBlock *SuccPred : SuccPreds) { if (BBPreds.count(SuccPred)) { if (CommonPred) @@ -1133,7 +1139,7 @@ bool llvm::TryToSimplifyUncondBranchFromEmptyBlock(BasicBlock *BB, bool BBKillable = CanPropagatePredecessorsForPHIs(BB, Succ, BBPreds); - // Even if we can not fold bB into Succ, we may be able to redirect the + // Even if we can not fold BB into Succ, we may be able to redirect the // predecessors of BB to Succ. bool BBPhisMergeable = BBKillable || diff --git a/contrib/llvm-project/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp b/contrib/llvm-project/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp index ab2b96cdc42d..746ba51a981f 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp @@ -15440,9 +15440,25 @@ bool BoUpSLP::collectValuesToDemote( MaskedValueIsZero(I->getOperand(1), Mask, SimplifyQuery(*DL))); }); }; + auto AbsChecker = [&](unsigned BitWidth, unsigned OrigBitWidth) { + assert(BitWidth <= OrigBitWidth && "Unexpected bitwidths!"); + return all_of(E.Scalars, [&](Value *V) { + auto *I = cast(V); + unsigned SignBits = OrigBitWidth - BitWidth; + APInt Mask = APInt::getBitsSetFrom(OrigBitWidth, BitWidth - 1); + unsigned Op0SignBits = + ComputeNumSignBits(I->getOperand(0), *DL, 0, AC, nullptr, DT); + return SignBits <= Op0SignBits && + ((SignBits != Op0SignBits && + !isKnownNonNegative(I->getOperand(0), SimplifyQuery(*DL))) || + MaskedValueIsZero(I->getOperand(0), Mask, SimplifyQuery(*DL))); + }); + }; if (ID != Intrinsic::abs) { Operands.push_back(getOperandEntry(&E, 1)); CallChecker = CompChecker; + } else { + CallChecker = AbsChecker; } InstructionCost BestCost = std::numeric_limits::max(); diff --git a/contrib/llvm-project/llvm/utils/TableGen/Common/CodeGenDAGPatterns.cpp b/contrib/llvm-project/llvm/utils/TableGen/Common/CodeGenDAGPatterns.cpp index a8cecca0d4a5..ca71569008d5 100644 --- a/contrib/llvm-project/llvm/utils/TableGen/Common/CodeGenDAGPatterns.cpp +++ b/contrib/llvm-project/llvm/utils/TableGen/Common/CodeGenDAGPatterns.cpp @@ -3042,6 +3042,14 @@ static bool SimplifyTree(TreePatternNodePtr &N) { !N->getExtType(0).empty() && N->getExtType(0) == N->getChild(0).getExtType(0) && N->getName().empty()) { + if (!N->getPredicateCalls().empty()) { + std::string Str; + raw_string_ostream OS(Str); + OS << *N + << "\n trivial bitconvert node should not have predicate calls\n"; + PrintFatalError(Str); + return false; + } N = N->getChildShared(0); SimplifyTree(N); return true; diff --git a/lib/clang/include/VCSVersion.inc b/lib/clang/include/VCSVersion.inc index 2197c8ca2947..7624a2e4b17a 100644 --- a/lib/clang/include/VCSVersion.inc +++ b/lib/clang/include/VCSVersion.inc @@ -1,8 +1,8 @@ -#define LLVM_REVISION "llvmorg-19.1.4-0-gaadaa00de76e" +#define LLVM_REVISION "llvmorg-19.1.5-0-gab4b5a2db582" #define LLVM_REPOSITORY "https://github.com/llvm/llvm-project.git" -#define CLANG_REVISION "llvmorg-19.1.4-0-gaadaa00de76e" +#define CLANG_REVISION "llvmorg-19.1.5-0-gab4b5a2db582" #define CLANG_REPOSITORY "https://github.com/llvm/llvm-project.git" -#define LLDB_REVISION "llvmorg-19.1.4-0-gaadaa00de76e" +#define LLDB_REVISION "llvmorg-19.1.5-0-gab4b5a2db582" #define LLDB_REPOSITORY "https://github.com/llvm/llvm-project.git" diff --git a/lib/clang/include/clang/Basic/Version.inc b/lib/clang/include/clang/Basic/Version.inc index d7a4777e7cec..5104f9d7ad7a 100644 --- a/lib/clang/include/clang/Basic/Version.inc +++ b/lib/clang/include/clang/Basic/Version.inc @@ -1,8 +1,8 @@ -#define CLANG_VERSION 19.1.4 -#define CLANG_VERSION_STRING "19.1.4" +#define CLANG_VERSION 19.1.5 +#define CLANG_VERSION_STRING "19.1.5" #define CLANG_VERSION_MAJOR 19 #define CLANG_VERSION_MAJOR_STRING "19" #define CLANG_VERSION_MINOR 1 -#define CLANG_VERSION_PATCHLEVEL 4 +#define CLANG_VERSION_PATCHLEVEL 5 #define CLANG_VENDOR "FreeBSD " diff --git a/lib/clang/include/lld/Common/Version.inc b/lib/clang/include/lld/Common/Version.inc index b041a27576fb..6cf430b53591 100644 --- a/lib/clang/include/lld/Common/Version.inc +++ b/lib/clang/include/lld/Common/Version.inc @@ -1,4 +1,4 @@ // Local identifier in __FreeBSD_version style #define LLD_FREEBSD_VERSION 1400007 -#define LLD_VERSION_STRING "19.1.4 (FreeBSD llvmorg-19.1.4-0-gaadaa00de76e-" __XSTRING(LLD_FREEBSD_VERSION) ")" +#define LLD_VERSION_STRING "19.1.5 (FreeBSD llvmorg-19.1.5-0-gab4b5a2db582-" __XSTRING(LLD_FREEBSD_VERSION) ")" diff --git a/lib/clang/include/lldb/Version/Version.inc b/lib/clang/include/lldb/Version/Version.inc index d69a702815ff..5aa1f29215b4 100644 --- a/lib/clang/include/lldb/Version/Version.inc +++ b/lib/clang/include/lldb/Version/Version.inc @@ -1,6 +1,6 @@ -#define LLDB_VERSION 19.1.4 -#define LLDB_VERSION_STRING "19.1.4" +#define LLDB_VERSION 19.1.5 +#define LLDB_VERSION_STRING "19.1.5" #define LLDB_VERSION_MAJOR 19 #define LLDB_VERSION_MINOR 1 -#define LLDB_VERSION_PATCH 4 +#define LLDB_VERSION_PATCH 5 /* #undef LLDB_FULL_VERSION_STRING */ diff --git a/lib/clang/include/llvm/Config/config.h b/lib/clang/include/llvm/Config/config.h index a775cc7e9bbf..f86e4b6b5946 100644 --- a/lib/clang/include/llvm/Config/config.h +++ b/lib/clang/include/llvm/Config/config.h @@ -338,10 +338,10 @@ #define PACKAGE_NAME "LLVM" /* Define to the full name and version of this package. */ -#define PACKAGE_STRING "LLVM 19.1.4" +#define PACKAGE_STRING "LLVM 19.1.5" /* Define to the version of this package. */ -#define PACKAGE_VERSION "19.1.4" +#define PACKAGE_VERSION "19.1.5" /* Define to the vendor of this package. */ /* #undef PACKAGE_VENDOR */ diff --git a/lib/clang/include/llvm/Config/llvm-config.h b/lib/clang/include/llvm/Config/llvm-config.h index 16af33f177e6..966249436723 100644 --- a/lib/clang/include/llvm/Config/llvm-config.h +++ b/lib/clang/include/llvm/Config/llvm-config.h @@ -176,10 +176,10 @@ #define LLVM_VERSION_MINOR 1 /* Patch version of the LLVM API */ -#define LLVM_VERSION_PATCH 4 +#define LLVM_VERSION_PATCH 5 /* LLVM version string */ -#define LLVM_VERSION_STRING "19.1.4" +#define LLVM_VERSION_STRING "19.1.5" /* Whether LLVM records statistics for use with GetStatistics(), * PrintStatistics() or PrintStatisticsJSON() diff --git a/lib/clang/include/llvm/Support/VCSRevision.h b/lib/clang/include/llvm/Support/VCSRevision.h index 68785cd03f5d..db3347a0e5a5 100644 --- a/lib/clang/include/llvm/Support/VCSRevision.h +++ b/lib/clang/include/llvm/Support/VCSRevision.h @@ -1,2 +1,2 @@ -#define LLVM_REVISION "llvmorg-19.1.4-0-gaadaa00de76e" +#define LLVM_REVISION "llvmorg-19.1.5-0-gab4b5a2db582" #define LLVM_REPOSITORY "https://github.com/llvm/llvm-project.git" From nobody Wed Dec 11 08:17:42 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 4Y7T470VDQz5gbv1; Wed, 11 Dec 2024 08:17:43 +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 4Y7T466vGNz4cM0; Wed, 11 Dec 2024 08:17:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733905062; 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=LcagUBmKJqbeyz5hc8FPOACybAQuyfX8XfYNNnGn0OI=; b=tWEktZEgD+mKR7paGOCdhe6iYe+whDNvt7EyyKilbBwCx0XneSawbO0Avk0FK6R+kHvC7S xEFISyv01pKoGXV0x+0TedQ71RHbYM8w6svoQqWPjUDp6LcVWhQZHeMF/83iZsXDZWF5pU PY97wwXyBmhd9syk3lW4KX7zt2/CQ+V+wbrsUhWkGtzl3IfM8boKKWL4N/uaado6OGLSxM Nfw6qVByK8DpNFgkpeiYizOCtLSbn69x6oiLkeJ7ujVeJ9QibUOO0KzLjMMmZujsct8paX QdvjrDpSMlqb1zo63LE/df2oyjn6uvJIvRQHtRTVuf0tTBMcMWnXzw8t0WzEiw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733905062; 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=LcagUBmKJqbeyz5hc8FPOACybAQuyfX8XfYNNnGn0OI=; b=w1d/m9ULz1D1xioAdI909Iabf2PmbqENL9e/pkKWdHhlm/XaORSNJqelVTS07yHHPrt5K2 9ay66SYptNXVPY92VzzfUig3EJ7QYuyN6wFPR35KorwfQYODNwc+6d9x+OZtjlTZpAO8ik LaEqlwf7r1I2GW/Me9Xyi/EnBRSfRK+6d5Ajg7WigETQZlWxo4AFIks7SVlVfXZlveuU99 B/70AZKAQI11KchEEs/Jsy6lllRZ4Es+IQ1SVB7UvDTXE8MApUH0tbtZpwV9mhwSvkw04p osVxl3aZ2koxYLvamAWl/+nyCLORSQlhPvHOVYfgNhZhjjc67NKpemH5WrgtaA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733905062; a=rsa-sha256; cv=none; b=XCAa3OnFPJsVxahuE9QfFY54kAmrKh1jbI2eVnOB5RFsjWgquH/QkOkuurYoajnmBQRRkR eE6IWIzNsGOno/N2Jqc3JsCuatyPooI+HDm8tK59ed4QA3NDlzHcB7WqutP3FnHv7k/WBo cTYj+smPdu2XrDlo3hDLroqgJxvWs5UsAl+mI5Yk4CXTO1cse/i3B41Wq5c9LATXswidNs DTfQ5uOk3KqQALkHkeUHlC4A0pjx1hJ4dIz1cVwkiBEcXZJpQyDF9G4uMHp5qR2JeEv/L2 rF8QvKiVD0VzNy5WJREzuxHZdTrz5Y4SO5N+RfrRtM10joAfhyC4T3qjAVlDIg== 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 4Y7T466VWsz10d4; Wed, 11 Dec 2024 08:17:42 +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 4BB8Hgkk087619; Wed, 11 Dec 2024 08:17:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BB8HgBo087616; Wed, 11 Dec 2024 08:17:42 GMT (envelope-from git) Date: Wed, 11 Dec 2024 08:17:42 GMT Message-Id: <202412110817.4BB8HgBo087616@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dimitry Andric Subject: git: a8e22567d3fa - stable/13 - Merge llvm-project release/19.x llvmorg-19.1.5-0-gab4b5a2db582 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: dim X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: a8e22567d3fa660c9f61daa3c9c8f0f587df6fb0 Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=a8e22567d3fa660c9f61daa3c9c8f0f587df6fb0 commit a8e22567d3fa660c9f61daa3c9c8f0f587df6fb0 Author: Dimitry Andric AuthorDate: 2024-12-06 17:26:41 +0000 Commit: Dimitry Andric CommitDate: 2024-12-11 08:17:06 +0000 Merge llvm-project release/19.x llvmorg-19.1.5-0-gab4b5a2db582 This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp to llvm-project release/19.x llvmorg-19.1.5-0-gab4b5a2db582, a.k.a. 19.1.5 release. PR: 280562 MFC after: 3 days (cherry picked from commit 71ac745d76c3ba442e753daff1870893f272b29d) --- .../clang/lib/Driver/ToolChains/Hexagon.cpp | 7 ++- .../clang/lib/Interpreter/IncrementalExecutor.h | 2 +- .../clang/lib/Interpreter/Interpreter.cpp | 2 +- .../llvm-project/clang/lib/Interpreter/Wasm.cpp | 65 +++++++++++++++++----- contrib/llvm-project/clang/lib/Interpreter/Wasm.h | 1 + contrib/llvm-project/libcxx/include/__config | 2 +- contrib/llvm-project/lld/ELF/Arch/Hexagon.cpp | 2 +- .../llvm/include/llvm/Analysis/MemorySSAUpdater.h | 5 ++ .../llvm/lib/Analysis/MemorySSAUpdater.cpp | 13 ++++- .../llvm/lib/Analysis/ScalarEvolution.cpp | 4 +- .../llvm-project/llvm/lib/CodeGen/MachineLICM.cpp | 2 +- .../lib/Target/AArch64/AArch64FrameLowering.cpp | 34 ++++++----- .../lib/Target/AArch64/AArch64ISelLowering.cpp | 19 ++++--- .../LoongArch/LoongArchExpandPseudoInsts.cpp | 2 +- .../lib/Target/LoongArch/LoongArchLSXInstrInfo.td | 6 +- .../MCTargetDesc/LoongArchMCTargetDesc.cpp | 2 +- .../llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp | 4 ++ .../llvm/lib/Target/Mips/MipsISelDAGToDAG.h | 3 + .../llvm/lib/Target/Mips/MipsMSAInstrInfo.td | 59 +++++++------------- .../llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp | 12 ++++ .../llvm/lib/Target/Mips/MipsSEISelDAGToDAG.h | 3 + .../llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp | 4 ++ .../Transforms/InstCombine/InstCombineCalls.cpp | 4 +- .../InstCombine/InstCombineSimplifyDemanded.cpp | 2 +- .../Transforms/Scalar/ConstraintElimination.cpp | 13 +++-- .../llvm/lib/Transforms/Scalar/LICM.cpp | 5 +- .../llvm/lib/Transforms/Utils/Local.cpp | 10 +++- .../lib/Transforms/Vectorize/SLPVectorizer.cpp | 16 ++++++ .../utils/TableGen/Common/CodeGenDAGPatterns.cpp | 8 +++ lib/clang/include/VCSVersion.inc | 6 +- lib/clang/include/clang/Basic/Version.inc | 6 +- lib/clang/include/lld/Common/Version.inc | 2 +- lib/clang/include/lldb/Version/Version.inc | 6 +- lib/clang/include/llvm/Config/config.h | 4 +- lib/clang/include/llvm/Config/llvm-config.h | 4 +- lib/clang/include/llvm/Support/VCSRevision.h | 2 +- 36 files changed, 225 insertions(+), 116 deletions(-) diff --git a/contrib/llvm-project/clang/lib/Driver/ToolChains/Hexagon.cpp b/contrib/llvm-project/clang/lib/Driver/ToolChains/Hexagon.cpp index 29781399cbab..be7851adecea 100644 --- a/contrib/llvm-project/clang/lib/Driver/ToolChains/Hexagon.cpp +++ b/contrib/llvm-project/clang/lib/Driver/ToolChains/Hexagon.cpp @@ -294,9 +294,10 @@ constructHexagonLinkArgs(Compilation &C, const JobAction &JA, bool IncStartFiles = !Args.hasArg(options::OPT_nostartfiles); bool IncDefLibs = !Args.hasArg(options::OPT_nodefaultlibs); bool UseG0 = false; - const char *Exec = Args.MakeArgString(HTC.GetLinkerPath()); - bool UseLLD = (llvm::sys::path::filename(Exec).equals_insensitive("ld.lld") || - llvm::sys::path::stem(Exec).equals_insensitive("ld.lld")); + bool UseLLD = false; + const char *Exec = Args.MakeArgString(HTC.GetLinkerPath(&UseLLD)); + UseLLD = UseLLD || llvm::sys::path::filename(Exec).ends_with("ld.lld") || + llvm::sys::path::stem(Exec).ends_with("ld.lld"); bool UseShared = IsShared && !IsStatic; StringRef CpuVer = toolchains::HexagonToolChain::GetTargetCPUVersion(Args); diff --git a/contrib/llvm-project/clang/lib/Interpreter/IncrementalExecutor.h b/contrib/llvm-project/clang/lib/Interpreter/IncrementalExecutor.h index 7954cde36588..dbd61f0b8b1e 100644 --- a/contrib/llvm-project/clang/lib/Interpreter/IncrementalExecutor.h +++ b/contrib/llvm-project/clang/lib/Interpreter/IncrementalExecutor.h @@ -56,7 +56,7 @@ public: virtual llvm::Error addModule(PartialTranslationUnit &PTU); virtual llvm::Error removeModule(PartialTranslationUnit &PTU); virtual llvm::Error runCtors() const; - llvm::Error cleanUp(); + virtual llvm::Error cleanUp(); llvm::Expected getSymbolAddress(llvm::StringRef Name, SymbolNameKind NameKind) const; diff --git a/contrib/llvm-project/clang/lib/Interpreter/Interpreter.cpp b/contrib/llvm-project/clang/lib/Interpreter/Interpreter.cpp index b4882ab5d223..985d0b7c0ef3 100644 --- a/contrib/llvm-project/clang/lib/Interpreter/Interpreter.cpp +++ b/contrib/llvm-project/clang/lib/Interpreter/Interpreter.cpp @@ -192,8 +192,8 @@ IncrementalCompilerBuilder::CreateCpp() { #ifdef __EMSCRIPTEN__ Argv.push_back("-target"); Argv.push_back("wasm32-unknown-emscripten"); - Argv.push_back("-pie"); Argv.push_back("-shared"); + Argv.push_back("-fvisibility=default"); #endif Argv.insert(Argv.end(), UserArgs.begin(), UserArgs.end()); diff --git a/contrib/llvm-project/clang/lib/Interpreter/Wasm.cpp b/contrib/llvm-project/clang/lib/Interpreter/Wasm.cpp index 1001410aa0f2..aa10b160ccf8 100644 --- a/contrib/llvm-project/clang/lib/Interpreter/Wasm.cpp +++ b/contrib/llvm-project/clang/lib/Interpreter/Wasm.cpp @@ -23,6 +23,31 @@ #include namespace lld { +enum Flavor { + Invalid, + Gnu, // -flavor gnu + MinGW, // -flavor gnu MinGW + WinLink, // -flavor link + Darwin, // -flavor darwin + Wasm, // -flavor wasm +}; + +using Driver = bool (*)(llvm::ArrayRef, llvm::raw_ostream &, + llvm::raw_ostream &, bool, bool); + +struct DriverDef { + Flavor f; + Driver d; +}; + +struct Result { + int retCode; + bool canRunAgain; +}; + +Result lldMain(llvm::ArrayRef args, llvm::raw_ostream &stdoutOS, + llvm::raw_ostream &stderrOS, llvm::ArrayRef drivers); + namespace wasm { bool link(llvm::ArrayRef args, llvm::raw_ostream &stdoutOS, llvm::raw_ostream &stderrOS, bool exitEarly, bool disableOutput); @@ -51,13 +76,14 @@ llvm::Error WasmIncrementalExecutor::addModule(PartialTranslationUnit &PTU) { llvm::TargetMachine *TargetMachine = Target->createTargetMachine( PTU.TheModule->getTargetTriple(), "", "", TO, llvm::Reloc::Model::PIC_); PTU.TheModule->setDataLayout(TargetMachine->createDataLayout()); - std::string OutputFileName = PTU.TheModule->getName().str() + ".wasm"; + std::string ObjectFileName = PTU.TheModule->getName().str() + ".o"; + std::string BinaryFileName = PTU.TheModule->getName().str() + ".wasm"; std::error_code Error; - llvm::raw_fd_ostream OutputFile(llvm::StringRef(OutputFileName), Error); + llvm::raw_fd_ostream ObjectFileOutput(llvm::StringRef(ObjectFileName), Error); llvm::legacy::PassManager PM; - if (TargetMachine->addPassesToEmitFile(PM, OutputFile, nullptr, + if (TargetMachine->addPassesToEmitFile(PM, ObjectFileOutput, nullptr, llvm::CodeGenFileType::ObjectFile)) { return llvm::make_error( "Wasm backend cannot produce object.", llvm::inconvertibleErrorCode()); @@ -69,27 +95,30 @@ llvm::Error WasmIncrementalExecutor::addModule(PartialTranslationUnit &PTU) { llvm::inconvertibleErrorCode()); } - OutputFile.close(); + ObjectFileOutput.close(); std::vector LinkerArgs = {"wasm-ld", - "-pie", + "-shared", "--import-memory", - "--no-entry", - "--export-all", "--experimental-pic", - "--no-export-dynamic", "--stack-first", - OutputFileName.c_str(), + "--allow-undefined", + ObjectFileName.c_str(), "-o", - OutputFileName.c_str()}; - int Result = - lld::wasm::link(LinkerArgs, llvm::outs(), llvm::errs(), false, false); - if (!Result) + BinaryFileName.c_str()}; + + const lld::DriverDef WasmDriver = {lld::Flavor::Wasm, &lld::wasm::link}; + std::vector WasmDriverArgs; + WasmDriverArgs.push_back(WasmDriver); + lld::Result Result = + lld::lldMain(LinkerArgs, llvm::outs(), llvm::errs(), WasmDriverArgs); + + if (Result.retCode) return llvm::make_error( "Failed to link incremental module", llvm::inconvertibleErrorCode()); void *LoadedLibModule = - dlopen(OutputFileName.c_str(), RTLD_NOW | RTLD_GLOBAL); + dlopen(BinaryFileName.c_str(), RTLD_NOW | RTLD_GLOBAL); if (LoadedLibModule == nullptr) { llvm::errs() << dlerror() << '\n'; return llvm::make_error( @@ -109,6 +138,12 @@ llvm::Error WasmIncrementalExecutor::runCtors() const { return llvm::Error::success(); } +llvm::Error WasmIncrementalExecutor::cleanUp() { + // Can't call cleanUp through IncrementalExecutor as it + // tries to deinitialize JIT which hasn't been initialized + return llvm::Error::success(); +} + WasmIncrementalExecutor::~WasmIncrementalExecutor() = default; -} // namespace clang +} // namespace clang \ No newline at end of file diff --git a/contrib/llvm-project/clang/lib/Interpreter/Wasm.h b/contrib/llvm-project/clang/lib/Interpreter/Wasm.h index b1fd88024f14..4632613326d3 100644 --- a/contrib/llvm-project/clang/lib/Interpreter/Wasm.h +++ b/contrib/llvm-project/clang/lib/Interpreter/Wasm.h @@ -28,6 +28,7 @@ public: llvm::Error addModule(PartialTranslationUnit &PTU) override; llvm::Error removeModule(PartialTranslationUnit &PTU) override; llvm::Error runCtors() const override; + llvm::Error cleanUp() override; ~WasmIncrementalExecutor() override; }; diff --git a/contrib/llvm-project/libcxx/include/__config b/contrib/llvm-project/libcxx/include/__config index 8b49c6b309a6..458910d6139e 100644 --- a/contrib/llvm-project/libcxx/include/__config +++ b/contrib/llvm-project/libcxx/include/__config @@ -27,7 +27,7 @@ // _LIBCPP_VERSION represents the version of libc++, which matches the version of LLVM. // Given a LLVM release LLVM XX.YY.ZZ (e.g. LLVM 17.0.1 == 17.00.01), _LIBCPP_VERSION is // defined to XXYYZZ. -# define _LIBCPP_VERSION 190104 +# define _LIBCPP_VERSION 190105 # define _LIBCPP_CONCAT_IMPL(_X, _Y) _X##_Y # define _LIBCPP_CONCAT(_X, _Y) _LIBCPP_CONCAT_IMPL(_X, _Y) diff --git a/contrib/llvm-project/lld/ELF/Arch/Hexagon.cpp b/contrib/llvm-project/lld/ELF/Arch/Hexagon.cpp index 56cf96fd1770..8bcd28309f8b 100644 --- a/contrib/llvm-project/lld/ELF/Arch/Hexagon.cpp +++ b/contrib/llvm-project/lld/ELF/Arch/Hexagon.cpp @@ -329,7 +329,7 @@ void Hexagon::relocate(uint8_t *loc, const Relocation &rel, case R_HEX_B22_PCREL: case R_HEX_GD_PLT_B22_PCREL: case R_HEX_PLT_B22_PCREL: - checkInt(loc, val, 22, rel); + checkInt(loc, val, 24, rel); or32le(loc, applyMask(0x1ff3ffe, val >> 2)); break; case R_HEX_B22_PCREL_X: diff --git a/contrib/llvm-project/llvm/include/llvm/Analysis/MemorySSAUpdater.h b/contrib/llvm-project/llvm/include/llvm/Analysis/MemorySSAUpdater.h index d4da3ef1146d..f598dedea75f 100644 --- a/contrib/llvm-project/llvm/include/llvm/Analysis/MemorySSAUpdater.h +++ b/contrib/llvm-project/llvm/include/llvm/Analysis/MemorySSAUpdater.h @@ -192,6 +192,11 @@ public: const BasicBlock *BB, MemorySSA::InsertionPlace Point); + MemoryAccess *createMemoryAccessInBB(Instruction *I, MemoryAccess *Definition, + const BasicBlock *BB, + MemorySSA::InsertionPlace Point, + bool CreationMustSucceed); + /// Create a MemoryAccess in MemorySSA before an existing MemoryAccess. /// /// See createMemoryAccessInBB() for usage details. diff --git a/contrib/llvm-project/llvm/lib/Analysis/MemorySSAUpdater.cpp b/contrib/llvm-project/llvm/lib/Analysis/MemorySSAUpdater.cpp index aa550f0b6a7b..94061c949b7f 100644 --- a/contrib/llvm-project/llvm/lib/Analysis/MemorySSAUpdater.cpp +++ b/contrib/llvm-project/llvm/lib/Analysis/MemorySSAUpdater.cpp @@ -1404,8 +1404,17 @@ void MemorySSAUpdater::changeToUnreachable(const Instruction *I) { MemoryAccess *MemorySSAUpdater::createMemoryAccessInBB( Instruction *I, MemoryAccess *Definition, const BasicBlock *BB, MemorySSA::InsertionPlace Point) { - MemoryUseOrDef *NewAccess = MSSA->createDefinedAccess(I, Definition); - MSSA->insertIntoListsForBlock(NewAccess, BB, Point); + return createMemoryAccessInBB(I, Definition, BB, Point, + /*CreationMustSucceed=*/true); +} + +MemoryAccess *MemorySSAUpdater::createMemoryAccessInBB( + Instruction *I, MemoryAccess *Definition, const BasicBlock *BB, + MemorySSA::InsertionPlace Point, bool CreationMustSucceed) { + MemoryUseOrDef *NewAccess = MSSA->createDefinedAccess( + I, Definition, /*Template=*/nullptr, CreationMustSucceed); + if (NewAccess) + MSSA->insertIntoListsForBlock(NewAccess, BB, Point); return NewAccess; } diff --git a/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp b/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp index 51cffac80876..412cfe73d3e5 100644 --- a/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp +++ b/contrib/llvm-project/llvm/lib/Analysis/ScalarEvolution.cpp @@ -6313,8 +6313,10 @@ APInt ScalarEvolution::getConstantMultipleImpl(const SCEV *S) { return getConstantMultiple(Z->getOperand()).zext(BitWidth); } case scSignExtend: { + // Only multiples that are a power of 2 will hold after sext. const SCEVSignExtendExpr *E = cast(S); - return getConstantMultiple(E->getOperand()).sext(BitWidth); + uint32_t TZ = getMinTrailingZeros(E->getOperand()); + return GetShiftedByZeros(TZ); } case scMulExpr: { const SCEVMulExpr *M = cast(S); diff --git a/contrib/llvm-project/llvm/lib/CodeGen/MachineLICM.cpp b/contrib/llvm-project/llvm/lib/CodeGen/MachineLICM.cpp index f24ab187ef40..21a02a6f0947 100644 --- a/contrib/llvm-project/llvm/lib/CodeGen/MachineLICM.cpp +++ b/contrib/llvm-project/llvm/lib/CodeGen/MachineLICM.cpp @@ -1474,7 +1474,7 @@ void MachineLICMBase::InitializeLoadsHoistableLoops() { if (!AllowedToHoistLoads[Loop]) continue; for (auto &MI : *MBB) { - if (!MI.mayStore() && !MI.isCall() && + if (!MI.isLoadFoldBarrier() && !MI.mayStore() && !MI.isCall() && !(MI.mayLoad() && MI.hasOrderedMemoryRef())) continue; for (MachineLoop *L = Loop; L != nullptr; L = L->getParentLoop()) diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp index 87e057a468af..c183ffd384c2 100644 --- a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp @@ -1394,6 +1394,18 @@ bool requiresGetVGCall(MachineFunction &MF) { !MF.getSubtarget().hasSVE(); } +static bool requiresSaveVG(MachineFunction &MF) { + AArch64FunctionInfo *AFI = MF.getInfo(); + // For Darwin platforms we don't save VG for non-SVE functions, even if SME + // is enabled with streaming mode changes. + if (!AFI->hasStreamingModeChanges()) + return false; + auto &ST = MF.getSubtarget(); + if (ST.isTargetDarwin()) + return ST.hasSVE(); + return true; +} + bool isVGInstruction(MachineBasicBlock::iterator MBBI) { unsigned Opc = MBBI->getOpcode(); if (Opc == AArch64::CNTD_XPiI || Opc == AArch64::RDSVLI_XI || @@ -1430,8 +1442,7 @@ static MachineBasicBlock::iterator convertCalleeSaveRestoreToSPPrePostIncDec( // functions, we need to do this for both the streaming and non-streaming // vector length. Move past these instructions if necessary. MachineFunction &MF = *MBB.getParent(); - AArch64FunctionInfo *AFI = MF.getInfo(); - if (AFI->hasStreamingModeChanges()) + if (requiresSaveVG(MF)) while (isVGInstruction(MBBI)) ++MBBI; @@ -1936,12 +1947,9 @@ void AArch64FrameLowering::emitPrologue(MachineFunction &MF, // pointer bump above. while (MBBI != End && MBBI->getFlag(MachineInstr::FrameSetup) && !IsSVECalleeSave(MBBI)) { - // Move past instructions generated to calculate VG - if (AFI->hasStreamingModeChanges()) - while (isVGInstruction(MBBI)) - ++MBBI; - - if (CombineSPBump) + if (CombineSPBump && + // Only fix-up frame-setup load/store instructions. + (!requiresSaveVG(MF) || !isVGInstruction(MBBI))) fixupCalleeSaveRestoreStackOffset(*MBBI, AFI->getLocalStackSize(), NeedsWinCFI, &HasWinCFI); ++MBBI; @@ -2848,7 +2856,8 @@ static bool produceCompactUnwindFrame(MachineFunction &MF) { return Subtarget.isTargetMachO() && !(Subtarget.getTargetLowering()->supportSwiftError() && Attrs.hasAttrSomewhere(Attribute::SwiftError)) && - MF.getFunction().getCallingConv() != CallingConv::SwiftTail; + MF.getFunction().getCallingConv() != CallingConv::SwiftTail && + !requiresSaveVG(MF); } static bool invalidateWindowsRegisterPairing(unsigned Reg1, unsigned Reg2, @@ -3720,7 +3729,7 @@ void AArch64FrameLowering::determineCalleeSaves(MachineFunction &MF, // non-streaming VG value. const Function &F = MF.getFunction(); SMEAttrs Attrs(F); - if (AFI->hasStreamingModeChanges()) { + if (requiresSaveVG(MF)) { if (Attrs.hasStreamingBody() && !Attrs.hasStreamingInterface()) CSStackSize += 16; else @@ -3873,7 +3882,7 @@ bool AArch64FrameLowering::assignCalleeSavedSpillSlots( } // Insert VG into the list of CSRs, immediately before LR if saved. - if (AFI->hasStreamingModeChanges()) { + if (requiresSaveVG(MF)) { std::vector VGSaves; SMEAttrs Attrs(MF.getFunction()); @@ -4602,10 +4611,9 @@ MachineBasicBlock::iterator emitVGSaveRestore(MachineBasicBlock::iterator II, void AArch64FrameLowering::processFunctionBeforeFrameIndicesReplaced( MachineFunction &MF, RegScavenger *RS = nullptr) const { - AArch64FunctionInfo *AFI = MF.getInfo(); for (auto &BB : MF) for (MachineBasicBlock::iterator II = BB.begin(); II != BB.end();) { - if (AFI->hasStreamingModeChanges()) + if (requiresSaveVG(MF)) II = emitVGSaveRestore(II, this); if (StackTaggingMergeSetTag) II = tryMergeAdjacentSTG(II, this, RS); diff --git a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp index 62078822c89b..ef2789e96213 100644 --- a/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp +++ b/contrib/llvm-project/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp @@ -8732,10 +8732,11 @@ AArch64TargetLowering::LowerCall(CallLoweringInfo &CLI, SDValue InGlue; if (RequiresSMChange) { - - Chain = DAG.getNode(AArch64ISD::VG_SAVE, DL, - DAG.getVTList(MVT::Other, MVT::Glue), Chain); - InGlue = Chain.getValue(1); + if (!Subtarget->isTargetDarwin() || Subtarget->hasSVE()) { + Chain = DAG.getNode(AArch64ISD::VG_SAVE, DL, + DAG.getVTList(MVT::Other, MVT::Glue), Chain); + InGlue = Chain.getValue(1); + } SDValue NewChain = changeStreamingMode( DAG, DL, CalleeAttrs.hasStreamingInterface(), Chain, InGlue, @@ -8914,11 +8915,13 @@ AArch64TargetLowering::LowerCall(CallLoweringInfo &CLI, Result = changeStreamingMode( DAG, DL, !CalleeAttrs.hasStreamingInterface(), Result, InGlue, getSMCondition(CallerAttrs, CalleeAttrs), PStateSM); - InGlue = Result.getValue(1); - Result = - DAG.getNode(AArch64ISD::VG_RESTORE, DL, - DAG.getVTList(MVT::Other, MVT::Glue), {Result, InGlue}); + if (!Subtarget->isTargetDarwin() || Subtarget->hasSVE()) { + InGlue = Result.getValue(1); + Result = + DAG.getNode(AArch64ISD::VG_RESTORE, DL, + DAG.getVTList(MVT::Other, MVT::Glue), {Result, InGlue}); + } } if (CallerAttrs.requiresEnablingZAAfterCall(CalleeAttrs)) diff --git a/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchExpandPseudoInsts.cpp b/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchExpandPseudoInsts.cpp index c136f5b3e515..e680dda7374d 100644 --- a/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchExpandPseudoInsts.cpp +++ b/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchExpandPseudoInsts.cpp @@ -721,7 +721,7 @@ bool LoongArchExpandPseudo::expandFunctionCALL( IsTailCall ? LoongArch::PseudoJIRL_TAIL : LoongArch::PseudoJIRL_CALL; Register AddrReg = IsTailCall ? LoongArch::R19 : LoongArch::R1; - bool UseGOT = Func.isGlobal() && !Func.getGlobal()->isDSOLocal(); + bool UseGOT = Func.getTargetFlags() == LoongArchII::MO_CALL_PLT; unsigned MO = UseGOT ? LoongArchII::MO_GOT_PC_HI : LoongArchII::MO_PCREL_LO; unsigned LAOpcode = UseGOT ? LoongArch::LDX_D : LoongArch::ADD_D; expandLargeAddressLoad(MBB, MBBI, NextMBBI, LAOpcode, MO, Func, AddrReg, diff --git a/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchLSXInstrInfo.td b/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchLSXInstrInfo.td index 0580683c3ce3..0233baecf6dd 100644 --- a/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchLSXInstrInfo.td +++ b/contrib/llvm-project/llvm/lib/Target/LoongArch/LoongArchLSXInstrInfo.td @@ -67,8 +67,7 @@ class VecCondgetValueType(0).getVectorElementType(); @@ -109,8 +108,7 @@ def vsplati32_imm_eq_31 : PatFrags<(ops), [(build_vector)], [{ return selectVSplat(N, Imm, EltTy.getSizeInBits()) && Imm.getBitWidth() == EltTy.getSizeInBits() && Imm == 31; }]>; -def vsplati64_imm_eq_63 : PatFrags<(ops), [(build_vector), - (bitconvert (v4i32 (build_vector)))], [{ +def vsplati64_imm_eq_63 : PatFrags<(ops), [(build_vector)], [{ APInt Imm; EVT EltTy = N->getValueType(0).getVectorElementType(); diff --git a/contrib/llvm-project/llvm/lib/Target/LoongArch/MCTargetDesc/LoongArchMCTargetDesc.cpp b/contrib/llvm-project/llvm/lib/Target/LoongArch/MCTargetDesc/LoongArchMCTargetDesc.cpp index e40981f5b5cd..0712cc01ea03 100644 --- a/contrib/llvm-project/llvm/lib/Target/LoongArch/MCTargetDesc/LoongArchMCTargetDesc.cpp +++ b/contrib/llvm-project/llvm/lib/Target/LoongArch/MCTargetDesc/LoongArchMCTargetDesc.cpp @@ -55,7 +55,7 @@ static MCInstrInfo *createLoongArchMCInstrInfo() { static MCSubtargetInfo * createLoongArchMCSubtargetInfo(const Triple &TT, StringRef CPU, StringRef FS) { if (CPU.empty() || CPU == "generic") - CPU = TT.isArch64Bit() ? "la464" : "generic-la32"; + CPU = TT.isArch64Bit() ? "generic-la64" : "generic-la32"; return createLoongArchMCSubtargetInfoImpl(TT, CPU, /*TuneCPU*/ CPU, FS); } diff --git a/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp b/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp index f6f32fde3b77..a9ffd2bedf21 100644 --- a/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp +++ b/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp @@ -220,6 +220,10 @@ bool MipsDAGToDAGISel::selectVSplatMaskR(SDValue N, SDValue &Imm) const { return false; } +bool MipsDAGToDAGISel::selectVSplatImmEq1(SDValue N) const { + llvm_unreachable("Unimplemented function."); +} + /// Convert vector addition with vector subtraction if that allows to encode /// constant as an immediate and thus avoid extra 'ldi' instruction. /// add X, <-1, -1...> --> sub X, <1, 1...> diff --git a/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.h b/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.h index 6135f9680785..3485300a782c 100644 --- a/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.h +++ b/contrib/llvm-project/llvm/lib/Target/Mips/MipsISelDAGToDAG.h @@ -120,6 +120,9 @@ private: /// starting at bit zero. virtual bool selectVSplatMaskR(SDValue N, SDValue &Imm) const; + /// Select constant vector splats whose value is 1. + virtual bool selectVSplatImmEq1(SDValue N) const; + /// Convert vector addition with vector subtraction if that allows to encode /// constant as an immediate and thus avoid extra 'ldi' instruction. /// add X, <-1, -1...> --> sub X, <1, 1...> diff --git a/contrib/llvm-project/llvm/lib/Target/Mips/MipsMSAInstrInfo.td b/contrib/llvm-project/llvm/lib/Target/Mips/MipsMSAInstrInfo.td index c4abccb24c6f..f4c32c9dcd42 100644 --- a/contrib/llvm-project/llvm/lib/Target/Mips/MipsMSAInstrInfo.td +++ b/contrib/llvm-project/llvm/lib/Target/Mips/MipsMSAInstrInfo.td @@ -198,14 +198,8 @@ def vsplati32 : PatFrag<(ops node:$e0), (v4i32 (build_vector node:$e0, node:$e0, node:$e0, node:$e0))>; -def vsplati64_imm_eq_1 : PatLeaf<(bitconvert (v4i32 (build_vector))), [{ - APInt Imm; - SDNode *BV = N->getOperand(0).getNode(); - EVT EltTy = N->getValueType(0).getVectorElementType(); - - return selectVSplat(BV, Imm, EltTy.getSizeInBits()) && - Imm.getBitWidth() == EltTy.getSizeInBits() && Imm == 1; -}]>; +// Any build_vector that is a constant splat with a value that equals 1 +def vsplat_imm_eq_1 : ComplexPattern; def vsplati64 : PatFrag<(ops node:$e0), (v2i64 (build_vector node:$e0, node:$e0))>; @@ -217,7 +211,7 @@ def vsplati64_splat_d : PatFrag<(ops node:$e0), node:$e0, node:$e0, node:$e0)), - vsplati64_imm_eq_1))))>; + (vsplat_imm_eq_1)))))>; def vsplatf32 : PatFrag<(ops node:$e0), (v4f32 (build_vector node:$e0, node:$e0, @@ -352,46 +346,35 @@ def vsplat_maskr_bits_uimm6 : SplatComplexPattern; -// Any build_vector that is a constant splat with a value that equals 1 -// FIXME: These should be a ComplexPattern but we can't use them because the -// ISel generator requires the uses to have a name, but providing a name -// causes other errors ("used in pattern but not operand list") -def vsplat_imm_eq_1 : PatLeaf<(build_vector), [{ - APInt Imm; - EVT EltTy = N->getValueType(0).getVectorElementType(); - - return selectVSplat(N, Imm, EltTy.getSizeInBits()) && - Imm.getBitWidth() == EltTy.getSizeInBits() && Imm == 1; -}]>; def vbclr_b : PatFrag<(ops node:$ws, node:$wt), - (and node:$ws, (vnot (shl vsplat_imm_eq_1, node:$wt)))>; + (and node:$ws, (vnot (shl (vsplat_imm_eq_1), node:$wt)))>; def vbclr_h : PatFrag<(ops node:$ws, node:$wt), - (and node:$ws, (vnot (shl vsplat_imm_eq_1, node:$wt)))>; + (and node:$ws, (vnot (shl (vsplat_imm_eq_1), node:$wt)))>; def vbclr_w : PatFrag<(ops node:$ws, node:$wt), - (and node:$ws, (vnot (shl vsplat_imm_eq_1, node:$wt)))>; + (and node:$ws, (vnot (shl (vsplat_imm_eq_1), node:$wt)))>; def vbclr_d : PatFrag<(ops node:$ws, node:$wt), - (and node:$ws, (vnot (shl (v2i64 vsplati64_imm_eq_1), + (and node:$ws, (vnot (shl (v2i64 (vsplat_imm_eq_1)), node:$wt)))>; def vbneg_b : PatFrag<(ops node:$ws, node:$wt), - (xor node:$ws, (shl vsplat_imm_eq_1, node:$wt))>; + (xor node:$ws, (shl (vsplat_imm_eq_1), node:$wt))>; def vbneg_h : PatFrag<(ops node:$ws, node:$wt), - (xor node:$ws, (shl vsplat_imm_eq_1, node:$wt))>; + (xor node:$ws, (shl (vsplat_imm_eq_1), node:$wt))>; def vbneg_w : PatFrag<(ops node:$ws, node:$wt), - (xor node:$ws, (shl vsplat_imm_eq_1, node:$wt))>; + (xor node:$ws, (shl (vsplat_imm_eq_1), node:$wt))>; def vbneg_d : PatFrag<(ops node:$ws, node:$wt), - (xor node:$ws, (shl (v2i64 vsplati64_imm_eq_1), + (xor node:$ws, (shl (v2i64 (vsplat_imm_eq_1)), node:$wt))>; def vbset_b : PatFrag<(ops node:$ws, node:$wt), - (or node:$ws, (shl vsplat_imm_eq_1, node:$wt))>; + (or node:$ws, (shl (vsplat_imm_eq_1), node:$wt))>; def vbset_h : PatFrag<(ops node:$ws, node:$wt), - (or node:$ws, (shl vsplat_imm_eq_1, node:$wt))>; + (or node:$ws, (shl (vsplat_imm_eq_1), node:$wt))>; def vbset_w : PatFrag<(ops node:$ws, node:$wt), - (or node:$ws, (shl vsplat_imm_eq_1, node:$wt))>; + (or node:$ws, (shl (vsplat_imm_eq_1), node:$wt))>; def vbset_d : PatFrag<(ops node:$ws, node:$wt), - (or node:$ws, (shl (v2i64 vsplati64_imm_eq_1), + (or node:$ws, (shl (v2i64 (vsplat_imm_eq_1)), node:$wt))>; def muladd : PatFrag<(ops node:$wd, node:$ws, node:$wt), @@ -3842,7 +3825,7 @@ class MSAShiftPat : (VT (Insn VT:$ws, VT:$wt))>; class MSABitPat : - MSAPat<(VT (Node VT:$ws, (shl vsplat_imm_eq_1, (Frag VT:$wt)))), + MSAPat<(VT (Node VT:$ws, (shl (vsplat_imm_eq_1), (Frag VT:$wt)))), (VT (Insn VT:$ws, VT:$wt))>; multiclass MSAShiftPats { @@ -3861,7 +3844,7 @@ multiclass MSABitPats { def : MSABitPat(Insn#_B), vsplati8imm7>; def : MSABitPat(Insn#_H), vsplati16imm15>; def : MSABitPat(Insn#_W), vsplati32imm31>; - def : MSAPat<(Node v2i64:$ws, (shl (v2i64 vsplati64_imm_eq_1), + def : MSAPat<(Node v2i64:$ws, (shl (v2i64 (vsplat_imm_eq_1)), (vsplati64imm63 v2i64:$wt))), (v2i64 (!cast(Insn#_D) v2i64:$ws, v2i64:$wt))>; } @@ -3872,16 +3855,16 @@ defm : MSAShiftPats; defm : MSABitPats; defm : MSABitPats; -def : MSAPat<(and v16i8:$ws, (vnot (shl vsplat_imm_eq_1, +def : MSAPat<(and v16i8:$ws, (vnot (shl (vsplat_imm_eq_1), (vsplati8imm7 v16i8:$wt)))), (v16i8 (BCLR_B v16i8:$ws, v16i8:$wt))>; -def : MSAPat<(and v8i16:$ws, (vnot (shl vsplat_imm_eq_1, +def : MSAPat<(and v8i16:$ws, (vnot (shl (vsplat_imm_eq_1), (vsplati16imm15 v8i16:$wt)))), (v8i16 (BCLR_H v8i16:$ws, v8i16:$wt))>; -def : MSAPat<(and v4i32:$ws, (vnot (shl vsplat_imm_eq_1, +def : MSAPat<(and v4i32:$ws, (vnot (shl (vsplat_imm_eq_1), (vsplati32imm31 v4i32:$wt)))), (v4i32 (BCLR_W v4i32:$ws, v4i32:$wt))>; -def : MSAPat<(and v2i64:$ws, (vnot (shl (v2i64 vsplati64_imm_eq_1), +def : MSAPat<(and v2i64:$ws, (vnot (shl (v2i64 (vsplat_imm_eq_1)), (vsplati64imm63 v2i64:$wt)))), (v2i64 (BCLR_D v2i64:$ws, v2i64:$wt))>; diff --git a/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp b/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp index 7ad300c6cccd..66c034a889c6 100644 --- a/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp +++ b/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp @@ -730,6 +730,18 @@ bool MipsSEDAGToDAGISel::selectVSplatUimmInvPow2(SDValue N, return false; } +// Select const vector splat of 1. +bool MipsSEDAGToDAGISel::selectVSplatImmEq1(SDValue N) const { + APInt ImmValue; + EVT EltTy = N->getValueType(0).getVectorElementType(); + + if (N->getOpcode() == ISD::BITCAST) + N = N->getOperand(0); + + return selectVSplat(N.getNode(), ImmValue, EltTy.getSizeInBits()) && + ImmValue.getBitWidth() == EltTy.getSizeInBits() && ImmValue == 1; +} + bool MipsSEDAGToDAGISel::trySelect(SDNode *Node) { unsigned Opcode = Node->getOpcode(); SDLoc DL(Node); diff --git a/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.h b/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.h index 7b843b0e0b25..22d8e924ac53 100644 --- a/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.h +++ b/contrib/llvm-project/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.h @@ -124,6 +124,9 @@ private: /// starting at bit zero. bool selectVSplatMaskR(SDValue N, SDValue &Imm) const override; + /// Select constant vector splats whose value is 1. + bool selectVSplatImmEq1(SDValue N) const override; + bool trySelect(SDNode *Node) override; // Emits proper ABI for _mcount profiling calls. diff --git a/contrib/llvm-project/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp b/contrib/llvm-project/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp index 6975412ce5d3..b2153a7afe73 100644 --- a/contrib/llvm-project/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp +++ b/contrib/llvm-project/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp @@ -229,6 +229,10 @@ static void ComputePTXValueVTs(const TargetLowering &TLI, const DataLayout &DL, // v*i8 are formally lowered as v4i8 EltVT = MVT::v4i8; NumElts = (NumElts + 3) / 4; + } else if (EltVT.getSimpleVT() == MVT::i8 && NumElts == 2) { + // v2i8 is promoted to v2i16 + NumElts = 1; + EltVT = MVT::v2i16; } for (unsigned j = 0; j != NumElts; ++j) { ValueVTs.push_back(EltVT); diff --git a/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp b/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp index 9d2990c98ce2..3223fccbcf49 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp @@ -506,8 +506,10 @@ static Instruction *foldCttzCtlz(IntrinsicInst &II, InstCombinerImpl &IC) { // If ctlz/cttz is only used as a shift amount, set is_zero_poison to true. if (II.hasOneUse() && match(Op1, m_Zero()) && - match(II.user_back(), m_Shift(m_Value(), m_Specific(&II)))) + match(II.user_back(), m_Shift(m_Value(), m_Specific(&II)))) { + II.dropUBImplyingAttrsAndMetadata(); return IC.replaceOperand(II, 1, IC.Builder.getTrue()); + } Constant *C; diff --git a/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp b/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp index 8a6ec3076ac6..b9d06b593685 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp @@ -1004,7 +1004,7 @@ Value *InstCombinerImpl::SimplifyDemandedUseBits(Instruction *I, uint64_t MaskedGEPIndex = HighBitsGEPIndex | MaskedLowBitsGEPIndex; if (MaskedGEPIndex != GEPIndex) { - auto *GEP = cast(II->getArgOperand(0)); + auto *GEP = cast(II->getArgOperand(0)); Builder.SetInsertPoint(I); Type *GEPIndexType = DL.getIndexType(GEP->getPointerOperand()->getType()); diff --git a/contrib/llvm-project/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp b/contrib/llvm-project/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp index 37022104d0a9..d1c80aa67124 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp @@ -1033,9 +1033,9 @@ void State::addInfoForInductions(BasicBlock &BB) { DTN, CmpInst::ICMP_SLT, PN, B, ConditionTy(CmpInst::ICMP_SLE, StartValue, B))); - // Try to add condition from header to the exit blocks. When exiting either - // with EQ or NE in the header, we know that the induction value must be u<= - // B, as other exits may only exit earlier. + // Try to add condition from header to the dedicated exit blocks. When exiting + // either with EQ or NE in the header, we know that the induction value must + // be u<= B, as other exits may only exit earlier. assert(!StepOffset.isNegative() && "induction must be increasing"); assert((Pred == CmpInst::ICMP_EQ || Pred == CmpInst::ICMP_NE) && "unsupported predicate"); @@ -1043,8 +1043,11 @@ void State::addInfoForInductions(BasicBlock &BB) { SmallVector ExitBBs; L->getExitBlocks(ExitBBs); for (BasicBlock *EB : ExitBBs) { - WorkList.emplace_back(FactOrCheck::getConditionFact( - DT.getNode(EB), CmpInst::ICMP_ULE, A, B, Precond)); + // Bail out on non-dedicated exits. + if (DT.dominates(&BB, EB)) { + WorkList.emplace_back(FactOrCheck::getConditionFact( + DT.getNode(EB), CmpInst::ICMP_ULE, A, B, Precond)); + } } } diff --git a/contrib/llvm-project/llvm/lib/Transforms/Scalar/LICM.cpp b/contrib/llvm-project/llvm/lib/Transforms/Scalar/LICM.cpp index 91ef2b4b7c18..ca03eff7a4e2 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Scalar/LICM.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Scalar/LICM.cpp @@ -1464,8 +1464,11 @@ static Instruction *cloneInstructionInExitBlock( if (MSSAU.getMemorySSA()->getMemoryAccess(&I)) { // Create a new MemoryAccess and let MemorySSA set its defining access. + // After running some passes, MemorySSA might be outdated, and the + // instruction `I` may have become a non-memory touching instruction. MemoryAccess *NewMemAcc = MSSAU.createMemoryAccessInBB( - New, nullptr, New->getParent(), MemorySSA::Beginning); + New, nullptr, New->getParent(), MemorySSA::Beginning, + /*CreationMustSucceed=*/false); if (NewMemAcc) { if (auto *MemDef = dyn_cast(NewMemAcc)) MSSAU.insertDef(MemDef, /*RenameUses=*/true); diff --git a/contrib/llvm-project/llvm/lib/Transforms/Utils/Local.cpp b/contrib/llvm-project/llvm/lib/Transforms/Utils/Local.cpp index 7192efe3f16b..f68cbf62b982 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Utils/Local.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Utils/Local.cpp @@ -1028,7 +1028,13 @@ CanRedirectPredsOfEmptyBBToSucc(BasicBlock *BB, BasicBlock *Succ, if (!BB->hasNPredecessorsOrMore(2)) return false; - // Get single common predecessors of both BB and Succ + if (any_of(BBPreds, [](const BasicBlock *Pred) { + return isa(Pred->getTerminator()); + })) + return false; + + // Get the single common predecessor of both BB and Succ. Return false + // when there are more than one common predecessors. for (BasicBlock *SuccPred : SuccPreds) { if (BBPreds.count(SuccPred)) { if (CommonPred) @@ -1133,7 +1139,7 @@ bool llvm::TryToSimplifyUncondBranchFromEmptyBlock(BasicBlock *BB, bool BBKillable = CanPropagatePredecessorsForPHIs(BB, Succ, BBPreds); - // Even if we can not fold bB into Succ, we may be able to redirect the + // Even if we can not fold BB into Succ, we may be able to redirect the // predecessors of BB to Succ. bool BBPhisMergeable = BBKillable || diff --git a/contrib/llvm-project/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp b/contrib/llvm-project/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp index ab2b96cdc42d..746ba51a981f 100644 --- a/contrib/llvm-project/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp +++ b/contrib/llvm-project/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp @@ -15440,9 +15440,25 @@ bool BoUpSLP::collectValuesToDemote( MaskedValueIsZero(I->getOperand(1), Mask, SimplifyQuery(*DL))); }); }; + auto AbsChecker = [&](unsigned BitWidth, unsigned OrigBitWidth) { + assert(BitWidth <= OrigBitWidth && "Unexpected bitwidths!"); + return all_of(E.Scalars, [&](Value *V) { + auto *I = cast(V); + unsigned SignBits = OrigBitWidth - BitWidth; + APInt Mask = APInt::getBitsSetFrom(OrigBitWidth, BitWidth - 1); + unsigned Op0SignBits = + ComputeNumSignBits(I->getOperand(0), *DL, 0, AC, nullptr, DT); + return SignBits <= Op0SignBits && + ((SignBits != Op0SignBits && + !isKnownNonNegative(I->getOperand(0), SimplifyQuery(*DL))) || + MaskedValueIsZero(I->getOperand(0), Mask, SimplifyQuery(*DL))); + }); + }; if (ID != Intrinsic::abs) { Operands.push_back(getOperandEntry(&E, 1)); CallChecker = CompChecker; + } else { + CallChecker = AbsChecker; } InstructionCost BestCost = std::numeric_limits::max(); diff --git a/contrib/llvm-project/llvm/utils/TableGen/Common/CodeGenDAGPatterns.cpp b/contrib/llvm-project/llvm/utils/TableGen/Common/CodeGenDAGPatterns.cpp index a8cecca0d4a5..ca71569008d5 100644 --- a/contrib/llvm-project/llvm/utils/TableGen/Common/CodeGenDAGPatterns.cpp +++ b/contrib/llvm-project/llvm/utils/TableGen/Common/CodeGenDAGPatterns.cpp @@ -3042,6 +3042,14 @@ static bool SimplifyTree(TreePatternNodePtr &N) { !N->getExtType(0).empty() && N->getExtType(0) == N->getChild(0).getExtType(0) && N->getName().empty()) { + if (!N->getPredicateCalls().empty()) { + std::string Str; + raw_string_ostream OS(Str); + OS << *N + << "\n trivial bitconvert node should not have predicate calls\n"; + PrintFatalError(Str); + return false; + } N = N->getChildShared(0); SimplifyTree(N); return true; diff --git a/lib/clang/include/VCSVersion.inc b/lib/clang/include/VCSVersion.inc index 2197c8ca2947..7624a2e4b17a 100644 --- a/lib/clang/include/VCSVersion.inc +++ b/lib/clang/include/VCSVersion.inc @@ -1,8 +1,8 @@ -#define LLVM_REVISION "llvmorg-19.1.4-0-gaadaa00de76e" +#define LLVM_REVISION "llvmorg-19.1.5-0-gab4b5a2db582" #define LLVM_REPOSITORY "https://github.com/llvm/llvm-project.git" -#define CLANG_REVISION "llvmorg-19.1.4-0-gaadaa00de76e" +#define CLANG_REVISION "llvmorg-19.1.5-0-gab4b5a2db582" #define CLANG_REPOSITORY "https://github.com/llvm/llvm-project.git" -#define LLDB_REVISION "llvmorg-19.1.4-0-gaadaa00de76e" +#define LLDB_REVISION "llvmorg-19.1.5-0-gab4b5a2db582" #define LLDB_REPOSITORY "https://github.com/llvm/llvm-project.git" diff --git a/lib/clang/include/clang/Basic/Version.inc b/lib/clang/include/clang/Basic/Version.inc index d7a4777e7cec..5104f9d7ad7a 100644 --- a/lib/clang/include/clang/Basic/Version.inc +++ b/lib/clang/include/clang/Basic/Version.inc @@ -1,8 +1,8 @@ -#define CLANG_VERSION 19.1.4 -#define CLANG_VERSION_STRING "19.1.4" +#define CLANG_VERSION 19.1.5 +#define CLANG_VERSION_STRING "19.1.5" #define CLANG_VERSION_MAJOR 19 #define CLANG_VERSION_MAJOR_STRING "19" #define CLANG_VERSION_MINOR 1 -#define CLANG_VERSION_PATCHLEVEL 4 +#define CLANG_VERSION_PATCHLEVEL 5 #define CLANG_VENDOR "FreeBSD " diff --git a/lib/clang/include/lld/Common/Version.inc b/lib/clang/include/lld/Common/Version.inc index b041a27576fb..6cf430b53591 100644 --- a/lib/clang/include/lld/Common/Version.inc +++ b/lib/clang/include/lld/Common/Version.inc @@ -1,4 +1,4 @@ // Local identifier in __FreeBSD_version style #define LLD_FREEBSD_VERSION 1400007 -#define LLD_VERSION_STRING "19.1.4 (FreeBSD llvmorg-19.1.4-0-gaadaa00de76e-" __XSTRING(LLD_FREEBSD_VERSION) ")" +#define LLD_VERSION_STRING "19.1.5 (FreeBSD llvmorg-19.1.5-0-gab4b5a2db582-" __XSTRING(LLD_FREEBSD_VERSION) ")" diff --git a/lib/clang/include/lldb/Version/Version.inc b/lib/clang/include/lldb/Version/Version.inc index d69a702815ff..5aa1f29215b4 100644 --- a/lib/clang/include/lldb/Version/Version.inc +++ b/lib/clang/include/lldb/Version/Version.inc @@ -1,6 +1,6 @@ -#define LLDB_VERSION 19.1.4 -#define LLDB_VERSION_STRING "19.1.4" +#define LLDB_VERSION 19.1.5 +#define LLDB_VERSION_STRING "19.1.5" #define LLDB_VERSION_MAJOR 19 #define LLDB_VERSION_MINOR 1 -#define LLDB_VERSION_PATCH 4 +#define LLDB_VERSION_PATCH 5 /* #undef LLDB_FULL_VERSION_STRING */ diff --git a/lib/clang/include/llvm/Config/config.h b/lib/clang/include/llvm/Config/config.h index a775cc7e9bbf..f86e4b6b5946 100644 --- a/lib/clang/include/llvm/Config/config.h +++ b/lib/clang/include/llvm/Config/config.h @@ -338,10 +338,10 @@ #define PACKAGE_NAME "LLVM" /* Define to the full name and version of this package. */ -#define PACKAGE_STRING "LLVM 19.1.4" +#define PACKAGE_STRING "LLVM 19.1.5" /* Define to the version of this package. */ -#define PACKAGE_VERSION "19.1.4" +#define PACKAGE_VERSION "19.1.5" /* Define to the vendor of this package. */ /* #undef PACKAGE_VENDOR */ diff --git a/lib/clang/include/llvm/Config/llvm-config.h b/lib/clang/include/llvm/Config/llvm-config.h index 16af33f177e6..966249436723 100644 --- a/lib/clang/include/llvm/Config/llvm-config.h +++ b/lib/clang/include/llvm/Config/llvm-config.h @@ -176,10 +176,10 @@ #define LLVM_VERSION_MINOR 1 /* Patch version of the LLVM API */ -#define LLVM_VERSION_PATCH 4 +#define LLVM_VERSION_PATCH 5 /* LLVM version string */ -#define LLVM_VERSION_STRING "19.1.4" +#define LLVM_VERSION_STRING "19.1.5" /* Whether LLVM records statistics for use with GetStatistics(), * PrintStatistics() or PrintStatisticsJSON() diff --git a/lib/clang/include/llvm/Support/VCSRevision.h b/lib/clang/include/llvm/Support/VCSRevision.h index 68785cd03f5d..db3347a0e5a5 100644 --- a/lib/clang/include/llvm/Support/VCSRevision.h +++ b/lib/clang/include/llvm/Support/VCSRevision.h @@ -1,2 +1,2 @@ -#define LLVM_REVISION "llvmorg-19.1.4-0-gaadaa00de76e" +#define LLVM_REVISION "llvmorg-19.1.5-0-gab4b5a2db582" #define LLVM_REPOSITORY "https://github.com/llvm/llvm-project.git" From nobody Wed Dec 11 17:47:50 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 4Y7jjy5DSRz5gFk4; Wed, 11 Dec 2024 17:47:50 +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 4Y7jjy4hxgz4LCg; Wed, 11 Dec 2024 17:47:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733939270; 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=+zZtVEW2dTM1SsmpG0X34hbFworx4hKTDgJR+ioSrWU=; b=ndODUHN2q9mm15t9rjfbw32za0xlomYgsm73L6okC0VWMQmEYSUhRbD/7PPZOws/jyszdu NezWaeT3c+Z3y2kUaLW9sFmvT7OC3OL438M+gOthsyawT7lDktd677k+W7tp5omCdVWupK YqVkJnsdP6xtyrwsz2mp2L1y2KuKXn1lOC0a+a8hU8BXj0G+LrOcwRQ+qCoHAVj5qXVVih oT840w3mc4vLVzj0+/NE8ijj5wdYbNbEvYxEr4QbdbLz4crG6uI7LNAkb8tNZrFW/BbFTJ fChKr7bco3yk1SX0Khy+I/gHFKbmNqwXt9p/T+GOE75/dYMSImLAMTaZAFcXsw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733939270; 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=+zZtVEW2dTM1SsmpG0X34hbFworx4hKTDgJR+ioSrWU=; b=lRsjIgsFHBZc9QEE9T/++mRlnI9c5vPm9WwAkAypMgkcVZ4u4tBluY4He21Fe+XlidsaVv rXeiH5kTkJmwTHO2lLdmkpuK6Hl3sMvyUvFBpQ355EsJrEtzngEcTCFJbDpaB8PWn+ByaZ fBY8iHpbfWwn3/y+DUJL83y+FFwWa8PXR7EbOdlmmpWSQXiSHNpOlYyGEzps9uSTAVvnZA QFyLzZ6hNnaglnqi/HobcxEfnN4g6uymdO7aNryEJpRCkIuu3Bo27Da/ftV5dafJXRFFdb mqFMeJdT2OWM+Mwyh3qXPWJ9xzCfV+FuXrwEg2VOnR+Pnf1Aue5KPaUrbvFQ7w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733939270; a=rsa-sha256; cv=none; b=WzC7lyPzXwjJBGoqWjB4FyXUoozYlC+tv7S42nzBAJggGd9Bdps3HqZbPf+AnM4UwpcnCQ sGvlLTHlJBfVD9slw+ckFQ7pNfvkdS7svZ0ENytm31Z/SJQ+i9r8ZYKNB5saeBTUbG5i/D rWBTjXWOPXODg1PJ+E/y+Pr1QwlR2aX+Om4cOwP4EoVO1tL1/epLe+Jwce5xDNCUee5Mdm eDbvK2TxGKBB/umM8MZCqP8JiQGsNXrAWMta+8QKcdyO/OzGBEb1ug1eXvKgI5X7TFZ/qp UaN1W6DE0OKIyUXTfFe9bu8XPhakLKJCBA6oUi+5Gfc6WAafEJbvtUKd4QdDMA== 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 4Y7jjy4G25zHQ7; Wed, 11 Dec 2024 17:47:50 +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 4BBHloK4049193; Wed, 11 Dec 2024 17:47:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BBHloZj049190; Wed, 11 Dec 2024 17:47:50 GMT (envelope-from git) Date: Wed, 11 Dec 2024 17:47:50 GMT Message-Id: <202412111747.4BBHloZj049190@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Andrew Turner Subject: git: 37bb465d27ee - main - buf_ring: Remove an unneeded barrier 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: andrew X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 37bb465d27eefd2237e6e3af9592457fccf324e2 Auto-Submitted: auto-generated The branch main has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=37bb465d27eefd2237e6e3af9592457fccf324e2 commit 37bb465d27eefd2237e6e3af9592457fccf324e2 Author: Andrew Turner AuthorDate: 2024-12-11 15:15:25 +0000 Commit: Andrew Turner CommitDate: 2024-12-11 17:02:24 +0000 buf_ring: Remove an unneeded barrier This was left over from before using atomic(9) consistently. It is unneeded as these loads are already ordered correctly. Reviewed by: alc, kib Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D48002 --- sys/sys/buf_ring.h | 1 - 1 file changed, 1 deletion(-) diff --git a/sys/sys/buf_ring.h b/sys/sys/buf_ring.h index ab7e683ed0e9..00870cbf3531 100644 --- a/sys/sys/buf_ring.h +++ b/sys/sys/buf_ring.h @@ -107,7 +107,6 @@ buf_ring_enqueue(struct buf_ring *br, void *buf) cons_tail = atomic_load_acq_32(&br->br_cons_tail); if ((int32_t)(cons_tail + br->br_prod_size - prod_next) < 1) { - rmb(); if (prod_head == atomic_load_32(&br->br_prod_head) && cons_tail == atomic_load_32(&br->br_cons_tail)) { br->br_drops++; From nobody Wed Dec 11 17:47:51 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 4Y7jjz6MPbz5gFrp; Wed, 11 Dec 2024 17:47:51 +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 4Y7jjz5kgQz4L2B; Wed, 11 Dec 2024 17:47:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733939271; 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=MRFbsrre7pm6S5l6omvnpe6Eg7q3l5zrZeXL4J29sCk=; b=SxOehDwo3Fup0SpgDoUaVza164SYihx2zUYgnetr/f4vTSF7cuujzMytB3Ad0jeL2fxiLW mJOSTmLGA6gSgZHYs6/4XMiXHYWFBrCW4bpyVJ2qnc8QqrZDGTu47/4IyPh2l2AaIBpAEf xtVg6SYgx/LfVU2ER9v2+o0dCwp7lR82KfILfRR/78ods5+TAZMeN/wUcqfbRlZZDnKTlh Tv+6Cd1vTVKExKcUTOi4A57EDaPTSs2nNGy2czqvEJLQSpl0ilcIUu8JbXdZwc6dwG7SWC gDXM4G3Zm+vFE+qyrrGhQ/LsZSolM+QCjZ4yiE505VKKExRW+xMN6EZ8elE/KA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733939271; 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=MRFbsrre7pm6S5l6omvnpe6Eg7q3l5zrZeXL4J29sCk=; b=XxDPViTwVIOsDJkuGpGLpduG9rWme7dXXO5nBs/C/peGT1W0RujXdfU0dTlPrAKAHC6tT9 mmdukETdW4fxCwvLAafO/mbTjGXFTZCFKCgEUhkRoVHUZJ91A4WENV/qNzbLAdlULGOLsJ cD1oHRVvyal2+GmG9VOY09soJNwln29bD61l1b04NqE/28hInYGytCwxUtGth/1ZIL9JiV gsmtbOSYqUnvzAKfIX4YEXJhisFFQ7YfeK9PE4nYQRSsQugO6W1nhxNfjLu7lmbP8/PItF TE5S7NQzdkil15/R9cRmz2zpw86KOET44grk0aiHtlcRk4fd7S8w7Yjf5UDtDg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733939271; a=rsa-sha256; cv=none; b=x6XaC01rF8SmkWaJfJIvaRQK2W/DFZEciRvunicxGnWvuXBC8FFeLSZ3ZbVmtgWo+vGo2C cu4yGhdNNV7+pgT2Ae075xU6qMaQeVNlqdmgbVPuxe5ILlFH120IPezht+R5/+njJxGR/+ BDYvauOWlzsoEq3Svbxv+mV0IuTsQCeTou4qejWir0JXeV/soEYWLxCZ7BrX4G50uRmG5X EyR7rYxmjYdt7gjChdSukYYm2FNfWDJNj4o3uK3fXsq5LhlCZEH5nEr0krWscpSFNV0V9K 7BajAFjeN6VXrmIuPjf8Y2R1RUAYwrHR+9DNG0aW1v9YjsvxwSjYK9BF3sglig== 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 4Y7jjz5KTxzJ2T; Wed, 11 Dec 2024 17:47:51 +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 4BBHlpMG049249; Wed, 11 Dec 2024 17:47:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BBHlpjI049245; Wed, 11 Dec 2024 17:47:51 GMT (envelope-from git) Date: Wed, 11 Dec 2024 17:47:51 GMT Message-Id: <202412111747.4BBHlpjI049245@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Andrew Turner Subject: git: 4056e774b1b3 - main - arm64: Move setting TCR_HD to C code 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: andrew X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 4056e774b1b3b07db83fcf3dea2e62d0bf02cd9b Auto-Submitted: auto-generated The branch main has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=4056e774b1b3b07db83fcf3dea2e62d0bf02cd9b commit 4056e774b1b3b07db83fcf3dea2e62d0bf02cd9b Author: Andrew Turner AuthorDate: 2024-12-11 15:48:56 +0000 Commit: Andrew Turner CommitDate: 2024-12-11 17:02:24 +0000 arm64: Move setting TCR_HD to C code To allow for it to be more selective when we enable it, e.g. if the CPU has an erratum that prevents us from doing so, move the check for setting TCR_HD to C. Reviewed by: alc Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D47808 --- sys/arm64/arm64/locore.S | 17 +++++++---------- sys/arm64/arm64/mp_machdep.c | 1 + sys/arm64/arm64/pmap.c | 21 +++++++++++++++++++++ sys/arm64/include/pmap.h | 1 + 4 files changed, 30 insertions(+), 10 deletions(-) diff --git a/sys/arm64/arm64/locore.S b/sys/arm64/arm64/locore.S index f9a179931d7d..e721092455e8 100644 --- a/sys/arm64/arm64/locore.S +++ b/sys/arm64/arm64/locore.S @@ -940,20 +940,17 @@ LENTRY(start_mmu) bfi x2, x3, #(TCR_ASID_SHIFT), #(TCR_ASID_WIDTH) /* - * Check if the HW supports access flag and dirty state updates, - * and set TCR_EL1.HA and TCR_EL1.HD accordingly. + * Check if the HW supports access flag updates, and set + * TCR_EL1.HA accordingly. The TCR_EL1.HD flag to enable + * HW management of dirty state is set in C code as it may + * need to be disabled because of CPU errata. */ mrs x3, id_aa64mmfr1_el1 and x3, x3, #(ID_AA64MMFR1_HAFDBS_MASK) - cmp x3, #1 - b.ne 1f - orr x2, x2, #(TCR_HA) - b 2f + cbz x3, 1f + orr x2, x2, #(TCR_HA) 1: - cmp x3, #2 - b.ne 2f - orr x2, x2, #(TCR_HA | TCR_HD) -2: + msr tcr_el1, x2 /* diff --git a/sys/arm64/arm64/mp_machdep.c b/sys/arm64/arm64/mp_machdep.c index e9b015443477..636f26fba939 100644 --- a/sys/arm64/arm64/mp_machdep.c +++ b/sys/arm64/arm64/mp_machdep.c @@ -219,6 +219,7 @@ init_secondary(uint64_t cpu) pcpup = cpuid_to_pcpu[cpu]; pcpup->pc_midr = get_midr(); identify_cpu(cpu); + pmap_cpu_init(); /* Ensure the stores in identify_cpu have completed */ atomic_thread_fence_acq_rel(); diff --git a/sys/arm64/arm64/pmap.c b/sys/arm64/arm64/pmap.c index 17e34888282a..b8f519388977 100644 --- a/sys/arm64/arm64/pmap.c +++ b/sys/arm64/arm64/pmap.c @@ -1309,6 +1309,8 @@ pmap_bootstrap(vm_size_t kernlen) vm_paddr_t start_pa, pa; uint64_t tcr; + pmap_cpu_init(); + tcr = READ_SPECIALREG(tcr_el1); /* Verify that the ASID is set through TTBR0. */ @@ -1623,6 +1625,25 @@ pmap_init_pv_table(void) } } +void +pmap_cpu_init(void) +{ + uint64_t id_aa64mmfr1, tcr; + + /* Enable HAFDBS if supported */ + id_aa64mmfr1 = READ_SPECIALREG(id_aa64mmfr1_el1); + if (ID_AA64MMFR1_HAFDBS_VAL(id_aa64mmfr1) >=ID_AA64MMFR1_HAFDBS_AF_DBS){ + tcr = READ_SPECIALREG(tcr_el1) | TCR_HD; + WRITE_SPECIALREG(tcr_el1, tcr); + isb(); + /* Flush the local TLB for the TCR_HD flag change */ + dsb(nshst); + __asm __volatile("tlbi vmalle1"); + dsb(nsh); + isb(); + } +} + /* * Initialize the pmap module. * diff --git a/sys/arm64/include/pmap.h b/sys/arm64/include/pmap.h index 8bdb4cf025e3..d92069ee42fd 100644 --- a/sys/arm64/include/pmap.h +++ b/sys/arm64/include/pmap.h @@ -140,6 +140,7 @@ extern pt_entry_t pmap_sh_attr; void pmap_activate_vm(pmap_t); void pmap_bootstrap(vm_size_t); +void pmap_cpu_init(void); int pmap_change_attr(vm_offset_t va, vm_size_t size, int mode); int pmap_change_prot(vm_offset_t va, vm_size_t size, vm_prot_t prot); void pmap_kenter(vm_offset_t sva, vm_size_t size, vm_paddr_t pa, int mode); From nobody Wed Dec 11 17:47:52 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 4Y7jk112d8z5gFrs; Wed, 11 Dec 2024 17:47:53 +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 4Y7jk06n6fz4LKM; Wed, 11 Dec 2024 17:47:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733939272; 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=54s/K7LtWOnQANA5dZNSszOAWjmcDJ6FxBO+/r2JWWg=; b=RQLWxKlhGEQjIGN6+ypBRxhdZWup+shiiVz4deaQZ078Hz3d/+Mixr1p1S6vunIF5fsiCl mhZ8hqCq8ahcHk5vfPVIR+7+mhUu7gJ8pxFdNxbEGn4oPpjEj7Z9Gu48cxw77rDOZceHHy VIeoO9nGVsA1sj6heM+clcMfwSgMQYDVZaVP062hxU5EzvsZi5ZPFzV9tjMlx1Y2RwnlT4 eCoYeuw+U15jpQ8p7cgNbE47RMo/IzP2mhuElyqyNZZTkG0BQsaRAaZM7fh2paUvn+8oZp SARKNAJV2x+CW1wp8G646PI1H4ASfZz3ZGUIyAuIrLbt+2uQDvfPf2ZE8b0eZQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733939272; 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=54s/K7LtWOnQANA5dZNSszOAWjmcDJ6FxBO+/r2JWWg=; b=JkkY2Oy0xGLHCcf/MOzQwx9HtugJEOC4QapSrFxIFp13ICqc1OUTug9nO3Ap3WpbKQTBrI 29WsRCTVbDE8nZCCN1gaEAQoAjxjzmFTAdIOgVg7fy2/VwZp1xjjZQgE01bn32f9GrXidx TBN/JFlR7h/I4tfpCjmFDza+oJ6YWwfU/Wa9o0/mpXx0osaAaybiJjk/R23yvJOGUmKdtk H/09fDfxeWJnTrrEFiR1T0k2QUw0v1ABvHmrZimLBkZEclr+N+8C+eyTfCrqzlEIRot4uW VHBW7UwABDJjFP6z/dYCf9iHe9Y0kVszQvqHGtDGbqlunmDhu063BlYQvYBz+g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733939272; a=rsa-sha256; cv=none; b=COsYIGJozs4v9nZVqn6oDHW+ZNUiWZW24h4d7rOXi35hb5q2iHnrdnHOzxiqPHOhofikTn JD0XFuLUBj21nHxeWIcLiliPkVsTmUuaVPMTOUhc+qXrZQJl6yTsET99F0XZBGVY53MWDk W1zmCMHVtWH7UKGcMoGlT0n2Pm4r9H9/E32OVsqtgR2OKaffgzwQLtIgbibgwc7zZ9YTtG amN2m8rnf9z3bV2QTyfDiMd/eMsgHboPCk2kiuzZHHrqkVJ0UJOoWdEFlUu2mDHhzOQ6h0 q4/sKtBmRLT3OYixGbsJ8JcgTlzZnnlbRgNPj8SwUHG+fdL/wPuIvPV9zZ1+xQ== 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 4Y7jk06P0ZzHc3; Wed, 11 Dec 2024 17:47:52 +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 4BBHlqcH049294; Wed, 11 Dec 2024 17:47:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BBHlq08049291; Wed, 11 Dec 2024 17:47:52 GMT (envelope-from git) Date: Wed, 11 Dec 2024 17:47:52 GMT Message-Id: <202412111747.4BBHlq08049291@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Andrew Turner Subject: git: e7bc16422031 - main - arm64: Add a DBM errata workaround 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: andrew X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e7bc16422031803823fd6ef0c5083631dc7dfffc Auto-Submitted: auto-generated The branch main has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=e7bc16422031803823fd6ef0c5083631dc7dfffc commit e7bc16422031803823fd6ef0c5083631dc7dfffc Author: Andrew Turner AuthorDate: 2024-12-11 15:49:15 +0000 Commit: Andrew Turner CommitDate: 2024-12-11 17:02:24 +0000 arm64: Add a DBM errata workaround Add a workaround for Cortex-A55 erratum 1024718 and Cortex-A510 erratum 2051678. Both errata are related to the hardware handling of the dirty field in page tables and can be worked around by disabling this feature. Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D47809 --- sys/arm64/arm64/pmap.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/sys/arm64/arm64/pmap.c b/sys/arm64/arm64/pmap.c index b8f519388977..fd6798668626 100644 --- a/sys/arm64/arm64/pmap.c +++ b/sys/arm64/arm64/pmap.c @@ -1629,10 +1629,24 @@ void pmap_cpu_init(void) { uint64_t id_aa64mmfr1, tcr; + bool enable_dbm; + + enable_dbm = false; /* Enable HAFDBS if supported */ id_aa64mmfr1 = READ_SPECIALREG(id_aa64mmfr1_el1); - if (ID_AA64MMFR1_HAFDBS_VAL(id_aa64mmfr1) >=ID_AA64MMFR1_HAFDBS_AF_DBS){ + if (ID_AA64MMFR1_HAFDBS_VAL(id_aa64mmfr1) >= ID_AA64MMFR1_HAFDBS_AF_DBS) + enable_dbm = true; + /* Disable on Cortex-A55 for erratum 1024718 - all revisions */ + if (CPU_MATCH(CPU_IMPL_MASK | CPU_PART_MASK, CPU_IMPL_ARM, + CPU_PART_CORTEX_A55, 0, 0)) + enable_dbm = false; + /* Disable on Cortex-A510 for erratum 2051678 - r0p0 to r0p2 */ + else if (CPU_MATCH(CPU_IMPL_MASK | CPU_PART_MASK | CPU_VAR_MASK, + CPU_IMPL_ARM, CPU_PART_CORTEX_A510, 0, 0)) + if (CPU_REV(PCPU_GET(midr)) < 3) + enable_dbm = false; + if (enable_dbm) { tcr = READ_SPECIALREG(tcr_el1) | TCR_HD; WRITE_SPECIALREG(tcr_el1, tcr); isb(); From nobody Wed Dec 11 18:24:44 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 4Y7kXX6CJyz5gHdy; Wed, 11 Dec 2024 18:24:44 +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 4Y7kXX5dtfz4RBp; Wed, 11 Dec 2024 18:24:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733941484; 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=PDjgb70BAokXGdyDeERTJStgD6lQGRQiAG252Tw5mCE=; b=gVtf8SupakVtBUnQReU3lzg19uPnUj0Jc3DHudKOvSdz9PYJCTb7gsOinyN1ngSF7ZrFYV pDPqECjnyeHBNOYyzOl/CW7Pglgmly07SUx2PIcbC+oNrnDzua/BzMdxMWMD+UiS7EpPGX YyPSBJe28vQ+wKT5VeKWM7KfzRmD6TXQJkFUSVALoz1Mu+w40Y2xGcr/4CiZlSORacxICM tNunLNv3o6bhgmJMA1IIe+iwpMJ/WSM91twmHFrXdh8hGLrn7HfItmSWuGO5tVAHi45sPz Er0ms1gk75BocnA3Ils4eZIUEKPR29oAeaE4UgEFX/+1EMp+JVODxg8MMxb0vw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733941484; 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=PDjgb70BAokXGdyDeERTJStgD6lQGRQiAG252Tw5mCE=; b=ogh2oVfUgM5RVwCQJZztDAHHmfoqHxgzTSbr9V4oSCsepsDPKrW2jkT7S2A2hiuPaRfuq/ ZD6wfO57EZPIjaLqr9/lHu2QRILNOcWrDgRHEg6tHo71vGnF3NLvc1a0BwxT4oCHCTS+SE I+oAOAw5jGWvfwJTd+L3XlU2reRveAhAliFONsUdzROei54hjbmUiXi7F5JVjJJTjPOVa+ xyJ0uxfbc1IYebSHQLU/A25WAL3WHaUQiwevv0ld752wVEYuLxKP+gJzMkDW9gwAF77MPv vYHrtcs3NW5wjAfXxOb2NTL8H4CwbKSfFFze85qE5Nyo8JO64S6mrvrHItqqEg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733941484; a=rsa-sha256; cv=none; b=EAoA3KnJBK+08MqWIP2C963zLJPYgTd1QlLR1loo84IJVf++fwZu+GrGdXQAaCZ40wAjvT OyWYYm7yuhYNLa7l0NIT9qrMJJjE4yCj4y/ucvwqEOa2i3J9t1xqHXlkl1AbYi1VOxocDW 7ZMsvagbwVKNNjGhjnDShLw5zsdITQZDtEmqn1KQLX82rAuMp/uB73cTSR+qHh9pc4G/EX 5UpmEFjOsS8ussz9ZgPTh6Uycelf8fMJwnXjZSUEtZX0hHyvznGmCHoVQ6tHniyVAoT4+d HufK9Np3I95FuCZLMCbcveNxFY43cb9JtcJIy8oXtUJuRQrFU0Cxo6Ilyfkd8g== 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 4Y7kXX4fsSzK94; Wed, 11 Dec 2024 18:24:44 +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 4BBIOind023468; Wed, 11 Dec 2024 18:24:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BBIOiLh023465; Wed, 11 Dec 2024 18:24:44 GMT (envelope-from git) Date: Wed, 11 Dec 2024 18:24:44 GMT Message-Id: <202412111824.4BBIOiLh023465@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Maxim Konovalov Subject: git: d6917af2b9da - main - login.conf.5: remove a stray quote 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: maxim X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d6917af2b9da76ac1df1977b2a3c09fb9d45db11 Auto-Submitted: auto-generated The branch main has been updated by maxim: URL: https://cgit.FreeBSD.org/src/commit/?id=d6917af2b9da76ac1df1977b2a3c09fb9d45db11 commit d6917af2b9da76ac1df1977b2a3c09fb9d45db11 Author: Maxim Konovalov AuthorDate: 2024-12-11 18:23:22 +0000 Commit: Maxim Konovalov CommitDate: 2024-12-11 18:23:22 +0000 login.conf.5: remove a stray quote PR: 282858 --- lib/libutil/login.conf.5 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/libutil/login.conf.5 b/lib/libutil/login.conf.5 index b1e7211e4c18..d43fdfb761f3 100644 --- a/lib/libutil/login.conf.5 +++ b/lib/libutil/login.conf.5 @@ -204,7 +204,7 @@ login environment. .It "pseudoterminals number Maximum number of pseudo-terminals." .It "swapuse size Maximum swap space size limit." .It "umtxp number Maximum number of process-shared pthread locks." -.It "pipebuf" size Maximum size of pipe buffers." +.It "pipebuf size Maximum size of pipe buffers." .El .Pp These resource limit entries actually specify both the maximum From nobody Wed Dec 11 18:50:16 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 4Y7l604bwJz5gKRR; Wed, 11 Dec 2024 18:50:16 +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 4Y7l603ZzPz4WK9; Wed, 11 Dec 2024 18:50:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733943016; 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=r/0b3shijbDZ8O5QbEk7NvG1amxEPxeDkYNsZendtiA=; b=GwFeXJRrv5CkdzAy4CzOIpCrEAXFAXvDB1sGle8RH9Ocn/O/CLsbAr9J1MCalBrjzOnOIN ng9Crdnxrp07525jtCwYuQMiDdU6re80vOfgkvZ8SWD96jrpJHC3wTCZ9xHwi6W7xTEfHL 9LJ2Q3FXbqZvwiKb67txNuAnw5mF4j4/0Ed4+VfGmuM0ajcGpSvmf2Pg0NtB8Tx1OHOOnu GTlw6tyVnfznUACdvUqFo/E6GZ+80XZryAUFUHhKYx/NOt7DwV+eBrff7BKOS0OtX2234C UUkmYFlJWKXfBw7HMf1LbIoVoQ2T0nPVXupmn9hEuFYC0HA8G7/Io1On0W/+fw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733943016; 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=r/0b3shijbDZ8O5QbEk7NvG1amxEPxeDkYNsZendtiA=; b=kGwTokxnbtdtTzMmMl4d0pq0qnESNz9IIURg5fg7i8M3/NgEz59sAUI8cp4pNGsvr7pQt3 KO3UxtC7ZdCh/gBn/SdQ8P1qzYTyO8p8t1Lor0R2E2X6ehVlfSGo8PIpLOaHi8VjNRGIYL IchBBVi+AShqJhgWWx0kdu9ZLiXT8TlmC7dMQzeRnI4xFIDemNTv9orK8PSZSC4nERM6Mh OO2DZCdDR9J974B8YfICTuL1vWSgsF3CcR2Bo/V1VUeacaJczHOG9Fentwk03DRBsHNOqC RzJs92Jp7yoH3B5XYnSgpTguFPyKFBkWN+bZz98fJHqNOfNLWoUPL9N0gVkAMw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733943016; a=rsa-sha256; cv=none; b=XO9YMoDLcNnPWQwKl5+wDJzGTJnBJ8NkMP8iUpOS6r3vthlJ9+GA/48KqPDCRI1PLdq+42 sX/nrViwNf2maTAiRXoOLIlSpXM1uJ720Qay5SExTTjqlWMSARWAiji26OEhIAx9TtqzDS 8RkTwEtptLLG8PdKfOn85g/3Fow3GXT3ZcB6gBP+bEhmyMlC2o7Gf3KAbU5JClR160VHZ1 QYnfk6bx6cVm01Trtoaju4V6TTgzRB/jzFAmNh7DKN0wprExOwEbqPa9QiyuM4+9ycE9d7 gLTweiTygDrjavAx2Enb502SVvq6l+ysW6Ie3O9k0rM9hbJuSKifix5/iUI9sg== 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 4Y7l602gFRzKhM; Wed, 11 Dec 2024 18:50:16 +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 4BBIoGbG068770; Wed, 11 Dec 2024 18:50:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BBIoGMa068757; Wed, 11 Dec 2024 18:50:16 GMT (envelope-from git) Date: Wed, 11 Dec 2024 18:50:16 GMT Message-Id: <202412111850.4BBIoGMa068757@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Michael Tuexen Subject: git: eba715c544ea - main - icmp.4: improve icmplim and add icmplim_jitter description 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: tuexen X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: eba715c544ea89c6b402c55e03b388b77030b997 Auto-Submitted: auto-generated The branch main has been updated by tuexen: URL: https://cgit.FreeBSD.org/src/commit/?id=eba715c544ea89c6b402c55e03b388b77030b997 commit eba715c544ea89c6b402c55e03b388b77030b997 Author: Michael Tuexen AuthorDate: 2024-12-11 18:47:11 +0000 Commit: Michael Tuexen CommitDate: 2024-12-11 18:47:11 +0000 icmp.4: improve icmplim and add icmplim_jitter description Reviewed by: cc, bcr MFC after: 1 week Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D48025 --- share/man/man4/icmp.4 | 27 ++++++++++++++++++++++++--- 1 file changed, 24 insertions(+), 3 deletions(-) diff --git a/share/man/man4/icmp.4 b/share/man/man4/icmp.4 index 7bc844edd3c0..c8c92a794e24 100644 --- a/share/man/man4/icmp.4 +++ b/share/man/man4/icmp.4 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 1, 2022 +.Dd December 11, 2024 .Dt ICMP 4 .Os .Sh NAME @@ -169,10 +169,31 @@ Defaults to false. Enable/disable dropping of ICMP Redirect packets. Defaults to false. .It Va icmplim -.Pq Vt integer -Bandwidth limit for ICMP replies in packets/second. +.Pq Vt unsigned integer +Mean rate limit for replies in packets/second. +The actual limit is +.Va icmplim +plus a random jitter limited by +.Va icmplim_jitter . If set to zero, no limiting will occur. Defaults to 200. +.It Va icmplim_jitter +.Pq Vt unsigned integer +A random jitter between the negative of +.Va icmplim_jitter +and +.Va icmplim_jitter +is applied to +.Va icmplim +for limiting the sending rate of replies. +.Va icmplim_jitter +must be smaller than +.Va icmplim , +if +.Va icmplim +is not zero. +If set to zero, no jitter will be applied. +Defaults to 16. .It Va icmplim_output .Pq Vt boolean Enable/disable logging of ICMP replies bandwidth limiting. From nobody Wed Dec 11 19:31:43 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 4Y7m1q3SwLz5gNDL; Wed, 11 Dec 2024 19:31:43 +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 4Y7m1q2vLzz4btn; Wed, 11 Dec 2024 19:31:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733945503; 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=xR7Ol74XBRm561fOYKlGtzemNtFqM/oDy/hfp+t4yyw=; b=xCUHgoLvt6aCm0iGJNDbfPzoLzkJZDaJO08PD/k/muTAvPyCG+elYi6+3dXWcPLhsWIuvI vELpf/N1LVrkYwz4sz1cQ12pmtZCHo2LOYbLOQMgLV9cw40WaRn3EV8b/6Pamos1RH18Pt zzmwGMLa4gTRKbS2xtXOG3sSKxJlAJJTSdlp4HlgEmtfV5ZQz1jbRKe82FZxEvHBLp6NaI tOirzpcM1/ZRyzplv6fw9nQ9qv+DFeX8JR1VuuKgO1sxgVPwv+ni3Xs3LcVGetfebBtGCj Y0ZkLmo5+J4MqxYMHkbDMNMLj2OciGG9O9rJ9hNjAOTd/4VE8grBRMsIeaJBOQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733945503; 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=xR7Ol74XBRm561fOYKlGtzemNtFqM/oDy/hfp+t4yyw=; b=Iyv9Lhf9kzmaB2e1wHxo4X7rDKyo6uwLrqgo+6Zhet7lkP97CAQnOztLCGIUCeEASx34WG N8L9FGyOzAYEunMDATaY5RwjQhVXn+UAHUwSc5oNkIh1phZYq0WMiveqPJnWTHE3fbd/6W dDkRVFMStkMqFc4mGWxal7BI5X93efVKAlPtW/Ruhdb9SZjJN3iexjdG8xfeQNXTcdyj3L Pvai0Zwe2fcKgMupbAMyGhqLGUoQKp2QtjoQTWQwla9nK/BT5K3MhQE97iizSlBU46NcNa c7aCA9FcS7aOYXXk3gGkzb4cSwOmyq4Y/gxyVRyF/w6R2uFsx6JFxWb2JrZjuw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733945503; a=rsa-sha256; cv=none; b=GLE6Ga/Gq2YD/f88I2+J98PYHiqDbCc8csqPlCvxRCUZs5f5yA/K5euiNsMxzc5Mmny8Qd Fw26rCKjE3qUfk4ECJ/8SlV1p5XMkB7qSE7LrJb3nYbly2AjQyBhfzAsITrdiIMOiAF+7Y Pqeps413bgLPxf1aHEWDLDOpIplYWY1+SN10fW6YbFejossEUdZ98O7IGcybPv+saqXmH2 SPqaxPbWsLkLNXHI8Kl7iaeGO+Hfl9GAgty2Y1mFsfQD98yquOi5wUsykeW7iiDq8y3bbO 9Zsna6s/4k1/XlUPqovKZx73PL2wt4e+gSIZr+ol6ydn/tCJvUFrStGCKBTMJw== 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 4Y7m1q2VbkzLxk; Wed, 11 Dec 2024 19:31:43 +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 4BBJVhdf049042; Wed, 11 Dec 2024 19:31:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BBJVhBP049031; Wed, 11 Dec 2024 19:31:43 GMT (envelope-from git) Date: Wed, 11 Dec 2024 19:31:43 GMT Message-Id: <202412111931.4BBJVhBP049031@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Maxim Konovalov Subject: git: ac3dedf4e8e0 - main - bsd-family-tree: add FreeBSD 14.2 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: maxim X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ac3dedf4e8e08647a2c08e75f1ef69d8bb2831e6 Auto-Submitted: auto-generated The branch main has been updated by maxim: URL: https://cgit.FreeBSD.org/src/commit/?id=ac3dedf4e8e08647a2c08e75f1ef69d8bb2831e6 commit ac3dedf4e8e08647a2c08e75f1ef69d8bb2831e6 Author: Maxim Konovalov AuthorDate: 2024-12-11 19:31:25 +0000 Commit: Maxim Konovalov CommitDate: 2024-12-11 19:31:25 +0000 bsd-family-tree: add FreeBSD 14.2 --- share/misc/bsd-family-tree | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/share/misc/bsd-family-tree b/share/misc/bsd-family-tree index 98f49d3989db..dab6d5a1f77d 100644 --- a/share/misc/bsd-family-tree +++ b/share/misc/bsd-family-tree @@ -465,10 +465,12 @@ FreeBSD 5.2 | | | | | | | | | 8.3 | | | FreeBSD | | | | | | 14.1 | | | | | - | | macOS | | | - | | 15 | | | - | FreeBSD | | | | - | 13.4 | | OpenBSD 7.6 | + | | | macOS | | | + | | | 15 | | | + | | FreeBSD | | | | + | | 13.4 | | OpenBSD 7.6 | + | FreeBSD | | | | + | 14.2 | | | | | | | | | FreeBSD 15 -current | NetBSD -current OpenBSD -current DragonFly -current | | | | | @@ -907,6 +909,7 @@ FreeBSD 14.1 2024-06-04 [FBD] macOS 15 2024-09-16 [APL] FreeBSD 13.4 2024-09-17 [FBD] OpenBSD 7.6 2024-10-08 [OBD] +FreeBSD 14.2 2024-12-03 [FBD] Bibliography ------------------------ From nobody Wed Dec 11 20:32:50 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 4Y7nNM1MThz5gRSN; Wed, 11 Dec 2024 20:32:51 +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 4Y7nNM0qCYz4kmb; Wed, 11 Dec 2024 20:32:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733949171; 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=+hDKdFTHlYbzQgrKLsWAyBZAFVsfDqNMTyNOTba2GPI=; b=RhYTK6u3Xz7Wl1ZxEtOzdZzznQoYYVKJg4gndgGiO7y3icneiHcv5eAOZHCxuOcpajmZtI 0CQRyoPniwy4zPHIL6DK2yfo+E2JcVoEaHpGvVneIhogVDfXAtbQZ/prOXectDjl3QXj+1 Dl33KLD9m2jaMDXOUxdTtNgEp7UjYQHb20Rax+Qll2QSz5dYO6NpQJBZaWX/oXDkHleF22 2m5XJyYkGw6QnGvorMrkiFCidY+dQQUoagPtGGm05jTlh2zqu2M9z+4F+Va8KjRJfYHfyf LH2LD/wsZ9Ipqfkmfs3ObndnVXvz+Sik0Z1z0wi9m4nxzd5VM9HjkdHfvtCKlA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1733949171; 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=+hDKdFTHlYbzQgrKLsWAyBZAFVsfDqNMTyNOTba2GPI=; b=sQuyksoI1c3775RXexUTT3nkmBL3s6JnHP9suymmOKqnepGeMxmU3Y8HnvVgfRU5g6pVbT C/HoQ/OtNpVQ/CnN0whtJYd4rRTkaurwd9ZZ0yCQlVIf33KJoeAdyLFqQPbSJ8rv33Ukdc RWdMW+5zXVjNlDMojqVHyad9fC9TWk7SexzXhDzq8/VVsaTdIPyD/pA79QtNldb1J9nnZy mvIZRPTiJMDS7qnHwGGTNImYmzsKK5qYHsiFJUw4VSYzlUDUgUKpwY9eryQS9uhjJVEe0f HpGSnKyPWBWyhhJkKKMf1zv/NV6X22acKPV61kg8URscgNiYTdEr2Zrzr95B+A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1733949171; a=rsa-sha256; cv=none; b=Vzbul+cBs7SOjDTogyROD58WfnHgM2Tw0/GOf9cgrTpwUx4Y45A42gYZUWv2RCzrLG5ZDj ZRDTWEkUpAn1DNyzwYObYYSFj4woFOS4wvpAIic13j8dURpt5t+GLNC7FU4Uj7K+56roTO 4lM/pTXfVn0bA16ik/3USDyjnFYWL6GxJY6dysU4lcXFg6dQ5kYEaK+r6441tF7U0Hwaz5 KbglCHEAswCSOhj6Nxsz1jtn5iBgiuO+jg9YxisugNJrwkAf2IgpnhtXkF33/2hOmVH0hw bYFXX1RDZhLsZudHVUmF0lvaTjntPV95BObAIZl6E2PMcgzOh2t4SZ/dGuFhpw== 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 4Y7nNM0Qd1zMr0; Wed, 11 Dec 2024 20:32:51 +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 4BBKWoWH064548; Wed, 11 Dec 2024 20:32:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BBKWoZ9064543; Wed, 11 Dec 2024 20:32:50 GMT (envelope-from git) Date: Wed, 11 Dec 2024 20:32:50 GMT Message-Id: <202412112032.4BBKWoZ9064543@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Brooks Davis Subject: git: b9cf179622ba - main - libsys/i386/Symbol.sys.map: sort symbol names 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: brooks X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: b9cf179622ba002e35f48d2c997f57e9d348a16d Auto-Submitted: auto-generated The branch main has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=b9cf179622ba002e35f48d2c997f57e9d348a16d commit b9cf179622ba002e35f48d2c997f57e9d348a16d Author: Brooks Davis AuthorDate: 2024-12-11 20:09:33 +0000 Commit: Brooks Davis CommitDate: 2024-12-11 20:31:30 +0000 libsys/i386/Symbol.sys.map: sort symbol names No functional change. Sponsored by: DARPA, AFRL --- lib/libsys/i386/Symbol.sys.map | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/libsys/i386/Symbol.sys.map b/lib/libsys/i386/Symbol.sys.map index 303804935435..6b3169336a3f 100644 --- a/lib/libsys/i386/Symbol.sys.map +++ b/lib/libsys/i386/Symbol.sys.map @@ -1,5 +1,4 @@ FBSD_1.0 { - rfork_thread; i386_clr_watch; i386_get_fsbase; i386_get_gsbase; @@ -11,12 +10,13 @@ FBSD_1.0 { i386_set_ldt; i386_set_watch; i386_vm86; + rfork_thread; }; FBSD_1.6 { x86_pkru_get_perm; - x86_pkru_set_perm; x86_pkru_protect_range; + x86_pkru_set_perm; x86_pkru_unprotect_range; };