From nobody Sat Sep 30 06:54:12 2023 X-Original-To: dev-commits-src-branches@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 4RyHy175KCz4vhJb; Sat, 30 Sep 2023 06:54: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RyHy16kVkz4sZJ; Sat, 30 Sep 2023 06:54:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696056857; 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=vbMCANWs+yJHsAIPm14xX+eYZIoQnydsRBnTYDGrL/4=; b=EIM7z890VWsKHNBnnr+Ez7t2k/HJjYtdHW0o6MPnrj51J0H2YW9yXAS/V5p7fBUduv49E0 IMJlasTm2i4K+TjrJhcEm0iLTgCkH1SuaqhC8Ja48gc03zcNwKPK86hkXkYYgdlTYCu0Mq f0VqvkaY4Ze5l72qFi5iLfxXDpp5SH9Amd81yuye9E10UpQ9aMBMbUDFa7dADeWtvIrYJS Ur3uLUSWYiCQWkfE1bymO9ZyRBktRedVbbRfJmUzR73fFNIts8aE5IT0cgpG5OI/giEIO7 aDbZP3SJHAkFP4iCiwyw1bEC517s1wvPD1UBspI06XPr3LE3QdE80m8MYlyoLQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696056857; a=rsa-sha256; cv=none; b=h3Qil9CwVwia46fLw3vTUWIUuoPSGBndbcP2zq1sRqU0d7jGa5qT96xvUyQR5iNk2eeZzu tp0pLIN8GymlFuCr3jnCG+yepjoCqZqSq11OiN668A3SenPdBtLn1kXUZ7FYCmep9oKE8C mfTFdZDzosBQerPVFyAlx1rDPCA0AX/xlSXORIlArDzuseD4k0CnSHbZKvxOmG02GBnwVJ f+9sSueKGrao9VRSSc5ZUwTPKlx9sFp0eVkrKbpRjKxGkV5xrrlNalLhOqrDRwjIRpUIvB NJX6CgR1m+idGuDE7+fkJJGqc/vzHOvxddYinajQQwNZ8CCssVTJFJtoEgYtyA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696056857; 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=vbMCANWs+yJHsAIPm14xX+eYZIoQnydsRBnTYDGrL/4=; b=mcMHeNcdG+HfIP0AZFWH5eWLfTfUvzEEFWFpFt1KPQhsplxTTRFrlXXiKZqntkMa6Np0gs OxjzFZ2ve82+RKElWU4uoy0z/ImjxEG2u8eLHazgxX+pZMKS4TBvICUq4kcarch7oeDS94 M9VRtzRhaND7f4Zd7IFSzCXx8NbDIF/XF7il8/kSX7JE42FbQf7FrhTV9shg3DXErM3Ah1 1Wb9AuE7hmIGxE7Qd7PFm5zrHlgz68bji4AXpxEwiOK5VzU2aQmkbauuNgOI+Kg7Do3dcI kdQVx79z4RqtpP4ycyXFfbUh/wWCY9lmfmJ+aOEQQIaGgAaA7XN7EYwvyKFY1w== 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 4RyHy15ks9zcqc; Sat, 30 Sep 2023 06:54:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 38U6sHuK046433; Sat, 30 Sep 2023 06:54:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 38U6sCAU046417; Sat, 30 Sep 2023 06:54:12 GMT (envelope-from git) Date: Sat, 30 Sep 2023 06:54:12 GMT Message-Id: <202309300654.38U6sCAU046417@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Martin Matuska Subject: git: d9a61490b098 - stable/13 - zfs: merge openzfs/zfs@eb62221ff (zfs-2.1-release) into stable/13 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mm X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: d9a61490b0988b1187ea169e538762f70dfaeb12 Auto-Submitted: auto-generated The branch stable/13 has been updated by mm: URL: https://cgit.FreeBSD.org/src/commit/?id=d9a61490b0988b1187ea169e538762f70dfaeb12 commit d9a61490b0988b1187ea169e538762f70dfaeb12 Merge: ac695744e2cf eb62221ff0f9 Author: Martin Matuska AuthorDate: 2023-09-30 06:52:40 +0000 Commit: Martin Matuska CommitDate: 2023-09-30 06:53:32 +0000 zfs: merge openzfs/zfs@eb62221ff (zfs-2.1-release) into stable/13 OpenZFS release 2.1.13 Notable upstream pull request merges: #14828 d91778e31 Remove duplicate code in l2arc_evict() #14939 425f7895d Fix the L2ARC write size calculating logic #14954 c12b5829e Fix the L2ARC write size calculating logic (2) #14963 f28cd347c Store the L2ARC device ashift in the vdev label #14981 ef2156c66 Shorten arcstat_quiescence sleep time #14987 cb549c742 Fix memory leak in zil_parse() #15000 6e79bcd35 Fix remount when setting multiple properties #15039 e01e3a4e1 Fix raw receive with different indirect block size #15084 846a4cc08 zed: Fix zed ASSERT on slot power cycle #15094 1abf68b7a zed: Reduce log noise for large JBODs Obtained from: OpenZFS OpenZFS tag: zfs-2.1.13 OpenZFS commit: eb62221ff0f9efbc2ab826ec6f1388c5f05fb664 Relnotes: yes sys/contrib/openzfs/META | 4 +- sys/contrib/openzfs/cmd/zed/agents/zfs_mod.c | 2 - sys/contrib/openzfs/cmd/zed/agents/zfs_retire.c | 5 + sys/contrib/openzfs/cmd/zed/zed.d/Makefile.am | 2 + .../openzfs/cmd/zed/zed.d/statechange-slot_off.sh | 64 ++++++++++ sys/contrib/openzfs/cmd/zed/zed.d/zed.rc | 5 + sys/contrib/openzfs/config/kernel-blkdev.m4 | 138 ++++++++++++++++++++- .../config/kernel-block-device-operations.m4 | 35 +++++- .../openzfs/config/kernel-filemap-splice-read.m4 | 25 ++++ .../openzfs/config/kernel-register_sysctl_table.m4 | 27 ++++ sys/contrib/openzfs/config/kernel-vfs-iov_iter.m4 | 26 +++- sys/contrib/openzfs/config/kernel.m4 | 4 + .../openzfs/contrib/bash_completion.d/zfs.in | 2 +- .../include/os/linux/kernel/linux/blkdev_compat.h | 17 +++ .../openzfs/include/os/linux/spl/sys/types.h | 2 +- sys/contrib/openzfs/include/os/linux/spl/sys/uio.h | 12 ++ sys/contrib/openzfs/lib/libzfs/libzfs_dataset.c | 7 +- sys/contrib/openzfs/module/lua/lfunc.h | 4 +- sys/contrib/openzfs/module/lua/lobject.h | 4 +- .../openzfs/module/os/freebsd/zfs/zfs_debug.c | 4 +- .../openzfs/module/os/linux/spl/spl-kmem-cache.c | 12 +- sys/contrib/openzfs/module/os/linux/spl/spl-proc.c | 77 ++++++++---- .../openzfs/module/os/linux/zfs/vdev_disk.c | 65 ++++++++-- .../openzfs/module/os/linux/zfs/zfs_ctldir.c | 36 +++++- .../openzfs/module/os/linux/zfs/zfs_debug.c | 4 +- .../openzfs/module/os/linux/zfs/zfs_vnops_os.c | 2 +- .../openzfs/module/os/linux/zfs/zpl_ctldir.c | 2 +- sys/contrib/openzfs/module/os/linux/zfs/zpl_file.c | 15 ++- sys/contrib/openzfs/module/os/linux/zfs/zvol_os.c | 28 ++++- sys/contrib/openzfs/module/zfs/arc.c | 73 ++++++----- sys/contrib/openzfs/module/zfs/dmu_recv.c | 22 ++-- sys/contrib/openzfs/module/zfs/dnode.c | 31 ++--- sys/contrib/openzfs/module/zfs/vdev_indirect.c | 2 +- sys/contrib/openzfs/module/zfs/vdev_label.c | 3 + sys/contrib/openzfs/module/zfs/zil.c | 8 +- sys/contrib/openzfs/module/zstd/Makefile.in | 2 +- sys/contrib/openzfs/rpm/generic/zfs-dkms.spec.in | 45 +------ .../openzfs/tests/test-runner/bin/zts-report.py.in | 64 +++++----- .../openzfs/tests/zfs-tests/include/libtest.shlib | 2 +- .../functional/l2arc/persist_l2arc_001_pos.ksh | 19 ++- .../zfs-tests/tests/functional/trim/trim_l2arc.ksh | 2 +- sys/modules/zfs/zfs_config.h | 35 +++++- sys/modules/zfs/zfs_gitrev.h | 2 +- 43 files changed, 721 insertions(+), 219 deletions(-) diff --cc sys/contrib/openzfs/cmd/zed/zed.d/statechange-slot_off.sh index 000000000000,150012abe71a..150012abe71a mode 000000,100755..100755 --- a/sys/contrib/openzfs/cmd/zed/zed.d/statechange-slot_off.sh +++ b/sys/contrib/openzfs/cmd/zed/zed.d/statechange-slot_off.sh diff --cc sys/contrib/openzfs/config/kernel-filemap-splice-read.m4 index 000000000000,4c83b31d738a..4c83b31d738a mode 000000,100644..100644 --- a/sys/contrib/openzfs/config/kernel-filemap-splice-read.m4 +++ b/sys/contrib/openzfs/config/kernel-filemap-splice-read.m4 diff --cc sys/contrib/openzfs/config/kernel-register_sysctl_table.m4 index 000000000000,a5e934f56d29..a5e934f56d29 mode 000000,100644..100644 --- a/sys/contrib/openzfs/config/kernel-register_sysctl_table.m4 +++ b/sys/contrib/openzfs/config/kernel-register_sysctl_table.m4 diff --cc sys/modules/zfs/zfs_config.h index 53d6e0d6e52e,000000000000..95886fc74c39 mode 100644,000000..100644 --- a/sys/modules/zfs/zfs_config.h +++ b/sys/modules/zfs/zfs_config.h @@@ -1,1055 -1,0 +1,1082 @@@ +/* + */ + +/* zfs_config.h. Generated from zfs_config.h.in by configure. */ +/* zfs_config.h.in. Generated from configure.ac by autoheader. */ + +/* Define to 1 if translation of program messages to the user's native + language is requested. */ +/* #undef ENABLE_NLS */ + +/* bio_end_io_t wants 1 arg */ +/* #undef HAVE_1ARG_BIO_END_IO_T */ + +/* lookup_bdev() wants 1 arg */ +/* #undef HAVE_1ARG_LOOKUP_BDEV */ + +/* submit_bio() wants 1 arg */ +/* #undef HAVE_1ARG_SUBMIT_BIO */ + +/* bdi_setup_and_register() wants 2 args */ +/* #undef HAVE_2ARGS_BDI_SETUP_AND_REGISTER */ + +/* vfs_getattr wants 2 args */ +/* #undef HAVE_2ARGS_VFS_GETATTR */ + +/* zlib_deflate_workspacesize() wants 2 args */ +/* #undef HAVE_2ARGS_ZLIB_DEFLATE_WORKSPACESIZE */ + +/* bdi_setup_and_register() wants 3 args */ +/* #undef HAVE_3ARGS_BDI_SETUP_AND_REGISTER */ + +/* vfs_getattr wants 3 args */ +/* #undef HAVE_3ARGS_VFS_GETATTR */ + +/* vfs_getattr wants 4 args */ +/* #undef HAVE_4ARGS_VFS_GETATTR */ + +/* kernel has access_ok with 'type' parameter */ +/* #undef HAVE_ACCESS_OK_TYPE */ + +/* posix_acl has refcount_t */ +/* #undef HAVE_ACL_REFCOUNT */ + +/* add_disk() returns int */ +/* #undef HAVE_ADD_DISK_RET */ + +/* Define if host toolchain supports AES */ +#define HAVE_AES 1 + +#ifdef __amd64__ +#ifndef RESCUE +/* Define if host toolchain supports AVX */ +#define HAVE_AVX 1 +#endif + +/* Define if host toolchain supports AVX2 */ +#define HAVE_AVX2 1 + +/* Define if host toolchain supports AVX512BW */ +#define HAVE_AVX512BW 1 + +/* Define if host toolchain supports AVX512CD */ +#define HAVE_AVX512CD 1 + +/* Define if host toolchain supports AVX512DQ */ +#define HAVE_AVX512DQ 1 + +/* Define if host toolchain supports AVX512ER */ +#define HAVE_AVX512ER 1 + +/* Define if host toolchain supports AVX512F */ +#define HAVE_AVX512F 1 + +/* Define if host toolchain supports AVX512IFMA */ +#define HAVE_AVX512IFMA 1 + +/* Define if host toolchain supports AVX512PF */ +#define HAVE_AVX512PF 1 + +/* Define if host toolchain supports AVX512VBMI */ +#define HAVE_AVX512VBMI 1 + +/* Define if host toolchain supports AVX512VL */ +#define HAVE_AVX512VL 1 +#endif + +/* bdevname() is available */ +/* #undef HAVE_BDEVNAME */ + +/* bdev_check_media_change() exists */ +/* #undef HAVE_BDEV_CHECK_MEDIA_CHANGE */ + +/* bdev_*_io_acct() available */ +/* #undef HAVE_BDEV_IO_ACCT_63 */ + +/* bdev_*_io_acct() available */ +/* #undef HAVE_BDEV_IO_ACCT_OLD */ + +/* bdev_kobj() exists */ +/* #undef HAVE_BDEV_KOBJ */ + +/* bdev_max_discard_sectors() is available */ +/* #undef HAVE_BDEV_MAX_DISCARD_SECTORS */ + +/* bdev_max_secure_erase_sectors() is available */ +/* #undef HAVE_BDEV_MAX_SECURE_ERASE_SECTORS */ + +/* block_device_operations->submit_bio() returns void */ +/* #undef HAVE_BDEV_SUBMIT_BIO_RETURNS_VOID */ + +/* bdev_whole() is available */ +/* #undef HAVE_BDEV_WHOLE */ + +/* bio_alloc() takes 4 arguments */ +/* #undef HAVE_BIO_ALLOC_4ARG */ + +/* bio->bi_bdev->bd_disk exists */ +/* #undef HAVE_BIO_BDEV_DISK */ + +/* bio->bi_opf is defined */ +/* #undef HAVE_BIO_BI_OPF */ + +/* bio->bi_status exists */ +/* #undef HAVE_BIO_BI_STATUS */ + +/* bio has bi_iter */ +/* #undef HAVE_BIO_BVEC_ITER */ + +/* bio_*_io_acct() available */ +/* #undef HAVE_BIO_IO_ACCT */ + +/* bio_max_segs() is implemented */ +/* #undef HAVE_BIO_MAX_SEGS */ + +/* bio_set_dev() is available */ +/* #undef HAVE_BIO_SET_DEV */ + +/* bio_set_dev() GPL-only */ +/* #undef HAVE_BIO_SET_DEV_GPL_ONLY */ + +/* bio_set_dev() is a macro */ +/* #undef HAVE_BIO_SET_DEV_MACRO */ + +/* bio_set_op_attrs is available */ +/* #undef HAVE_BIO_SET_OP_ATTRS */ + ++/* blkdev_get_by_path() exists and takes 4 args */ ++/* #undef HAVE_BLKDEV_GET_BY_PATH_4ARG */ ++ +/* blkdev_get_by_path() handles ERESTARTSYS */ +/* #undef HAVE_BLKDEV_GET_ERESTARTSYS */ + +/* blkdev_issue_discard() is available */ +/* #undef HAVE_BLKDEV_ISSUE_DISCARD */ + +/* blkdev_issue_secure_erase() is available */ +/* #undef HAVE_BLKDEV_ISSUE_SECURE_ERASE */ + ++/* blkdev_put() accepts void* as arg 2 */ ++/* #undef HAVE_BLKDEV_PUT_HOLDER */ ++ +/* blkdev_reread_part() exists */ +/* #undef HAVE_BLKDEV_REREAD_PART */ + +/* blkg_tryget() is available */ +/* #undef HAVE_BLKG_TRYGET */ + +/* blkg_tryget() GPL-only */ +/* #undef HAVE_BLKG_TRYGET_GPL_ONLY */ + +/* blk_alloc_disk() exists */ +/* #undef HAVE_BLK_ALLOC_DISK */ + +/* blk_alloc_queue() expects request function */ +/* #undef HAVE_BLK_ALLOC_QUEUE_REQUEST_FN */ + +/* blk_alloc_queue_rh() expects request function */ +/* #undef HAVE_BLK_ALLOC_QUEUE_REQUEST_FN_RH */ + +/* blk_cleanup_disk() exists */ +/* #undef HAVE_BLK_CLEANUP_DISK */ + ++/* blk_mode_t is defined */ ++/* #undef HAVE_BLK_MODE_T */ ++ +/* blk queue backing_dev_info is dynamic */ +/* #undef HAVE_BLK_QUEUE_BDI_DYNAMIC */ + +/* blk_queue_discard() is available */ +/* #undef HAVE_BLK_QUEUE_DISCARD */ + +/* blk_queue_flag_clear() exists */ +/* #undef HAVE_BLK_QUEUE_FLAG_CLEAR */ + +/* blk_queue_flag_set() exists */ +/* #undef HAVE_BLK_QUEUE_FLAG_SET */ + +/* blk_queue_flush() is available */ +/* #undef HAVE_BLK_QUEUE_FLUSH */ + +/* blk_queue_flush() is GPL-only */ +/* #undef HAVE_BLK_QUEUE_FLUSH_GPL_ONLY */ + +/* blk_queue_secdiscard() is available */ +/* #undef HAVE_BLK_QUEUE_SECDISCARD */ + +/* blk_queue_secure_erase() is available */ +/* #undef HAVE_BLK_QUEUE_SECURE_ERASE */ + +/* blk_queue_update_readahead() exists */ +/* #undef HAVE_BLK_QUEUE_UPDATE_READAHEAD */ + +/* blk_queue_write_cache() exists */ +/* #undef HAVE_BLK_QUEUE_WRITE_CACHE */ + +/* blk_queue_write_cache() is GPL-only */ +/* #undef HAVE_BLK_QUEUE_WRITE_CACHE_GPL_ONLY */ + ++/* BLK_STS_RESV_CONFLICT is defined */ ++/* #undef HAVE_BLK_STS_RESV_CONFLICT */ ++ ++/* Define if release() in block_device_operations takes 1 arg */ ++/* #undef HAVE_BLOCK_DEVICE_OPERATIONS_RELEASE_1ARG */ ++ +/* Define if revalidate_disk() in block_device_operations */ +/* #undef HAVE_BLOCK_DEVICE_OPERATIONS_REVALIDATE_DISK */ + +/* Define to 1 if you have the Mac OS X function CFLocaleCopyCurrent in the + CoreFoundation framework. */ +/* #undef HAVE_CFLOCALECOPYCURRENT */ + +/* 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 */ + +/* check_disk_change() exists */ +/* #undef HAVE_CHECK_DISK_CHANGE */ + +/* clear_inode() is available */ +/* #undef HAVE_CLEAR_INODE */ + +/* dentry uses const struct dentry_operations */ +/* #undef HAVE_CONST_DENTRY_OPERATIONS */ + +/* copy_from_iter() is available */ +/* #undef HAVE_COPY_FROM_ITER */ + ++/* copy_splice_read exists */ ++/* #undef HAVE_COPY_SPLICE_READ */ ++ +/* copy_to_iter() is available */ +/* #undef HAVE_COPY_TO_ITER */ + +/* cpu_has_feature() is GPL-only */ +/* #undef HAVE_CPU_HAS_FEATURE_GPL_ONLY */ + +/* yes */ +/* #undef HAVE_CPU_HOTPLUG */ + +/* current_time() exists */ +/* #undef HAVE_CURRENT_TIME */ + +/* Define if the GNU dcgettext() function is already present or preinstalled. + */ +/* #undef HAVE_DCGETTEXT */ + +/* DECLARE_EVENT_CLASS() is available */ +/* #undef HAVE_DECLARE_EVENT_CLASS */ + +/* dentry aliases are in d_u member */ +/* #undef HAVE_DENTRY_D_U_ALIASES */ + +/* dequeue_signal() takes 4 arguments */ +/* #undef HAVE_DEQUEUE_SIGNAL_4ARG */ + +/* lookup_bdev() wants dev_t arg */ +/* #undef HAVE_DEVT_LOOKUP_BDEV */ + +/* sops->dirty_inode() wants flags */ +/* #undef HAVE_DIRTY_INODE_WITH_FLAGS */ + ++/* disk_check_media_change() exists */ ++/* #undef HAVE_DISK_CHECK_MEDIA_CHANGE */ ++ +/* disk_*_io_acct() available */ +/* #undef HAVE_DISK_IO_ACCT */ + +/* disk_update_readahead() exists */ +/* #undef HAVE_DISK_UPDATE_READAHEAD */ + +/* Define to 1 if you have the header file. */ +#define HAVE_DLFCN_H 1 + +/* d_make_root() is available */ +/* #undef HAVE_D_MAKE_ROOT */ + +/* d_prune_aliases() is available */ +/* #undef HAVE_D_PRUNE_ALIASES */ + +/* dops->d_revalidate() operation takes nameidata */ +/* #undef HAVE_D_REVALIDATE_NAMEIDATA */ + +/* eops->encode_fh() wants child and parent inodes */ +/* #undef HAVE_ENCODE_FH_WITH_INODE */ + +/* sops->evict_inode() exists */ +/* #undef HAVE_EVICT_INODE */ + +/* FALLOC_FL_ZERO_RANGE is defined */ +/* #undef HAVE_FALLOC_FL_ZERO_RANGE */ + +/* fault_in_iov_iter_readable() is available */ +/* #undef HAVE_FAULT_IN_IOV_ITER_READABLE */ + +/* filemap_range_has_page() is available */ +/* #undef HAVE_FILEMAP_RANGE_HAS_PAGE */ + +/* fops->aio_fsync() exists */ +/* #undef HAVE_FILE_AIO_FSYNC */ + +/* file_dentry() is available */ +/* #undef HAVE_FILE_DENTRY */ + +/* file_inode() is available */ +/* #undef HAVE_FILE_INODE */ + +/* flush_dcache_page() is GPL-only */ +/* #undef HAVE_FLUSH_DCACHE_PAGE_GPL_ONLY */ + +/* iops->follow_link() cookie */ +/* #undef HAVE_FOLLOW_LINK_COOKIE */ + +/* iops->follow_link() nameidata */ +/* #undef HAVE_FOLLOW_LINK_NAMEIDATA */ + +/* fops->fsync() with range */ +/* #undef HAVE_FSYNC_RANGE */ + +/* fops->fsync() without dentry */ +/* #undef HAVE_FSYNC_WITHOUT_DENTRY */ + +/* generic_fillattr requires struct mnt_idmap* */ +/* #undef HAVE_GENERIC_FILLATTR_IDMAP */ + +/* generic_fillattr requires struct user_namespace* */ +/* #undef HAVE_GENERIC_FILLATTR_USERNS */ + +/* generic_*_io_acct() 3 arg available */ +/* #undef HAVE_GENERIC_IO_ACCT_3ARG */ + +/* generic_*_io_acct() 4 arg available */ +/* #undef HAVE_GENERIC_IO_ACCT_4ARG */ + +/* generic_readlink is global */ +/* #undef HAVE_GENERIC_READLINK */ + +/* generic_setxattr() exists */ +/* #undef HAVE_GENERIC_SETXATTR */ + +/* generic_write_checks() takes kiocb */ +/* #undef HAVE_GENERIC_WRITE_CHECKS_KIOCB */ + +/* Define if the GNU gettext() function is already present or preinstalled. */ +/* #undef HAVE_GETTEXT */ + +/* iops->get_acl() exists */ +/* #undef HAVE_GET_ACL */ + +/* iops->get_acl() takes rcu */ +/* #undef HAVE_GET_ACL_RCU */ + +/* has iops->get_inode_acl() */ +/* #undef HAVE_GET_INODE_ACL */ + +/* iops->get_link() cookie */ +/* #undef HAVE_GET_LINK_COOKIE */ + +/* iops->get_link() delayed */ +/* #undef HAVE_GET_LINK_DELAYED */ + +/* group_info->gid exists */ +/* #undef HAVE_GROUP_INFO_GID */ + +/* has_capability() is available */ +/* #undef HAVE_HAS_CAPABILITY */ + +/* Define if you have the iconv() function and it works. */ +#define HAVE_ICONV 1 + +/* iops->getattr() takes struct mnt_idmap* */ +/* #undef HAVE_IDMAP_IOPS_GETATTR */ + +/* iops->setattr() takes struct mnt_idmap* */ +/* #undef HAVE_IDMAP_IOPS_SETATTR */ + +/* Define if compiler supports -Wimplicit-fallthrough */ +/* #define HAVE_IMPLICIT_FALLTHROUGH 1 */ + +/* Define if compiler supports -Winfinite-recursion */ +/* #undef HAVE_INFINITE_RECURSION */ + +/* yes */ +/* #undef HAVE_INODE_LOCK_SHARED */ + +/* inode_owner_or_capable() exists */ +/* #undef HAVE_INODE_OWNER_OR_CAPABLE */ + +/* inode_owner_or_capable() takes mnt_idmap */ +/* #undef HAVE_INODE_OWNER_OR_CAPABLE_IDMAP */ + +/* inode_owner_or_capable() takes user_ns */ +/* #undef HAVE_INODE_OWNER_OR_CAPABLE_USERNS */ + +/* inode_set_flags() exists */ +/* #undef HAVE_INODE_SET_FLAGS */ + +/* inode_set_iversion() exists */ +/* #undef HAVE_INODE_SET_IVERSION */ + +/* inode->i_*time's are timespec64 */ +/* #undef HAVE_INODE_TIMESPEC64_TIMES */ + +/* timestamp_truncate() exists */ +/* #undef HAVE_INODE_TIMESTAMP_TRUNCATE */ + +/* Define to 1 if you have the header file. */ +#define HAVE_INTTYPES_H 1 + +/* in_compat_syscall() is available */ +/* #undef HAVE_IN_COMPAT_SYSCALL */ + +/* iops->create() takes struct mnt_idmap* */ +/* #undef HAVE_IOPS_CREATE_IDMAP */ + +/* iops->create() takes struct user_namespace* */ +/* #undef HAVE_IOPS_CREATE_USERNS */ + +/* iops->mkdir() takes struct mnt_idmap* */ +/* #undef HAVE_IOPS_MKDIR_IDMAP */ + +/* iops->mkdir() takes struct user_namespace* */ +/* #undef HAVE_IOPS_MKDIR_USERNS */ + +/* iops->mknod() takes struct mnt_idmap* */ +/* #undef HAVE_IOPS_MKNOD_IDMAP */ + +/* iops->mknod() takes struct user_namespace* */ +/* #undef HAVE_IOPS_MKNOD_USERNS */ + +/* iops->rename() takes struct mnt_idmap* */ +/* #undef HAVE_IOPS_RENAME_IDMAP */ + +/* iops->rename() takes struct user_namespace* */ +/* #undef HAVE_IOPS_RENAME_USERNS */ + +/* iops->setattr() exists */ +/* #undef HAVE_IOPS_SETATTR */ + +/* iops->symlink() takes struct mnt_idmap* */ +/* #undef HAVE_IOPS_SYMLINK_IDMAP */ + +/* iops->symlink() takes struct user_namespace* */ +/* #undef HAVE_IOPS_SYMLINK_USERNS */ + +/* iov_iter_advance() is available */ +/* #undef HAVE_IOV_ITER_ADVANCE */ + +/* iov_iter_count() is available */ +/* #undef HAVE_IOV_ITER_COUNT */ + +/* iov_iter_fault_in_readable() is available */ +/* #undef HAVE_IOV_ITER_FAULT_IN_READABLE */ + +/* iov_iter_revert() is available */ +/* #undef HAVE_IOV_ITER_REVERT */ + +/* iov_iter_type() is available */ +/* #undef HAVE_IOV_ITER_TYPE */ + +/* iov_iter types are available */ +/* #undef HAVE_IOV_ITER_TYPES */ + +/* yes */ +/* #undef HAVE_IO_SCHEDULE_TIMEOUT */ + +/* Define to 1 if you have the `issetugid' function. */ +#define HAVE_ISSETUGID 1 + ++/* iter_iov() is available */ ++/* #undef HAVE_ITER_IOV */ ++ +/* kernel has kernel_fpu_* functions */ +/* #undef HAVE_KERNEL_FPU */ + +/* kernel has asm/fpu/api.h */ +/* #undef HAVE_KERNEL_FPU_API_HEADER */ + +/* kernel fpu internal */ +/* #undef HAVE_KERNEL_FPU_INTERNAL */ + +/* kernel has asm/fpu/internal.h */ +/* #undef HAVE_KERNEL_FPU_INTERNAL_HEADER */ + +/* kernel has asm/fpu/xcr.h */ +/* #undef HAVE_KERNEL_FPU_XCR_HEADER */ + +/* kernel fpu and XSAVE internal */ +/* #undef HAVE_KERNEL_FPU_XSAVE_INTERNAL */ + +/* uncached_acl_sentinel() exists */ +/* #undef HAVE_KERNEL_GET_ACL_HANDLE_CACHE */ + +/* kernel does stack verification */ +/* #undef HAVE_KERNEL_OBJTOOL */ + +/* kernel has linux/objtool.h */ +/* #undef HAVE_KERNEL_OBJTOOL_HEADER */ + +/* kernel_read() take loff_t pointer */ +/* #undef HAVE_KERNEL_READ_PPOS */ + +/* timer_list.function gets a timer_list */ +/* #undef HAVE_KERNEL_TIMER_FUNCTION_TIMER_LIST */ + +/* struct timer_list has a flags member */ +/* #undef HAVE_KERNEL_TIMER_LIST_FLAGS */ + +/* timer_setup() is available */ +/* #undef HAVE_KERNEL_TIMER_SETUP */ + +/* kernel_write() take loff_t pointer */ +/* #undef HAVE_KERNEL_WRITE_PPOS */ + +/* kmem_cache_create_usercopy() exists */ +/* #undef HAVE_KMEM_CACHE_CREATE_USERCOPY */ + +/* kstrtoul() exists */ +/* #undef HAVE_KSTRTOUL */ + +/* ktime_get_coarse_real_ts64() exists */ +/* #undef HAVE_KTIME_GET_COARSE_REAL_TS64 */ + +/* ktime_get_raw_ts64() exists */ +/* #undef HAVE_KTIME_GET_RAW_TS64 */ + +/* kvmalloc exists */ +/* #undef HAVE_KVMALLOC */ + +/* Define if you have [aio] */ +/* #undef HAVE_LIBAIO */ + +/* Define if you have [blkid] */ +/* #undef HAVE_LIBBLKID */ + +/* Define if you have [crypto] */ +#define HAVE_LIBCRYPTO 1 + +/* Define if you have [tirpc] */ +/* #undef HAVE_LIBTIRPC */ + +/* Define if you have [udev] */ +/* #undef HAVE_LIBUDEV */ + +/* Define if you have [uuid] */ +/* #undef HAVE_LIBUUID */ + +/* linux/blk-cgroup.h exists */ +/* #undef HAVE_LINUX_BLK_CGROUP_HEADER */ + +/* lseek_execute() is available */ +/* #undef HAVE_LSEEK_EXECUTE */ + +/* makedev() is declared in sys/mkdev.h */ +/* #undef HAVE_MAKEDEV_IN_MKDEV */ + +/* makedev() is declared in sys/sysmacros.h */ +/* #undef HAVE_MAKEDEV_IN_SYSMACROS */ + +/* Noting that make_request_fn() returns blk_qc_t */ +/* #undef HAVE_MAKE_REQUEST_FN_RET_QC */ + +/* Noting that make_request_fn() returns void */ +/* #undef HAVE_MAKE_REQUEST_FN_RET_VOID */ + +/* iops->mkdir() takes umode_t */ +/* #undef HAVE_MKDIR_UMODE_T */ + +/* Define to 1 if you have the `mlockall' function. */ +#define HAVE_MLOCKALL 1 + +/* lookup_bdev() wants mode arg */ +/* #undef HAVE_MODE_LOOKUP_BDEV */ + +/* Define if host toolchain supports MOVBE */ +#define HAVE_MOVBE 1 + +/* new_sync_read()/new_sync_write() are available */ +/* #undef HAVE_NEW_SYNC_READ */ + +/* folio_wait_bit() exists */ +/* #undef HAVE_PAGEMAP_FOLIO_WAIT_BIT */ + +/* part_to_dev() exists */ +/* #undef HAVE_PART_TO_DEV */ + +/* iops->getattr() takes a path */ +/* #undef HAVE_PATH_IOPS_GETATTR */ + +/* Define if host toolchain supports PCLMULQDQ */ +#define HAVE_PCLMULQDQ 1 + +/* percpu_counter_add_batch() is defined */ +/* #undef HAVE_PERCPU_COUNTER_ADD_BATCH */ + +/* percpu_counter_init() wants gfp_t */ +/* #undef HAVE_PERCPU_COUNTER_INIT_WITH_GFP */ + +/* posix_acl_chmod() exists */ +/* #undef HAVE_POSIX_ACL_CHMOD */ + +/* posix_acl_from_xattr() needs user_ns */ +/* #undef HAVE_POSIX_ACL_FROM_XATTR_USERNS */ + +/* posix_acl_release() is available */ +/* #undef HAVE_POSIX_ACL_RELEASE */ + +/* posix_acl_release() is GPL-only */ +/* #undef HAVE_POSIX_ACL_RELEASE_GPL_ONLY */ + +/* posix_acl_valid() wants user namespace */ +/* #undef HAVE_POSIX_ACL_VALID_WITH_NS */ + +/* proc_ops structure exists */ +/* #undef HAVE_PROC_OPS_STRUCT */ + +/* iops->put_link() cookie */ +/* #undef HAVE_PUT_LINK_COOKIE */ + +/* iops->put_link() delayed */ +/* #undef HAVE_PUT_LINK_DELAYED */ + +/* iops->put_link() nameidata */ +/* #undef HAVE_PUT_LINK_NAMEIDATA */ + +/* If available, contains the Python version number currently in use. */ +#define HAVE_PYTHON "3.7" + +/* qat is enabled and existed */ +/* #undef HAVE_QAT */ + +/* struct reclaim_state has reclaimed */ +/* #undef HAVE_RECLAIM_STATE_RECLAIMED */ + +/* register_shrinker is vararg */ +/* #undef HAVE_REGISTER_SHRINKER_VARARG */ + ++/* register_sysctl_table exists */ ++/* #undef HAVE_REGISTER_SYSCTL_TABLE */ ++ +/* iops->rename() wants flags */ +/* #undef HAVE_RENAME_WANTS_FLAGS */ + +/* REQ_DISCARD is defined */ +/* #undef HAVE_REQ_DISCARD */ + +/* REQ_FLUSH is defined */ +/* #undef HAVE_REQ_FLUSH */ + +/* REQ_OP_DISCARD is defined */ +/* #undef HAVE_REQ_OP_DISCARD */ + +/* REQ_OP_FLUSH is defined */ +/* #undef HAVE_REQ_OP_FLUSH */ + +/* REQ_OP_SECURE_ERASE is defined */ +/* #undef HAVE_REQ_OP_SECURE_ERASE */ + +/* REQ_PREFLUSH is defined */ +/* #undef HAVE_REQ_PREFLUSH */ + +/* revalidate_disk() is available */ +/* #undef HAVE_REVALIDATE_DISK */ + +/* revalidate_disk_size() is available */ +/* #undef HAVE_REVALIDATE_DISK_SIZE */ + +/* struct rw_semaphore has member activity */ +/* #undef HAVE_RWSEM_ACTIVITY */ + +/* struct rw_semaphore has atomic_long_t member count */ +/* #undef HAVE_RWSEM_ATOMIC_LONG_COUNT */ + +/* linux/sched/signal.h exists */ +/* #undef HAVE_SCHED_SIGNAL_HEADER */ + +/* Define to 1 if you have the header file. */ +#define HAVE_SECURITY_PAM_MODULES_H 1 + +/* setattr_prepare() accepts mnt_idmap */ +/* #undef HAVE_SETATTR_PREPARE_IDMAP */ + +/* setattr_prepare() is available, doesn't accept user_namespace */ +/* #undef HAVE_SETATTR_PREPARE_NO_USERNS */ + +/* setattr_prepare() accepts user_namespace */ +/* #undef HAVE_SETATTR_PREPARE_USERNS */ + +/* iops->set_acl() exists, takes 3 args */ +/* #undef HAVE_SET_ACL */ + +/* iops->set_acl() takes 4 args, arg1 is struct mnt_idmap * */ +/* #undef HAVE_SET_ACL_IDMAP_DENTRY */ + +/* iops->set_acl() takes 4 args */ +/* #undef HAVE_SET_ACL_USERNS */ + +/* iops->set_acl() takes 4 args, arg2 is struct dentry * */ +/* #undef HAVE_SET_ACL_USERNS_DENTRY_ARG2 */ + +/* set_cached_acl() is usable */ +/* #undef HAVE_SET_CACHED_ACL_USABLE */ + +/* set_special_state() exists */ +/* #undef HAVE_SET_SPECIAL_STATE */ + +/* struct shrink_control exists */ +/* #undef HAVE_SHRINK_CONTROL_STRUCT */ + +/* kernel_siginfo_t exists */ +/* #undef HAVE_SIGINFO */ + +/* signal_stop() exists */ +/* #undef HAVE_SIGNAL_STOP */ + +/* new shrinker callback wants 2 args */ +/* #undef HAVE_SINGLE_SHRINKER_CALLBACK */ + +/* cs->count_objects exists */ +/* #undef HAVE_SPLIT_SHRINKER_CALLBACK */ + +#if defined(__amd64__) || defined(__i386__) +/* Define if host toolchain supports SSE */ +#define HAVE_SSE 1 + +/* Define if host toolchain supports SSE2 */ +#define HAVE_SSE2 1 + +/* Define if host toolchain supports SSE3 */ +#define HAVE_SSE3 1 + +/* Define if host toolchain supports SSE4.1 */ +#define HAVE_SSE4_1 1 + +/* Define if host toolchain supports SSE4.2 */ +#define HAVE_SSE4_2 1 + +/* Define if host toolchain supports SSSE3 */ +#define HAVE_SSSE3 1 +#endif + +/* STACK_FRAME_NON_STANDARD is defined */ +/* #undef HAVE_STACK_FRAME_NON_STANDARD */ + +/* standalone exists */ +/* #undef HAVE_STANDALONE_LINUX_STDARG */ + +/* 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 the `strlcat' function. */ +#define HAVE_STRLCAT 1 + +/* Define to 1 if you have the `strlcpy' function. */ +#define HAVE_STRLCPY 1 + +/* submit_bio is member of struct block_device_operations */ +/* #undef HAVE_SUBMIT_BIO_IN_BLOCK_DEVICE_OPERATIONS */ + +/* super_setup_bdi_name() exits */ +/* #undef HAVE_SUPER_SETUP_BDI_NAME */ + +/* super_block->s_user_ns exists */ +/* #undef HAVE_SUPER_USER_NS */ + +/* struct kobj_type has default_groups */ +/* #undef HAVE_SYSFS_DEFAULT_GROUPS */ + +/* 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 + +/* i_op->tmpfile() exists */ +/* #undef HAVE_TMPFILE */ + +/* i_op->tmpfile() uses old dentry signature */ +/* #undef HAVE_TMPFILE_DENTRY */ + +/* i_op->tmpfile() has mnt_idmap */ +/* #undef HAVE_TMPFILE_IDMAP */ + +/* i_op->tmpfile() has userns */ +/* #undef HAVE_TMPFILE_USERNS */ + +/* totalhigh_pages() exists */ +/* #undef HAVE_TOTALHIGH_PAGES */ + +/* kernel has totalram_pages() */ +/* #undef HAVE_TOTALRAM_PAGES_FUNC */ + +/* Define to 1 if you have the `udev_device_get_is_initialized' function. */ +/* #undef HAVE_UDEV_DEVICE_GET_IS_INITIALIZED */ + +/* kernel has __kernel_fpu_* functions */ +/* #undef HAVE_UNDERSCORE_KERNEL_FPU */ + +/* Define to 1 if you have the header file. */ +#define HAVE_UNISTD_H 1 + +/* iops->getattr() takes struct user_namespace* */ +/* #undef HAVE_USERNS_IOPS_GETATTR */ + +/* iops->setattr() takes struct user_namespace* */ +/* #undef HAVE_USERNS_IOPS_SETATTR */ + +/* iops->getattr() takes a vfsmount */ +/* #undef HAVE_VFSMOUNT_IOPS_GETATTR */ + +/* aops->direct_IO() uses iovec */ +/* #undef HAVE_VFS_DIRECT_IO_IOVEC */ + +/* aops->direct_IO() uses iov_iter without rw */ +/* #undef HAVE_VFS_DIRECT_IO_ITER */ + +/* aops->direct_IO() uses iov_iter with offset */ +/* #undef HAVE_VFS_DIRECT_IO_ITER_OFFSET */ + +/* aops->direct_IO() uses iov_iter with rw and offset */ +/* #undef HAVE_VFS_DIRECT_IO_ITER_RW_OFFSET */ + +/* filemap_dirty_folio exists */ +/* #undef HAVE_VFS_FILEMAP_DIRTY_FOLIO */ + +/* All required iov_iter interfaces are available */ +/* #undef HAVE_VFS_IOV_ITER */ + +/* fops->iterate() is available */ +/* #undef HAVE_VFS_ITERATE */ + +/* fops->iterate_shared() is available */ +/* #undef HAVE_VFS_ITERATE_SHARED */ + +/* fops->readdir() is available */ +/* #undef HAVE_VFS_READDIR */ + +/* address_space_operations->readpages exists */ +/* #undef HAVE_VFS_READPAGES */ + +/* read_folio exists */ +/* #undef HAVE_VFS_READ_FOLIO */ + +/* fops->read/write_iter() are available */ +/* #undef HAVE_VFS_RW_ITERATE */ + +/* __set_page_dirty_nobuffers exists */ +/* #undef HAVE_VFS_SET_PAGE_DIRTY_NOBUFFERS */ + +/* __vmalloc page flags exists */ +/* #undef HAVE_VMALLOC_PAGE_KERNEL */ + +/* yes */ *** 206 LINES SKIPPED *** From nobody Sun Oct 1 00:22:10 2023 X-Original-To: dev-commits-src-branches@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 4RylC631CPz4w2gV; Sun, 1 Oct 2023 00:22: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RylC62TkWz4LGc; Sun, 1 Oct 2023 00:22:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696119730; 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=DDfLT55oIesf1Nu30UAME1FOmoNkYK78z7QUyE0Ohd0=; b=urhTioD+2xWLlXOgiS4kxbN4geI3ihV3pPcn13sTQsVkQ3uE2INKfK2qiXWS8TyOPetk24 tfo9ZytEx4hxl3dWNYEzVavpdVhzjcFlMYeBYLgiglNOz1ApSHU8T5W3+honzUCAVmII9e sg+yBfeZ+YSulsAydLdfAKxg4p8uvnNmwKNA34L8lvB4QyY9q619AMMyl9oKHdB2bJ2lC1 +vgRi8qm0X1XkAk8lVGvRwD2a5AagVBd3y1oWvUHM95uIuLFFUkD40nd3s2OuXreFUgEo1 P3XW5u9DKkhKK1euRdCNVJlfnXFVMPz4Xbqawe9q+WL5gQjWYhZNRVrgH9nIZw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696119730; a=rsa-sha256; cv=none; b=KURGI3le8EJwFdh4tfF5OCnh0jCksE5vDzqS6pOabLQGXDaLG8CXn56HvDJplXBdsWINxi 42iXLuVl4BtAvBk2NPsoLE/K14XBsBvqqvMjurpA9fFfn42GCXHhmQvS7fVJA0gNSqoi6j /hdw2bPovLdNB/60Ao8jStkUmAuGq6JiKuIWwuv/tsqdjx1Br+NKc8rCD/0UrONcHfGkgs spnGEwh323n81S2lVPPbPEmSfgJ1Xvu7/TBt7ryNWIzO3BCVKesPAgNLdLyU8Ive4WjJOd PA4yJ/IBGhx593xjC7v5eyZP42o76Rr+uoby772Pu16dA8F5xzspdz/+hvTeVQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696119730; 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=DDfLT55oIesf1Nu30UAME1FOmoNkYK78z7QUyE0Ohd0=; b=gK9M5yX69P2rzZ/dNU2Rgqk6Yte5PwJ+eMZbrW2mVbtIu0XdWNlp35mhANt/BWieDGJq78 PlK0eFW2QQlj+tDRPp0EQqUAc5MmGjrNS4swFFW5rZztnJR7KWvA+aPkoixURbjngG5O/c 5jCWTOnfIjM94il9aXq/IWatpUXFnDez/h3yEPi1n5lzyGex34sqp3Z0YJjPCz6j4UvdGm pweuXEPEOY4V6fkZSrIxVAt+DR83BClGpFn9/QQ83CFThmY6UWO7+e2DEd86bVeWKYuAXB KIoxQ8IqS5k85vQTTfeafw4t7PSACIS51L376wgCGBCOxpFY/7DtSF3Psiq+MA== 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 4RylC61XrJz17Y4; Sun, 1 Oct 2023 00:22:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3910MA4r093440; Sun, 1 Oct 2023 00:22:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3910MAlp093437; Sun, 1 Oct 2023 00:22:10 GMT (envelope-from git) Date: Sun, 1 Oct 2023 00:22:10 GMT Message-Id: <202310010022.3910MAlp093437@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: f21f0d2e16af - stable/14 - arp(8): fix by-interface and by-host filtering when using netlink List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: f21f0d2e16af702c53bc150c6c23d1bc99399bcd Auto-Submitted: auto-generated The branch stable/14 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=f21f0d2e16af702c53bc150c6c23d1bc99399bcd commit f21f0d2e16af702c53bc150c6c23d1bc99399bcd Author: R. Christian McDonald AuthorDate: 2023-09-14 07:07:24 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2023-09-30 13:26:12 +0000 arp(8): fix by-interface and by-host filtering when using netlink arp(8) has traditionally supported filtering by interface via -i and by hostname. However, this functionality was omitted from the initial netlink-ification of arp. This patch re-introduces this filtering functionality. This patch also improves by-interface filtering by storing and using the ifindex of the requested interface for filtering instead of comparing interface name strings Reviewed by: melifaro Sponsored by: Rubicon Communications, LLC ("Netgate") (cherry picked from commit 79278872ad966e5f54805efbeb692c8cbc0306c8) --- usr.sbin/arp/arp.c | 34 +++++++++++++++------------------- usr.sbin/arp/arp.h | 2 ++ usr.sbin/arp/arp_netlink.c | 8 ++++++++ 3 files changed, 25 insertions(+), 19 deletions(-) diff --git a/usr.sbin/arp/arp.c b/usr.sbin/arp/arp.c index 02b2bb1ac4f8..9a19d792f788 100644 --- a/usr.sbin/arp/arp.c +++ b/usr.sbin/arp/arp.c @@ -98,8 +98,6 @@ static int get_ether_addr(in_addr_t ipaddr, struct ether_addr *hwaddr); static int set_rtsock(struct sockaddr_in *dst, struct sockaddr_dl *sdl_m, char *host); -static char *rifname; - struct if_nameindex *ifnameindex; struct arp_opts opts = {}; @@ -146,7 +144,7 @@ main(int argc, char *argv[]) SETFUNC(F_FILESET); break; case 'i': - rifname = optarg; + opts.rifname = optarg; break; case '?': default: @@ -157,15 +155,15 @@ main(int argc, char *argv[]) if (!func) func = F_GET; - if (rifname) { + if (opts.rifname) { if (func != F_GET && !(func == F_DELETE && opts.aflag)) xo_errx(1, "-i not applicable to this operation"); - if (if_nametoindex(rifname) == 0) { + if ((opts.rifindex = if_nametoindex(opts.rifname)) == 0) { if (errno == ENXIO) xo_errx(1, "interface %s does not exist", - rifname); + opts.rifname); else - xo_err(1, "if_nametoindex(%s)", rifname); + xo_err(1, "if_nametoindex(%s)", opts.rifname); } } switch (func) { @@ -179,7 +177,7 @@ main(int argc, char *argv[]) xo_open_list("arp-cache"); struct in_addr all_addrs = {}; - print_entries(0, all_addrs); + print_entries(opts.rifindex, all_addrs); xo_close_list("arp-cache"); xo_close_container("arp"); @@ -448,13 +446,13 @@ get(char *host) xo_open_container("arp"); xo_open_list("arp-cache"); - found = print_entries(0, addr->sin_addr); + found = print_entries(opts.rifindex, addr->sin_addr); if (found == 0) { xo_emit("{d:hostname/%s} ({d:ip-address/%s}) -- no entry", host, inet_ntoa(addr->sin_addr)); - if (rifname) - xo_emit(" on {d:interface/%s}", rifname); + if (opts.rifname) + xo_emit(" on {d:interface/%s}", opts.rifname); xo_emit("\n"); } @@ -552,7 +550,6 @@ search(u_long addr, action_fn *action) struct rt_msghdr *rtm; struct sockaddr_in *sin2; struct sockaddr_dl *sdl; - char ifname[IF_NAMESIZE]; int st, found_entry = 0; mib[0] = CTL_NET; @@ -586,14 +583,13 @@ search(u_long addr, action_fn *action) rtm = (struct rt_msghdr *)next; sin2 = (struct sockaddr_in *)(rtm + 1); sdl = (struct sockaddr_dl *)((char *)sin2 + SA_SIZE(sin2)); - if (rifname && if_indextoname(sdl->sdl_index, ifname) && - strcmp(ifname, rifname)) + if (opts.rifindex && + (opts.rifindex != sdl->sdl_index)) continue; - if (addr) { - if (addr != sin2->sin_addr.s_addr) - continue; - found_entry = 1; - } + if (addr && + (addr != sin2->sin_addr.s_addr)) + continue; + found_entry = 1; (*action)(sdl, sin2, rtm); } free(buf); diff --git a/usr.sbin/arp/arp.h b/usr.sbin/arp/arp.h index a7de3a1a3024..487863be43e7 100644 --- a/usr.sbin/arp/arp.h +++ b/usr.sbin/arp/arp.h @@ -10,6 +10,8 @@ struct arp_opts { bool nflag; time_t expire_time; int flags; + char *rifname; + unsigned int rifindex; }; extern struct arp_opts opts; diff --git a/usr.sbin/arp/arp_netlink.c b/usr.sbin/arp/arp_netlink.c index 4e5c8f3d9940..40b5367f330d 100644 --- a/usr.sbin/arp/arp_netlink.c +++ b/usr.sbin/arp/arp_netlink.c @@ -281,6 +281,7 @@ print_entries_nl(uint32_t ifindex, struct in_addr addr) struct ndmsg *ndmsg = snl_reserve_msg_object(&nw, struct ndmsg); if (ndmsg != NULL) { ndmsg->ndm_family = AF_INET; + /* let kernel filter results by interface if provided */ ndmsg->ndm_ifindex = ifindex; } @@ -296,6 +297,7 @@ print_entries_nl(uint32_t ifindex, struct in_addr addr) while ((hdr = snl_read_reply_multi(&ss_req, nlmsg_seq, &e)) != NULL) { struct snl_parsed_neigh neigh = {}; + struct sockaddr_in *neighaddr; if (!snl_parse_nlmsg(&ss_req, hdr, &snl_rtm_neigh_parser, &neigh)) continue; @@ -307,6 +309,12 @@ print_entries_nl(uint32_t ifindex, struct in_addr addr) continue; } + /* filter results based on host if provided */ + neighaddr = (struct sockaddr_in *)neigh.nda_dst; + if (addr.s_addr && + (addr.s_addr != neighaddr->sin_addr.s_addr)) + continue; + print_entry(&neigh, &link); count++; snl_clear_lb(&ss_req); From nobody Sun Oct 1 04:41:58 2023 X-Original-To: dev-commits-src-branches@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 4Ryryt5jnDz4wHG9; Sun, 1 Oct 2023 04:41: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Ryryt5D8Dz3DNv; Sun, 1 Oct 2023 04:41:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696135318; 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=okEzIn0baRUBYj4N0V0ESunPZg6HUi7fdIh0nAcQzi8=; b=KdWSPWOeidJeK3+jX2aovL0Z2h5/4bWu6VF1c5MESRzSGh/mCmZYJxv5E24XuS3TGTyLgi oEXcahdgzTtYK9J96cMgZ1/4M+fn1YDi8VYWkTI0Cj4tIihcwM/+GNOudQ15q1hiZwu/3y ScQCfuQynmJULwzTE3Y/TD04dzjn5DF9ZnBg3C92wz3M7jBXeNfr/+LMo+GxKD7z0G+4Mt Ufmyexmxp0zrvRADAAZdI8X0uyqXSqj5WZeNig6ihzcMJlHIspU48SPqjw+9qzyaPMkg3w KOQPoLq8pcrzVxhLsPWp3HTcgs4VAu/4Lbo7cshM3cAMOmXbZruyNOHo50mYfw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696135318; a=rsa-sha256; cv=none; b=hivmey3rGmjvE6cTuoh9YE92SMg4U2yzJZmcaMOqWT87yWF/H2fEdMmCRt7wByb28CuCNw /HiuEqTWiQpQkcVd+ofEYWLPdKtlKm8nffwTb6IkluiS7+pkFjev9/0EoeNY10wFiQD4ms mCKtseV2id3VW6bdq9fBL4n2ev5IK9MyAjkInTxj6M3ZTxvK6KB1nro7M8IlxLBMxH7N8M mYBzZiiMD8ScKEItnoDGB14rE8+aCdx7rg9X6VpfK74FJG3ZHJ+ZFzYKgfPixZO0cZf0WD Z59eVGzgwV5ONajb3qd/z3ULLcBwMmi+g27dqVk9Dn10CZz0NX+4mmDuxoQt4Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696135318; 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=okEzIn0baRUBYj4N0V0ESunPZg6HUi7fdIh0nAcQzi8=; b=GFnE15qAlxzX8aCUHuBniJ6CKf/IL/1bjQjGRxaMUrdCVbjLOcoQ/4qb9V7uwNs13YNtzf W426uiV+6EQ0mkF7NkYELKn9NdtHSxXPJRzIksNYoLFq/4ChQ4KBBUjOQHn4eGIgufxfMy vyNOZznloLeKW3qwU19MeYLL9qSjGox1FQw1JWGrYzFMB/aSkThgcqChYGvUB9X4JC9pJa z2hX7Dzb65HMmkCN1WabBXV+kWFQaQmwcL1lT6/6Y9MRQRglSDP8TIT5CMNF/Zxw75stv7 38hkyMLapHOCRYRcSWkcdICf5LuKBpvQ3A9byVkD9VWnKc2PYiuQQI6FC7j4ag== 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 4Ryryt4GjPz1rt; Sun, 1 Oct 2023 04:41:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3914fw0R023889; Sun, 1 Oct 2023 04:41:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3914fwVS023886; Sun, 1 Oct 2023 04:41:58 GMT (envelope-from git) Date: Sun, 1 Oct 2023 04:41:58 GMT Message-Id: <202310010441.3914fwVS023886@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 7454117918cd - releng/14.0 - timerfd: Namespace pollution adjustments List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 7454117918cd9f7900d92513a7a4e3ed361987bc Auto-Submitted: auto-generated The branch releng/14.0 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=7454117918cd9f7900d92513a7a4e3ed361987bc commit 7454117918cd9f7900d92513a7a4e3ed361987bc Author: Jake Freeland AuthorDate: 2023-09-17 15:02:09 +0000 Commit: Warner Losh CommitDate: 2023-10-01 04:40:03 +0000 timerfd: Namespace pollution adjustments Do not pollute userspace with , instead declare struct thread when _KERNEL is defined. Include instead of . This causes intentional namespace pollution that mimics Linux. g/musl libcs include in their , exposing clock gettime, settime functions and CLOCK_ macro constants. Ports like Chromium expect this namespace pollution and fail without it. MFC After: 3 days Reviewed by: imp, markj Differential Revision: https://reviews.freebsd.org/D41641 (cherry picked from commit fb5daae920bae84e3eec8175bf9e46304c3b2ae6) (cherry picked from commit 8bcf9a87c79d8de05bc79ff2f8530bf4a52162ca) Approved-by: re (gjb) --- sys/sys/timerfd.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/sys/sys/timerfd.h b/sys/sys/timerfd.h index 8cb9939ba60f..cace3b71498c 100644 --- a/sys/sys/timerfd.h +++ b/sys/sys/timerfd.h @@ -30,8 +30,12 @@ #include #include -#include -#include +/* + * We only need , but glibc pollutes the namespace + * with . This pollution is expected by most programs, so + * reproduce it by including here. + */ +#include typedef uint64_t timerfd_t; @@ -54,6 +58,8 @@ __END_DECLS #else /* _KERNEL */ +struct thread; + int kern_timerfd_create(struct thread *td, int clockid, int flags); int kern_timerfd_gettime(struct thread *td, int fd, struct itimerspec *curr_value); From nobody Sun Oct 1 04:46:17 2023 X-Original-To: dev-commits-src-branches@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 4Rys3s52pvz4wH8l; Sun, 1 Oct 2023 04:46: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Rys3s4QMsz3Dbn; Sun, 1 Oct 2023 04:46:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696135577; 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=xk+upWZE07s7AiiIIl1rlXC/RbSdSeny5MFmjFg9hT8=; b=O3yITLXhDkKW5j9Un/rHf1YOS+n4sIKRz4n+b5VVUGN6PC4lBomrO/E3NGWP6Ijhq/zPwt BLxKNwuNYCdcbHW5wu+Ypvbf8qZviUNHNl642IZwHoprYffdN+DIwd9Mu+JTcgkUtlFREA gkK7Vz/b7PrMhdKYox+uu5YlGgCHhGplgD41bPRkIzedevq71H8BCOPVNaK7o7q5mOZQYW uDBID/Mm8hCQjwG4P7M1VATSjSGPm5ARPO2j6k/1cHMpRzduGnNdxH+6E3RK7HHImbcEXQ fJ8e0T/1aZAU1yfJs/ThERF+O5t+eZuO99f0FAHxJCbQLcHrdJQlnbbqOB8S8w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696135577; a=rsa-sha256; cv=none; b=B+CsaEkZ0rPCzJbWy+RZEvkwee6k9Zk3LenxiNAzYO/4t/8e1eUx5AS66L5qcLj0a4djtO 2qhhIDIvtW8Lu1Po5xPDdTlVcNugZ45R8Q1lui6PKCmCKkoXisxdBmP88lhMWrdhLY1Cr9 hPMVwgJLaMtMfOPMloS1bl42kLpOQQDb0gv2pzzrWR+BsxHbuNfkN4WPcMHiIy8doJg8MO YGye9N69JtZ3Bjinjmc47++zHV7VFnmb/cz4u5rbP3FjRvSb1q1/PPpI6YRoBz2iNf/dIV uMObcHc0KJN+OWAKjyFGDXfq2eRVQFuE1+r0fWlnI2wp72Nhgr7HR3W54OlSGg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696135577; 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=xk+upWZE07s7AiiIIl1rlXC/RbSdSeny5MFmjFg9hT8=; b=ni2bE9C2COh//XyscLjYIP8VVYHR5KiPViExL4X977ZWMC1QoHoj96Pvr4T9wMYFGCDAVo zUN9eAxf9usIGS5uGEzaauMD7RJ13ryvQXs9+O7GWAuZtt2fFaFqj2gerYu4PT0T7ZQrfm DcGbrg5N7EUF1lDwuNas185erJO2tFUDPWBxP5JO3KLwLbda2tgfZCFltUwGOp5T+r9UkV r5iOabJ+JWNYjsJMHjZDJso7JVWBK/J8dOmjAYJ8S6Od/gcVsLpZqCD6+viwJJyrI5FBvU 6Gmy3S25ek1lh/fBEElMR3zRKzjBRqC2T9eKiZb0HiMZUIbqrIl7GUC7WCpUpQ== 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 4Rys3s3Tq4z268; Sun, 1 Oct 2023 04:46:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3914kHtg026926; Sun, 1 Oct 2023 04:46:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3914kHPQ026923; Sun, 1 Oct 2023 04:46:17 GMT (envelope-from git) Date: Sun, 1 Oct 2023 04:46:17 GMT Message-Id: <202310010446.3914kHPQ026923@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: 408daf2caa92 - releng/14.0 - regcomp: use unsigned char when testing for escapes List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 408daf2caa9273b1cbdc8223a3da6e179e922fc2 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=408daf2caa9273b1cbdc8223a3da6e179e922fc2 commit 408daf2caa9273b1cbdc8223a3da6e179e922fc2 Author: Christos Zoulas AuthorDate: 2023-08-30 20:37:24 +0000 Commit: Kyle Evans CommitDate: 2023-10-01 04:46:02 +0000 regcomp: use unsigned char when testing for escapes - cast GETNEXT to unsigned where it is being promoted to int to prevent sign-extension (really it would have been better for PEEK*() and GETNEXT() to return unsigned char; this would have removed a ton of (uch) casts, but it is too intrusive for now). - fix an isalpha that should have been iswalpha PR: 264275, 274032 Reviewed by: kevans, eugen (previous version) Approved by: re (gjb) Obtained from: NetBSD (cherry picked from commit 3fb80f1476c7776f04ba7ef6d08397cef6abcfb0) (cherry picked from commit 56b09feb23d98fcd0c4aed8d4f907a5a2f6b5ea9) --- lib/libc/regex/regcomp.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/libc/regex/regcomp.c b/lib/libc/regex/regcomp.c index 791755ceb14d..42fa1b99e58e 100644 --- a/lib/libc/regex/regcomp.c +++ b/lib/libc/regex/regcomp.c @@ -828,10 +828,10 @@ p_simp_re(struct parse *p, struct branchc *bc) handled = false; assert(MORE()); /* caller should have ensured this */ - c = GETNEXT(); + c = (uch)GETNEXT(); if (c == '\\') { (void)REQUIRE(MORE(), REG_EESCAPE); - cc = GETNEXT(); + cc = (uch)GETNEXT(); c = BACKSL | cc; #ifdef LIBREGEX if (p->gnuext) { @@ -992,7 +992,7 @@ p_count(struct parse *p) int ndigits = 0; while (MORE() && isdigit((uch)PEEK()) && count <= DUPMAX) { - count = count*10 + (GETNEXT() - '0'); + count = count*10 + ((uch)GETNEXT() - '0'); ndigits++; } @@ -1302,7 +1302,7 @@ may_escape(struct parse *p, const wint_t ch) if ((p->pflags & PFLAG_LEGACY_ESC) != 0) return (true); - if (isalpha(ch) || ch == '\'' || ch == '`') + if (iswalpha(ch) || ch == '\'' || ch == '`') return (false); return (true); #ifdef NOTYET From nobody Sun Oct 1 07:05:09 2023 X-Original-To: dev-commits-src-branches@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 4Ryw855d6Gz4wPqR; Sun, 1 Oct 2023 07:05: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Ryw8555Yvz3NNd; Sun, 1 Oct 2023 07:05:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696143909; 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=23RhBupbGqpOYOXqDNWgTycqHM670LhPyDshfFzU41s=; b=tQRnOwV30HSh2ggRct9koo8OuUpQ8rKYOCfdchJT/bfqZ/94dk4/jtjik9pIS0VELv4HHA Tw/wLSwd5q4q2JbqiW3Jsk8IOQ0o0Zfe/nEElX5a0ZgOfzFYUX5EdLbKqhaH49MMIdgOlo /Ch5OaNuInPmRVjmETZHfGKCHye5ssc43+jpeU31TkU3lNmEpYpBnrzhBr1GUIdO0eDTrA OvOqizpgZG5jLQatVKp42//4exBbLhPM1iUvK4GmzFdowkvU5sMzKeBZvcigVLj911L4gv raYfPEo0jqQ5RDPayzr6xeqfYOMWRBSe/px9bSI9fI1CCfqAIGfekIE+TJZ1Gw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696143909; a=rsa-sha256; cv=none; b=tO6R1/Un+idqPchLe841XMZmShqS2J3j5KZkLhFc5a+sbEu9O9rDbmv+Xg6CRKy+yFzURM cuytr03CiQrQnHD+zwMFcdFbKZd3VsDZqAO7tW9sVk3p2+QOE2wSQab2L0y83/beaZXtOP twP4IC0BpgKSaB4AfKGwQ7NkmbJQZwRxqec+AfJ2YD5z/iy7bEo5iIPSpiWrqGY8nnOlNc UmeRjssz1TTtTDAsiPH3Kw58T2tw88B0YplpnkvwewhZvszuIOMQFiyC/scT8j8hsuwAvY DstFw85ITSe8mmNen20Iq4DjQ5B1RRCY7J6tlpleNvn2wWnnrglOsHS7lovEEQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696143909; 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=23RhBupbGqpOYOXqDNWgTycqHM670LhPyDshfFzU41s=; b=iyVRS6mOSt6GTC6CA4FjbePkbGUUIigQ7k6xjzb387mI1GdzhDO8yQO+XzjInheL9GyAV7 SNHDnQyqwZ6b2Nar5GvH9Rc5CJlglsysNsu/tXIq/yfoiFE26iO1mSiAcyBkdbtv2chWJQ 3WiDCBvYO1QMIkqHM2PnN5tqcV7OhoAu0Wp8rKjjpDhUs3UrhRSUU0h14CCrxbwjwKyLjh Cw34jiwTrVHw2wUlCvI/c1RMnMAnWEiKEiA7w/e53ukHT7haaM7loqLJ9lhg9nbYgZ3hm+ VzHe52PLooe9sMOjqzf9FujWiWqsNvOtctMOXfbGCcWIVZ7aU9N4tdQYIc6/KQ== 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 4Ryw853t60z4dX; Sun, 1 Oct 2023 07:05:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 391759V9059250; Sun, 1 Oct 2023 07:05:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3917592x059247; Sun, 1 Oct 2023 07:05:09 GMT (envelope-from git) Date: Sun, 1 Oct 2023 07:05:09 GMT Message-Id: <202310010705.3917592x059247@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: e6d405e2bad2 - releng/14.0 - arp(8): fix by-interface and by-host filtering when using netlink List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: e6d405e2bad22fd98f6296a793ad0c97776fe03c Auto-Submitted: auto-generated The branch releng/14.0 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=e6d405e2bad22fd98f6296a793ad0c97776fe03c commit e6d405e2bad22fd98f6296a793ad0c97776fe03c Author: R. Christian McDonald AuthorDate: 2023-09-14 07:07:24 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2023-10-01 07:04:45 +0000 arp(8): fix by-interface and by-host filtering when using netlink arp(8) has traditionally supported filtering by interface via -i and by hostname. However, this functionality was omitted from the initial netlink-ification of arp. This patch re-introduces this filtering functionality. This patch also improves by-interface filtering by storing and using the ifindex of the requested interface for filtering instead of comparing interface name strings Reviewed by: melifaro Sponsored by: Rubicon Communications, LLC ("Netgate") Approved by: re (gjb) (cherry picked from commit 79278872ad966e5f54805efbeb692c8cbc0306c8) (cherry picked from commit f21f0d2e16af702c53bc150c6c23d1bc99399bcd) --- usr.sbin/arp/arp.c | 34 +++++++++++++++------------------- usr.sbin/arp/arp.h | 2 ++ usr.sbin/arp/arp_netlink.c | 8 ++++++++ 3 files changed, 25 insertions(+), 19 deletions(-) diff --git a/usr.sbin/arp/arp.c b/usr.sbin/arp/arp.c index 02b2bb1ac4f8..9a19d792f788 100644 --- a/usr.sbin/arp/arp.c +++ b/usr.sbin/arp/arp.c @@ -98,8 +98,6 @@ static int get_ether_addr(in_addr_t ipaddr, struct ether_addr *hwaddr); static int set_rtsock(struct sockaddr_in *dst, struct sockaddr_dl *sdl_m, char *host); -static char *rifname; - struct if_nameindex *ifnameindex; struct arp_opts opts = {}; @@ -146,7 +144,7 @@ main(int argc, char *argv[]) SETFUNC(F_FILESET); break; case 'i': - rifname = optarg; + opts.rifname = optarg; break; case '?': default: @@ -157,15 +155,15 @@ main(int argc, char *argv[]) if (!func) func = F_GET; - if (rifname) { + if (opts.rifname) { if (func != F_GET && !(func == F_DELETE && opts.aflag)) xo_errx(1, "-i not applicable to this operation"); - if (if_nametoindex(rifname) == 0) { + if ((opts.rifindex = if_nametoindex(opts.rifname)) == 0) { if (errno == ENXIO) xo_errx(1, "interface %s does not exist", - rifname); + opts.rifname); else - xo_err(1, "if_nametoindex(%s)", rifname); + xo_err(1, "if_nametoindex(%s)", opts.rifname); } } switch (func) { @@ -179,7 +177,7 @@ main(int argc, char *argv[]) xo_open_list("arp-cache"); struct in_addr all_addrs = {}; - print_entries(0, all_addrs); + print_entries(opts.rifindex, all_addrs); xo_close_list("arp-cache"); xo_close_container("arp"); @@ -448,13 +446,13 @@ get(char *host) xo_open_container("arp"); xo_open_list("arp-cache"); - found = print_entries(0, addr->sin_addr); + found = print_entries(opts.rifindex, addr->sin_addr); if (found == 0) { xo_emit("{d:hostname/%s} ({d:ip-address/%s}) -- no entry", host, inet_ntoa(addr->sin_addr)); - if (rifname) - xo_emit(" on {d:interface/%s}", rifname); + if (opts.rifname) + xo_emit(" on {d:interface/%s}", opts.rifname); xo_emit("\n"); } @@ -552,7 +550,6 @@ search(u_long addr, action_fn *action) struct rt_msghdr *rtm; struct sockaddr_in *sin2; struct sockaddr_dl *sdl; - char ifname[IF_NAMESIZE]; int st, found_entry = 0; mib[0] = CTL_NET; @@ -586,14 +583,13 @@ search(u_long addr, action_fn *action) rtm = (struct rt_msghdr *)next; sin2 = (struct sockaddr_in *)(rtm + 1); sdl = (struct sockaddr_dl *)((char *)sin2 + SA_SIZE(sin2)); - if (rifname && if_indextoname(sdl->sdl_index, ifname) && - strcmp(ifname, rifname)) + if (opts.rifindex && + (opts.rifindex != sdl->sdl_index)) continue; - if (addr) { - if (addr != sin2->sin_addr.s_addr) - continue; - found_entry = 1; - } + if (addr && + (addr != sin2->sin_addr.s_addr)) + continue; + found_entry = 1; (*action)(sdl, sin2, rtm); } free(buf); diff --git a/usr.sbin/arp/arp.h b/usr.sbin/arp/arp.h index a7de3a1a3024..487863be43e7 100644 --- a/usr.sbin/arp/arp.h +++ b/usr.sbin/arp/arp.h @@ -10,6 +10,8 @@ struct arp_opts { bool nflag; time_t expire_time; int flags; + char *rifname; + unsigned int rifindex; }; extern struct arp_opts opts; diff --git a/usr.sbin/arp/arp_netlink.c b/usr.sbin/arp/arp_netlink.c index 4e5c8f3d9940..40b5367f330d 100644 --- a/usr.sbin/arp/arp_netlink.c +++ b/usr.sbin/arp/arp_netlink.c @@ -281,6 +281,7 @@ print_entries_nl(uint32_t ifindex, struct in_addr addr) struct ndmsg *ndmsg = snl_reserve_msg_object(&nw, struct ndmsg); if (ndmsg != NULL) { ndmsg->ndm_family = AF_INET; + /* let kernel filter results by interface if provided */ ndmsg->ndm_ifindex = ifindex; } @@ -296,6 +297,7 @@ print_entries_nl(uint32_t ifindex, struct in_addr addr) while ((hdr = snl_read_reply_multi(&ss_req, nlmsg_seq, &e)) != NULL) { struct snl_parsed_neigh neigh = {}; + struct sockaddr_in *neighaddr; if (!snl_parse_nlmsg(&ss_req, hdr, &snl_rtm_neigh_parser, &neigh)) continue; @@ -307,6 +309,12 @@ print_entries_nl(uint32_t ifindex, struct in_addr addr) continue; } + /* filter results based on host if provided */ + neighaddr = (struct sockaddr_in *)neigh.nda_dst; + if (addr.s_addr && + (addr.s_addr != neighaddr->sin_addr.s_addr)) + continue; + print_entry(&neigh, &link); count++; snl_clear_lb(&ss_req); From nobody Sun Oct 1 13:07:17 2023 X-Original-To: dev-commits-src-branches@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 4Rz49y0flHz4vGpR; Sun, 1 Oct 2023 13:07: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Rz49y06dbz4NyD; Sun, 1 Oct 2023 13:07:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696165638; 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=geFe3S4PGQUUYJewWC2StnHlHvkCVj/PlNUbLUOZ8lw=; b=xPWAazZEImvbH/WJ68rsHLxd/JeOqCsPbxZWvII+uNCrJYIsvdhq/SfLOjceTrAgOBtF8e Re7g8hVQn5g3DKlNmQ/OMjSkoPp+QOIHEatJk8NmapBRiwqTDRLGTBYKRX2PrH1Pt93Svn F8q50NWs0chEEB8JHc6e8WSOV330s+aG1du0CdqoH7sGc6pWTN3D1j60+aVVqPyO7Zulyo FLZ45HCZiJlRXTUd5jz7+b79uCKPc3HERAgaRWPlRnVmIYfOvjh5xpDn+TcDybhyskUsw1 /10Yss58x8ES+Ec4u4e+uJn42/sWAWpQXPxZJrCu/xES2xkx89ey3/0eT1BYjQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696165638; a=rsa-sha256; cv=none; b=hBZqyR3SmP6N13acbN7+mrWld8w9qtAFI1gwa7fUxMq+5xkdfJ97IpKzI9GXMawKgsQl5J wIRRUU/876WYG0jSfxYbLRXg8ZAQ31IO+r2u379lyj4vEAR5Gt4Nu+p3ZP3MYccDF2c/bS /F9Ik5x+foZBHhdX7KC+OMRuZecvKDjKn0OuoN2WwtbkhIaY9EqVMa0WvDTx75lJQ5RVO/ 0JBB3Q7mQB2GWzsjxaMeWQCn0PX8aQ7eO+VwMxhRSVeG9lI5KeZUX/KsV3ysC1LCMQtomW 1irQoZdI/4KfeTuHtilagNWuW+DhIyvVolhYniK14zJc1eJ5y4hQgWV4Ks/VNw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696165638; 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=geFe3S4PGQUUYJewWC2StnHlHvkCVj/PlNUbLUOZ8lw=; b=KNhGpblp7wSu9dCrnkVu96MVBXJtJRsU0Z4hOy1YphjG6K5KmFYBVQV6vrxluAgXeUh2fX OuJ/iQ7jgN9MoGCwLrlp+sei172OU8s6/Je7/xOY7T07yuteZVRn8QdRgCQY7RCLCIx1Sj uG9Leh54N1dXe2iO6j903Hw1CXAAyT1YOp3Yifjx98UEE/oM4KqA3+B2kN3F9ASOm9eic/ quM1MqXF2DJBMlg4rgh7Th6lW0k+DS0ah+zpj1j2RV6cIXe7bT/3ej4S8E9U9JhV4NiCoT kjSrQTPoLacwQr/yyd4tUrRR6NdniPPI11v+v1KUkqqOSBo5QKZYvvhADCnVeQ== 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 4Rz49x6HHvzWNF; Sun, 1 Oct 2023 13:07:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 391D7Hss058537; Sun, 1 Oct 2023 13:07:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 391D7Hta058534; Sun, 1 Oct 2023 13:07:17 GMT (envelope-from git) Date: Sun, 1 Oct 2023 13:07:17 GMT Message-Id: <202310011307.391D7Hta058534@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: bc412215646c - stable/14 - freebsd-update: handle file -> directory on upgrade List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: bc412215646cbb21529156d08fbbb7bbf5028c26 Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=bc412215646cbb21529156d08fbbb7bbf5028c26 commit bc412215646cbb21529156d08fbbb7bbf5028c26 Author: Ed Maste AuthorDate: 2023-09-27 13:36:33 +0000 Commit: Ed Maste CommitDate: 2023-10-01 13:06:44 +0000 freebsd-update: handle file -> directory on upgrade Upgrading from FreeBSD 13.2 to 14.0 failed with install: ///usr/include/c++/v1/__string exists but is not a directory because __string changed from a file to a directory with an LLVM upgrade. Now, remove the existing file when the type conflicts. Note that this is only an interim fix to facilitate upgrades from 13.2 for 14.0 BETA testing. This change does not handle the directory -> file case and further work is needed. PR: 273661 Reviewed by: dim, gordon Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D41893 (cherry picked from commit f6d37c9ca13f8ab0ef32cf5344daecb8122d1e85) --- usr.sbin/freebsd-update/freebsd-update.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/usr.sbin/freebsd-update/freebsd-update.sh b/usr.sbin/freebsd-update/freebsd-update.sh index 9cdff05c24e4..b9b277cca1c8 100644 --- a/usr.sbin/freebsd-update/freebsd-update.sh +++ b/usr.sbin/freebsd-update/freebsd-update.sh @@ -2903,7 +2903,13 @@ install_from_index () { while read FPATH TYPE OWNER GROUP PERM FLAGS HASH LINK; do case ${TYPE} in d) - # Create a directory + # Create a directory. A file may change to a directory + # on upgrade (PR273661). If that happens, remove the + # file first. + if [ -e "${BASEDIR}/${FPATH}" ] && \ + ! [ -d "${BASEDIR}/${FPATH}" ]; then + rm -f -- "${BASEDIR}/${FPATH}" + fi install -d -o ${OWNER} -g ${GROUP} \ -m ${PERM} ${BASEDIR}/${FPATH} ;; From nobody Sun Oct 1 13:07:18 2023 X-Original-To: dev-commits-src-branches@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 4Rz49z24LSz4vGvy; Sun, 1 Oct 2023 13:07: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Rz49z1FNGz4Nyl; Sun, 1 Oct 2023 13:07:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696165639; 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=LjG92aV2me+XfPCPlkFCz5N2zF+JZ6XjrSpsUgBO4uY=; b=SP99PJbzyAEYVq5c3vvKV7kdPSm0/mIZJ1NykXFLsmTuOM9lUi3wPUfobrIpR9afddI2K8 F+lTBAciOB5kAZF9k8q+1aWpS6mwLb3JRcYPygCdyjU02tjkUH8bdESXgFeF+/lHa/XDOK eynAqBBAHm+aqEV2lR3lX3ITE/JRT9aPlysZskGbZ+3AulKrXfVZu/mKiVeri8OkTP7SrE GHDVtoZsYdRZWH+rrDsWkg3ls7IZzJss3xhIMVIjpGO2T47Y+S9A/Hyvb33wjzYf5gkidu M05d9jnciGm6x/aYEyzTpi8RRX780Um5qNbZzTlJTMNTQsqxX0CiUcSAU7cxSA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696165639; a=rsa-sha256; cv=none; b=cM3/xr7kOlRnsbhXFLG2OIDQ1PgxP0dVKhfndC2I6QEwmtA7biLINdxdqjyg6qtc6UlD7P Cm5bVmGu94t3amByr3HqHu1ZvhUjajpen44N6+OMxr5l2VUQme2Ch9EtZ51k57WQSH34sJ mBWyZ5jgM/PvQmqhxcfSKKDCJp5GjPd2rtvMMg3HsSY8lDSl5nYNVVJ4jyA6e2lDw+WVCZ IRaYdqm+S0Yhg7TwzH8LSYmbe8pwhWPa+eZ95c/12xIIkXcf/zVSkZiNccGg5xouN/7UUJ xSyNFXF1+8riBU47eRHrrHv9XeDvH1LqOP+VpXTovYs8C0/VET+HNSmcp7Dybw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696165639; 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=LjG92aV2me+XfPCPlkFCz5N2zF+JZ6XjrSpsUgBO4uY=; b=d4yB3eTRwRVbpTe8ViKWw63CLikkzpn3BnRPZFgL56UBvTTmGy0mzIB+Sl7jQDWoG7eQbZ 5RZEeO9QsVmnOlhdXFPlcjoqgOHZDH7oNF4ORq4hMN81Fz4OU0876sXzISrsqE+LwgaOa+ aas4MHjf6J6HQWLyn0iqXVBgdmShjd5PgdLpKpd/rnqQo4LSkAw7uGk1c+4GHVA5k1eg+H TSY+8C66a2EXYpGlBGS6CsU8J5OCcw4JoSEfTBAUJGq800MPYVpSWiL2+/zIm94/x7i31c SERXzUjroDqT5+sE7Req9uegjiz6i+TlBc6KG9v9sc0mqNrZkzgND9EtVwAe3g== 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 4Rz49z07zXzWcV; Sun, 1 Oct 2023 13:07:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 391D7IcZ058594; Sun, 1 Oct 2023 13:07:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 391D7Iw9058591; Sun, 1 Oct 2023 13:07:18 GMT (envelope-from git) Date: Sun, 1 Oct 2023 13:07:18 GMT Message-Id: <202310011307.391D7Iw9058591@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: 48316eed02bd - stable/14 - pf: add note about changes ported from OpenBSD after 4.5 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 48316eed02bd6d31d2aa5cbcb77cda33625aed8e Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=48316eed02bd6d31d2aa5cbcb77cda33625aed8e commit 48316eed02bd6d31d2aa5cbcb77cda33625aed8e Author: Ed Maste AuthorDate: 2023-09-27 17:59:30 +0000 Commit: Ed Maste CommitDate: 2023-10-01 13:06:44 +0000 pf: add note about changes ported from OpenBSD after 4.5 The last comprehensive sync with OpenBSD's pf corresponds to OpenBSD 4.5, but many changes have been ported over since then. Reviewed by: kp, gbe, Kajetan Staszkiewicz Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D42002 (cherry picked from commit 3e609fd481c07802fe837ed834c3710b8c19493c) --- share/man/man4/pf.4 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/share/man/man4/pf.4 b/share/man/man4/pf.4 index 4055c66fbbce..4f0ff50d3db5 100644 --- a/share/man/man4/pf.4 +++ b/share/man/man4/pf.4 @@ -1219,6 +1219,9 @@ and then .Pp This implementation is derived from .Ox 4.5 . +A number of individual features, improvements, bug fixes and security fixes +have been ported from later versions of +.Ox . It has been heavily modified to be capable of running in multithreaded .Fx kernel and scale its performance on multiple CPUs. From nobody Sun Oct 1 16:31:00 2023 X-Original-To: dev-commits-src-branches@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 4Rz8j05VhGz4vWKD; Sun, 1 Oct 2023 16:31: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Rz8j053hZz3QWV; Sun, 1 Oct 2023 16:31:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696177860; 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=hJIxSNctamg7y0/LwFUfKzkfOLkEjzHa8ml4051FfQo=; b=u8IRKd2W4Rg9jieBb/cM5NK4sxGhMq4Ln/UUv5Ua7FDsfWwP3uPSH4U5jsBxdDOqTtvlZp bWUVVO/2A8waiPB5oMklAuiR0l9IaSU+usRLm6/tY+19dNiUnWMzOoUTOACH0JrhAyybCr 1F7OplDBhH8EzSBaVgNE85N9dAzXhJnV3kKc0J8Nlhr0VW+f16MO0s08a/+R35QBo/AMel JdTokiuK+2O/XGo3Uf9MMW6mkUrY9y3tt99ePc2Fg9pE7W5hVcgeF8Out5XZgfrpJSLsGZ 9IPUWDd2BXfd87dxxDlysyhBIlD20HsjlBF8Rwqw5j5f6+DQFXTg+FIblT17nw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696177860; a=rsa-sha256; cv=none; b=cZPIu89ACYzTLyO+0yTHA86hcehiW2OSrwi0bBL8ilLVCCmAl3JuU13DeB2KRz1qFzdPIf hsxdDQTRZI0p1esaSqbSqycEq/ebglJbo03U2V4A5gXZwWVdR0Xr0YKBSai42kZSv+ZSRg uBPg7Ljhtc71gOFNpLn3QjAsHLDjJuxPyl/jPR+tzU9T4uHinbaYIbOTmdYzrq6nY1HkDK PmpHgNy2ktggixelN/wROzPKO/xwCj5wliJrpOWslRZRoeQZg6hoWD8W/nEqIly+8243Ge LKFTGdEkrl0a4QOSak080OL+uspVvUmZ1qVQwsYql8lAtzUuLD2rPYkSs85UBg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696177860; 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=hJIxSNctamg7y0/LwFUfKzkfOLkEjzHa8ml4051FfQo=; b=yz9xErM5JrmZjGy0dB+mstx2HMSiz0KyP7Sa+W5mnvE5JGAgz+I7KzcYD78LtxLZs5ZrB3 jjbve0QCkfsUwffYgJWazaUXbpgR1buM+SBta9/65J8VZri2ZXXC6jX+NpYoCWbZAsCVlR KK9w6ubiGYfwZfF7RFU4HTCHSF0v4fzpVxPApqSYdN/CPfwKR11PFtioEJgSv8G41APxY3 N97Z1f+sAXE6PWfub+vlhtaEGb3g+6YPIJ+gY64x+iFqnq73SY8TjeBvAmf9MUb8Y4xYiX IJA3wrs//+uzfFsys6PSRoXjgUXALenW7ly8RCXXn2m11g7TPY+VJZUFrONnLw== 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 4Rz8j0476wzcF3; Sun, 1 Oct 2023 16:31:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 391GV0VW098853; Sun, 1 Oct 2023 16:31:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 391GV0Ow098850; Sun, 1 Oct 2023 16:31:00 GMT (envelope-from git) Date: Sun, 1 Oct 2023 16:31:00 GMT Message-Id: <202310011631.391GV0Ow098850@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: 4719202d8cff - releng/14.0 - freebsd-update: handle file -> directory on upgrade List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 4719202d8cffdcae1645b2bf508ba6097e912b77 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=4719202d8cffdcae1645b2bf508ba6097e912b77 commit 4719202d8cffdcae1645b2bf508ba6097e912b77 Author: Ed Maste AuthorDate: 2023-09-27 13:36:33 +0000 Commit: Ed Maste CommitDate: 2023-10-01 16:28:04 +0000 freebsd-update: handle file -> directory on upgrade Upgrading from FreeBSD 13.2 to 14.0 failed with install: ///usr/include/c++/v1/__string exists but is not a directory because __string changed from a file to a directory with an LLVM upgrade. Now, remove the existing file when the type conflicts. Note that this is only an interim fix to facilitate upgrades from 13.2 for 14.0 BETA testing. This change does not handle the directory -> file case and further work is needed. PR: 273661 Reviewed by: dim, gordon Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D41893 (cherry picked from commit f6d37c9ca13f8ab0ef32cf5344daecb8122d1e85) (cherry picked from commit bc412215646cbb21529156d08fbbb7bbf5028c26) Approved by: re (gjb) --- usr.sbin/freebsd-update/freebsd-update.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/usr.sbin/freebsd-update/freebsd-update.sh b/usr.sbin/freebsd-update/freebsd-update.sh index 9cdff05c24e4..b9b277cca1c8 100644 --- a/usr.sbin/freebsd-update/freebsd-update.sh +++ b/usr.sbin/freebsd-update/freebsd-update.sh @@ -2903,7 +2903,13 @@ install_from_index () { while read FPATH TYPE OWNER GROUP PERM FLAGS HASH LINK; do case ${TYPE} in d) - # Create a directory + # Create a directory. A file may change to a directory + # on upgrade (PR273661). If that happens, remove the + # file first. + if [ -e "${BASEDIR}/${FPATH}" ] && \ + ! [ -d "${BASEDIR}/${FPATH}" ]; then + rm -f -- "${BASEDIR}/${FPATH}" + fi install -d -o ${OWNER} -g ${GROUP} \ -m ${PERM} ${BASEDIR}/${FPATH} ;; From nobody Sun Oct 1 16:33:11 2023 X-Original-To: dev-commits-src-branches@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 4Rz8lW6fKYz4vWlB; Sun, 1 Oct 2023 16:33: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Rz8lW688rz3Qt6; Sun, 1 Oct 2023 16:33:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696177991; 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=oVoyy+9NOVuV1ro0IGc7AI55uL8P08OY/EdaF4yK/ak=; b=ZZ0192LcCbJa1Clifn82mubqWLPb7mh9ki0Zq2b53wcbRlY3mgbWvdf4WfsMRkltwIFZ2H ACmHE6Gpa/A9P7kIxsQJ+ovC2eNy/s8DGERNdQD03Uu3PvQ7DOio3kLbzlZN8HkjYZd5cz bfrfW4Z8XgasRI8DOU/vJpk9YUGwcxebww4+k7KH2jihoXLn8dCUG1o9cQGuAkhfSPLPGz 6kG6S6W3VNo48qe4u+4xT10u8S7xyjnbVi/SzTiuBjQlfXDUhGuS4YFrM6IIEmUmRWMokk hnU1bjipJbJe6Lqpo3EaHFxpXdcBZSqKgHGxkSlamblIZXBJK6+igkEwITWfQQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696177991; a=rsa-sha256; cv=none; b=xWjJifABfUZJi5O9XcnFvQ93Urvi1vrury8HCQ6clm3GZ/j4TLRU4XegdXphnDEFP7maEj O45rqVyfkhdB8XImQLfErwNGYmhLdOR28EUSLLKBHZnlks9+NIYogz46SYRzT8fLPEv5Ke iGfSNbfDyFIyM8etvDNj6yQ1uQktUqVHW54EV5mC0NODLz10lhtM9mhGqct4oKfBt8vUsT APbs0PsOi9UJbLTCWhU/cany9JWNpk2Yj4GVNEqgaT/HRato+yCxR9wAUby2yEwlxgEFhF /h9sg+gMJ1o+4nclNkemTachPFUICQBLrfCggCu4W3tgvnNKeUMSxJ6SoIZdPA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696177991; 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=oVoyy+9NOVuV1ro0IGc7AI55uL8P08OY/EdaF4yK/ak=; b=HjLPkKdX4w3F/TQgZUTlzmUSMCsn30jwudZFGmWcYGYaABrWhfe2dVNXZGjEvb4MDFHCRH hjzrkqiJGfRY0+FjuMUXFrDTBZk2UUzf6aIyvRu6nGrdlnMwEcck/LycJ9U+XvID5jmhdP RwoEwaowW+SRXkf5BuQV0pynNRJ9ETfDspL9NmL3Rn5wAshkc9ultOlTZbdyTaWHEv5K/e PoS6tyLWi9ADLOyVYMsmIClhluKsZX7yzTMgAwJpoKCiITw/NUWuvuv8vTolF7AR9gFaNq nHDv2xFLITCuoJdNi0qVboPkVQkUqrGJid4HjXx+n925C6MQt6N02fOgHMEAPg== 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 4Rz8lW5BdJzcvn; Sun, 1 Oct 2023 16:33:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 391GXBV7005681; Sun, 1 Oct 2023 16:33:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 391GXBtg005678; Sun, 1 Oct 2023 16:33:11 GMT (envelope-from git) Date: Sun, 1 Oct 2023 16:33:11 GMT Message-Id: <202310011633.391GXBtg005678@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: 774cc6348a50 - stable/13 - freebsd-update: handle file -> directory on upgrade List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: 774cc6348a50c13b952e9f36ef8395f9b48733db Auto-Submitted: auto-generated The branch stable/13 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=774cc6348a50c13b952e9f36ef8395f9b48733db commit 774cc6348a50c13b952e9f36ef8395f9b48733db Author: Ed Maste AuthorDate: 2023-09-27 13:36:33 +0000 Commit: Ed Maste CommitDate: 2023-10-01 16:33:03 +0000 freebsd-update: handle file -> directory on upgrade Upgrading from FreeBSD 13.2 to 14.0 failed with install: ///usr/include/c++/v1/__string exists but is not a directory because __string changed from a file to a directory with an LLVM upgrade. Now, remove the existing file when the type conflicts. Note that this is only an interim fix to facilitate upgrades from 13.2 for 14.0 BETA testing. This change does not handle the directory -> file case and further work is needed. PR: 273661 Reviewed by: dim, gordon Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D41893 (cherry picked from commit f6d37c9ca13f8ab0ef32cf5344daecb8122d1e85) --- usr.sbin/freebsd-update/freebsd-update.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/usr.sbin/freebsd-update/freebsd-update.sh b/usr.sbin/freebsd-update/freebsd-update.sh index 9cdff05c24e4..b9b277cca1c8 100644 --- a/usr.sbin/freebsd-update/freebsd-update.sh +++ b/usr.sbin/freebsd-update/freebsd-update.sh @@ -2903,7 +2903,13 @@ install_from_index () { while read FPATH TYPE OWNER GROUP PERM FLAGS HASH LINK; do case ${TYPE} in d) - # Create a directory + # Create a directory. A file may change to a directory + # on upgrade (PR273661). If that happens, remove the + # file first. + if [ -e "${BASEDIR}/${FPATH}" ] && \ + ! [ -d "${BASEDIR}/${FPATH}" ]; then + rm -f -- "${BASEDIR}/${FPATH}" + fi install -d -o ${OWNER} -g ${GROUP} \ -m ${PERM} ${BASEDIR}/${FPATH} ;; From nobody Sun Oct 1 16:34:08 2023 X-Original-To: dev-commits-src-branches@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 4Rz8mc2DKzz4vX2K; Sun, 1 Oct 2023 16:34:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Rz8mc1jvHz3RJk; Sun, 1 Oct 2023 16:34:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696178048; 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=HQ28zKlhBJhFiBAzN0GVRdVXY/CND/wUEHCVsB3AVa0=; b=S7Olr1aex417ncn+69FJoubtNWU1Cvl5T8LVpUTiJShabSjS7/VDlD5XZMrajWmHWYkq4m hJjueTOBaWkZP9vpuidTkeJ9IBLg7zthdg6a25t56IpQrpMeSeNvF26ByJ79k7z1fUUIIv yBtKyV+SJtdcLqVjpAFtLbfmwDYsVbI9o+/5P9v1DOHPN4x07RKdeDUfQSYUbuM3jsBpxE D0QYmuzoFH1gIXhkP/hxAOmxV/q2a97ZeokAbZAnXtctrScyjC7ZZPEZV1IqbIfTV51hjE ec6rW6nNYkha5hEJKAT1XNHVsUrupi00ibK8ZZVkszCzNMuuKLZmnhWCMI2qBw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696178048; a=rsa-sha256; cv=none; b=DwPJaUG8JpQX19SqI+3+2N7liwUHFLxXkPLNZqrK3p7F6/IP2Yq26gTx5DKPtHs+l9k2ut uZN/xCSF9ClELtdYtS4Bu8tsT/9ID7rJjCpRLnULoclviv20vTY0kMXV7S7a54UZ070dAU wKxxxiayBgnNbti/6UxJEB/PGFiKVkSEIQL0OGGNElF+FloccPpC8lSQIHcz64g+rQUIdV jxS9wDMIMYzY/UWKhjGGJ1pUzuVt1W5Jxo+mFCpSDa681uTy/qzpbxrKi+Yqm6/A5kvQak gAr5j8mxiAR9bd2PJM2eQt/QVIcx0j18d6fDkzyFpi6dOXcofAxSNZN7ojercg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696178048; 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=HQ28zKlhBJhFiBAzN0GVRdVXY/CND/wUEHCVsB3AVa0=; b=ff7gK+UZuSDWqQk72VQVYgly3dFmPIca0s16j0FarQwTJXL40VryqtqFIaREf4zAF355m6 1nac6zYeEkLFMc4anvetVLXIzBlyd0a4Yy7AnUtkNdfCBJbBXVqZLskO/E6ujoWV5kYAZ/ 5ZDBWzMsYmpoJb+kfuuhbvJGKvkxegIQ6q85gMMxunPTUUFer8TPcJzTSTosxFaWY8ELLc PdVTXi4i+aOrLHrDRsjmT3eplBJVWmSxRQPknmuPiM5CUbbCFXR+3/saqJxKdV6t+bXW0R zqLSWrCGSC7sXVyKRdsC6rW64NZo2WHzYbH45XK9u0oL7lujghKvcyy9jjFxAg== 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 4Rz8mc0mZhzcmC; Sun, 1 Oct 2023 16:34:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 391GY8Pd005939; Sun, 1 Oct 2023 16:34:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 391GY8qh005936; Sun, 1 Oct 2023 16:34:08 GMT (envelope-from git) Date: Sun, 1 Oct 2023 16:34:08 GMT Message-Id: <202310011634.391GY8qh005936@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: 274281864fc0 - stable/12 - freebsd-update: handle file -> directory on upgrade List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/12 X-Git-Reftype: branch X-Git-Commit: 274281864fc03c62443677751bf3036fbbf9d778 Auto-Submitted: auto-generated The branch stable/12 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=274281864fc03c62443677751bf3036fbbf9d778 commit 274281864fc03c62443677751bf3036fbbf9d778 Author: Ed Maste AuthorDate: 2023-09-27 13:36:33 +0000 Commit: Ed Maste CommitDate: 2023-10-01 16:33:56 +0000 freebsd-update: handle file -> directory on upgrade Upgrading from FreeBSD 13.2 to 14.0 failed with install: ///usr/include/c++/v1/__string exists but is not a directory because __string changed from a file to a directory with an LLVM upgrade. Now, remove the existing file when the type conflicts. Note that this is only an interim fix to facilitate upgrades from 13.2 for 14.0 BETA testing. This change does not handle the directory -> file case and further work is needed. PR: 273661 Reviewed by: dim, gordon Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D41893 (cherry picked from commit f6d37c9ca13f8ab0ef32cf5344daecb8122d1e85) --- usr.sbin/freebsd-update/freebsd-update.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/usr.sbin/freebsd-update/freebsd-update.sh b/usr.sbin/freebsd-update/freebsd-update.sh index 0641aa41921c..a01e81d7be49 100644 --- a/usr.sbin/freebsd-update/freebsd-update.sh +++ b/usr.sbin/freebsd-update/freebsd-update.sh @@ -2905,7 +2905,13 @@ install_from_index () { while read FPATH TYPE OWNER GROUP PERM FLAGS HASH LINK; do case ${TYPE} in d) - # Create a directory + # Create a directory. A file may change to a directory + # on upgrade (PR273661). If that happens, remove the + # file first. + if [ -e "${BASEDIR}/${FPATH}" ] && \ + ! [ -d "${BASEDIR}/${FPATH}" ]; then + rm -f -- "${BASEDIR}/${FPATH}" + fi install -d -o ${OWNER} -g ${GROUP} \ -m ${PERM} ${BASEDIR}/${FPATH} ;; From nobody Sun Oct 1 17:30:16 2023 X-Original-To: dev-commits-src-branches@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 4RzB1P1JB6z4vZqh; Sun, 1 Oct 2023 17:30: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzB1P0Q7Dz3YR5; Sun, 1 Oct 2023 17:30:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696181417; 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=JTxHh98fHcDjo/DetIg9fBqmFIi22j9crEXjZlfigYA=; b=J0EQsjUYlXfCroUO52acfg4JMB/E6K97dbXCH/z02rDgyprhAXIC7MLjOlj7xy+Um1FsEP ZnssPWldx5LGllz9VVi0W1poxEczghi1+Yqu64AqD/MalTfPN4YDo0zP323XzESWuQBQZc KDWd5+haph4HtLwZ57eIAZsUC573cnyhWAYxK2lnbIDfyICJbijqymCFy4+hh3Ocm1ckB4 +pwGQU+tDwWxw5VJ2uq+dWfXijaOfHuHAY5czCJA7/UDJKvrxaj+0n46bcP0FfGhxYKWX8 YOolm53PI/XTzN9J1fvHS4nuxt/K7zVllmsIT0dByPPyxKpt/fP9jXr5SMA9og== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696181417; a=rsa-sha256; cv=none; b=NeZPxZwH1IF7rwDxkRN944f8uw22LA0stcVOj10Tu+rUVjVTkcX/+Sjly9p8riYyYuxZaM fv7yiJ45NKBfGpSRvO4FVb7PoUt+d58ScsGRLih6PB1UVsHNrgSlXTnGtxcwo5Q0bIqs+1 CvznYuvHEf8fpJCbIV/ktSkiHi2FzTFps7oRuhyDu8lAOc0TMTM6MFDl81+7CRmB0xPARs cdWk/foLExSVgSPJaSw+dBpy4HeMUQYrui4OkMzquq/6pdrt0Dzwd/BJMXOJaZVL4/56ss 1FCXvg1gLRaySD67KRHDB1ThuKoCvzM5TsMtmpDeXsPvnpEYusBzBs1wACXqRQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696181417; 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=JTxHh98fHcDjo/DetIg9fBqmFIi22j9crEXjZlfigYA=; b=knBnFzVKnNShJDIRnsyqmZ4dFiLnYIRHhNzfP5sfiAYYcWhxaun0rRTTlQrQJKeu68NxM0 MSCj5uROgRAZ9w1IsovVQiwkn74nVHL4xiJZdtM+rrg14XG5qDYUiXIjAHGiqqXJEUWbqv YnF+wHQsC3EZZOHlWq3C5JLBngsk7x3wzWL0eCPmhdQurDax0HSUFD2/1BdECAW+NG5oSQ 64Gog1l1WjMU6Wuzr5rHaadF/W/U7cWDkSuzF16V1roas2RTbRkC7BpXVnMFu3/XdCNa3i 5S8vA2L2ZNKSoV8tnAO+InKitpY1FHcUzcoYdxF//ZpQfxwCWD9KnPhrQwhm5g== 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 4RzB1N6cYFzf5W; Sun, 1 Oct 2023 17:30:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 391HUGRp097917; Sun, 1 Oct 2023 17:30:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 391HUG5I097907; Sun, 1 Oct 2023 17:30:16 GMT (envelope-from git) Date: Sun, 1 Oct 2023 17:30:16 GMT Message-Id: <202310011730.391HUG5I097907@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: a39ddf881ad8 - stable/14 - freebsd-update: Allow for upper/lowercase y/n List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: a39ddf881ad8530013c5e4cc5f84b3a6b58cca51 Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=a39ddf881ad8530013c5e4cc5f84b3a6b58cca51 commit a39ddf881ad8530013c5e4cc5f84b3a6b58cca51 Author: Juraj Lutter AuthorDate: 2023-09-17 16:15:27 +0000 Commit: Ed Maste CommitDate: 2023-10-01 17:30:06 +0000 freebsd-update: Allow for upper/lowercase y/n Allow for upper/lowercase y/n in "Does this look right?" question. Reviewed by: emaste Approved by: emaste Differential revision: https://reviews.freebsd.org/D40434 (cherry picked from commit 39f4633b3d2354c01a290d5f422dce7874061769) --- usr.sbin/freebsd-update/freebsd-update.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.sbin/freebsd-update/freebsd-update.sh b/usr.sbin/freebsd-update/freebsd-update.sh index b9b277cca1c8..c6432dcd6b0e 100644 --- a/usr.sbin/freebsd-update/freebsd-update.sh +++ b/usr.sbin/freebsd-update/freebsd-update.sh @@ -1202,10 +1202,10 @@ fetch_progress () { continuep () { while read -p "Does this look reasonable (y/n)? " CONTINUE; do case "${CONTINUE}" in - y*) + [yY]*) return 0 ;; - n*) + [nN]*) return 1 ;; esac From nobody Sun Oct 1 17:30:53 2023 X-Original-To: dev-commits-src-branches@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 4RzB254Xxyz4vZwB; Sun, 1 Oct 2023 17:30: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzB253l7Gz3Yks; Sun, 1 Oct 2023 17:30:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696181453; 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=+xoEueE1HvHWBRLtJy72qM/H1rkWzwsAHM0kvWii0LU=; b=ZhPLGPKit7hK+2C4kfwbf/9W73FvGO522CFvTo2H29oaDRXNxwkhIrP14XVpJsacA2f9i+ SjulsYLcAM+iF4IAbXqQPOc4GyYUqJtwuz4CNbPIZGUSTAVak9N0SiW46Ai2RmJ3rGOi8w M+tjTAsY2nkNNd3AD/KTYyL24Ds1GBuq0kRovdQvjTfZ9gneORBaDe/2nHDbUvacSF2PoF sIqHicpY39kGV9PVgV892fySQXQH2Q/KW4cRYqXxRjA/ZWkV+Hr1m6ZExm7af42wpV9gRv 5Eq7nOfhBbzmP6bNfMnjsHnfF52M1yZ3z/lkH07R+aRjZIGCvfvyXcaLz8bdBQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696181453; a=rsa-sha256; cv=none; b=D5MZxxmBe5Vbl1NLWqgD1nNw9/o3kvrCQYvM/iVMY2thvQEYaJD6bGkt/FzZYSGH3k9V18 DvEt6lPJJAf9j1bYza8B+Qy0pHVtG2uEeS0z4ov4RFNJTlHJgmsOrE6DTBVjuVP7CeXH+0 vdB+/yA9E+0cQMnmF1kW8pSyuiYa2hF4FCi8hUHtWErCwrzSytY/emgzxFwOd/NwBcvVst KRikmSKV/vdZ8Pl9GLL1fhURUBBEVKhf0I2L6Nv6JSywc603Sw7gJs8QLy1bqk/G5HrnwY LeXEdpoSkhNrlfOSCCaGXgK1UIUHRcWLeg9IPC8jWaXRU+xmSf6O22TkXRjmow== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696181453; 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=+xoEueE1HvHWBRLtJy72qM/H1rkWzwsAHM0kvWii0LU=; b=K0+sD0yRRXGd/0LkJjIATIlbqhjHfZpk50VBx8CuYVkHMhicoB+YdvuEbXDPoFaYPTdk+K 9Oz3/Kv5BkGMfQLRg+FQK8Oy9M/fpzUte1UWzYHrWVB6e0wRJ3uwQZyHIYBv/NICjVLvLL ifbL3oJti3sIB0fXLI2m4BL43qKY0nBM1zshWNRBBD1lIrQEWj0YVsmhMTvi6UMg1VwqK3 RR5wT8LbOzjuHHz++5nqKf+6KWY34T4ZNIA+YWJoHfQBFKSJxQbFlysziKzy+8JU7QviI3 2j+mYhmBxk/Z0rMt6JwGBHulBCxyklnsUkg9dK0nI6z3ceLSuUZLNo0O53tetQ== 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 4RzB252mhkzdmW; Sun, 1 Oct 2023 17:30:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 391HUrul000573; Sun, 1 Oct 2023 17:30:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 391HUrNo000570; Sun, 1 Oct 2023 17:30:53 GMT (envelope-from git) Date: Sun, 1 Oct 2023 17:30:53 GMT Message-Id: <202310011730.391HUrNo000570@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: ef295f69abbf - stable/13 - freebsd-update: Allow for upper/lowercase y/n List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: ef295f69abbffb3447771a30df6906ca56a5d0c0 Auto-Submitted: auto-generated The branch stable/13 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=ef295f69abbffb3447771a30df6906ca56a5d0c0 commit ef295f69abbffb3447771a30df6906ca56a5d0c0 Author: Juraj Lutter AuthorDate: 2023-09-17 16:15:27 +0000 Commit: Ed Maste CommitDate: 2023-10-01 17:30:35 +0000 freebsd-update: Allow for upper/lowercase y/n Allow for upper/lowercase y/n in "Does this look right?" question. Reviewed by: emaste Approved by: emaste Differential revision: https://reviews.freebsd.org/D40434 (cherry picked from commit 39f4633b3d2354c01a290d5f422dce7874061769) --- usr.sbin/freebsd-update/freebsd-update.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.sbin/freebsd-update/freebsd-update.sh b/usr.sbin/freebsd-update/freebsd-update.sh index b9b277cca1c8..c6432dcd6b0e 100644 --- a/usr.sbin/freebsd-update/freebsd-update.sh +++ b/usr.sbin/freebsd-update/freebsd-update.sh @@ -1202,10 +1202,10 @@ fetch_progress () { continuep () { while read -p "Does this look reasonable (y/n)? " CONTINUE; do case "${CONTINUE}" in - y*) + [yY]*) return 0 ;; - n*) + [nN]*) return 1 ;; esac From nobody Sun Oct 1 17:31:14 2023 X-Original-To: dev-commits-src-branches@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 4RzB2V3xMHz4vb2g; Sun, 1 Oct 2023 17:31:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzB2V3Vf9z3ZDM; Sun, 1 Oct 2023 17:31:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696181474; 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=DCYA5XsK93v43A5dz5Tz5ow1zWk7lyl6Ge0DMR2XAUs=; b=sShMxvAgYnaCRMprX9KxZHLEOJmGnnp/Vi16bHba7DHgVaODT7X0AQilYP3GicJSXaGJNd ce/N3o5bkumfGhh27z5GmZ0rmM1dKKfxweBgtwXfEi3ZRxL5KapsPUE/DXhKHVQk/LziOR xj+TipiOdePxcX2lDzRSbMzQU7+tM6J5bc5y3ag6TvQrVVVo2wjITrgvL9RHRgjHwtfH0h klSh/KDtxTRczrOoPA6XMaTgZd2og3HU2JKp/SC2E4+c9hh6zL2TGF18/UUIBRh/VkewrK dlyMChhMQ56XCHZo6t4rEy56bba0adeqvm4prKjlSwfmICmquhGa8/ktlx50qA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696181474; a=rsa-sha256; cv=none; b=Zc+hIZQsve7u15DfBgt181Wd3YXGagbUxFRbGj3lzXJPO+fho1GE8BphOpynYI1ue3ExTm luISUK9Y8wS3x/QSOYN3n5uFKcRvqIi0up31haUL8PH+zD0EJyoCWyoTypw/Qv++Zp0/GM O6zZw9XYuL2DgY0cUx0gkCdWOm2Iunx/eUCWmz8pJRGJ6Gbjl1ORNz/0kYWy3TCF0CitR8 2BtOBROoGdAwgNsn89Wair9hkb0+MIZowxC6ae6KZBh0/jxJAGyWpxUeiv60IL+dMPIbgK WBPg0X2jYyk2QUapSVcJBR+NQ2vk5MAQcKVro1HaziKXIv3frMTbXxHTxfklKA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696181474; 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=DCYA5XsK93v43A5dz5Tz5ow1zWk7lyl6Ge0DMR2XAUs=; b=t6TrZtK0n7CAqGummjTnsbuWkleix485ubSYlfGyIDmUANra9f1rVvJk4l0820sp1Edntw 1llMA649teD+Y9MALtTLBwfQFPmjBxrJqRosWvi5dnOCazunwsjd61NT3LVd6j4p+fg0Uc 2XOQd3Y6b0UK57EFpDvuN/Bu3tFBEMEfm+xTnoKket9HMyHVi3D6a1LELyVcDVG+/TzJn9 SVV0HmmhtAJ7sIZwip/lYWAxBcQGMAMSoXiTRMK0s2gQpP0zz+tXlBHBeZmCJU8c0DfO0K YCsufF8plgZ77dxRU4tI8i/nvH02FtUhByAgsSUFTK4t14QmahzGuUAlpdaXXQ== 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 4RzB2V2bCGzdFJ; Sun, 1 Oct 2023 17:31:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 391HVE6L000746; Sun, 1 Oct 2023 17:31:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 391HVEer000743; Sun, 1 Oct 2023 17:31:14 GMT (envelope-from git) Date: Sun, 1 Oct 2023 17:31:14 GMT Message-Id: <202310011731.391HVEer000743@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: 05f988e987f4 - stable/12 - freebsd-update: Allow for upper/lowercase y/n List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/12 X-Git-Reftype: branch X-Git-Commit: 05f988e987f42a182fdda64e83bd1cb7aba59109 Auto-Submitted: auto-generated The branch stable/12 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=05f988e987f42a182fdda64e83bd1cb7aba59109 commit 05f988e987f42a182fdda64e83bd1cb7aba59109 Author: Juraj Lutter AuthorDate: 2023-09-17 16:15:27 +0000 Commit: Ed Maste CommitDate: 2023-10-01 17:30:58 +0000 freebsd-update: Allow for upper/lowercase y/n Allow for upper/lowercase y/n in "Does this look right?" question. Reviewed by: emaste Approved by: emaste Differential revision: https://reviews.freebsd.org/D40434 (cherry picked from commit 39f4633b3d2354c01a290d5f422dce7874061769) --- usr.sbin/freebsd-update/freebsd-update.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.sbin/freebsd-update/freebsd-update.sh b/usr.sbin/freebsd-update/freebsd-update.sh index a01e81d7be49..5a523775dbbb 100644 --- a/usr.sbin/freebsd-update/freebsd-update.sh +++ b/usr.sbin/freebsd-update/freebsd-update.sh @@ -1204,10 +1204,10 @@ fetch_progress () { continuep () { while read -p "Does this look reasonable (y/n)? " CONTINUE; do case "${CONTINUE}" in - y*) + [yY]*) return 0 ;; - n*) + [nN]*) return 1 ;; esac From nobody Mon Oct 2 00:50:42 2023 X-Original-To: dev-commits-src-branches@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 4RzMnb1qYbz4w33y; Mon, 2 Oct 2023 00:50: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzMnb174gz4qVw; Mon, 2 Oct 2023 00:50:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696207843; 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=0FUAl6sYLLdTq2RxJHNYBSQbdBHKMC8gAlafLQ9gt1U=; b=GWpA8CnDg9XxARjUnGglXtEHUHQYfWcTK/Ww53OSMP9BZX/GSSOFfHW+0n3H+oxdtFTBkb xmNsOtNEpqN33ortWcHBW9gNgAS6BqjrFMC06Qz1ftbScdeOT02MidR7OjdxaWFfGCm4of An2ZHqlcZS8+yiwS0Uc7EU7hGEcdpjzSPenAHenwuHlmkuH+C4dTNfmkXpruHlOjUpW2ga uiqKi4p/xxOvVZQq3C/B4C3BjyjhW9XDHVZ3o9AuIC848POu8DXEGzmWnhX8CobsmBp4LT y7yIx+2nL/P+wB35S8u/0BP7RC+TRnvepvRy7GAgptF7z9UmUX6Di2jZUtV45g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696207843; a=rsa-sha256; cv=none; b=hUzqzbiV9MTSN/c3Q6PeTmpNPRTwPfn6e7VNJn7msPteHKGC8AFcDsqgvXEPQPawFIgvTL 0E6D9n/uVgGBCR0zmwsZxTqCqZfXm+3zYF7Vy3klCfS8t3l6hFaYN+j5lmIAW/x5ktT/ve 1mFk6oKISK8hKltw8WSsE9Atw69kHyumvwTYk7pimbjAt39JG2B1U74AnO7V+ioxTOfz5L fGwIqP69ibtMqBJa5CVI0+de2MrxXEmHNHpoufUetxezzQQrA3DVxOXbFhLo4Mn9Dg8PM8 eFZ4rRSSgOB6RzmzxF5miJL6yGkBmE6Ea65NWHP771EX/78lEVGiSrVW5eaJ4A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696207843; 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=0FUAl6sYLLdTq2RxJHNYBSQbdBHKMC8gAlafLQ9gt1U=; b=L32jGZ1bmjyjic3tDQEjz1dtlHRRtkzLUF9xfo1I8Ygv1iY01cfv1Y2ZniQ5r/Dj9L9r2I NSEUrBpzv41Q0acTQ5c9CDlKVt+dAVmnrk1xBVmacUeVJpoiYaXjy+NcMpCb93CNqhSWSz 2CJI/HqQk0NTbd4bhM4xiviHzrmGMvUDQwf/EIoelJhi423FXlJKghFqueCIYkidno0jk1 eLBoITHznUp6C1IXIFrUtWmJSHGmxnbBrUUcm9863VGZtMMR3w2wh/JCmOEBNs0QFapZWy maed0fZDH6HgvmudWfDLR39ncEUpGccIgBfRsqPeRKQnoGBLk2YeEDosDFa29g== 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 4RzMnb09pxzrsm; Mon, 2 Oct 2023 00:50:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3920ogdj028326; Mon, 2 Oct 2023 00:50:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3920ogxR028323; Mon, 2 Oct 2023 00:50:42 GMT (envelope-from git) Date: Mon, 2 Oct 2023 00:50:42 GMT Message-Id: <202310020050.3920ogxR028323@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: bffb01eda9bf - stable/14 - rtsock: Add sysctl flag CTLFLAG_TUN to loader tunable List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: bffb01eda9bffc3307ea8bf70f91087ed316e01c Auto-Submitted: auto-generated The branch stable/14 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=bffb01eda9bffc3307ea8bf70f91087ed316e01c commit bffb01eda9bffc3307ea8bf70f91087ed316e01c Author: Zhenlei Huang AuthorDate: 2023-09-25 10:10:46 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 00:49:37 +0000 rtsock: Add sysctl flag CTLFLAG_TUN to loader tunable The sysctl variable `net.route.netisr_maxqlen` is actually a loader tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` will report it correctly. No functional change intended. Reviewed by: glebius MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41928 (cherry picked from commit 21a722d9593eb477f4ccdad011a2b4df0727fc62) --- sys/net/rtsock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/net/rtsock.c b/sys/net/rtsock.c index 1a83fc2d8abe..019b9e80291c 100644 --- a/sys/net/rtsock.c +++ b/sys/net/rtsock.c @@ -241,7 +241,7 @@ sysctl_route_netisr_maxqlen(SYSCTL_HANDLER_ARGS) return (netisr_setqlimit(&rtsock_nh, qlimit)); } SYSCTL_PROC(_net_route, OID_AUTO, netisr_maxqlen, - CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_MPSAFE, + CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_MPSAFE, 0, 0, sysctl_route_netisr_maxqlen, "I", "maximum routing socket dispatch queue length"); From nobody Mon Oct 2 00:50:44 2023 X-Original-To: dev-commits-src-branches@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 4RzMnc3h3pz4w326; Mon, 2 Oct 2023 00:50: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzMnc22CXz4qms; Mon, 2 Oct 2023 00:50:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696207844; 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=xAlqrjYV9GHdpoVBEQDT65zKI6SUw6E7b7SPkygDgBQ=; b=TXU2mFidcCyVlbLm18P3duBOPKovxZZ9WpQ4ZQePLyTKQQrHS270Yg8cQ919A6n1OsDBZ2 cgFms2RQZOB0e1j1UexfNyYDDfF+JD7O1FdM4NvrgmSydCWPKrZ1JshEWFrrBSfZf18o+M NdnoeXOva/pRj+iYxVJCxvs+CRMpddUHcGY5n0mRsrocAN2UNRgNhRRNNWhknguh5roUt+ MwG9Fb8H8NOh1v/VK7XxfSN52xfGT+M1epyZZ+XDADhkczK08arQ9H96o6x8urKmvZXF1X 2DjQHzWgIsQSItAw1FZqdvJEey3QSeKaRrRD4OlI66Nj+Ien3CjJrZ+A4uy0jQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696207844; a=rsa-sha256; cv=none; b=GlVVWEVz3WuJP1JnqG9p38IZ476KdyVPvME3GZZesFK7UxGXKIvnAsAwQx3tEVCuetSzjz 2Q1JOH3T93SbNT3A3KzM2HB7mBxhrI71yzaAI7wjQ4f1K+4wUPh1nAEm1CACyG8+Weo2lp TqZMjpYDhCz6JcrFMir04lsOkEnqzlyEHT8Daxael29cK8B4xoa/wV9n/RDttaMi/ex74f rImaDatS/UTG4S392kLqFmLA66cZn6KmxroCOCdWO1ftPJxbXhk8zs1vQ0Twgd0zhPTjY6 LiX3+iKrEEUQ2e1e405OjqsDbm8a/xW6TnYneI7FJJFK9PTEgceAKrKNRVecjA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696207844; 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=xAlqrjYV9GHdpoVBEQDT65zKI6SUw6E7b7SPkygDgBQ=; b=W0sV94TpidyFDw6jGEa5t0+RHk4czBYTqfu/p6eyeqxDH7hKJErc5tLdZFy8YQA8Rc2Kdh yUhnYXA+UbqTM5GvzcNHuIRo5jXMfjdAToqrcvGxO1zgNxVxf9PRJGUT4yfKrtJ9Ry0Iqg GRlNf5QAEG66IQj0Hkq363ND7Lg2yrJaLlyF0b6O4rkZ1FllpKh1AHTCEHOckrr/I1whVU OHnIcwAvq25pmVY3mxSyF6m1vYfNwaJulmQHvLjij4tTdp+26P7WBswAhRck9z/fV10jUk X6IenX31iUNgpQLJsttiaSRzjrzQQQ6qOMIjLzavon5fgQ2ArhDbNBCpDZN5/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 4RzMnc0p4bzrj6; Mon, 2 Oct 2023 00:50:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3920oiuc028380; Mon, 2 Oct 2023 00:50:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3920oiaN028377; Mon, 2 Oct 2023 00:50:44 GMT (envelope-from git) Date: Mon, 2 Oct 2023 00:50:44 GMT Message-Id: <202310020050.3920oiaN028377@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: da2b630c12ec - stable/14 - netinet6: Add sysctl flag CTLFLAG_TUN to loader tunables List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: da2b630c12ec074673dfc646b2055a31b0d8d6d9 Auto-Submitted: auto-generated The branch stable/14 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=da2b630c12ec074673dfc646b2055a31b0d8d6d9 commit da2b630c12ec074673dfc646b2055a31b0d8d6d9 Author: Zhenlei Huang AuthorDate: 2023-09-25 10:10:47 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 00:49:37 +0000 netinet6: Add sysctl flag CTLFLAG_TUN to loader tunables The following sysctl variables are actually loader tunables. Add sysctl flag CTLFLAG_TUN to them so that `sysctl -T` will report them correctly. 1. net.inet6.ip6.auto_linklocal 2. net.inet6.ip6.accept_rtadv 3. net.inet6.ip6.no_radr No functional change intended. Reviewed by: glebius MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41928 (cherry picked from commit 03dac3e37993801dab4418087bfedacce0526e66) --- sys/netinet6/in6_proto.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/netinet6/in6_proto.c b/sys/netinet6/in6_proto.c index 1d67577f8055..6e7ffedc3dcd 100644 --- a/sys/netinet6/in6_proto.c +++ b/sys/netinet6/in6_proto.c @@ -278,10 +278,10 @@ SYSCTL_VNET_PCPUSTAT(_net_inet6_ip6, IPV6CTL_STATS, stats, struct ip6stat, ip6stat, "IP6 statistics (struct ip6stat, netinet6/ip6_var.h)"); SYSCTL_INT(_net_inet6_ip6, IPV6CTL_ACCEPT_RTADV, accept_rtadv, - CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_accept_rtadv), 0, + CTLFLAG_VNET | CTLFLAG_RWTUN, &VNET_NAME(ip6_accept_rtadv), 0, "Default value of per-interface flag for accepting ICMPv6 RA messages"); SYSCTL_INT(_net_inet6_ip6, IPV6CTL_NO_RADR, no_radr, - CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_no_radr), 0, + CTLFLAG_VNET | CTLFLAG_RWTUN, &VNET_NAME(ip6_no_radr), 0, "Default value of per-interface flag to control whether routers " "sending ICMPv6 RA messages on that interface are added into the " "default router list"); @@ -334,7 +334,7 @@ SYSCTL_INT(_net_inet6_ip6, IPV6CTL_V6ONLY, v6only, CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_v6only), 0, "Restrict AF_INET6 sockets to IPv6 addresses only"); SYSCTL_INT(_net_inet6_ip6, IPV6CTL_AUTO_LINKLOCAL, auto_linklocal, - CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_auto_linklocal), 0, + CTLFLAG_VNET | CTLFLAG_RWTUN, &VNET_NAME(ip6_auto_linklocal), 0, "Default value of per-interface flag for automatically adding an IPv6 " "link-local address to interfaces when attached"); SYSCTL_VNET_PCPUSTAT(_net_inet6_ip6, IPV6CTL_RIP6STATS, rip6stats, From nobody Mon Oct 2 00:50:45 2023 X-Original-To: dev-commits-src-branches@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 4RzMnd3LBPz4w344; Mon, 2 Oct 2023 00:50:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzMnd2mFXz4qwC; Mon, 2 Oct 2023 00:50:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696207845; 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=EneUkHx6yWCLG1fahtJbSwh+GWa/sc3mD+zY0i/KoA8=; b=h8id0B5xaoGFhvK9IReX5CCWL9mZal7GXbx7Jc3B8a1+UruEB4IKkRDc+KBPfP0lqiBtH4 +446d3eQHjsNK0SvOt//z0Zrw7o9UZN5L/czKGMIYnTXV8UqnVuWtocs/YPh3RFe+PYow8 4jLLVGalhcCDOv2B+3iJgRhi2NS8ZTfqznDpucXqpm3tLtDeioJTTiRDNcm+NueFG9G3ON 49Ckg/ABwa1u+ueOJkYx+AS0BCXcKJxvy9FNt2HKWcywu+IcR9MGeWkYlZVLET2XIJpvSJ RUfaofeFcyKIxj9znGMi1NDhJArFX/oFCwSTlOIwkY01lxE06UsIwJIiDAoItQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696207845; a=rsa-sha256; cv=none; b=XT+U8LS+srQUNb24mBeN25exmqx6c7u9Kp6tiU/LMbFa3duTk69d5CUF449CxCf3AtpIV3 3FW00M897NTPObmz9RwxHNk6ifXCFC1pxVLGbBhIBQCUiZToyrW+hiNeBi/mlPYkqM0q8X os70QwH7UWnx1zutt7dR7FYvC9xQPsc6Z1GFHaKay56dYvCtMT3lVpulNH2F4S41FqSldG UcpqRAwyomXsI1NGWGcndDQoutDvkZZcfDoPaZ17cjsWMBqH09B72ZthGrbxLn8AxjKbey IGrfi0w6G7cTJ6sqk+8wOuQWoKPDXLxlIwGjh4ATXJ2Mq3bOEbY4ch4rJlIIFg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696207845; 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=EneUkHx6yWCLG1fahtJbSwh+GWa/sc3mD+zY0i/KoA8=; b=nJNvmUVhLff+DrtrP0TRNc6JKibN+nhV49SOgTOrjEJ6tZEYp29Vk8c8gc53r+x9Wwm3nn n263VRQhLSuyi4rf8SjP4+C6Gl5aOhtTRMGbc8c3mzB9p8Rl1Y05bbH9MRWRYKPhC3RYfJ wmep2BQVPylYcevFdL9sjsf2UbBVMKvQxPEDr8dN3b4K0Uvtx2CfUIDtOQz8rXnbsU3Ygj /ULPr/N6MsWxcaMT9askzwt3wPPs5bQTipwr9utyYoCj9yr0l5eKJi1zSCZHyJ7yDTsR9l XAMNmZTeMmSrlPk3/qknb3aSsSoTpqlKx6gXjXUfoTWbNM73Ar6AGImcMmKrRA== 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 4RzMnd1qyPzrj7; Mon, 2 Oct 2023 00:50:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3920ojn3028437; Mon, 2 Oct 2023 00:50:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3920ojI0028434; Mon, 2 Oct 2023 00:50:45 GMT (envelope-from git) Date: Mon, 2 Oct 2023 00:50:45 GMT Message-Id: <202310020050.3920ojI0028434@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: f5f6da90597c - stable/14 - ipfw: Add sysctl flag CTLFLAG_TUN to loader tunables List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: f5f6da90597cb65ce55c4f17718a200097f6f78f Auto-Submitted: auto-generated The branch stable/14 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=f5f6da90597cb65ce55c4f17718a200097f6f78f commit f5f6da90597cb65ce55c4f17718a200097f6f78f Author: Zhenlei Huang AuthorDate: 2023-09-25 10:10:47 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 00:49:37 +0000 ipfw: Add sysctl flag CTLFLAG_TUN to loader tunables The following sysctl variables are actually loader tunables. Add sysctl flag CTLFLAG_TUN to them so that `sysctl -T` will report them correctly. 1. net.inet.ip.fw.enable 2. net.inet6.ip6.fw.enable 3. net.link.ether.ipfw No functional change intended. Reviewed by: glebius MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41928 (cherry picked from commit 49197c391b3d49a33bcd08471bf64d533cd10f9d) --- sys/netpfil/ipfw/ip_fw_pfil.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/netpfil/ipfw/ip_fw_pfil.c b/sys/netpfil/ipfw/ip_fw_pfil.c index 1cfff1870d7f..4dae28aa0544 100644 --- a/sys/netpfil/ipfw/ip_fw_pfil.c +++ b/sys/netpfil/ipfw/ip_fw_pfil.c @@ -91,20 +91,20 @@ SYSBEGIN(f1) SYSCTL_DECL(_net_inet_ip_fw); SYSCTL_PROC(_net_inet_ip_fw, OID_AUTO, enable, - CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE3 | + CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_SECURE3 | CTLFLAG_NEEDGIANT, &VNET_NAME(fw_enable), 0, ipfw_chg_hook, "I", "Enable ipfw"); #ifdef INET6 SYSCTL_DECL(_net_inet6_ip6_fw); SYSCTL_PROC(_net_inet6_ip6_fw, OID_AUTO, enable, - CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE3 | + CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_SECURE3 | CTLFLAG_NEEDGIANT, &VNET_NAME(fw6_enable), 0, ipfw_chg_hook, "I", "Enable ipfw+6"); #endif /* INET6 */ SYSCTL_DECL(_net_link_ether); SYSCTL_PROC(_net_link_ether, OID_AUTO, ipfw, - CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE3 | + CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_SECURE3 | CTLFLAG_NEEDGIANT, &VNET_NAME(fwlink_enable), 0, ipfw_chg_hook, "I", "Pass ether pkts through firewall"); From nobody Mon Oct 2 00:50:46 2023 X-Original-To: dev-commits-src-branches@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 4RzMnf4FmWz4w2mY; Mon, 2 Oct 2023 00:50: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzMnf3cgqz4r2g; Mon, 2 Oct 2023 00:50:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696207846; 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=NfV5+sgWPIDv1TEugCl4VAFNFgwzUjNN4OHrbSac2vs=; b=weEmm9r9mX2gSV4LfBLUiPDU8ZiGZEsxNpB0ok71R00AaovMP8ye4kUDPccwpKye4S8Ydw HYWbMSL9TK3vVFzrwhjI3y2Lje0//43b5mSvHg68ZoOBd3GKpO8NBdcjcC3W1Ivx1nZEUv LKVbDUBLZKr05ygRXli9TeGpXEFsNG/qEMXtscHOouQKA5B4tTi2fDMQafDknq8tFngsss 6PBZUTRzP110+28PmVyMjCHZF0nyNLzskI1iPmPTx9EWbbRu1lRWxYFAdpXrTOZNKwpWAg ku6UBys//Y+xtX3VnDi3Fuby3ubKTjhLEAr7/eepuuSSDt8WKgrh4NBZR0ic8A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696207846; a=rsa-sha256; cv=none; b=AUs8kJYe6YjAjJG9WVSKLfO7eKNfrrtta2ZJcJh47jQyi0/hfAtjiZtq0NY80Sgl90BK47 fwfgF+HYLVZFolIxwMkNu6HMrAI3GqrFhD8HLtiYGTI3zI8YBgJp+TLTw9GRn1YQYdlKUz VRmrYzsc0wXvEAHpvzZRCFx70JqAXoIQPXkbs8jlhP7uyvdSIpPv3FZB1wnCIRdBdUxnPH cG/yxq4vCB72z67ev+pkOH971dintlZ+uBkVN04Ys4sUtjk2TUdHnU4i/EyH/sw+k50VwH uaqpI5pB4JmpC+0NA9bWwCQmiM4ACLAIOLcMkSk1W35pnr5pq0ye5gZQdJe/tw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696207846; 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=NfV5+sgWPIDv1TEugCl4VAFNFgwzUjNN4OHrbSac2vs=; b=ixYgj1ttwz6FUNpkc2ZaB6ADZPn4VHS2GOkzBGlLz0txytugj9Rwun9/BlWl0lONAUt1iS 5CyaY8mhya29mqBFWwbtpOC8GXDMwkW01+iP6IK1pO9H4ScouWZ+F+rBt+p38aTGeoNHft AyESZ68RBY2stVq5DlU42dtyz/F1/XnjRHaKtuYAmpMa1SJ6+X6swILs2NYGlSTMhVUMU9 bC35eylM8IwJCTvnjIscwbWIR2j2pRQO1/9s8vj6R70hqxv36+6nnZHFdg7UiYpxFAlelw xgS2Wr7fplveZb8gmGdrQvKNnMMHuRqMtrJd5Q18SAu1yrcoPwrsXJdX8oflzQ== 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 4RzMnf2jhyzrj9; Mon, 2 Oct 2023 00:50:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3920okxY029300; Mon, 2 Oct 2023 00:50:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3920okTA029297; Mon, 2 Oct 2023 00:50:46 GMT (envelope-from git) Date: Mon, 2 Oct 2023 00:50:46 GMT Message-Id: <202310020050.3920okTA029297@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: bb6f9a95402a - stable/14 - ipfw.8: Adjust section for loader tunables List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: bb6f9a95402a6c3ab8167481b81465f8ad5016fc Auto-Submitted: auto-generated The branch stable/14 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=bb6f9a95402a6c3ab8167481b81465f8ad5016fc commit bb6f9a95402a6c3ab8167481b81465f8ad5016fc Author: Zhenlei Huang AuthorDate: 2023-09-28 04:58:44 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 00:49:38 +0000 ipfw.8: Adjust section for loader tunables Move the descriptions of loader tunables from section 'SYSCTL VARIABLES' to section 'LOADER TUNABLES'. See also 49197c391b3d (ipfw: Add sysctl flag CTLFLAG_TUN to loader tunables). MFC after: 2 days Differential Revision: https://reviews.freebsd.org/D41981 (cherry picked from commit 12349f38898f231ca803dcf526bac88cb1b5cd2b) --- sbin/ipfw/ipfw.8 | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/sbin/ipfw/ipfw.8 b/sbin/ipfw/ipfw.8 index 1a042ae2bbbf..e62b8d6efc95 100644 --- a/sbin/ipfw/ipfw.8 +++ b/sbin/ipfw/ipfw.8 @@ -1,5 +1,5 @@ .\" -.Dd April 25, 2023 +.Dd September 28, 2023 .Dt IPFW 8 .Os .Sh NAME @@ -3761,6 +3761,16 @@ or .Xr kenv 1 before ipfw module gets loaded. .Bl -tag -width indent +.It Va net.inet.ip.fw.enable : No 1 +Enables the firewall. +Setting this variable to 0 lets you run your machine without +firewall even if compiled in. +.It Va net.inet6.ip6.fw.enable : No 1 +provides the same functionality as above for the IPv6 case. +.It Va net.link.ether.ipfw : No 0 +Controls whether layer2 packets are passed to +.Nm . +Default is no. .It Va net.inet.ip.fw.default_to_accept : No 0 Defines ipfw last rule behavior. This value overrides @@ -4154,12 +4164,6 @@ Keep dynamic states on rule/set deletion. States are relinked to default rule (65535). This can be handly for ruleset reload. Turned off by default. -.It Va net.inet.ip.fw.enable : No 1 -Enables the firewall. -Setting this variable to 0 lets you run your machine without -firewall even if compiled in. -.It Va net.inet6.ip6.fw.enable : No 1 -provides the same functionality as above for the IPv6 case. .It Va net.inet.ip.fw.one_pass : No 1 When set, the packet exiting from the .Nm dummynet @@ -4176,10 +4180,6 @@ Enables verbose messages. Limits the number of messages produced by a verbose firewall. .It Va net.inet6.ip6.fw.deny_unknown_exthdrs : No 1 If enabled packets with unknown IPv6 Extension Headers will be denied. -.It Va net.link.ether.ipfw : No 0 -Controls whether layer2 packets are passed to -.Nm . -Default is no. .It Va net.link.bridge.ipfw : No 0 Controls whether bridged packets are passed to .Nm . From nobody Mon Oct 2 00:50:47 2023 X-Original-To: dev-commits-src-branches@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 4RzMng5Msjz4w2wB; Mon, 2 Oct 2023 00:50: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzMng4qJBz4r7J; Mon, 2 Oct 2023 00:50:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696207847; 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=76SIPGKLgEkL9TOLwbzKK18QPIodl+BSeDKYdEtDj7Q=; b=qg7HbjTxxUA5173vsLLRryMkiGd5xgEJD2/T937pq8ek9naB2SerzLYrWfNds12EOqgW+m I09cp1c5WwFt+mtbQ9PM8fHNT/s9TJjO9sZTuxwh6ro2BI5FXaKfolQJ7asAjLd+HA8hUk SO5BOLlX3jAdqKM1TV4WOPJtpded4oXJgKAJ6t6LqJwPBwKPswqZiN0W30zRPRrgTGjbRx 9QnbXjzlW4D5o04GgaL63aT2vc06/oGdPkaN5SYtEITZvtjS7XjbvCKjARIxmWXdAUbKu/ pdnZQNApnRG6QJPyLguGNUBvSn5kDyPI35F4lx4B+7b4xKWApFQy4GoZoxlLPg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696207847; a=rsa-sha256; cv=none; b=rWaoVbz3AGZAf+wZswa9zREnAUO4uVgGqvXPaUNN4VzwdvkEhHwKkzFjpl/YCPT2Cix68n W04eCBbbrQgeIdR9Zmfv7ncTZzp5Z2JJ+zZrJb6jhzxDbsBqrEjeLNuIFOInaz9XZgoxlK 0VMRabDPKfFPFuALYtrq/MuoD5pkcVZ7sVFIva00fAvbshUauBqAgf9PcZ/aYwLy2KW9N1 rzBPKfkUV5/voN/7RoFPcbFEB2PjI+6mUm65wQIV2LRuwDk7KDg5Tu/Bjuak1z5PQ1IrcP okwlWix9a78MTkaGj/RaMonif0hg6GCoztRFrlSCYuzG3Z4QOA9/ytgIqU12VA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696207847; 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=76SIPGKLgEkL9TOLwbzKK18QPIodl+BSeDKYdEtDj7Q=; b=VqUsA7Q284/3ugl+SGrm+HXy+PVey4hbVUWYGqc3DMsnK2zHV40NqxFOF9HMH7duOjsFfB xgE+OrbN2XIFAz5qaxEmfKzWQN3MBz5gSGmJUQHPTmM/autV1AY5mvo1CLQgxoCAsQnOwo t3nrBYJVWFlPOuf2bDagF1DmIlj9t1mq53KTiUovDfbiOVxqQrj0T8ZRS51JO2QSdboKiN 45mMq8P2IE/P2V4A4xsPJGBwoBmMTRnkVOQTRfuiAtSGOl6OAZaaWANi2wZTP1InO4epN3 /umFImDGhazpVYx8CoYMzWRsKHQ5wnxezgFXdHzNRqUOUb/UETtbF8yAS4FCFg== 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 4RzMng3jhczrGD; Mon, 2 Oct 2023 00:50:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3920olqm029412; Mon, 2 Oct 2023 00:50:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3920olZM029409; Mon, 2 Oct 2023 00:50:47 GMT (envelope-from git) Date: Mon, 2 Oct 2023 00:50:47 GMT Message-Id: <202310020050.3920olZM029409@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: b0f026435a15 - stable/14 - ip_mroute: Fix sysctl knobs List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: b0f026435a150933ecb6f2d1359fd1b4898657f1 Auto-Submitted: auto-generated The branch stable/14 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=b0f026435a150933ecb6f2d1359fd1b4898657f1 commit b0f026435a150933ecb6f2d1359fd1b4898657f1 Author: Zhenlei Huang AuthorDate: 2023-09-27 16:23:22 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 00:49:38 +0000 ip_mroute: Fix sysctl knobs The loader tunable `net.inet.ip.mfchashsize` does not have corresponding sysctl MIB entry. Just add it. While here, the sysctl variable `net.inet.pim.squelch_wholepkt` is actually a loader tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` will report it correctly. Reviewed by: kp Fixes: 443fc3176dee Introduce a number of changes to the MROUTING code MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41997 (cherry picked from commit f549e22901b3a391c76659bee55802b1214112fd) --- sys/netinet/ip_mroute.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/sys/netinet/ip_mroute.c b/sys/netinet/ip_mroute.c index 2444fd9686f7..cda5f160e8fb 100644 --- a/sys/netinet/ip_mroute.c +++ b/sys/netinet/ip_mroute.c @@ -172,7 +172,9 @@ VNET_DEFINE_STATIC(u_long, mfchash); ((g).s_addr >> 20) ^ ((g).s_addr >> 10) ^ (g).s_addr) & V_mfchash) #define MFCHASHSIZE 256 -static u_long mfchashsize; /* Hash size */ +static u_long mfchashsize = MFCHASHSIZE; /* Hash size */ +SYSCTL_ULONG(_net_inet_ip, OID_AUTO, mfchashsize, CTLFLAG_RDTUN, + &mfchashsize, 0, "IPv4 Multicast Forwarding Table hash size"); VNET_DEFINE_STATIC(u_char *, nexpire); /* 0..mfchashsize-1 */ #define V_nexpire VNET(nexpire) VNET_DEFINE_STATIC(LIST_HEAD(mfchashhdr, mfc)*, mfchashtbl); @@ -226,7 +228,7 @@ SYSCTL_VNET_PCPUSTAT(_net_inet_pim, PIMCTL_STATS, stats, struct pimstat, pimstat, "PIM Statistics (struct pimstat, netinet/pim_var.h)"); static u_long pim_squelch_wholepkt = 0; -SYSCTL_ULONG(_net_inet_pim, OID_AUTO, squelch_wholepkt, CTLFLAG_RW, +SYSCTL_ULONG(_net_inet_pim, OID_AUTO, squelch_wholepkt, CTLFLAG_RWTUN, &pim_squelch_wholepkt, 0, "Disable IGMP_WHOLEPKT notifications if rendezvous point is unspecified"); @@ -2817,18 +2819,12 @@ ip_mroute_modevent(module_t mod, int type, void *unused) return (EINVAL); } - mfchashsize = MFCHASHSIZE; - if (TUNABLE_ULONG_FETCH("net.inet.ip.mfchashsize", &mfchashsize) && - !powerof2(mfchashsize)) { + if (!powerof2(mfchashsize)) { printf("WARNING: %s not a power of 2; using default\n", "net.inet.ip.mfchashsize"); mfchashsize = MFCHASHSIZE; } - pim_squelch_wholepkt = 0; - TUNABLE_ULONG_FETCH("net.inet.pim.squelch_wholepkt", - &pim_squelch_wholepkt); - pim_encap_cookie = ip_encap_attach(&ipv4_encap_cfg, NULL, M_WAITOK); ip_mcast_src = X_ip_mcast_src; From nobody Mon Oct 2 00:50:48 2023 X-Original-To: dev-commits-src-branches@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 4RzMnh64T3z4w2sV; Mon, 2 Oct 2023 00:50: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzMnh5XkHz4rJj; Mon, 2 Oct 2023 00:50:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696207848; 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=p1LiFaJRYd3Laq6be7RtOk7ofBo0Cc2PWUuKhMFDraU=; b=bnUVLVjKcy9kuOlvDCPJihrJzk7OQT/uF16u3BlxrZJqHznfNXY3botWdEU8aHz1xrFSdV pjVx+vXurucQww9lQc/LukCn4iPot14AbnlzJBcRKrXvx4Vl0E5Aw/DsVsK+evWKvSUeKS jV1Pjt/0FodupaWxQps+N4awkHVumWAh59s39g3PekRt1PZPEe87oMEPGRvZKRxfL7i9zf 3XfxNwmtNtRv85D/83nbDhWA3CoF7dUt5U0ANdDtl63rj1jvKEdf+U9bo3kBMJNC0PEKTR +yl26JCudrOwxowUmiw7EKW/B+G/UPU0xnhdNwu2WnKmcr2g5fzgqlMOCYjTrQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696207848; a=rsa-sha256; cv=none; b=SyylPUQfu4qwFr+iVuRqDMVcPRb5+3XT1lo0ceEAtgk6gpszPo9U1N3Og+RBrSLmETjc4c ODmAfLxzvOsT5i7afLo9YQwDEVU2qE17ceQ9XPPJI0BB/xCbrHNUd9FZqA21g/RrkFN2cc G3kxeoD4id1JpMAmsDr6WoRlY8ZEAFRee1MMvxYFELbsKTV05WSmgnJuDUOyJ5+vtioKV4 n8lBsKTtpvqWgKsGgr6fV4I6YME5NGZW+5+3Aity04FKKN9mg5OhPZwR5GEe23aWEFyBVF Rs69AKZaEvNfbKgkJET1HkPwcP2BuCVOVYP8/ZVG6SagYmvqd+T8RJPXwNHm5g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696207848; 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=p1LiFaJRYd3Laq6be7RtOk7ofBo0Cc2PWUuKhMFDraU=; b=qSDe9KDn/X5XUDpSfUb5PumuwSHAWYI+NHU0qW9gQjSsK6bO7RFS6PZ/NzWBcoyWXs64fw T23MdJPm9PmrVHcRxFNKebiJBfLWw8eQKmWwRohiQS7NgVa1dy6RszVhBN0bsViNXW9Che l/fWPluY3ms7dIVEp0Rl8pswl6hcYY7JO0oJ9DmsR4mgRcrfvu1KLC2rum0dE+X2uLBRS+ YtYi9tUntTkMtwBpyf5UhIXlWwzPRUI1vDCCPpUNutvjI8tHGpcK9X77aWGXnJ+yWkUvTM O+wyg+8Z6hAtM3UAVMRiNX+TUO+5h3xx02nS+/SVzXa0DAY50kOTT5IWghW9Lg== 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 4RzMnh4fV0zrGG; Mon, 2 Oct 2023 00:50:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3920om1l029463; Mon, 2 Oct 2023 00:50:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3920omhH029460; Mon, 2 Oct 2023 00:50:48 GMT (envelope-from git) Date: Mon, 2 Oct 2023 00:50:48 GMT Message-Id: <202310020050.3920omhH029460@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: a9359dcde241 - stable/14 - ipfilter: Add sysctl flag CTLFLAG_TUN to loader tunable List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: a9359dcde241f17421a71bc8c96dee08625db9dd Auto-Submitted: auto-generated The branch stable/14 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=a9359dcde241f17421a71bc8c96dee08625db9dd commit a9359dcde241f17421a71bc8c96dee08625db9dd Author: Zhenlei Huang AuthorDate: 2023-09-29 00:01:43 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 00:49:38 +0000 ipfilter: Add sysctl flag CTLFLAG_TUN to loader tunable The sysctl variable `net.inet.ipf.large_nat` is actually a loader tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` will report it correctly. No functional change intended. Reviewed by: cy (for #network) Fixes: a805ffbcbce8 ipfilter: Make LARGE_NAT a tunable MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D42005 (cherry picked from commit ba883e7a5ac43b27a373f2b1b0044fd2eb769d4e) --- sys/netpfil/ipfilter/netinet/mlfk_ipl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c b/sys/netpfil/ipfilter/netinet/mlfk_ipl.c index 35daad4715bf..69be4abb2485 100644 --- a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c +++ b/sys/netpfil/ipfilter/netinet/mlfk_ipl.c @@ -134,7 +134,7 @@ SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_running, CTLFLAG_RD, &VNET_NAME(ipfmain.ipf_running), 0, "IPF is running"); SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_chksrc, CTLFLAG_RW, &VNET_NAME(ipfmain.ipf_chksrc), 0, ""); SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_minttl, CTLFLAG_RW, &VNET_NAME(ipfmain.ipf_minttl), 0, ""); -SYSCTL_IPF(_net_inet_ipf, OID_AUTO, large_nat, CTLFLAG_RD, &VNET_NAME(ipfmain.ipf_large_nat), 0, "large_nat"); +SYSCTL_IPF(_net_inet_ipf, OID_AUTO, large_nat, CTLFLAG_RDTUN | CTLFLAG_NOFETCH, &VNET_NAME(ipfmain.ipf_large_nat), 0, "large_nat"); #define CDEV_MAJOR 79 #include From nobody Mon Oct 2 02:53:15 2023 X-Original-To: dev-commits-src-branches@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 4RzQW23sSNz4w8l9; Mon, 2 Oct 2023 02:53:18 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Received: from omta001.cacentral1.a.cloudfilter.net (omta001.cacentral1.a.cloudfilter.net [3.97.99.32]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "Client", Issuer "CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzQW21Xwmz3Hyg; Mon, 2 Oct 2023 02:53:18 +0000 (UTC) (envelope-from cy.schubert@cschubert.com) Authentication-Results: mx1.freebsd.org; none Received: from shw-obgw-4004a.ext.cloudfilter.net ([10.228.9.227]) by cmsmtp with ESMTPS id mt8uqaCsmmfesn93dqBm9s; Mon, 02 Oct 2023 02:53:17 +0000 Received: from spqr.komquats.com ([70.66.152.170]) by cmsmtp with ESMTPSA id n93bq5R3eSxZQn93cqPmq7; Mon, 02 Oct 2023 02:53:17 +0000 X-Authority-Analysis: v=2.4 cv=JbqvEGGV c=1 sm=1 tr=0 ts=651a309d a=y8EK/9tc/U6QY+pUhnbtgQ==:117 a=y8EK/9tc/U6QY+pUhnbtgQ==:17 a=kj9zAlcOel0A:10 a=bhdUkHdE2iEA:10 a=6I5d2MoRAAAA:8 a=YxBL1-UpAAAA:8 a=EkcXrb_YAAAA:8 a=mVaAT9imt_-sTEsIGqYA:9 a=CjuIK1q_8ugA:10 a=IjZwj45LgO3ly-622nXo:22 a=Ia-lj3WSrqcvXOmTRaiG:22 a=LK5xJRSDVpKd5WXXoEvA:22 Received: from slippy.cwsent.com (slippy [10.1.1.91]) by spqr.komquats.com (Postfix) with ESMTP id 53D9B33E2; Sun, 1 Oct 2023 19:53:15 -0700 (PDT) Received: by slippy.cwsent.com (Postfix, from userid 1000) id 41C99A7C; Sun, 1 Oct 2023 19:53:15 -0700 (PDT) X-Mailer: exmh version 2.9.0 11/07/2018 with nmh-1.8+dev Reply-to: Cy Schubert From: Cy Schubert X-os: FreeBSD X-Sender: cy@cwsent.com X-URL: http://www.cschubert.com/ To: Zhenlei Huang cc: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Subject: Re: git: a9359dcde241 - stable/14 - ipfilter: Add sysctl flag CTLFLAG_TUN to loader tunable In-reply-to: <202310020050.3920omhH029460@gitrepo.freebsd.org> References: <202310020050.3920omhH029460@gitrepo.freebsd.org> Comments: In-reply-to Zhenlei Huang message dated "Mon, 02 Oct 2023 00:50:48 +0000." List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Sun, 01 Oct 2023 19:53:15 -0700 Message-Id: <20231002025315.41C99A7C@slippy.cwsent.com> X-CMAE-Envelope: MS4xfPTwxOQxjj/VsUT7vu59nLyivchlWK4LJEJ3OP0rVMtMCk6QTUkD+cTJGfwxkiJmi53rNwuoZp2h1fNGBXns0Gt8xBWnOCZzJMr3LGf6FiWUXulnIDqa 0onaoIchQukLemg2qO59JMfhCFvrQTY18dJ4lQeqvkr3REh+j8FDWUQ4cEOa77KgiMvo3RqodUUBAnMy/kIjhadapBSGN9mGjF+PHiNAS4x3I9qpgEILeP2r spCirwh+T02juqIS12Kw2t1cjowdO50TJE+Nc+iXFu7FdVky7XcSVEJwYJcRcM9XTGMhKfggiVQMy6Ja8Aybcquu+ZvpcuRRpBQs4gsAVlo= X-Spamd-Bar: ---- 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:16509, ipnet:3.96.0.0/15, country:US] X-Rspamd-Queue-Id: 4RzQW21Xwmz3Hyg In message <202310020050.3920omhH029460@gitrepo.freebsd.org>, Zhenlei Huang wri tes: > The branch stable/14 has been updated by zlei: > > URL: https://cgit.FreeBSD.org/src/commit/?id=a9359dcde241f17421a71bc8c96dee08 > 625db9dd > > commit a9359dcde241f17421a71bc8c96dee08625db9dd > Author: Zhenlei Huang > AuthorDate: 2023-09-29 00:01:43 +0000 > Commit: Zhenlei Huang > CommitDate: 2023-10-02 00:49:38 +0000 > > ipfilter: Add sysctl flag CTLFLAG_TUN to loader tunable > > The sysctl variable `net.inet.ipf.large_nat` is actually a loader > tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` will > report it correctly. > > No functional change intended. > > Reviewed by: cy (for #network) > Fixes: a805ffbcbce8 ipfilter: Make LARGE_NAT a tunable > MFC after: 3 days > Differential Revision: https://reviews.freebsd.org/D42005 > > (cherry picked from commit ba883e7a5ac43b27a373f2b1b0044fd2eb769d4e) > --- > sys/netpfil/ipfilter/netinet/mlfk_ipl.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c b/sys/netpfil/ipfilter/n > etinet/mlfk_ipl.c > index 35daad4715bf..69be4abb2485 100644 > --- a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c > +++ b/sys/netpfil/ipfilter/netinet/mlfk_ipl.c > @@ -134,7 +134,7 @@ SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_running, CTLFLAG_R > D, > &VNET_NAME(ipfmain.ipf_running), 0, "IPF is running"); > SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_chksrc, CTLFLAG_RW, &VNET_NAME(ipfmai > n.ipf_chksrc), 0, ""); > SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_minttl, CTLFLAG_RW, &VNET_NAME(ipfmai > n.ipf_minttl), 0, ""); > -SYSCTL_IPF(_net_inet_ipf, OID_AUTO, large_nat, CTLFLAG_RD, &VNET_NAME(ipfmai > n.ipf_large_nat), 0, "large_nat"); > +SYSCTL_IPF(_net_inet_ipf, OID_AUTO, large_nat, CTLFLAG_RDTUN | CTLFLAG_NOFET > CH, &VNET_NAME(ipfmain.ipf_large_nat), 0, "large_nat"); > > #define CDEV_MAJOR 79 > #include > Can you also please MFC to stable/13 and 12? -- Cheers, Cy Schubert FreeBSD UNIX: Web: https://FreeBSD.org NTP: Web: https://nwtime.org e^(i*pi)+1=0 From nobody Mon Oct 2 05:45:14 2023 X-Original-To: dev-commits-src-branches@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 4RzVKR11lbz4vc6d; Mon, 2 Oct 2023 05:45: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzVKQ6nw9z3Xck; Mon, 2 Oct 2023 05:45:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696225515; 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=0dLbNg3/VBgxrLITMlDjL2aSvINxeGcYeFlHhv89AyM=; b=r3GEK0OBZpYK8CDKLL/N9p+apuIxCnD8BeS62B7LSIQJBodj7Bn/xpMRI9x55FD5OUNzkP LDAhp3zNWBE+aOsHLok0WM1aproyBghSbk5kyZFWVB0XLrC5O5k6x5Bjr42KkRofH/j6DR Jg0OCl9SChaNYE2JQGKbsqV6hxi+5otN+Ay8IDCTNeudOICZJ40HNiOODWn9SOfgt0zQSu wKeW+lfKfckFVs9C3LW5t1nNe1bkuBUpmQynUqZndWObM3zb1Wp39vXwmcqQMqG4C+j+4a yICxKrpzsDnIEZb5vsgbzDE3UEna0do41zogS05dg15Uw89xAdSnNPdvRerXsw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696225515; a=rsa-sha256; cv=none; b=grlIg3mGCsCdupxsU2QkMLA4BtC/5mbM8QkIysr82YwOWwD4V1GkEI36DApgmHO+FON7mK GjBa0EOHPiWCxG9u39jjRhcwCGOlCgAsBXqDTxKlavK9rMpHLxUITdi1CISrPHLE7lXgEs BzmdnuEjTef10kUHWRLip6sliNWw3u9uV6g2FEny1G+2VwuKLtTl831XQV2HxuWjB0EeOY UlNfYt6t5Nya9V731+5wcnjWxWT2NTmrX8spvUKnTovgcwfKX4yHhJFYPjsWYqNJUKXb+N cD1wF1R9YLXkGeMVGMDSWESqjIY5tjgRiXifKYfMUXOTUgKu3pyDkCNYEEhXsg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696225515; 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=0dLbNg3/VBgxrLITMlDjL2aSvINxeGcYeFlHhv89AyM=; b=uZ8jN5GfEE5+E92H4cz8j+/qaa4WndMh3xQvmLj8Zlnw9Qf67wG6Om1VKBrPXh1M6oMIxr WS6YMWhMnl5wd3RfmUTIirB2zD6cbQHxQlbo70XS/UJRb8pRDBm9SsV1OfPvQseyFDrd3a oF/7w18xh3qSIy/evuarslvHHXt2r28xU6Wzz+2Dq/lPqCFaG5091TzAPrFqjSQ0YRGglu sTXkelYVqYhzMjLg4E7J3SH9VoYE8qgw7EY31FOuSWItHO25u8LMU8kGIO6s6yoGsIZPHX hH4rDDLhBw7olJ6QPb5VHkj/N8A0B93t2hNlLPnZotdkcBfMfH96n9/QOezIbA== 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 4RzVKQ5SSqz108X; Mon, 2 Oct 2023 05:45:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3925jENl018833; Mon, 2 Oct 2023 05:45:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3925jElv018830; Mon, 2 Oct 2023 05:45:14 GMT (envelope-from git) Date: Mon, 2 Oct 2023 05:45:14 GMT Message-Id: <202310020545.3925jElv018830@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dmitry Chagin Subject: git: 4d46ca655013 - stable/14 - linux(4): Update syscalls.master to 6.5 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dchagin X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 4d46ca65501370869230f04d9b78484799dee5f5 Auto-Submitted: auto-generated The branch stable/14 has been updated by dchagin: URL: https://cgit.FreeBSD.org/src/commit/?id=4d46ca65501370869230f04d9b78484799dee5f5 commit 4d46ca65501370869230f04d9b78484799dee5f5 Author: Dmitry Chagin AuthorDate: 2023-09-25 09:24:58 +0000 Commit: Dmitry Chagin CommitDate: 2023-10-02 05:44:53 +0000 linux(4): Update syscalls.master to 6.5 MFC after: 1 week (cherry picked from commit 0a16d3d14db67c89ee08f954c670ec4f447a7ab5) --- sys/amd64/linux/linux_dummy_machdep.c | 2 ++ sys/amd64/linux/syscalls.master | 53 ++++++++++++++++++++++++++++++++-- sys/amd64/linux32/syscalls.master | 54 ++++++++++++++++++++++++++++++++--- sys/arm64/linux/syscalls.master | 53 ++++++++++++++++++++++++++++++++-- sys/compat/linux/linux_dummy.c | 35 ++++++++++++++++++----- sys/i386/linux/syscalls.master | 54 ++++++++++++++++++++++++++++++++--- 6 files changed, 231 insertions(+), 20 deletions(-) diff --git a/sys/amd64/linux/linux_dummy_machdep.c b/sys/amd64/linux/linux_dummy_machdep.c index 4737386cb7f7..759586d9f1fc 100644 --- a/sys/amd64/linux/linux_dummy_machdep.c +++ b/sys/amd64/linux/linux_dummy_machdep.c @@ -66,3 +66,5 @@ DUMMY(readahead); DUMMY(restart_syscall); /* Linux 3.15: */ DUMMY(kexec_file_load); +/* Linux 6.6: */ +DUMMY(map_shadow_stack); diff --git a/sys/amd64/linux/syscalls.master b/sys/amd64/linux/syscalls.master index 88caaa49367b..437066d1655b 100644 --- a/sys/amd64/linux/syscalls.master +++ b/sys/amd64/linux/syscalls.master @@ -2059,7 +2059,7 @@ uint32_t sig ); } -; Linux 5.0: +; Linux 5.1: 335-423 AUE_NULL UNIMPL nosys 424 AUE_NULL STD { int linux_pidfd_send_signal( @@ -2078,6 +2078,7 @@ 427 AUE_NULL STD { int linux_io_uring_register(void); } +; Linux 5.2: 428 AUE_NULL STD { int linux_open_tree(void); } @@ -2096,6 +2097,7 @@ 433 AUE_NULL STD { int linux_fspick(void); } +; Linux 5.3: 434 AUE_NULL STD { int linux_pidfd_open(void); } @@ -2105,6 +2107,7 @@ l_size_t usize ); } +; Linux 5.9: 436 AUE_CLOSERANGE STD { int linux_close_range( l_uint first, @@ -2112,12 +2115,14 @@ l_uint flags ); } +; Linux 5.6: 437 AUE_NULL STD { int linux_openat2(void); } 438 AUE_NULL STD { int linux_pidfd_getfd(void); } +; Linux 5.8: 439 AUE_NULL STD { int linux_faccessat2( l_int dfd, @@ -2126,9 +2131,11 @@ l_int flags ); } +; Linux 5.10: 440 AUE_NULL STD { int linux_process_madvise(void); } +; Linux 5.11: 441 AUE_NULL STD { int linux_epoll_pwait2( l_int epfd, @@ -2139,9 +2146,51 @@ l_size_t sigsetsize ); } +; Linux 5.12: 442 AUE_NULL STD { int linux_mount_setattr(void); } +; Linux 5.14: +443 AUE_NULL STD { + int linux_quotactl_fd(void); + } +; Linux 5.13: +444 AUE_NULL STD { + int linux_landlock_create_ruleset(void); + } +445 AUE_NULL STD { + int linux_landlock_add_rule(void); + } +446 AUE_NULL STD { + int linux_landlock_restrict_self(void); + } +; Linux 5.14: +447 AUE_NULL STD { + int linux_memfd_secret(void); + } +; Linux 5.15: +448 AUE_NULL STD { + int linux_process_mrelease(void); + } +; Linux 5.16: +449 AUE_NULL STD { + int linux_futex_waitv(void); + } +; Linux 5.17: +450 AUE_NULL STD { + int linux_set_mempolicy_home_node(void); + } +; Linux 6.5: +451 AUE_NULL STD { + int linux_cachestat(void); + } +; Linux 6.6: +452 AUE_NULL STD { + int linux_fchmodat2(void); + } +453 AUE_NULL STD { + int linux_map_shadow_stack(void); + } ; please, keep this line at the end. -443 AUE_NULL UNIMPL nosys +454 AUE_NULL UNIMPL nosys ; vim: syntax=off diff --git a/sys/amd64/linux32/syscalls.master b/sys/amd64/linux32/syscalls.master index 679eda14202a..32ed678fe0c6 100644 --- a/sys/amd64/linux32/syscalls.master +++ b/sys/amd64/linux32/syscalls.master @@ -2281,6 +2281,7 @@ uint32_t sig ); } +; Linux 5.1: 387-392 AUE_NULL UNIMPL nosys 393 AUE_NULL STD { int linux_semget( @@ -2353,7 +2354,6 @@ struct l_msqid_ds *buf ); } -; Linux 5.0: 403 AUE_NULL STD { int linux_clock_gettime64( clockid_t which, @@ -2506,6 +2506,7 @@ 427 AUE_NULL STD { int linux_io_uring_register(void); } +; Linux 5.2: 428 AUE_NULL STD { int linux_open_tree(void); } @@ -2524,6 +2525,7 @@ 433 AUE_NULL STD { int linux_fspick(void); } +; Linux 5.3: 434 AUE_NULL STD { int linux_pidfd_open(void); } @@ -2533,6 +2535,7 @@ l_size_t usize ); } +; Linux 5.9: 436 AUE_CLOSERANGE STD { int linux_close_range( l_uint first, @@ -2540,12 +2543,14 @@ l_uint flags ); } +; Linux 5.6: 437 AUE_NULL STD { int linux_openat2(void); } 438 AUE_NULL STD { int linux_pidfd_getfd(void); } +; Linux 5.8: 439 AUE_NULL STD { int linux_faccessat2( l_int dfd, @@ -2554,9 +2559,11 @@ l_int flags ); } +; Linux 5.10: 440 AUE_NULL STD { int linux_process_madvise(void); } +; Linux 5.11: 441 AUE_NULL STD { int linux_epoll_pwait2_64( l_int epfd, @@ -2567,9 +2574,48 @@ l_size_t sigsetsize ); } +; Linux 5.12: 442 AUE_NULL STD { int linux_mount_setattr(void); } -; please, keep this line at the end. -443 AUE_NULL UNIMPL nosys -; vim: syntax=off +; Linux 5.14: +443 AUE_NULL STD { + int linux_quotactl_fd(void); + } +; Linux 5.13: +444 AUE_NULL STD { + int linux_landlock_create_ruleset(void); + } +445 AUE_NULL STD { + int linux_landlock_add_rule(void); + } +446 AUE_NULL STD { + int linux_landlock_restrict_self(void); + } +; Linux 5.14: +447 AUE_NULL STD { + int linux_memfd_secret(void); + } +; Linux 5.15: +448 AUE_NULL STD { + int linux_process_mrelease(void); + } +; Linux 5.16: +449 AUE_NULL STD { + int linux_futex_waitv(void); + } +; Linux 5.17: +450 AUE_NULL STD { + int linux_set_mempolicy_home_node(void); + } +; Linux 6.5: +451 AUE_NULL STD { + int linux_cachestat(void); + } +; Linux 6.6: +452 AUE_NULL STD { + int linux_fchmodat2(void); + } + ; please, keep this line at the end. +453 AUE_NULL UNIMPL nosys + ; vim: syntax=off diff --git a/sys/arm64/linux/syscalls.master b/sys/arm64/linux/syscalls.master index daaeeef1acc2..9ba548359c46 100644 --- a/sys/arm64/linux/syscalls.master +++ b/sys/arm64/linux/syscalls.master @@ -1736,6 +1736,7 @@ 294 AUE_NULL STD { int linux_kexec_file_load(void); } +; Linux 5.1: 295-423 AUE_NULL UNIMPL unimpl_md_syscall 424 AUE_NULL STD { int linux_pidfd_send_signal( @@ -1754,6 +1755,7 @@ 427 AUE_NULL STD { int linux_io_uring_register(void); } +; Linux 5.2: 428 AUE_NULL STD { int linux_open_tree(void); } @@ -1772,6 +1774,7 @@ 433 AUE_NULL STD { int linux_fspick(void); } +; Linux 5.3: 434 AUE_NULL STD { int linux_pidfd_open(void); } @@ -1781,6 +1784,7 @@ l_size_t usize ); } +; Linux 5.9: 436 AUE_CLOSERANGE STD { int linux_close_range( l_uint first, @@ -1788,12 +1792,14 @@ l_uint flags ); } +; Linux 5.6: 437 AUE_NULL STD { int linux_openat2(void); } 438 AUE_NULL STD { int linux_pidfd_getfd(void); } +; Linux 5.8: 439 AUE_NULL STD { int linux_faccessat2( l_int dfd, @@ -1802,9 +1808,11 @@ l_int flags ); } +; Linux 5.10: 440 AUE_NULL STD { int linux_process_madvise(void); } +; Linux 5.11: 441 AUE_NULL STD { int linux_epoll_pwait2( l_int epfd, @@ -1815,9 +1823,48 @@ l_size_t sigsetsize ); } +; Linux 5.12: 442 AUE_NULL STD { int linux_mount_setattr(void); } -; please, keep this line at the end. -443 AUE_NULL UNIMPL nosys -; vim: syntax=off +; Linux 5.14: +443 AUE_NULL STD { + int linux_quotactl_fd(void); + } +; Linux 5.13: +444 AUE_NULL STD { + int linux_landlock_create_ruleset(void); + } +445 AUE_NULL STD { + int linux_landlock_add_rule(void); + } +446 AUE_NULL STD { + int linux_landlock_restrict_self(void); + } +; Linux 5.14: +447 AUE_NULL STD { + int linux_memfd_secret(void); + } +; Linux 5.15: +448 AUE_NULL STD { + int linux_process_mrelease(void); + } +; Linux 5.16: +449 AUE_NULL STD { + int linux_futex_waitv(void); + } +; Linux 5.17: +450 AUE_NULL STD { + int linux_set_mempolicy_home_node(void); + } +; Linux 6.5: +451 AUE_NULL STD { + int linux_cachestat(void); + } +; Linux 6.6: +452 AUE_NULL STD { + int linux_fchmodat2(void); + } + ; please, keep this line at the end. +453 AUE_NULL UNIMPL nosys + ; vim: syntax=off diff --git a/sys/compat/linux/linux_dummy.c b/sys/compat/linux/linux_dummy.c index 4fdab6daab48..35d6debe0da9 100644 --- a/sys/compat/linux/linux_dummy.c +++ b/sys/compat/linux/linux_dummy.c @@ -123,21 +123,42 @@ DUMMY(pwritev2); DUMMY(pkey_mprotect); DUMMY(pkey_alloc); DUMMY(pkey_free); +/* Linux 4.18: */ +DUMMY(io_pgetevents); +/* Linux 5.1: */ +DUMMY(pidfd_send_signal); +DUMMY(io_uring_setup); +DUMMY(io_uring_enter); +DUMMY(io_uring_register); +/* Linux 5.2: */ DUMMY(open_tree); DUMMY(move_mount); DUMMY(fsopen); DUMMY(fsconfig); DUMMY(fsmount); DUMMY(fspick); +/* Linux 5.3: */ DUMMY(pidfd_open); +/* Linux 5.6: */ DUMMY(openat2); DUMMY(pidfd_getfd); +/* Linux 5.10: */ DUMMY(process_madvise); +/* Linux 5.12: */ DUMMY(mount_setattr); -/* Linux 4.18: */ -DUMMY(io_pgetevents); -/* Linux 5.0: */ -DUMMY(pidfd_send_signal); -DUMMY(io_uring_setup); -DUMMY(io_uring_enter); -DUMMY(io_uring_register); +/* Linux 5.13: */ +DUMMY(landlock_create_ruleset); +DUMMY(landlock_add_rule); +DUMMY(landlock_restrict_self); +/* Linux 5.14: */ +DUMMY(memfd_secret); +DUMMY(quotactl_fd); +/* Linux 5.15: */ +DUMMY(process_mrelease); +/* Linux 5.16: */ +DUMMY(futex_waitv); +DUMMY(set_mempolicy_home_node); +/* Linux 6.5: */ +DUMMY(cachestat); +/* Linux 6.6: */ +DUMMY(fchmodat2); diff --git a/sys/i386/linux/syscalls.master b/sys/i386/linux/syscalls.master index 6144deeb31ab..3f37cc2fc485 100644 --- a/sys/i386/linux/syscalls.master +++ b/sys/i386/linux/syscalls.master @@ -2293,6 +2293,7 @@ uint32_t sig ); } +; Linux 5.1: 387-392 AUE_NULL UNIMPL nosys 393 AUE_NULL STD { int linux_semget( @@ -2365,7 +2366,6 @@ struct l_msqid_ds *buf ); } -; Linux 5.0: 403 AUE_NULL STD { int linux_clock_gettime64( clockid_t which, @@ -2518,6 +2518,7 @@ 427 AUE_NULL STD { int linux_io_uring_register(void); } +; Linux 5.2: 428 AUE_NULL STD { int linux_open_tree(void); } @@ -2536,6 +2537,7 @@ 433 AUE_NULL STD { int linux_fspick(void); } +; Linux 5.3: 434 AUE_NULL STD { int linux_pidfd_open(void); } @@ -2545,6 +2547,7 @@ l_size_t usize ); } +; Linux 5.9: 436 AUE_CLOSERANGE STD { int linux_close_range( l_uint first, @@ -2552,12 +2555,14 @@ l_uint flags ); } +; Linux 5.6: 437 AUE_NULL STD { int linux_openat2(void); } 438 AUE_NULL STD { int linux_pidfd_getfd(void); } +; Linux 5.8: 439 AUE_NULL STD { int linux_faccessat2( l_int dfd, @@ -2566,9 +2571,11 @@ l_int flags ); } +; Linux 5.10: 440 AUE_NULL STD { int linux_process_madvise(void); } +; Linux 5.11: 441 AUE_NULL STD { int linux_epoll_pwait2_64( l_int epfd, @@ -2579,9 +2586,48 @@ l_size_t sigsetsize ); } +; Linux 5.12: 442 AUE_NULL STD { int linux_mount_setattr(void); } -; please, keep this line at the end. -443 AUE_NULL UNIMPL nosys -; vim: syntax=off +; Linux 5.14: +443 AUE_NULL STD { + int linux_quotactl_fd(void); + } +; Linux 5.13: +444 AUE_NULL STD { + int linux_landlock_create_ruleset(void); + } +445 AUE_NULL STD { + int linux_landlock_add_rule(void); + } +446 AUE_NULL STD { + int linux_landlock_restrict_self(void); + } +; Linux 5.14: +447 AUE_NULL STD { + int linux_memfd_secret(void); + } +; Linux 5.15: +448 AUE_NULL STD { + int linux_process_mrelease(void); + } +; Linux 5.16: +449 AUE_NULL STD { + int linux_futex_waitv(void); + } +; Linux 5.17: +450 AUE_NULL STD { + int linux_set_mempolicy_home_node(void); + } +; Linux 6.5: +451 AUE_NULL STD { + int linux_cachestat(void); + } +; Linux 6.6: +452 AUE_NULL STD { + int linux_fchmodat2(void); + } + ; please, keep this line at the end. +453 AUE_NULL UNIMPL nosys + ; vim: syntax=off From nobody Mon Oct 2 05:45:15 2023 X-Original-To: dev-commits-src-branches@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 4RzVKS0vrbz4vcCH; Mon, 2 Oct 2023 05:45: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzVKR6vCqz3XXc; Mon, 2 Oct 2023 05:45:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696225516; 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=QV9mqmnWlSH3Gti1iCRYkye1QoB1QaPOygsB/no5/qs=; b=ViJFU579iA7uifnysgXQCaZUgeEwFWBje9bbaDdScxHSebDq4K3K6dJm3sL7wAglNurQsO b2gcXstcNMwV0+MUe4BZGy9/EhKs0WjvuRjH4DCpSmjz4xy2RM01UVCL4NrAcFl9TBy+zD xNPhoC78gQIRTPiNh4eGpMD6wLiVozsbKsr8Vx/mPLr5xYBQnbABMXpXqRznkEFMbjZ+60 kaFlFXdP9a/pJVq3U8n4gmHCLs1TH9HYh0W91jmw6AFSkPd49GcphUkJKiH71QOPELSINv WMOwfHn1NtmCzeczabj+LMAu790OQPpFeaX0P7JIsGFBUUIztCK4Txd7D18Edw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696225516; a=rsa-sha256; cv=none; b=BDi8Ju1qcuNitnwIunefThHeGFqYGFb9vnEeMa+s+JRgwDpufrWGcnxmvzWteUtgvOH09c 4XhXP8h5ae9ddSZl+KwBOx2MDST2QoaHI0MR5itMk8dxnLuW2yHlDr8U8Q6+TO8ZCVUKCf /QRkJaJnY24qMs3DI9NY1DHaAidAnyRz5CZph8kLG+hkHtzBqCZVrHrtY82pEaZtBIfCZ/ X6lUbsKnfhxwIdNaNX5oVgqT8XkeYCKzdhO8oVfXgqomwInZ+5pONpRLVxeUAqr2l7n15f HfTE9MtlFcYancXFgCSueNhEETt28eqpqqCabm5A9jKZOjQEfffvzalSfr5yhA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696225516; 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=QV9mqmnWlSH3Gti1iCRYkye1QoB1QaPOygsB/no5/qs=; b=kaTaqbEVUufn8hEbyrysNQgfyndEYBuBES+2Hvk5TGhMfyYdCe0lCIY5cnWi0gFWlfmjYl r1uToA5PHrtOc8NJBdOqRWhpRZl9iJFtNh9GlKW64zMJqTYcFvfSxVex0Crnu2qJPU/lZd pnKpRZC2lrsH7r3GoFu7RbMkrAgOoteB+mNKNDBv4cJE3AmI+02b3AZmWnu+8VhAral50J m0ypqjdFhrqvf+APUhqSjQR+3y+QBmhxZYlXjaLCSlbApizOgaDcnXLSsnP31MzG+PHCbP hlipcdtG8QAuBK82vjbcw/lkMtgo6BtfRQUmoF2xFlLvo97cVJIqDs40EcH5sw== 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 4RzVKR5ydQz119P; Mon, 2 Oct 2023 05:45:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3925jFtN018869; Mon, 2 Oct 2023 05:45:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3925jFpR018866; Mon, 2 Oct 2023 05:45:15 GMT (envelope-from git) Date: Mon, 2 Oct 2023 05:45:15 GMT Message-Id: <202310020545.3925jFpR018866@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dmitry Chagin Subject: git: 6f63d749febf - stable/14 - linux(4): Regen List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dchagin X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 6f63d749febfffbf6217d9f739339d7ebd213a37 Auto-Submitted: auto-generated The branch stable/14 has been updated by dchagin: URL: https://cgit.FreeBSD.org/src/commit/?id=6f63d749febfffbf6217d9f739339d7ebd213a37 commit 6f63d749febfffbf6217d9f739339d7ebd213a37 Author: Dmitry Chagin AuthorDate: 2023-09-25 09:26:34 +0000 Commit: Dmitry Chagin CommitDate: 2023-10-02 05:44:53 +0000 linux(4): Regen MFC after: 1 week (cherry picked from commit 28035f675b8590a24fddb418083788609ef75cc8) --- sys/amd64/linux/linux_proto.h | 55 +++++++++++++++ sys/amd64/linux/linux_syscall.h | 13 +++- sys/amd64/linux/linux_syscalls.c | 13 +++- sys/amd64/linux/linux_sysent.c | 13 +++- sys/amd64/linux/linux_systrace_args.c | 110 ++++++++++++++++++++++++++++++ sys/amd64/linux32/linux32_proto.h | 50 ++++++++++++++ sys/amd64/linux32/linux32_syscall.h | 12 +++- sys/amd64/linux32/linux32_syscalls.c | 12 +++- sys/amd64/linux32/linux32_sysent.c | 12 +++- sys/amd64/linux32/linux32_systrace_args.c | 100 +++++++++++++++++++++++++++ sys/arm64/linux/linux_proto.h | 50 ++++++++++++++ sys/arm64/linux/linux_syscall.h | 12 +++- sys/arm64/linux/linux_syscalls.c | 12 +++- sys/arm64/linux/linux_sysent.c | 12 +++- sys/arm64/linux/linux_systrace_args.c | 100 +++++++++++++++++++++++++++ sys/i386/linux/linux_proto.h | 50 ++++++++++++++ sys/i386/linux/linux_syscall.h | 12 +++- sys/i386/linux/linux_syscalls.c | 12 +++- sys/i386/linux/linux_sysent.c | 12 +++- sys/i386/linux/linux_systrace_args.c | 100 +++++++++++++++++++++++++++ 20 files changed, 750 insertions(+), 12 deletions(-) diff --git a/sys/amd64/linux/linux_proto.h b/sys/amd64/linux/linux_proto.h index 2a9dbf6fbe12..0759ce282499 100644 --- a/sys/amd64/linux/linux_proto.h +++ b/sys/amd64/linux/linux_proto.h @@ -1405,6 +1405,39 @@ struct linux_epoll_pwait2_args { struct linux_mount_setattr_args { syscallarg_t dummy; }; +struct linux_quotactl_fd_args { + syscallarg_t dummy; +}; +struct linux_landlock_create_ruleset_args { + syscallarg_t dummy; +}; +struct linux_landlock_add_rule_args { + syscallarg_t dummy; +}; +struct linux_landlock_restrict_self_args { + syscallarg_t dummy; +}; +struct linux_memfd_secret_args { + syscallarg_t dummy; +}; +struct linux_process_mrelease_args { + syscallarg_t dummy; +}; +struct linux_futex_waitv_args { + syscallarg_t dummy; +}; +struct linux_set_mempolicy_home_node_args { + syscallarg_t dummy; +}; +struct linux_cachestat_args { + syscallarg_t dummy; +}; +struct linux_fchmodat2_args { + syscallarg_t dummy; +}; +struct linux_map_shadow_stack_args { + syscallarg_t dummy; +}; #define nosys linux_nosys int linux_write(struct thread *, struct linux_write_args *); int linux_open(struct thread *, struct linux_open_args *); @@ -1705,6 +1738,17 @@ int linux_faccessat2(struct thread *, struct linux_faccessat2_args *); int linux_process_madvise(struct thread *, struct linux_process_madvise_args *); int linux_epoll_pwait2(struct thread *, struct linux_epoll_pwait2_args *); int linux_mount_setattr(struct thread *, struct linux_mount_setattr_args *); +int linux_quotactl_fd(struct thread *, struct linux_quotactl_fd_args *); +int linux_landlock_create_ruleset(struct thread *, struct linux_landlock_create_ruleset_args *); +int linux_landlock_add_rule(struct thread *, struct linux_landlock_add_rule_args *); +int linux_landlock_restrict_self(struct thread *, struct linux_landlock_restrict_self_args *); +int linux_memfd_secret(struct thread *, struct linux_memfd_secret_args *); +int linux_process_mrelease(struct thread *, struct linux_process_mrelease_args *); +int linux_futex_waitv(struct thread *, struct linux_futex_waitv_args *); +int linux_set_mempolicy_home_node(struct thread *, struct linux_set_mempolicy_home_node_args *); +int linux_cachestat(struct thread *, struct linux_cachestat_args *); +int linux_fchmodat2(struct thread *, struct linux_fchmodat2_args *); +int linux_map_shadow_stack(struct thread *, struct linux_map_shadow_stack_args *); #define LINUX_SYS_AUE_linux_write AUE_NULL #define LINUX_SYS_AUE_linux_open AUE_OPEN_RWTC #define LINUX_SYS_AUE_linux_newstat AUE_STAT @@ -2004,6 +2048,17 @@ int linux_mount_setattr(struct thread *, struct linux_mount_setattr_args *); #define LINUX_SYS_AUE_linux_process_madvise AUE_NULL #define LINUX_SYS_AUE_linux_epoll_pwait2 AUE_NULL #define LINUX_SYS_AUE_linux_mount_setattr AUE_NULL +#define LINUX_SYS_AUE_linux_quotactl_fd AUE_NULL +#define LINUX_SYS_AUE_linux_landlock_create_ruleset AUE_NULL +#define LINUX_SYS_AUE_linux_landlock_add_rule AUE_NULL +#define LINUX_SYS_AUE_linux_landlock_restrict_self AUE_NULL +#define LINUX_SYS_AUE_linux_memfd_secret AUE_NULL +#define LINUX_SYS_AUE_linux_process_mrelease AUE_NULL +#define LINUX_SYS_AUE_linux_futex_waitv AUE_NULL +#define LINUX_SYS_AUE_linux_set_mempolicy_home_node AUE_NULL +#define LINUX_SYS_AUE_linux_cachestat AUE_NULL +#define LINUX_SYS_AUE_linux_fchmodat2 AUE_NULL +#define LINUX_SYS_AUE_linux_map_shadow_stack AUE_NULL #undef PAD_ #undef PADL_ diff --git a/sys/amd64/linux/linux_syscall.h b/sys/amd64/linux/linux_syscall.h index 4755c673ab0f..efd3413f91ce 100644 --- a/sys/amd64/linux/linux_syscall.h +++ b/sys/amd64/linux/linux_syscall.h @@ -343,4 +343,15 @@ #define LINUX_SYS_linux_process_madvise 440 #define LINUX_SYS_linux_epoll_pwait2 441 #define LINUX_SYS_linux_mount_setattr 442 -#define LINUX_SYS_MAXSYSCALL 444 +#define LINUX_SYS_linux_quotactl_fd 443 +#define LINUX_SYS_linux_landlock_create_ruleset 444 +#define LINUX_SYS_linux_landlock_add_rule 445 +#define LINUX_SYS_linux_landlock_restrict_self 446 +#define LINUX_SYS_linux_memfd_secret 447 +#define LINUX_SYS_linux_process_mrelease 448 +#define LINUX_SYS_linux_futex_waitv 449 +#define LINUX_SYS_linux_set_mempolicy_home_node 450 +#define LINUX_SYS_linux_cachestat 451 +#define LINUX_SYS_linux_fchmodat2 452 +#define LINUX_SYS_linux_map_shadow_stack 453 +#define LINUX_SYS_MAXSYSCALL 455 diff --git a/sys/amd64/linux/linux_syscalls.c b/sys/amd64/linux/linux_syscalls.c index 201daec24f67..6851612ec749 100644 --- a/sys/amd64/linux/linux_syscalls.c +++ b/sys/amd64/linux/linux_syscalls.c @@ -449,5 +449,16 @@ const char *linux_syscallnames[] = { "linux_process_madvise", /* 440 = linux_process_madvise */ "linux_epoll_pwait2", /* 441 = linux_epoll_pwait2 */ "linux_mount_setattr", /* 442 = linux_mount_setattr */ - "#443", /* 443 = nosys */ + "linux_quotactl_fd", /* 443 = linux_quotactl_fd */ + "linux_landlock_create_ruleset", /* 444 = linux_landlock_create_ruleset */ + "linux_landlock_add_rule", /* 445 = linux_landlock_add_rule */ + "linux_landlock_restrict_self", /* 446 = linux_landlock_restrict_self */ + "linux_memfd_secret", /* 447 = linux_memfd_secret */ + "linux_process_mrelease", /* 448 = linux_process_mrelease */ + "linux_futex_waitv", /* 449 = linux_futex_waitv */ + "linux_set_mempolicy_home_node", /* 450 = linux_set_mempolicy_home_node */ + "linux_cachestat", /* 451 = linux_cachestat */ + "linux_fchmodat2", /* 452 = linux_fchmodat2 */ + "linux_map_shadow_stack", /* 453 = linux_map_shadow_stack */ + "#454", /* 454 = nosys */ }; diff --git a/sys/amd64/linux/linux_sysent.c b/sys/amd64/linux/linux_sysent.c index 694a22060125..ecb4ebb85b3a 100644 --- a/sys/amd64/linux/linux_sysent.c +++ b/sys/amd64/linux/linux_sysent.c @@ -459,5 +459,16 @@ struct sysent linux_sysent[] = { { .sy_narg = 0, .sy_call = (sy_call_t *)linux_process_madvise, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 440 = linux_process_madvise */ { .sy_narg = AS(linux_epoll_pwait2_args), .sy_call = (sy_call_t *)linux_epoll_pwait2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 441 = linux_epoll_pwait2 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_mount_setattr, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 442 = linux_mount_setattr */ - { .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 443 = nosys */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_quotactl_fd, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 443 = linux_quotactl_fd */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_landlock_create_ruleset, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 444 = linux_landlock_create_ruleset */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_landlock_add_rule, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 445 = linux_landlock_add_rule */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_landlock_restrict_self, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 446 = linux_landlock_restrict_self */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_memfd_secret, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 447 = linux_memfd_secret */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_process_mrelease, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 448 = linux_process_mrelease */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_futex_waitv, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 449 = linux_futex_waitv */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_set_mempolicy_home_node, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 450 = linux_set_mempolicy_home_node */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_cachestat, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 451 = linux_cachestat */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_fchmodat2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 452 = linux_fchmodat2 */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_map_shadow_stack, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 453 = linux_map_shadow_stack */ + { .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 454 = nosys */ }; diff --git a/sys/amd64/linux/linux_systrace_args.c b/sys/amd64/linux/linux_systrace_args.c index 9d53132063fa..2b0cf1df7e40 100644 --- a/sys/amd64/linux/linux_systrace_args.c +++ b/sys/amd64/linux/linux_systrace_args.c @@ -2751,6 +2751,61 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) *n_args = 0; break; } + /* linux_quotactl_fd */ + case 443: { + *n_args = 0; + break; + } + /* linux_landlock_create_ruleset */ + case 444: { + *n_args = 0; + break; + } + /* linux_landlock_add_rule */ + case 445: { + *n_args = 0; + break; + } + /* linux_landlock_restrict_self */ + case 446: { + *n_args = 0; + break; + } + /* linux_memfd_secret */ + case 447: { + *n_args = 0; + break; + } + /* linux_process_mrelease */ + case 448: { + *n_args = 0; + break; + } + /* linux_futex_waitv */ + case 449: { + *n_args = 0; + break; + } + /* linux_set_mempolicy_home_node */ + case 450: { + *n_args = 0; + break; + } + /* linux_cachestat */ + case 451: { + *n_args = 0; + break; + } + /* linux_fchmodat2 */ + case 452: { + *n_args = 0; + break; + } + /* linux_map_shadow_stack */ + case 453: { + *n_args = 0; + break; + } default: *n_args = 0; break; @@ -7181,6 +7236,39 @@ systrace_entry_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) /* linux_mount_setattr */ case 442: break; + /* linux_quotactl_fd */ + case 443: + break; + /* linux_landlock_create_ruleset */ + case 444: + break; + /* linux_landlock_add_rule */ + case 445: + break; + /* linux_landlock_restrict_self */ + case 446: + break; + /* linux_memfd_secret */ + case 447: + break; + /* linux_process_mrelease */ + case 448: + break; + /* linux_futex_waitv */ + case 449: + break; + /* linux_set_mempolicy_home_node */ + case 450: + break; + /* linux_cachestat */ + case 451: + break; + /* linux_fchmodat2 */ + case 452: + break; + /* linux_map_shadow_stack */ + case 453: + break; default: break; }; @@ -8681,6 +8769,28 @@ systrace_return_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_mount_setattr */ case 442: + /* linux_quotactl_fd */ + case 443: + /* linux_landlock_create_ruleset */ + case 444: + /* linux_landlock_add_rule */ + case 445: + /* linux_landlock_restrict_self */ + case 446: + /* linux_memfd_secret */ + case 447: + /* linux_process_mrelease */ + case 448: + /* linux_futex_waitv */ + case 449: + /* linux_set_mempolicy_home_node */ + case 450: + /* linux_cachestat */ + case 451: + /* linux_fchmodat2 */ + case 452: + /* linux_map_shadow_stack */ + case 453: default: break; }; diff --git a/sys/amd64/linux32/linux32_proto.h b/sys/amd64/linux32/linux32_proto.h index 8767199f2342..ae52fb81c560 100644 --- a/sys/amd64/linux32/linux32_proto.h +++ b/sys/amd64/linux32/linux32_proto.h @@ -1706,6 +1706,36 @@ struct linux_epoll_pwait2_64_args { struct linux_mount_setattr_args { syscallarg_t dummy; }; +struct linux_quotactl_fd_args { + syscallarg_t dummy; +}; +struct linux_landlock_create_ruleset_args { + syscallarg_t dummy; +}; +struct linux_landlock_add_rule_args { + syscallarg_t dummy; +}; +struct linux_landlock_restrict_self_args { + syscallarg_t dummy; +}; +struct linux_memfd_secret_args { + syscallarg_t dummy; +}; +struct linux_process_mrelease_args { + syscallarg_t dummy; +}; +struct linux_futex_waitv_args { + syscallarg_t dummy; +}; +struct linux_set_mempolicy_home_node_args { + syscallarg_t dummy; +}; +struct linux_cachestat_args { + syscallarg_t dummy; +}; +struct linux_fchmodat2_args { + syscallarg_t dummy; +}; #define nosys linux_nosys int linux_exit(struct thread *, struct linux_exit_args *); int linux_fork(struct thread *, struct linux_fork_args *); @@ -2071,6 +2101,16 @@ int linux_faccessat2(struct thread *, struct linux_faccessat2_args *); int linux_process_madvise(struct thread *, struct linux_process_madvise_args *); int linux_epoll_pwait2_64(struct thread *, struct linux_epoll_pwait2_64_args *); int linux_mount_setattr(struct thread *, struct linux_mount_setattr_args *); +int linux_quotactl_fd(struct thread *, struct linux_quotactl_fd_args *); +int linux_landlock_create_ruleset(struct thread *, struct linux_landlock_create_ruleset_args *); +int linux_landlock_add_rule(struct thread *, struct linux_landlock_add_rule_args *); +int linux_landlock_restrict_self(struct thread *, struct linux_landlock_restrict_self_args *); +int linux_memfd_secret(struct thread *, struct linux_memfd_secret_args *); +int linux_process_mrelease(struct thread *, struct linux_process_mrelease_args *); +int linux_futex_waitv(struct thread *, struct linux_futex_waitv_args *); +int linux_set_mempolicy_home_node(struct thread *, struct linux_set_mempolicy_home_node_args *); +int linux_cachestat(struct thread *, struct linux_cachestat_args *); +int linux_fchmodat2(struct thread *, struct linux_fchmodat2_args *); #define LINUX32_SYS_AUE_linux_exit AUE_EXIT #define LINUX32_SYS_AUE_linux_fork AUE_FORK #define LINUX32_SYS_AUE_linux_write AUE_NULL @@ -2435,6 +2475,16 @@ int linux_mount_setattr(struct thread *, struct linux_mount_setattr_args *); #define LINUX32_SYS_AUE_linux_process_madvise AUE_NULL #define LINUX32_SYS_AUE_linux_epoll_pwait2_64 AUE_NULL #define LINUX32_SYS_AUE_linux_mount_setattr AUE_NULL +#define LINUX32_SYS_AUE_linux_quotactl_fd AUE_NULL +#define LINUX32_SYS_AUE_linux_landlock_create_ruleset AUE_NULL +#define LINUX32_SYS_AUE_linux_landlock_add_rule AUE_NULL +#define LINUX32_SYS_AUE_linux_landlock_restrict_self AUE_NULL +#define LINUX32_SYS_AUE_linux_memfd_secret AUE_NULL +#define LINUX32_SYS_AUE_linux_process_mrelease AUE_NULL +#define LINUX32_SYS_AUE_linux_futex_waitv AUE_NULL +#define LINUX32_SYS_AUE_linux_set_mempolicy_home_node AUE_NULL +#define LINUX32_SYS_AUE_linux_cachestat AUE_NULL +#define LINUX32_SYS_AUE_linux_fchmodat2 AUE_NULL #undef PAD_ #undef PADL_ diff --git a/sys/amd64/linux32/linux32_syscall.h b/sys/amd64/linux32/linux32_syscall.h index e24080e3c2e7..b6d74578cdfd 100644 --- a/sys/amd64/linux32/linux32_syscall.h +++ b/sys/amd64/linux32/linux32_syscall.h @@ -403,4 +403,14 @@ #define LINUX32_SYS_linux_process_madvise 440 #define LINUX32_SYS_linux_epoll_pwait2_64 441 #define LINUX32_SYS_linux_mount_setattr 442 -#define LINUX32_SYS_MAXSYSCALL 444 +#define LINUX32_SYS_linux_quotactl_fd 443 +#define LINUX32_SYS_linux_landlock_create_ruleset 444 +#define LINUX32_SYS_linux_landlock_add_rule 445 +#define LINUX32_SYS_linux_landlock_restrict_self 446 +#define LINUX32_SYS_linux_memfd_secret 447 +#define LINUX32_SYS_linux_process_mrelease 448 +#define LINUX32_SYS_linux_futex_waitv 449 +#define LINUX32_SYS_linux_set_mempolicy_home_node 450 +#define LINUX32_SYS_linux_cachestat 451 +#define LINUX32_SYS_linux_fchmodat2 452 +#define LINUX32_SYS_MAXSYSCALL 454 diff --git a/sys/amd64/linux32/linux32_syscalls.c b/sys/amd64/linux32/linux32_syscalls.c index cdeda60a1577..3f1e0425e224 100644 --- a/sys/amd64/linux32/linux32_syscalls.c +++ b/sys/amd64/linux32/linux32_syscalls.c @@ -449,5 +449,15 @@ const char *linux32_syscallnames[] = { "linux_process_madvise", /* 440 = linux_process_madvise */ "linux_epoll_pwait2_64", /* 441 = linux_epoll_pwait2_64 */ "linux_mount_setattr", /* 442 = linux_mount_setattr */ - "#443", /* 443 = nosys */ + "linux_quotactl_fd", /* 443 = linux_quotactl_fd */ + "linux_landlock_create_ruleset", /* 444 = linux_landlock_create_ruleset */ + "linux_landlock_add_rule", /* 445 = linux_landlock_add_rule */ + "linux_landlock_restrict_self", /* 446 = linux_landlock_restrict_self */ + "linux_memfd_secret", /* 447 = linux_memfd_secret */ + "linux_process_mrelease", /* 448 = linux_process_mrelease */ + "linux_futex_waitv", /* 449 = linux_futex_waitv */ + "linux_set_mempolicy_home_node", /* 450 = linux_set_mempolicy_home_node */ + "linux_cachestat", /* 451 = linux_cachestat */ + "linux_fchmodat2", /* 452 = linux_fchmodat2 */ + "#453", /* 453 = nosys */ }; diff --git a/sys/amd64/linux32/linux32_sysent.c b/sys/amd64/linux32/linux32_sysent.c index a3570b9bfe5b..c1656a124026 100644 --- a/sys/amd64/linux32/linux32_sysent.c +++ b/sys/amd64/linux32/linux32_sysent.c @@ -460,5 +460,15 @@ struct sysent linux32_sysent[] = { { .sy_narg = 0, .sy_call = (sy_call_t *)linux_process_madvise, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 440 = linux_process_madvise */ { .sy_narg = AS(linux_epoll_pwait2_64_args), .sy_call = (sy_call_t *)linux_epoll_pwait2_64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 441 = linux_epoll_pwait2_64 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_mount_setattr, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 442 = linux_mount_setattr */ - { .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 443 = nosys */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_quotactl_fd, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 443 = linux_quotactl_fd */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_landlock_create_ruleset, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 444 = linux_landlock_create_ruleset */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_landlock_add_rule, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 445 = linux_landlock_add_rule */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_landlock_restrict_self, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 446 = linux_landlock_restrict_self */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_memfd_secret, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 447 = linux_memfd_secret */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_process_mrelease, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 448 = linux_process_mrelease */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_futex_waitv, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 449 = linux_futex_waitv */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_set_mempolicy_home_node, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 450 = linux_set_mempolicy_home_node */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_cachestat, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 451 = linux_cachestat */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_fchmodat2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 452 = linux_fchmodat2 */ + { .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 453 = nosys */ }; diff --git a/sys/amd64/linux32/linux32_systrace_args.c b/sys/amd64/linux32/linux32_systrace_args.c index de00b970027b..29940f4ed8a3 100644 --- a/sys/amd64/linux32/linux32_systrace_args.c +++ b/sys/amd64/linux32/linux32_systrace_args.c @@ -3265,6 +3265,56 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) *n_args = 0; break; } + /* linux_quotactl_fd */ + case 443: { + *n_args = 0; + break; + } + /* linux_landlock_create_ruleset */ + case 444: { + *n_args = 0; + break; + } + /* linux_landlock_add_rule */ + case 445: { + *n_args = 0; + break; + } + /* linux_landlock_restrict_self */ + case 446: { + *n_args = 0; + break; + } + /* linux_memfd_secret */ + case 447: { + *n_args = 0; + break; + } + /* linux_process_mrelease */ + case 448: { + *n_args = 0; + break; + } + /* linux_futex_waitv */ + case 449: { + *n_args = 0; + break; + } + /* linux_set_mempolicy_home_node */ + case 450: { + *n_args = 0; + break; + } + /* linux_cachestat */ + case 451: { + *n_args = 0; + break; + } + /* linux_fchmodat2 */ + case 452: { + *n_args = 0; + break; + } default: *n_args = 0; break; @@ -8560,6 +8610,36 @@ systrace_entry_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) /* linux_mount_setattr */ case 442: break; + /* linux_quotactl_fd */ + case 443: + break; + /* linux_landlock_create_ruleset */ + case 444: + break; + /* linux_landlock_add_rule */ + case 445: + break; + /* linux_landlock_restrict_self */ + case 446: + break; + /* linux_memfd_secret */ + case 447: + break; + /* linux_process_mrelease */ + case 448: + break; + /* linux_futex_waitv */ + case 449: + break; + /* linux_set_mempolicy_home_node */ + case 450: + break; + /* linux_cachestat */ + case 451: + break; + /* linux_fchmodat2 */ + case 452: + break; default: break; }; @@ -10347,6 +10427,26 @@ systrace_return_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_mount_setattr */ case 442: + /* linux_quotactl_fd */ + case 443: + /* linux_landlock_create_ruleset */ + case 444: + /* linux_landlock_add_rule */ + case 445: + /* linux_landlock_restrict_self */ + case 446: + /* linux_memfd_secret */ + case 447: + /* linux_process_mrelease */ + case 448: + /* linux_futex_waitv */ + case 449: + /* linux_set_mempolicy_home_node */ + case 450: + /* linux_cachestat */ + case 451: + /* linux_fchmodat2 */ + case 452: default: break; }; diff --git a/sys/arm64/linux/linux_proto.h b/sys/arm64/linux/linux_proto.h index f24b7f25669d..d002ad5a824f 100644 --- a/sys/arm64/linux/linux_proto.h +++ b/sys/arm64/linux/linux_proto.h @@ -1215,6 +1215,36 @@ struct linux_epoll_pwait2_args { struct linux_mount_setattr_args { syscallarg_t dummy; }; +struct linux_quotactl_fd_args { + syscallarg_t dummy; +}; +struct linux_landlock_create_ruleset_args { + syscallarg_t dummy; +}; +struct linux_landlock_add_rule_args { + syscallarg_t dummy; +}; +struct linux_landlock_restrict_self_args { + syscallarg_t dummy; +}; +struct linux_memfd_secret_args { + syscallarg_t dummy; +}; +struct linux_process_mrelease_args { + syscallarg_t dummy; +}; +struct linux_futex_waitv_args { + syscallarg_t dummy; +}; +struct linux_set_mempolicy_home_node_args { + syscallarg_t dummy; +}; +struct linux_cachestat_args { + syscallarg_t dummy; +}; +struct linux_fchmodat2_args { + syscallarg_t dummy; +}; #define nosys linux_nosys int linux_setxattr(struct thread *, struct linux_setxattr_args *); int linux_lsetxattr(struct thread *, struct linux_lsetxattr_args *); @@ -1466,6 +1496,16 @@ int linux_faccessat2(struct thread *, struct linux_faccessat2_args *); int linux_process_madvise(struct thread *, struct linux_process_madvise_args *); int linux_epoll_pwait2(struct thread *, struct linux_epoll_pwait2_args *); int linux_mount_setattr(struct thread *, struct linux_mount_setattr_args *); +int linux_quotactl_fd(struct thread *, struct linux_quotactl_fd_args *); +int linux_landlock_create_ruleset(struct thread *, struct linux_landlock_create_ruleset_args *); +int linux_landlock_add_rule(struct thread *, struct linux_landlock_add_rule_args *); +int linux_landlock_restrict_self(struct thread *, struct linux_landlock_restrict_self_args *); +int linux_memfd_secret(struct thread *, struct linux_memfd_secret_args *); +int linux_process_mrelease(struct thread *, struct linux_process_mrelease_args *); +int linux_futex_waitv(struct thread *, struct linux_futex_waitv_args *); +int linux_set_mempolicy_home_node(struct thread *, struct linux_set_mempolicy_home_node_args *); +int linux_cachestat(struct thread *, struct linux_cachestat_args *); +int linux_fchmodat2(struct thread *, struct linux_fchmodat2_args *); #define LINUX_SYS_AUE_linux_setxattr AUE_NULL #define LINUX_SYS_AUE_linux_lsetxattr AUE_NULL #define LINUX_SYS_AUE_linux_fsetxattr AUE_NULL @@ -1716,6 +1756,16 @@ int linux_mount_setattr(struct thread *, struct linux_mount_setattr_args *); #define LINUX_SYS_AUE_linux_process_madvise AUE_NULL #define LINUX_SYS_AUE_linux_epoll_pwait2 AUE_NULL #define LINUX_SYS_AUE_linux_mount_setattr AUE_NULL +#define LINUX_SYS_AUE_linux_quotactl_fd AUE_NULL +#define LINUX_SYS_AUE_linux_landlock_create_ruleset AUE_NULL +#define LINUX_SYS_AUE_linux_landlock_add_rule AUE_NULL +#define LINUX_SYS_AUE_linux_landlock_restrict_self AUE_NULL +#define LINUX_SYS_AUE_linux_memfd_secret AUE_NULL +#define LINUX_SYS_AUE_linux_process_mrelease AUE_NULL +#define LINUX_SYS_AUE_linux_futex_waitv AUE_NULL +#define LINUX_SYS_AUE_linux_set_mempolicy_home_node AUE_NULL +#define LINUX_SYS_AUE_linux_cachestat AUE_NULL +#define LINUX_SYS_AUE_linux_fchmodat2 AUE_NULL #undef PAD_ #undef PADL_ diff --git a/sys/arm64/linux/linux_syscall.h b/sys/arm64/linux/linux_syscall.h index f331bec5dc4f..c45f3ded47a2 100644 --- a/sys/arm64/linux/linux_syscall.h +++ b/sys/arm64/linux/linux_syscall.h @@ -291,4 +291,14 @@ #define LINUX_SYS_linux_process_madvise 440 #define LINUX_SYS_linux_epoll_pwait2 441 #define LINUX_SYS_linux_mount_setattr 442 -#define LINUX_SYS_MAXSYSCALL 444 +#define LINUX_SYS_linux_quotactl_fd 443 +#define LINUX_SYS_linux_landlock_create_ruleset 444 +#define LINUX_SYS_linux_landlock_add_rule 445 +#define LINUX_SYS_linux_landlock_restrict_self 446 +#define LINUX_SYS_linux_memfd_secret 447 +#define LINUX_SYS_linux_process_mrelease 448 +#define LINUX_SYS_linux_futex_waitv 449 +#define LINUX_SYS_linux_set_mempolicy_home_node 450 +#define LINUX_SYS_linux_cachestat 451 +#define LINUX_SYS_linux_fchmodat2 452 +#define LINUX_SYS_MAXSYSCALL 454 diff --git a/sys/arm64/linux/linux_syscalls.c b/sys/arm64/linux/linux_syscalls.c index 8bf57f971c54..81fed4cc0227 100644 --- a/sys/arm64/linux/linux_syscalls.c +++ b/sys/arm64/linux/linux_syscalls.c @@ -449,5 +449,15 @@ const char *linux_syscallnames[] = { "linux_process_madvise", /* 440 = linux_process_madvise */ "linux_epoll_pwait2", /* 441 = linux_epoll_pwait2 */ "linux_mount_setattr", /* 442 = linux_mount_setattr */ - "#443", /* 443 = nosys */ + "linux_quotactl_fd", /* 443 = linux_quotactl_fd */ + "linux_landlock_create_ruleset", /* 444 = linux_landlock_create_ruleset */ + "linux_landlock_add_rule", /* 445 = linux_landlock_add_rule */ + "linux_landlock_restrict_self", /* 446 = linux_landlock_restrict_self */ + "linux_memfd_secret", /* 447 = linux_memfd_secret */ + "linux_process_mrelease", /* 448 = linux_process_mrelease */ + "linux_futex_waitv", /* 449 = linux_futex_waitv */ + "linux_set_mempolicy_home_node", /* 450 = linux_set_mempolicy_home_node */ + "linux_cachestat", /* 451 = linux_cachestat */ + "linux_fchmodat2", /* 452 = linux_fchmodat2 */ + "#453", /* 453 = nosys */ }; diff --git a/sys/arm64/linux/linux_sysent.c b/sys/arm64/linux/linux_sysent.c index 3bc2e2ad96d9..c0b495482040 100644 --- a/sys/arm64/linux/linux_sysent.c +++ b/sys/arm64/linux/linux_sysent.c @@ -459,5 +459,15 @@ struct sysent linux_sysent[] = { { .sy_narg = 0, .sy_call = (sy_call_t *)linux_process_madvise, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 440 = linux_process_madvise */ { .sy_narg = AS(linux_epoll_pwait2_args), .sy_call = (sy_call_t *)linux_epoll_pwait2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 441 = linux_epoll_pwait2 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_mount_setattr, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 442 = linux_mount_setattr */ - { .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 443 = nosys */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_quotactl_fd, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 443 = linux_quotactl_fd */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_landlock_create_ruleset, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 444 = linux_landlock_create_ruleset */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_landlock_add_rule, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 445 = linux_landlock_add_rule */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_landlock_restrict_self, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 446 = linux_landlock_restrict_self */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_memfd_secret, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 447 = linux_memfd_secret */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_process_mrelease, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 448 = linux_process_mrelease */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_futex_waitv, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 449 = linux_futex_waitv */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_set_mempolicy_home_node, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 450 = linux_set_mempolicy_home_node */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_cachestat, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 451 = linux_cachestat */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_fchmodat2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 452 = linux_fchmodat2 */ + { .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 453 = nosys */ }; diff --git a/sys/arm64/linux/linux_systrace_args.c b/sys/arm64/linux/linux_systrace_args.c index 60daffbb420f..ff58a287ee88 100644 --- a/sys/arm64/linux/linux_systrace_args.c +++ b/sys/arm64/linux/linux_systrace_args.c @@ -2373,6 +2373,56 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) *n_args = 0; break; } + /* linux_quotactl_fd */ + case 443: { + *n_args = 0; + break; + } + /* linux_landlock_create_ruleset */ + case 444: { + *n_args = 0; + break; + } + /* linux_landlock_add_rule */ + case 445: { + *n_args = 0; + break; + } + /* linux_landlock_restrict_self */ + case 446: { + *n_args = 0; + break; + } + /* linux_memfd_secret */ + case 447: { + *n_args = 0; + break; + } + /* linux_process_mrelease */ + case 448: { + *n_args = 0; + break; + } + /* linux_futex_waitv */ + case 449: { + *n_args = 0; + break; + } + /* linux_set_mempolicy_home_node */ + case 450: { + *n_args = 0; + break; + } + /* linux_cachestat */ + case 451: { + *n_args = 0; + break; + } + /* linux_fchmodat2 */ + case 452: { + *n_args = 0; + break; + } default: *n_args = 0; break; @@ -6256,6 +6306,36 @@ systrace_entry_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) /* linux_mount_setattr */ case 442: break; + /* linux_quotactl_fd */ + case 443: + break; + /* linux_landlock_create_ruleset */ + case 444: + break; + /* linux_landlock_add_rule */ + case 445: + break; + /* linux_landlock_restrict_self */ + case 446: + break; + /* linux_memfd_secret */ + case 447: + break; + /* linux_process_mrelease */ + case 448: + break; + /* linux_futex_waitv */ + case 449: + break; + /* linux_set_mempolicy_home_node */ + case 450: + break; + /* linux_cachestat */ + case 451: + break; + /* linux_fchmodat2 */ + case 452: + break; default: break; }; @@ -7541,6 +7621,26 @@ systrace_return_setargdesc(int sysnum, int ndx, char *desc, size_t descsz) break; /* linux_mount_setattr */ case 442: + /* linux_quotactl_fd */ + case 443: + /* linux_landlock_create_ruleset */ + case 444: + /* linux_landlock_add_rule */ + case 445: + /* linux_landlock_restrict_self */ + case 446: + /* linux_memfd_secret */ + case 447: + /* linux_process_mrelease */ + case 448: + /* linux_futex_waitv */ + case 449: + /* linux_set_mempolicy_home_node */ + case 450: + /* linux_cachestat */ + case 451: + /* linux_fchmodat2 */ + case 452: default: break; }; diff --git a/sys/i386/linux/linux_proto.h b/sys/i386/linux/linux_proto.h index 5baec9364d5b..6cbab6b1e8d8 100644 --- a/sys/i386/linux/linux_proto.h +++ b/sys/i386/linux/linux_proto.h @@ -1700,6 +1700,36 @@ struct linux_epoll_pwait2_64_args { struct linux_mount_setattr_args { syscallarg_t dummy; }; +struct linux_quotactl_fd_args { + syscallarg_t dummy; +}; +struct linux_landlock_create_ruleset_args { + syscallarg_t dummy; +}; +struct linux_landlock_add_rule_args { + syscallarg_t dummy; +}; +struct linux_landlock_restrict_self_args { + syscallarg_t dummy; +}; +struct linux_memfd_secret_args { + syscallarg_t dummy; +}; +struct linux_process_mrelease_args { + syscallarg_t dummy; +}; +struct linux_futex_waitv_args { + syscallarg_t dummy; +}; +struct linux_set_mempolicy_home_node_args { + syscallarg_t dummy; +}; +struct linux_cachestat_args { + syscallarg_t dummy; +}; +struct linux_fchmodat2_args { + syscallarg_t dummy; +}; #define nosys linux_nosys int linux_exit(struct thread *, struct linux_exit_args *); int linux_fork(struct thread *, struct linux_fork_args *); @@ -2067,6 +2097,16 @@ int linux_faccessat2(struct thread *, struct linux_faccessat2_args *); int linux_process_madvise(struct thread *, struct linux_process_madvise_args *); int linux_epoll_pwait2_64(struct thread *, struct linux_epoll_pwait2_64_args *); int linux_mount_setattr(struct thread *, struct linux_mount_setattr_args *); +int linux_quotactl_fd(struct thread *, struct linux_quotactl_fd_args *); +int linux_landlock_create_ruleset(struct thread *, struct linux_landlock_create_ruleset_args *); +int linux_landlock_add_rule(struct thread *, struct linux_landlock_add_rule_args *); +int linux_landlock_restrict_self(struct thread *, struct linux_landlock_restrict_self_args *); +int linux_memfd_secret(struct thread *, struct linux_memfd_secret_args *); +int linux_process_mrelease(struct thread *, struct linux_process_mrelease_args *); +int linux_futex_waitv(struct thread *, struct linux_futex_waitv_args *); +int linux_set_mempolicy_home_node(struct thread *, struct linux_set_mempolicy_home_node_args *); +int linux_cachestat(struct thread *, struct linux_cachestat_args *); +int linux_fchmodat2(struct thread *, struct linux_fchmodat2_args *); #define LINUX_SYS_AUE_linux_exit AUE_EXIT #define LINUX_SYS_AUE_linux_fork AUE_FORK #define LINUX_SYS_AUE_linux_write AUE_NULL @@ -2433,6 +2473,16 @@ int linux_mount_setattr(struct thread *, struct linux_mount_setattr_args *); #define LINUX_SYS_AUE_linux_process_madvise AUE_NULL #define LINUX_SYS_AUE_linux_epoll_pwait2_64 AUE_NULL #define LINUX_SYS_AUE_linux_mount_setattr AUE_NULL +#define LINUX_SYS_AUE_linux_quotactl_fd AUE_NULL +#define LINUX_SYS_AUE_linux_landlock_create_ruleset AUE_NULL +#define LINUX_SYS_AUE_linux_landlock_add_rule AUE_NULL +#define LINUX_SYS_AUE_linux_landlock_restrict_self AUE_NULL +#define LINUX_SYS_AUE_linux_memfd_secret AUE_NULL +#define LINUX_SYS_AUE_linux_process_mrelease AUE_NULL +#define LINUX_SYS_AUE_linux_futex_waitv AUE_NULL +#define LINUX_SYS_AUE_linux_set_mempolicy_home_node AUE_NULL +#define LINUX_SYS_AUE_linux_cachestat AUE_NULL +#define LINUX_SYS_AUE_linux_fchmodat2 AUE_NULL #undef PAD_ #undef PADL_ diff --git a/sys/i386/linux/linux_syscall.h b/sys/i386/linux/linux_syscall.h index 96aa0fbc1815..19b1714fb5d9 100644 --- a/sys/i386/linux/linux_syscall.h +++ b/sys/i386/linux/linux_syscall.h @@ -409,4 +409,14 @@ #define LINUX_SYS_linux_process_madvise 440 #define LINUX_SYS_linux_epoll_pwait2_64 441 #define LINUX_SYS_linux_mount_setattr 442 -#define LINUX_SYS_MAXSYSCALL 444 +#define LINUX_SYS_linux_quotactl_fd 443 +#define LINUX_SYS_linux_landlock_create_ruleset 444 +#define LINUX_SYS_linux_landlock_add_rule 445 +#define LINUX_SYS_linux_landlock_restrict_self 446 +#define LINUX_SYS_linux_memfd_secret 447 +#define LINUX_SYS_linux_process_mrelease 448 +#define LINUX_SYS_linux_futex_waitv 449 +#define LINUX_SYS_linux_set_mempolicy_home_node 450 +#define LINUX_SYS_linux_cachestat 451 +#define LINUX_SYS_linux_fchmodat2 452 +#define LINUX_SYS_MAXSYSCALL 454 diff --git a/sys/i386/linux/linux_syscalls.c b/sys/i386/linux/linux_syscalls.c index ebb3fafca78d..112e6505bd00 100644 --- a/sys/i386/linux/linux_syscalls.c +++ b/sys/i386/linux/linux_syscalls.c @@ -449,5 +449,15 @@ const char *linux_syscallnames[] = { "linux_process_madvise", /* 440 = linux_process_madvise */ "linux_epoll_pwait2_64", /* 441 = linux_epoll_pwait2_64 */ "linux_mount_setattr", /* 442 = linux_mount_setattr */ - "#443", /* 443 = nosys */ + "linux_quotactl_fd", /* 443 = linux_quotactl_fd */ + "linux_landlock_create_ruleset", /* 444 = linux_landlock_create_ruleset */ + "linux_landlock_add_rule", /* 445 = linux_landlock_add_rule */ + "linux_landlock_restrict_self", /* 446 = linux_landlock_restrict_self */ + "linux_memfd_secret", /* 447 = linux_memfd_secret */ + "linux_process_mrelease", /* 448 = linux_process_mrelease */ + "linux_futex_waitv", /* 449 = linux_futex_waitv */ + "linux_set_mempolicy_home_node", /* 450 = linux_set_mempolicy_home_node */ + "linux_cachestat", /* 451 = linux_cachestat */ + "linux_fchmodat2", /* 452 = linux_fchmodat2 */ + "#453", /* 453 = nosys */ }; diff --git a/sys/i386/linux/linux_sysent.c b/sys/i386/linux/linux_sysent.c index c293f2173e8c..5aa7f4921774 100644 --- a/sys/i386/linux/linux_sysent.c +++ b/sys/i386/linux/linux_sysent.c @@ -459,5 +459,15 @@ struct sysent linux_sysent[] = { { .sy_narg = 0, .sy_call = (sy_call_t *)linux_process_madvise, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 440 = linux_process_madvise */ { .sy_narg = AS(linux_epoll_pwait2_64_args), .sy_call = (sy_call_t *)linux_epoll_pwait2_64, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 441 = linux_epoll_pwait2_64 */ { .sy_narg = 0, .sy_call = (sy_call_t *)linux_mount_setattr, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 442 = linux_mount_setattr */ - { .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 443 = nosys */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_quotactl_fd, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 443 = linux_quotactl_fd */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_landlock_create_ruleset, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 444 = linux_landlock_create_ruleset */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_landlock_add_rule, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 445 = linux_landlock_add_rule */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_landlock_restrict_self, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 446 = linux_landlock_restrict_self */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_memfd_secret, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 447 = linux_memfd_secret */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_process_mrelease, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 448 = linux_process_mrelease */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_futex_waitv, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 449 = linux_futex_waitv */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_set_mempolicy_home_node, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 450 = linux_set_mempolicy_home_node */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_cachestat, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 451 = linux_cachestat */ + { .sy_narg = 0, .sy_call = (sy_call_t *)linux_fchmodat2, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_STATIC }, /* 452 = linux_fchmodat2 */ + { .sy_narg = 0, .sy_call = (sy_call_t *)nosys, .sy_auevent = AUE_NULL, .sy_flags = 0, .sy_thrcnt = SY_THR_ABSENT }, /* 453 = nosys */ }; diff --git a/sys/i386/linux/linux_systrace_args.c b/sys/i386/linux/linux_systrace_args.c index 0bd681c68b6c..76781af18124 100644 --- a/sys/i386/linux/linux_systrace_args.c +++ b/sys/i386/linux/linux_systrace_args.c @@ -3296,6 +3296,56 @@ systrace_args(int sysnum, void *params, uint64_t *uarg, int *n_args) *n_args = 0; break; } *** 117 LINES SKIPPED *** From nobody Mon Oct 2 08:15:37 2023 X-Original-To: dev-commits-src-branches@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 4RzYfx69gtz4vlYq; Mon, 2 Oct 2023 08:15: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzYfx5Cwsz4J7R; Mon, 2 Oct 2023 08:15:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696234537; 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=4k/e29lN2GBPyFdEArsnSMvjsc4Fde3uOE/Eumk/WKM=; b=Bc2wZY87IfCsrQ9Gt57xVjqur8/o5oe6FWYNVPoTuu0yUASIIUNUVj7d5MWAKVKB8cQ1rl jE5TbCdI13mj6PdU1++Acvx3muZTKm9TTYqIDH+SKULgHzi8UTT85PBChaD23U/B+A0uFG gHDBl/PGS58svyG9r59XPdeUxxN3Hr2gNFi6dI5tVYQFyvmxE9fjQxteakyYaZxK9320F0 plL0Az1YBXMx75CoOzR/wCDSJAFfakBP51wpFRFPbjfL9xODY8i6eVg5Z6mBMcH/oBIFpD aIF1EtvnrRqSm+A9H079CPsiknqL+mqrzxZ5vy45Kp43deGl8dGWvkLFa1tLmA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696234537; a=rsa-sha256; cv=none; b=sGf/1pnXJHO14QltkouhlDy31v4ByqVcGl76dOaFHoqdl35tjWqqWzz8c9MwIYpFigWOuw JwDLpVGWzIZLGWZIgCCcterWlvcACmbCdUsjYxDryBUfuF4rp1Fs9yQPPPeBv5nk46+GVm 75kRuLZNP2QrbPEsnJMeNVd8KTrJ697OpSAFrQOL1HvoLiyZ59/CoY+m7yibTicC1taINA VBQt/Qvg6sBy5nSBxMYiiZOLsMFCWrCZ74K4GFqVejonP4z0miZ2HImfJ50vwUj09Cwigy U5YlQwMl+8iZM1b+vVmu1/hAqjjuxKvq3+Mo47i0NbkxmJ7CFTxrxvtVBQMN3Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696234537; 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=4k/e29lN2GBPyFdEArsnSMvjsc4Fde3uOE/Eumk/WKM=; b=iHnYGVJVrU4/iOBvOtY4a4Cag/RSOFF+tdbIhOoOTrQ6qvOO1YLnb/P2cFIf54aJX0Gohw vYrbqbh9rriPoYkBumOHvv7DT75ZXNAfYyMmC82FySCsFAyZa0tJiXy06PNLugN5j1TB/z xMIeDrIoikBcIy2fQsH19LzhJXkdrthVsxx2KxwtRRTjNoXzPE7yu2W8FZ2mHYJs3vjt0m krX/F2CVQdoSPBStUxIxh5R05c8XBNG10X+Md5/v2SnDM5OGMrPK4UMjm6Y2I0PmbJCXNO YaLcA5w3ABB/tnLzYb4eli0kgI/meQVaSxMzuShf56pbyg53q40x/htPvybFXw== 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 4RzYfx4GWKz144t; Mon, 2 Oct 2023 08:15:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3928FbLV068988; Mon, 2 Oct 2023 08:15:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3928Fb40068985; Mon, 2 Oct 2023 08:15:37 GMT (envelope-from git) Date: Mon, 2 Oct 2023 08:15:37 GMT Message-Id: <202310020815.3928Fb40068985@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mariusz Zaborski Subject: git: 87d68b131ef6 - stable/14 - copy_file_range: require CAP_SEEK capability List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: oshogbo X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 87d68b131ef65a0a5fb897280359e46067064a53 Auto-Submitted: auto-generated The branch stable/14 has been updated by oshogbo: URL: https://cgit.FreeBSD.org/src/commit/?id=87d68b131ef65a0a5fb897280359e46067064a53 commit 87d68b131ef65a0a5fb897280359e46067064a53 Author: Mariusz Zaborski AuthorDate: 2023-09-28 13:24:39 +0000 Commit: Mariusz Zaborski CommitDate: 2023-10-02 08:16:24 +0000 copy_file_range: require CAP_SEEK capability When using copy_file_range(2) with an offset parameter, the CAP_SEEK capability should be required. This requirement is similar to the behavior observed with pread(2)/pwrite(2). Reported by: theraven Reviewed by: emaste, theraven, kib, markj Approved by: secteam Differential Revision: https://reviews.freebsd.org/D41967 (cherry picked from commit 15a51d3abaef27ddea66320cac7caa549738a1a6) --- sys/kern/vfs_syscalls.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 06b861a2eb73..9d85a295a6ef 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -4899,7 +4899,8 @@ kern_copy_file_range(struct thread *td, int infd, off_t *inoffp, int outfd, len = SSIZE_MAX; /* Get the file structures for the file descriptors. */ - error = fget_read(td, infd, &cap_read_rights, &infp); + error = fget_read(td, infd, + inoffp != NULL ? &cap_pread_rights : &cap_read_rights, &infp); if (error != 0) goto out; if (infp->f_ops == &badfileops) { @@ -4910,7 +4911,8 @@ kern_copy_file_range(struct thread *td, int infd, off_t *inoffp, int outfd, error = EINVAL; goto out; } - error = fget_write(td, outfd, &cap_write_rights, &outfp); + error = fget_write(td, outfd, + outoffp != NULL ? &cap_pwrite_rights : &cap_write_rights, &outfp); if (error != 0) goto out; if (outfp->f_ops == &badfileops) { From nobody Mon Oct 2 08:17:18 2023 X-Original-To: dev-commits-src-branches@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 4RzYhv2Fwqz4vmDC; Mon, 2 Oct 2023 08:17: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzYhv1dnrz4JHj; Mon, 2 Oct 2023 08:17:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696234639; 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=jzyfAB80UcPFmXz7kgpg6POlYPSV77eQ7WLuQerPxQE=; b=dOvq1D6GBtp2tRGChSiXzlVCmD5yqOrU7Z5HYrQM4OgL+b8US6/0O9gbaGK7UJ0XfUibKn Pf+v9yhRDnVuKJaFYFh31oRT3xdfgS9rDlr1+W1ngKMxdR88cha1Bx2TD/1sqUA1HJ1ptK qjJc24dgc+9kItRrxy5vpKrQjr1uLxPEzu+63DrSW7kVvX+51a5QvKCuGJDMK1UN/MxbdN EN7NYNmWVcEuKWthFgrSKDEZXE17VncBlPWg9mchmpHeoBchn2GWGP6cUogfYAc1CBCxlC uJf1g8hftbrUl7hDoU4fDET2t5woZp/jODdki04frXJJsMYwXHJWcvgdD2NoAQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696234639; a=rsa-sha256; cv=none; b=VUebLNiw7Hhh5vMWOQLjIrLlKwZDhsMwWRlUctGk10cAFlusfnSa3YPNo6vCY91RIwZ2qk P/QYx4NyfZ7LyvXK7UYCyfx5M/ZwbhvG2HhaWiTBK1A0DK+f5gv2OdOcMy55qBwESgGx94 eVpDB/pP1Q4Xgkfyj9P6APyr2uCduGAwTnrfMNlgKQbsrl4BHs0qOGMkd+zop+EbnlI97m p3bfUpqETHIRsv9ukqt064FCad9WGQUepzt6hp4mvNWrgMUgsqlxpkA+Q1y7u7QZJKoPBG qkV8rsENmefAoULko2R6gLRmMiFBwBT2IpqvW/cVC83prZOv/G6r8ERFuoNqlg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696234639; 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=jzyfAB80UcPFmXz7kgpg6POlYPSV77eQ7WLuQerPxQE=; b=vrYFf6+mlaK5xiwqDM+zME4qcq9MMUOHdIQ8emmDaTMhi1PILuyM5BxXHLjFwPH4WQUdO6 KM4xcJMaw0DXDfd8qH/j69TOjmD/MRBhA1O9uIQgQ7ZSRntUafdtZFVi9f37BcZ8cWFUt+ ZbihO5FitE5ah7SZ1R0RU1vwn7h3ZwsYdDYY5BflMKSxwwVe1iIxys/4ZXGMofqiwhya5R 6Y0OjN4rvyE6M3gtujWuS4kT3jQov/I1RKYPPhhWO00UH72qv6OcTtoH7thUaIrOudjL5e xQIXeZPozp8M+GAZr8TbQYKygxCGbL4BHnCrycg9Cz8/NznyS0e8gOGnfW2p6A== 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 4RzYhv0hJvz14H3; Mon, 2 Oct 2023 08:17:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3928HJ1U069436; Mon, 2 Oct 2023 08:17:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3928HI2G069433; Mon, 2 Oct 2023 08:17:18 GMT (envelope-from git) Date: Mon, 2 Oct 2023 08:17:18 GMT Message-Id: <202310020817.3928HI2G069433@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mariusz Zaborski Subject: git: 857ce53d1d46 - releng/14.0 - copy_file_range: require CAP_SEEK capability List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: oshogbo X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 857ce53d1d4689884b624c4ec596b1bb77843761 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by oshogbo: URL: https://cgit.FreeBSD.org/src/commit/?id=857ce53d1d4689884b624c4ec596b1bb77843761 commit 857ce53d1d4689884b624c4ec596b1bb77843761 Author: Mariusz Zaborski AuthorDate: 2023-09-28 13:24:39 +0000 Commit: Mariusz Zaborski CommitDate: 2023-10-02 08:18:07 +0000 copy_file_range: require CAP_SEEK capability When using copy_file_range(2) with an offset parameter, the CAP_SEEK capability should be required. This requirement is similar to the behavior observed with pread(2)/pwrite(2). Reported by: theraven Reviewed by: emaste, theraven, kib, markj Approved by: secteam Differential Revision: https://reviews.freebsd.org/D41967 (cherry picked from commit 15a51d3abaef27ddea66320cac7caa549738a1a6) (cherry picked from commit 87d68b131ef65a0a5fb897280359e46067064a53) Approved by: re (gjb) --- sys/kern/vfs_syscalls.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 06b861a2eb73..9d85a295a6ef 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -4899,7 +4899,8 @@ kern_copy_file_range(struct thread *td, int infd, off_t *inoffp, int outfd, len = SSIZE_MAX; /* Get the file structures for the file descriptors. */ - error = fget_read(td, infd, &cap_read_rights, &infp); + error = fget_read(td, infd, + inoffp != NULL ? &cap_pread_rights : &cap_read_rights, &infp); if (error != 0) goto out; if (infp->f_ops == &badfileops) { @@ -4910,7 +4911,8 @@ kern_copy_file_range(struct thread *td, int infd, off_t *inoffp, int outfd, error = EINVAL; goto out; } - error = fget_write(td, outfd, &cap_write_rights, &outfp); + error = fget_write(td, outfd, + outoffp != NULL ? &cap_pwrite_rights : &cap_write_rights, &outfp); if (error != 0) goto out; if (outfp->f_ops == &badfileops) { From nobody Mon Oct 2 08:29:19 2023 X-Original-To: dev-commits-src-branches@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 4RzYyl6sYJz4vmbX; Mon, 2 Oct 2023 08:29: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzYyl5lzDz4KC4; Mon, 2 Oct 2023 08:29:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696235359; 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=4CjmppYL+alimIBFjQb5ISAh9NODQ0uu8LOCpthNf8U=; b=b1PiknFAMX05wbVOSHwpr8h8r+BcKxLBcnhJ0L8mFPdh+fi1PWZjqyiAEPttW7AJQtSXn5 D8bE/Nu4L9EF7tsFdUfRV/Gim/5QoCRnuCiV4i3WC/tKGxjC1GDuN0mAeT74UNbaTxA/nB GbSVrSjpNoTGy9xtQxn5JIRYXfnTwdTTXEPhhZs4/DKx/jyDEP4rhbHm99uyN7ctHfhKlb PIqNsJGruslzY4QoHvqtwDmPHBdJZ5Xy9fFG/5xyviw65NAcGIDa0JPVX90mRw97TezRS/ khD6A0V5Obg2x3sAbpTZ6Vln9mp3Apuk0KPSFFInQ1Lo+E/gqk+vOAAmJD/vzw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696235359; a=rsa-sha256; cv=none; b=rv4cybZQJetxspv72rZWaXG79uj4Ygv6Tt+VkP2nFJUVF00S+6KwUPlmgipwOB2eTl458u fgNagzO03rWbc2dk0aiOEvs12L3V9fFm6aXXujqMlBHi8xvaW47SIwof/4GG8uCHuRE6gn Z7+sN7cHQuz5cr0rtthEW4FjRszKjWiKU6Ol6+nFmnk5MFWTGy0jk6Z6zPKU25WXa/w8xP OdwfCEjrPLvHtgwqVxdDKvEOGtv0XLTrSqnNHJtY7HOJkA+00PdhbluvtSsawvsKscd06T AlFnvfq/Igcw0z5tALGZxQD414DeQZMMtYqNThoXfhVU52HI0OfGg+/P9nnOoA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696235359; 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=4CjmppYL+alimIBFjQb5ISAh9NODQ0uu8LOCpthNf8U=; b=lEz2GEOQEa9XP++IRsM2yN4hynVFJBz+eELevCWtII5I+1x6MYFUFQJVnW1x2lz39e9j1o aYgMr+BlrBsvOhqGUAXtq07LJxzRYL1NCY6FpKHB8bMy6mIClBKltdyoMkZCed1BepdLE4 9SYnEhjsLoejEkseH504oT9PpgC+Lt9PvB64E64GBo9TjfA4IB58w79mN+B2kVpm0HHIDB OHawsQqZn0O7tTMulpLAh2q5H1oyk9Uvopf6C5bWyRZ4I3c3k0oNNltWBrfNEUU/mt0dkI gs3Nx7Z7DkJNPu3Jy1lrbWXmohe9ZXtFnTowsbp+9/J6B5e1XdYfd944oBxDsQ== 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 4RzYyl4qgkz14t9; Mon, 2 Oct 2023 08:29:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3928TJur086133; Mon, 2 Oct 2023 08:29:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3928TJUd086130; Mon, 2 Oct 2023 08:29:19 GMT (envelope-from git) Date: Mon, 2 Oct 2023 08:29:19 GMT Message-Id: <202310020829.3928TJUd086130@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: c6afda2e5a03 - stable/13 - rtsock: Add sysctl flag CTLFLAG_TUN to loader tunable List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: c6afda2e5a0389ce293d3a3ced2889979aa2e442 Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=c6afda2e5a0389ce293d3a3ced2889979aa2e442 commit c6afda2e5a0389ce293d3a3ced2889979aa2e442 Author: Zhenlei Huang AuthorDate: 2023-09-25 10:10:46 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 08:28:22 +0000 rtsock: Add sysctl flag CTLFLAG_TUN to loader tunable The sysctl variable `net.route.netisr_maxqlen` is actually a loader tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` will report it correctly. No functional change intended. Reviewed by: glebius MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41928 (cherry picked from commit 21a722d9593eb477f4ccdad011a2b4df0727fc62) (cherry picked from commit bffb01eda9bffc3307ea8bf70f91087ed316e01c) --- sys/net/rtsock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/net/rtsock.c b/sys/net/rtsock.c index d89d661ca99b..4da7e9e74025 100644 --- a/sys/net/rtsock.c +++ b/sys/net/rtsock.c @@ -231,7 +231,7 @@ sysctl_route_netisr_maxqlen(SYSCTL_HANDLER_ARGS) return (netisr_setqlimit(&rtsock_nh, qlimit)); } SYSCTL_PROC(_net_route, OID_AUTO, netisr_maxqlen, - CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_MPSAFE, + CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_MPSAFE, 0, 0, sysctl_route_netisr_maxqlen, "I", "maximum routing socket dispatch queue length"); From nobody Mon Oct 2 08:29:20 2023 X-Original-To: dev-commits-src-branches@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 4RzYyn1Fssz4vmgF; Mon, 2 Oct 2023 08:29: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzYyn04kgz4KFn; Mon, 2 Oct 2023 08:29:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696235361; 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=uoYBdZgVgDA3CbOTopT7bO6ZLJRy3txlew30685bf10=; b=sVoQQgiVN4p5laO0BRYh+OPryEefXXHO1Epb5PO5V+6AREFNIPA/Gd20WzQ/kJ74Gkhcm5 EMSoE0vQcrPm5ah8ZJ19IVZfS0vL3Oe3Cg2k2tSc4vzAuhTSW8kV6llo3Wl+6EPchhkdUt G2fgg2Rn1H6Rffh9kMYjR2Hz6D9yyZyK2h0hs52kdCcH8GJqmyo2tkQTomapl6tb8kZXS6 3c1rcdrIrrTLaSyyVKetD6sZWCTQ6/FdyQKs/4tMXGK8UjY7iwhP+VSTOh/2ZJBcsSWRVe QB2dQ6O2wqJsW+eAENvvDidNyTSfiONU5yowNbdAqSz1ArwCDmn0rfN9U2Novg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696235361; a=rsa-sha256; cv=none; b=iBkBwDOh/qr3BsFD7W66xIX91PkvZ4OkSczQIU+avcIiBHSei6GBteXK4WsEtpZ8nN83tq IaZ86Gg77GrROSKRgkkdXjjNSWeWE4BydZPrI9ck6SH/+bNoHjF7dBHKIN1Mhg2Da73Vxp kP9hauGO0QvaPuIcv/h7w+7ZqVs4Ai1wHDln6Cr1uCiVovwBam7XrS/VhwbKnIm6lIlS1S 1x/ljbIqaCQo+bKYxG9QolCbc4c2ix+1e2h6gnCzKemOmoS3aw+qQj3ScaDVPiEm63yk7I 40hPi0C8CaZkF+ZeOBaRzz6x1+hrv/qssMI+HK7uV3cKPWUv+UWbab7gIoKbLA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696235361; 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=uoYBdZgVgDA3CbOTopT7bO6ZLJRy3txlew30685bf10=; b=RfDkrUPCUt49GW37Qd7J9hHOZbuNuc0cTDsq8IPszCm7ZFceBhYfSv0wyyY4SzdMIuVv4k Ks/JdzeJE6z38RXNQk+3tZ3oB4u8Gg0PbFVrX8SHutyruddQGB2L9r6WFQw2kDCAGMrBW2 H9Vt9v2BxHJm2GohOTSoKxkIn/Z6Iwn6ZNi6WvTwx85roj/8i0k6d9kUi96lbaphyA6eDB 2G3FOKbpiTrCjEH6yr4tcjOcCtpmj29gemUCHbQt65JtxRBvnxbic+xbkmhhADrxe9vXq+ sH7GN5/DmPT75JMnp1J6tjWts4+otyAaR4qffRrmBMYuQkRUAExQdXnuGXjxhw== 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 4RzYym5qzpz14pL; Mon, 2 Oct 2023 08:29:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3928TKYp086187; Mon, 2 Oct 2023 08:29:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3928TKba086184; Mon, 2 Oct 2023 08:29:20 GMT (envelope-from git) Date: Mon, 2 Oct 2023 08:29:20 GMT Message-Id: <202310020829.3928TKba086184@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: 28a80239fd6a - stable/13 - netinet6: Add sysctl flag CTLFLAG_TUN to loader tunables List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: 28a80239fd6ab2ff79af5a2b19e349fa6f1d62e9 Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=28a80239fd6ab2ff79af5a2b19e349fa6f1d62e9 commit 28a80239fd6ab2ff79af5a2b19e349fa6f1d62e9 Author: Zhenlei Huang AuthorDate: 2023-09-25 10:10:47 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 08:28:22 +0000 netinet6: Add sysctl flag CTLFLAG_TUN to loader tunables The following sysctl variables are actually loader tunables. Add sysctl flag CTLFLAG_TUN to them so that `sysctl -T` will report them correctly. 1. net.inet6.ip6.auto_linklocal 2. net.inet6.ip6.accept_rtadv 3. net.inet6.ip6.no_radr No functional change intended. Reviewed by: glebius MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41928 (cherry picked from commit 03dac3e37993801dab4418087bfedacce0526e66) (cherry picked from commit da2b630c12ec074673dfc646b2055a31b0d8d6d9) --- sys/netinet6/in6_proto.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/netinet6/in6_proto.c b/sys/netinet6/in6_proto.c index 4a92fff14e68..cfa368e7f7b0 100644 --- a/sys/netinet6/in6_proto.c +++ b/sys/netinet6/in6_proto.c @@ -482,10 +482,10 @@ SYSCTL_VNET_PCPUSTAT(_net_inet6_ip6, IPV6CTL_STATS, stats, struct ip6stat, ip6stat, "IP6 statistics (struct ip6stat, netinet6/ip6_var.h)"); SYSCTL_INT(_net_inet6_ip6, IPV6CTL_ACCEPT_RTADV, accept_rtadv, - CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_accept_rtadv), 0, + CTLFLAG_VNET | CTLFLAG_RWTUN, &VNET_NAME(ip6_accept_rtadv), 0, "Default value of per-interface flag for accepting ICMPv6 RA messages"); SYSCTL_INT(_net_inet6_ip6, IPV6CTL_NO_RADR, no_radr, - CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_no_radr), 0, + CTLFLAG_VNET | CTLFLAG_RWTUN, &VNET_NAME(ip6_no_radr), 0, "Default value of per-interface flag to control whether routers " "sending ICMPv6 RA messages on that interface are added into the " "default router list"); @@ -538,7 +538,7 @@ SYSCTL_INT(_net_inet6_ip6, IPV6CTL_V6ONLY, v6only, CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_v6only), 0, "Restrict AF_INET6 sockets to IPv6 addresses only"); SYSCTL_INT(_net_inet6_ip6, IPV6CTL_AUTO_LINKLOCAL, auto_linklocal, - CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_auto_linklocal), 0, + CTLFLAG_VNET | CTLFLAG_RWTUN, &VNET_NAME(ip6_auto_linklocal), 0, "Default value of per-interface flag for automatically adding an IPv6 " "link-local address to interfaces when attached"); SYSCTL_VNET_PCPUSTAT(_net_inet6_ip6, IPV6CTL_RIP6STATS, rip6stats, From nobody Mon Oct 2 08:29:21 2023 X-Original-To: dev-commits-src-branches@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 4RzYyp2lNSz4vmgH; Mon, 2 Oct 2023 08:29:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzYyp0bksz4KJQ; Mon, 2 Oct 2023 08:29:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696235362; 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=kAgKVF+qRkpWMyhYcP7tO7PL2e9vQO+/prN07+8+9JQ=; b=osB6CoZGrUU8JCRCjBO2ZjLVilQBNijD5nJqEriV9pRi3LKldqwGUlTnoyNQX/bNWwRSdV 2PZx5nwR2Mo10VTb7ebj+971p/pUHyR4P8ruOqr5enklWN0xV5ZnQ4Gxcv29kbKoPZZISg BLXMEWxyapyvLfo6epognzenoGij2kJN+kgPmimvelhuppgSMXnZ0hDNTYc8TGviKk2P5h fryY3GNni3M76179jdjQBbmNYGwFbPOsgmHcxh2Iw/NbCW2NzP1RQ8ek0Nkh15LY/0P5Yu Zok+2JGVA20bmur+PQtvE9l4+Hm8mbQz8Ym8KbuMAfOg/63cERT9DBcK61LKXA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696235362; a=rsa-sha256; cv=none; b=ue5JXTVwor21gL7Yhf6pg7fPmafnYYrcEcePvd+VbfkXlo/KaaV9lnndzfauSsdH/S77RA Ju+ihE6y9Yp9EbmwJ/H2qPL2+NzATbc0hd4THlJBHEeaWK2Z+PWkKSiAzqPD/IvEF8gNQg gAQ60U057vqO+4IDCdTxYrTAi788ltNT81K8F4VI3SrTtbnURSzZj00m9nOIVS79ordsMN O90UONc8Z9qZJpX7CSMQ5q+5Fhii7bCDMN5EBVcacalmPgbQUwMLtbSGDDr499w7/8RuIc pcOICsqKnf2/bGuHYfW+fxwAxSK0xTUVfPSefqg0TUUATtvu7g1HZJRRaQxpZw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696235362; 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=kAgKVF+qRkpWMyhYcP7tO7PL2e9vQO+/prN07+8+9JQ=; b=vi0whvA0qUu6FVMrOa5e20TFp5BIWI69ksAf3nYD0nIC2VSb0+Jls6VUvWacX+Pi/ilCkT gUsSwhFRaYxTe3ecn5AVD+DqGdFEl9aflX9V1ZaDS5hOtJp6GSAikdkbFwzO6YwUsufLvY VH+2xjpZvIDh93v4pSkM2W0RmYs4pP7fS0kQjog0UaxfPJ8OTZpJGkQRwQj3IEaZwokW6S WqNJKnZHEGxYcDtwPFvbWOk+Kh8Qrwbaeb7rIJJmKjRxO7eZaVusJcnbuiey7jZdel+ILo l9XONnRIP2Xqn6jS5yCFbb3Xe79rgIkvz0fKnRK7Pz1uXlNtr1BKeXJ7JFyHYg== 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 4RzYyn6WX4z14gh; Mon, 2 Oct 2023 08:29:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3928TLPV086251; Mon, 2 Oct 2023 08:29:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3928TL3H086248; Mon, 2 Oct 2023 08:29:21 GMT (envelope-from git) Date: Mon, 2 Oct 2023 08:29:21 GMT Message-Id: <202310020829.3928TL3H086248@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: 09f08dbe248e - stable/13 - ipfw: Add sysctl flag CTLFLAG_TUN to loader tunables List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: 09f08dbe248e6ffd031c1eff26aeacef0c6880e9 Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=09f08dbe248e6ffd031c1eff26aeacef0c6880e9 commit 09f08dbe248e6ffd031c1eff26aeacef0c6880e9 Author: Zhenlei Huang AuthorDate: 2023-09-25 10:10:47 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 08:28:23 +0000 ipfw: Add sysctl flag CTLFLAG_TUN to loader tunables The following sysctl variables are actually loader tunables. Add sysctl flag CTLFLAG_TUN to them so that `sysctl -T` will report them correctly. 1. net.inet.ip.fw.enable 2. net.inet6.ip6.fw.enable 3. net.link.ether.ipfw No functional change intended. Reviewed by: glebius MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41928 (cherry picked from commit 49197c391b3d49a33bcd08471bf64d533cd10f9d) (cherry picked from commit f5f6da90597cb65ce55c4f17718a200097f6f78f) --- sys/netpfil/ipfw/ip_fw_pfil.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/netpfil/ipfw/ip_fw_pfil.c b/sys/netpfil/ipfw/ip_fw_pfil.c index db898c97f504..9a7ecd506fc3 100644 --- a/sys/netpfil/ipfw/ip_fw_pfil.c +++ b/sys/netpfil/ipfw/ip_fw_pfil.c @@ -91,20 +91,20 @@ SYSBEGIN(f1) SYSCTL_DECL(_net_inet_ip_fw); SYSCTL_PROC(_net_inet_ip_fw, OID_AUTO, enable, - CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE3 | + CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_SECURE3 | CTLFLAG_NEEDGIANT, &VNET_NAME(fw_enable), 0, ipfw_chg_hook, "I", "Enable ipfw"); #ifdef INET6 SYSCTL_DECL(_net_inet6_ip6_fw); SYSCTL_PROC(_net_inet6_ip6_fw, OID_AUTO, enable, - CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE3 | + CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_SECURE3 | CTLFLAG_NEEDGIANT, &VNET_NAME(fw6_enable), 0, ipfw_chg_hook, "I", "Enable ipfw+6"); #endif /* INET6 */ SYSCTL_DECL(_net_link_ether); SYSCTL_PROC(_net_link_ether, OID_AUTO, ipfw, - CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE3 | + CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_SECURE3 | CTLFLAG_NEEDGIANT, &VNET_NAME(fwlink_enable), 0, ipfw_chg_hook, "I", "Pass ether pkts through firewall"); From nobody Mon Oct 2 08:29:22 2023 X-Original-To: dev-commits-src-branches@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 4RzYyq2RXDz4vm9W; Mon, 2 Oct 2023 08:29: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzYyq1L9Hz4KD9; Mon, 2 Oct 2023 08:29:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696235363; 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=uMKt8BRuOd2Br+JBbSxyNVq/YpQxqzUdXeklQgXb/d8=; b=LArPq0DXmP1w+uFdUe5NmHNQgSUc8pmYCTK2YGD6ap070UnObk+VhlXFHuNQJQ0AdvbOTc vLKr1F4JWC5EECg/WCjJm8Jo3FMNCKW1uzNH26ryg/1aabJBvRDtzaXLnG6MI1h/hUSTsW v/1zSvJGdgtgLci9qen8+xExSnNSpp1zrRL4SqqikAXGLnlshq4MjJsqO82Xyxn/uk6WCH AeIvqC/MsrGyBLA0wBqBnMWc5dlOWYmsRnP/heY6lA52efreuVc1v9jeHPD9unebUQ1BOo +5d/qZTx6vUDEbS+o5yJ1Gyvcq/BKGiDCXVoNT7ZU+UaT0IoFRRDQDU+rcYMng== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696235363; a=rsa-sha256; cv=none; b=e9scidsDohHIhv9FdYjAXQ5IshKlccnV/sn/XwDf3olU4jaT6vJGbboe0fiH4p02RdlzEk fwfnH1OstBYJW6aaABEh7VMLdZjJU88Zg5pj1VP2Gd0LH9nJdpqT7olykaZFP9h7f5dSg/ 19t3+6otoBEq7TfUSETEC5i7z/wqWLU0G5LYm7WvhPWzOTbAXvETm6nK8AYMB73mFYb+CK xpPdCoLiwoxigvpiLRrSZ9uVSKCRQQlMocX1YeeozKHEOeREzB1wPHu7MeqDBi60P9xBex hyNIJ8+GlOy968d8EaKUK3QNiOZGK+WReCcbzlEizvHVJQDllUZsaKB0F7/DHg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696235363; 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=uMKt8BRuOd2Br+JBbSxyNVq/YpQxqzUdXeklQgXb/d8=; b=h7ALe05ZrY8gp9ItxaryFKRNKtzfZmUN2UuH6cMBJLK3zcCWwkHwQ9Emem6GP9DYD0FROQ RIwvOauUm3OUgoUYILAnlo/+fWYxbUDPZzWd6TO9FtoR2cSF4VhKDWGcGOWuM/WrzJidKP Ll/wZcXnw1vThK+L1y7KAx1uhmq8Elez0xF2rKHjgLC6a7A5AOo0FjPuMXbGSXwth1TEm0 fiu3aujV2qTLve8VcHHkUIa5GjTIK2LJmkeEPJIjfHC7P4TdPE1AuiYM51543SRF+fAhbb xyHz+lV5DA3ih4XASqR/l+ruc3DdDExvQ28WKpT4inB6mX8E1hlRmADt3OrznQ== 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 4RzYyq0S8Kz14RW; Mon, 2 Oct 2023 08:29:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3928TMCZ086382; Mon, 2 Oct 2023 08:29:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3928TMPU086379; Mon, 2 Oct 2023 08:29:22 GMT (envelope-from git) Date: Mon, 2 Oct 2023 08:29:22 GMT Message-Id: <202310020829.3928TMPU086379@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: e31a331ddda6 - stable/13 - ipfw.8: Adjust section for loader tunables List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: e31a331ddda6ffcb711bb950794be5d53e537e2a Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=e31a331ddda6ffcb711bb950794be5d53e537e2a commit e31a331ddda6ffcb711bb950794be5d53e537e2a Author: Zhenlei Huang AuthorDate: 2023-09-28 04:58:44 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 08:28:23 +0000 ipfw.8: Adjust section for loader tunables Move the descriptions of loader tunables from section 'SYSCTL VARIABLES' to section 'LOADER TUNABLES'. See also 49197c391b3d (ipfw: Add sysctl flag CTLFLAG_TUN to loader tunables). MFC after: 2 days Differential Revision: https://reviews.freebsd.org/D41981 (cherry picked from commit 12349f38898f231ca803dcf526bac88cb1b5cd2b) (cherry picked from commit bb6f9a95402a6c3ab8167481b81465f8ad5016fc) --- sbin/ipfw/ipfw.8 | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/sbin/ipfw/ipfw.8 b/sbin/ipfw/ipfw.8 index efc338d40007..4a9ded2b9867 100644 --- a/sbin/ipfw/ipfw.8 +++ b/sbin/ipfw/ipfw.8 @@ -1,5 +1,5 @@ .\" -.Dd April 25, 2023 +.Dd September 28, 2023 .Dt IPFW 8 .Os .Sh NAME @@ -3713,6 +3713,16 @@ or .Xr kenv 1 before ipfw module gets loaded. .Bl -tag -width indent +.It Va net.inet.ip.fw.enable : No 1 +Enables the firewall. +Setting this variable to 0 lets you run your machine without +firewall even if compiled in. +.It Va net.inet6.ip6.fw.enable : No 1 +provides the same functionality as above for the IPv6 case. +.It Va net.link.ether.ipfw : No 0 +Controls whether layer2 packets are passed to +.Nm . +Default is no. .It Va net.inet.ip.fw.default_to_accept : No 0 Defines ipfw last rule behavior. This value overrides @@ -4106,12 +4116,6 @@ Keep dynamic states on rule/set deletion. States are relinked to default rule (65535). This can be handly for ruleset reload. Turned off by default. -.It Va net.inet.ip.fw.enable : No 1 -Enables the firewall. -Setting this variable to 0 lets you run your machine without -firewall even if compiled in. -.It Va net.inet6.ip6.fw.enable : No 1 -provides the same functionality as above for the IPv6 case. .It Va net.inet.ip.fw.one_pass : No 1 When set, the packet exiting from the .Nm dummynet @@ -4128,10 +4132,6 @@ Enables verbose messages. Limits the number of messages produced by a verbose firewall. .It Va net.inet6.ip6.fw.deny_unknown_exthdrs : No 1 If enabled packets with unknown IPv6 Extension Headers will be denied. -.It Va net.link.ether.ipfw : No 0 -Controls whether layer2 packets are passed to -.Nm . -Default is no. .It Va net.link.bridge.ipfw : No 0 Controls whether bridged packets are passed to .Nm . From nobody Mon Oct 2 08:29:24 2023 X-Original-To: dev-commits-src-branches@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 4RzYyr2nh3z4vmdC; Mon, 2 Oct 2023 08:29:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzYyr2B96z4KQ7; Mon, 2 Oct 2023 08:29:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696235364; 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=GqrGSG6GCIxIXJryrZUscJYVAusYRNoFLP/rq6xRQf4=; b=TnDVWwubGxkH77Jl+mPTgXzhKu/rFqjR4pdYu2zNRK8u7LCM+fWvzn9ikw65PqZ2wlCS8b YGiAU3fraEz/tYzRwkzhrdg1f4l4KzJNgYt+30POvkgWRjn4HLj/s1og+YEMBK9q8JM2vk RmaFibS72wAu6rQv8o6zauCSgk25nSUcZDik/Xs+INorgb6wWoNjQEz4GubFuCZch+BMaN Rx3bWl2joVn6XDUDIiTJmvSyCn7i8uk8zDVdH2DcBGbTkh3NEI1l/iYab+fAWChME3Hh24 yiGSSuQoz+IZsABDMPX5AdvVslDqWUmUOcJpKZcB4wfiJ0/nQzPoaDGQ5QuCNQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696235364; a=rsa-sha256; cv=none; b=WIM5dk7OXJ1c+wAVyOS3yh8+kp/EgFi9sZ0gsbToBKZ+Sq/97kal7eciHKZocpWmhoRtjX 2W0WcBG9eBK/s5tXbR5VAL28aX7CrB3lmHaw04OXJKVHTjD2phMAc7JxctvqKiyjz4URZY BUtlmKTE53zzunyq+5Ik187AbiHDfdvQl3JxHhpPQWfYFICDbLbsl6U+Xl+0OM+dg9uHiS DaBkcubrZTLYBztzT02oRXsBQXG7rWFUgS1rI2WvdoqdKPUu04tM2JEjkIEg2Z9Sdp8GR1 pqQ4uoJVM4KZlPdViAJW4awq0k5h8ZBk8NB6LYXdZgEGJoN1EvYOYwLREntsOg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696235364; 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=GqrGSG6GCIxIXJryrZUscJYVAusYRNoFLP/rq6xRQf4=; b=Gm8eWJp7Jce+1QaYKBKJg+5bk5M8pozm/2lCzXX1Pmnv3HdF3xCDSGU/3Rzwbx5x6MIypR 7BtnntjmWu0Rm8mSG6ZorCQznpkmUQ3C5feu3LoQ1IaMUGVUwfBl7n0tr6gqS4FFK0FXLn XZFNnY+U7F35RpmBJ0478Yz9MhIn8MJTtiVLpJ8MAUomSEMr1VyfiJPM23bbxnfJNlay6M orFLSQeWhnHllBGj07oQf3beorF6Qk56dlT0Cd938MyXGe3V776CbtWDxXmg8vS3EfCU/2 R3XkSpTQe3dWbN8OCzoeV/x1bGYUCKyLLe8OM1FQaxc4s3QSYuR/3Lh9ygPBCg== 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 4RzYyr1GFLz14pM; Mon, 2 Oct 2023 08:29:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3928TOFf086444; Mon, 2 Oct 2023 08:29:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3928TOdS086441; Mon, 2 Oct 2023 08:29:24 GMT (envelope-from git) Date: Mon, 2 Oct 2023 08:29:24 GMT Message-Id: <202310020829.3928TOdS086441@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: ef3edef9ec8b - stable/13 - ip_mroute: Fix sysctl knobs List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: ef3edef9ec8b7d19e5f66c385340604ab29ccc78 Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=ef3edef9ec8b7d19e5f66c385340604ab29ccc78 commit ef3edef9ec8b7d19e5f66c385340604ab29ccc78 Author: Zhenlei Huang AuthorDate: 2023-09-27 16:23:22 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 08:28:23 +0000 ip_mroute: Fix sysctl knobs The loader tunable `net.inet.ip.mfchashsize` does not have corresponding sysctl MIB entry. Just add it. While here, the sysctl variable `net.inet.pim.squelch_wholepkt` is actually a loader tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` will report it correctly. Reviewed by: kp Fixes: 443fc3176dee Introduce a number of changes to the MROUTING code MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41997 (cherry picked from commit f549e22901b3a391c76659bee55802b1214112fd) (cherry picked from commit b0f026435a150933ecb6f2d1359fd1b4898657f1) --- sys/netinet/ip_mroute.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/sys/netinet/ip_mroute.c b/sys/netinet/ip_mroute.c index d8c5c74231ec..ca510610e4e7 100644 --- a/sys/netinet/ip_mroute.c +++ b/sys/netinet/ip_mroute.c @@ -161,7 +161,9 @@ VNET_DEFINE_STATIC(u_long, mfchash); ((g).s_addr >> 20) ^ ((g).s_addr >> 10) ^ (g).s_addr) & V_mfchash) #define MFCHASHSIZE 256 -static u_long mfchashsize; /* Hash size */ +static u_long mfchashsize = MFCHASHSIZE; /* Hash size */ +SYSCTL_ULONG(_net_inet_ip, OID_AUTO, mfchashsize, CTLFLAG_RDTUN, + &mfchashsize, 0, "IPv4 Multicast Forwarding Table hash size"); VNET_DEFINE_STATIC(u_char *, nexpire); /* 0..mfchashsize-1 */ #define V_nexpire VNET(nexpire) VNET_DEFINE_STATIC(LIST_HEAD(mfchashhdr, mfc)*, mfchashtbl); @@ -234,7 +236,7 @@ SYSCTL_VNET_PCPUSTAT(_net_inet_pim, PIMCTL_STATS, stats, struct pimstat, pimstat, "PIM Statistics (struct pimstat, netinet/pim_var.h)"); static u_long pim_squelch_wholepkt = 0; -SYSCTL_ULONG(_net_inet_pim, OID_AUTO, squelch_wholepkt, CTLFLAG_RW, +SYSCTL_ULONG(_net_inet_pim, OID_AUTO, squelch_wholepkt, CTLFLAG_RWTUN, &pim_squelch_wholepkt, 0, "Disable IGMP_WHOLEPKT notifications if rendezvous point is unspecified"); @@ -2876,18 +2878,12 @@ ip_mroute_modevent(module_t mod, int type, void *unused) MFC_LOCK_INIT(); VIF_LOCK_INIT(); - mfchashsize = MFCHASHSIZE; - if (TUNABLE_ULONG_FETCH("net.inet.ip.mfchashsize", &mfchashsize) && - !powerof2(mfchashsize)) { + if (!powerof2(mfchashsize)) { printf("WARNING: %s not a power of 2; using default\n", "net.inet.ip.mfchashsize"); mfchashsize = MFCHASHSIZE; } - pim_squelch_wholepkt = 0; - TUNABLE_ULONG_FETCH("net.inet.pim.squelch_wholepkt", - &pim_squelch_wholepkt); - pim_encap_cookie = ip_encap_attach(&ipv4_encap_cfg, NULL, M_WAITOK); ip_mcast_src = X_ip_mcast_src; From nobody Mon Oct 2 08:29:25 2023 X-Original-To: dev-commits-src-branches@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 4RzYys44FWz4vmM3; Mon, 2 Oct 2023 08:29: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzYys3Wgpz4KWB; Mon, 2 Oct 2023 08:29:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696235365; 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=a+pSWsdjoq0ROvW5fJghtoLdbs4BpNPLCK242qQRbd4=; b=E0qnO+wQslslGY2LDGbH90oUDBJDvZbNR2QgnlLPBeItLhlfzwCrTUe0TTgQjJk64gnGCA K+89Y6TyV34QkQE3TpV02IAca1DKoKRMGVaNnzhe56h7dWpgone5KFg5ZxQsfX1znW3kJX A9GHx6CeFjHjDqddmUaFHGyGr0VJlKvqCqX8pdcfrOKWEHWOIq1m/QEsjnWx9gQO0sQ2UN iyCLUwc02QGIYo7LLESpj5kK4e8YXJhQcskGq5jxC1oVRTsDNkP3cj5p5zVvxvbMeCp9+3 WVkdqDs5paNxdUGNsoiHv2EpE3GHAwzjJyNfZVGHQt6Z9o/FRy0QcNC41fRNLg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696235365; a=rsa-sha256; cv=none; b=gcRs2Q19cH3EQz9v1CI7Gh4enZS/dsu24YaRz8YF7zBNAuRopSPZgUvOuzczIr4B1f7kc6 2Ai7VYxiAJpXyrEI3kE4uw/TYvEd/9pdLdXTbbOO5dcqRugSTHRHnE26nW/ApKB4DrkLs1 LYgyfGDxs8qfICVMT8rK0l2W8mVMuVkckzB0MHCdIHvPxS2iF9DZj8WP0N5hc9As1+UVqa raMcErrC1CiatVJTMig/sRsA/Ysr1zDZ3Y912McjRqXyU+1TNUmCUlM14INp4thGHjbgiM poRYR3bJ9DZNycmQYvjdn5OV9Vk/DfCReMzTVJDnwSEgOU8IMXbkF670OTH4BQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696235365; 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=a+pSWsdjoq0ROvW5fJghtoLdbs4BpNPLCK242qQRbd4=; b=oFZ0h109mUib0O1GoyVJws5cyevMqP7z8RC6AJfbto9lMPqvx7kr8cy+/Baq19f9Gf9TWd akdrjnD940uhQRyaggz3xDfZiMek7cuRVlZU7a3eScnbg+mv/GCukcynUGcOf5MYevI4r6 R2INXcGnZeNhSFdcVZNBpHRlcwCmO2qzg8T3mH+gXANV8MWCSY7c/UQOpmeYRAZbhMuKqY hfN4Sf6yU0bWP29mPhodutibRHUMBRuoRfo3QnXZudg6lyPj254lJ019urrblahYpZ+XsJ 16wn4nS47DC32TK6dFC8+erfAItK5yReAeMQBKDjktjEOxgqNEySz0sVWPGWhg== 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 4RzYys2TS2z14gj; Mon, 2 Oct 2023 08:29:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3928TPGq086495; Mon, 2 Oct 2023 08:29:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3928TPp6086492; Mon, 2 Oct 2023 08:29:25 GMT (envelope-from git) Date: Mon, 2 Oct 2023 08:29:25 GMT Message-Id: <202310020829.3928TPp6086492@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: 25c371dc559a - stable/13 - ipfilter: Add sysctl flag CTLFLAG_TUN to loader tunable List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: 25c371dc559a9ea23905baa5cbfed3f6d9d6eb5c Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=25c371dc559a9ea23905baa5cbfed3f6d9d6eb5c commit 25c371dc559a9ea23905baa5cbfed3f6d9d6eb5c Author: Zhenlei Huang AuthorDate: 2023-09-29 00:01:43 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 08:28:23 +0000 ipfilter: Add sysctl flag CTLFLAG_TUN to loader tunable The sysctl variable `net.inet.ipf.large_nat` is actually a loader tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` will report it correctly. No functional change intended. Reviewed by: cy (for #network) Fixes: a805ffbcbce8 ipfilter: Make LARGE_NAT a tunable MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D42005 (cherry picked from commit ba883e7a5ac43b27a373f2b1b0044fd2eb769d4e) (cherry picked from commit a9359dcde241f17421a71bc8c96dee08625db9dd) --- sys/netpfil/ipfilter/netinet/mlfk_ipl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c b/sys/netpfil/ipfilter/netinet/mlfk_ipl.c index fcd7a94575e6..a2f1b5070818 100644 --- a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c +++ b/sys/netpfil/ipfilter/netinet/mlfk_ipl.c @@ -134,7 +134,7 @@ SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_running, CTLFLAG_RD, &VNET_NAME(ipfmain.ipf_running), 0, "IPF is running"); SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_chksrc, CTLFLAG_RW, &VNET_NAME(ipfmain.ipf_chksrc), 0, ""); SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_minttl, CTLFLAG_RW, &VNET_NAME(ipfmain.ipf_minttl), 0, ""); -SYSCTL_IPF(_net_inet_ipf, OID_AUTO, large_nat, CTLFLAG_RD, &VNET_NAME(ipfmain.ipf_large_nat), 0, "large_nat"); +SYSCTL_IPF(_net_inet_ipf, OID_AUTO, large_nat, CTLFLAG_RDTUN | CTLFLAG_NOFETCH, &VNET_NAME(ipfmain.ipf_large_nat), 0, "large_nat"); #define CDEV_MAJOR 79 #include From nobody Mon Oct 2 09:09:57 2023 X-Original-To: dev-commits-src-branches@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 4RzZsd5gnsz4vq3y; Mon, 2 Oct 2023 09:09:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzZsd57RMz4Nq2; Mon, 2 Oct 2023 09:09:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696237797; 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=KkkjSYMABSEp4BeMeNo1sp1+TqxHOfH2gj+2cQ9dki0=; b=tfpGXzdhZXjhr2/TfD96wPdPdk2/zcTKpZZ9OiKI+EURD48Jdx4vsufvOU/duloSDzq+ZZ XiWHq+1dVOLv5JnjS1SUhkLuCGz/Ls+I4Ib0uW/JyVvyYVZQGdBn5n0FYW0ZRmVoabdwqn fmVEqF17LJTw5lWh7GOaEpkWDmk3NdOzio5CKfE9CJwHvMlCfFeEM+6qZswYtZ2m8DLb4L ywgsjQLwocKI4vdoDF71SsHSOYbZ9ZL3IZBshF2RH+4JjB0/yrNjyEn33GKi0BDPHdsrcy j1FXD2kveZaEO1dsEgm2FHYo3NVlxzpohfhqSmnknRdwFTMvubmcaoa+YC70YQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696237797; a=rsa-sha256; cv=none; b=VephHD7XRmb1b5sOCUx/wb6dPogrj97uLoWJwW19p7m09GDGtmQtkI2cSOeH5TMFESLGMN 3s6sAzqPheX0CR0b3WoTFU8mnslHigWA0wINQHXpOJNbsinZekycUYDPNaF9gnrNXLuUNu e2So1ObLduIVDVNh0YArCAfhugESNLh8musXbSQMzhNFi1bG5PD+rHO6L4qtxqoua4O0Tb S5PaNqRSxgyQmoMM7p0MSv3IX8TgXM9TBfuP1W4SVsZw+XzM8Ffi+S0C2fRYPM8iHRzwJS VeabHmpVtVsI2T/AkfchKHeKwQ1bRyegwKfpUyG8E2BwQkEJ0ErWw0sCM0reqw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696237797; 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=KkkjSYMABSEp4BeMeNo1sp1+TqxHOfH2gj+2cQ9dki0=; b=A/m6USiqt9+mzi330ocjUoQgkOr8BhnLpkf1RIkhteGOLE+HGGR5h69krvRxeXQ0DppEy6 i4XKXFbzF3CBhcIa9ClnQ9FsAZP3OSe/Vc8XxfoRjOqo3Qyc5FDwg2TA8Lcf477LOGR1il D8pLPLigw4rSUW0aSoZVsE0pGkEcNYduA1LBgi0W/+VLVby6gsm03Asqu2awJHAIU6HvyA kjO9JLz9aVytM19knW0w0lq9VHIfWAGt/gWd0eXlRr21CbKxfUuzzMz47iRzz0xvaN0fnx DEgq4kdzqJ6YlzAMRLzWb7ju1dwGHz8ywxDEv+rVmuw+AK6M2KIybYd6ufPMkA== 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 4RzZsd48WTz15Rq; Mon, 2 Oct 2023 09:09:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39299vSM053683; Mon, 2 Oct 2023 09:09:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39299viG053679; Mon, 2 Oct 2023 09:09:57 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:09:57 GMT Message-Id: <202310020909.39299viG053679@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: 453abc9f3a3e - stable/12 - rtsock: Add sysctl flag CTLFLAG_TUN to loader tunable List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/12 X-Git-Reftype: branch X-Git-Commit: 453abc9f3a3e1a305e49cbf425122352a15055fd Auto-Submitted: auto-generated The branch stable/12 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=453abc9f3a3e1a305e49cbf425122352a15055fd commit 453abc9f3a3e1a305e49cbf425122352a15055fd Author: Zhenlei Huang AuthorDate: 2023-09-25 10:10:46 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 09:08:54 +0000 rtsock: Add sysctl flag CTLFLAG_TUN to loader tunable The sysctl variable `net.route.netisr_maxqlen` is actually a loader tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` will report it correctly. No functional change intended. Reviewed by: glebius MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41928 (cherry picked from commit 21a722d9593eb477f4ccdad011a2b4df0727fc62) (cherry picked from commit bffb01eda9bffc3307ea8bf70f91087ed316e01c) (cherry picked from commit c6afda2e5a0389ce293d3a3ced2889979aa2e442) --- sys/net/rtsock.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/net/rtsock.c b/sys/net/rtsock.c index 8009ec5dd0a2..aa2f7422d6ce 100644 --- a/sys/net/rtsock.c +++ b/sys/net/rtsock.c @@ -196,7 +196,8 @@ sysctl_route_netisr_maxqlen(SYSCTL_HANDLER_ARGS) return (EINVAL); return (netisr_setqlimit(&rtsock_nh, qlimit)); } -SYSCTL_PROC(_net_route, OID_AUTO, netisr_maxqlen, CTLTYPE_INT|CTLFLAG_RW, +SYSCTL_PROC(_net_route, OID_AUTO, netisr_maxqlen, + CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH, 0, 0, sysctl_route_netisr_maxqlen, "I", "maximum routing socket dispatch queue length"); From nobody Mon Oct 2 09:09:58 2023 X-Original-To: dev-commits-src-branches@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 4RzZsf6b2Fz4vq13; Mon, 2 Oct 2023 09:09: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzZsf63zvz4PDX; Mon, 2 Oct 2023 09:09:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696237798; 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=/Fy2cGEFi80uNoaAn207ikUcJcDK9GWUirHoQE/VDxY=; b=HKK/IFQzL3IcCkdakvV22MAQPN16JrxP+Ku/h4YPpkJ+kU2JBPqeQ07nXKzN9Txt92Hl/R z3EFaEfjOFnrbLYiDck4L+T71v4rC/KTOmPIbIHZ68vUx3818HYtfsvmUna9krfyAmBSK8 aV2giKxupsVmJshgugp0KeDl/XPQxt2Y7kBNN53ZEw2Rt90cpkE8n03TF117IeSkrCH+cA /0JVwKwxqAud870P1MmpT3ooz83n4H2XYOOobjoUjbckAiAE0rq1zM9N8ljV93bsEsvd2W 0bnQarMEOj7JLX0TLkyEvGq/esa5/6XU0xHz5Sn9/l1WMkxjlwV0zWKZmkpILQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696237798; a=rsa-sha256; cv=none; b=GH47Ur50VCI1CFDjYVT8ABMkJzNXqhAIvw1k+yRmP8oV/KFlpPLO4WkIkBNYkZiJ4IlRAh pbtbODV13D0xWPre3WpRPI700ian+9BINpcTfB4NS+s1agmYuHbPDWEeldasBDj1bf1zwg hwCkMILNFswNdV+2uX1F1ZjPrdBYl4lCRsvrAyjs9ytqsvr3vOMRcqdXXLfHdl3k8n8zKS BuIX5LWXkacZ+lnP/XfP121l8jWG33fwNxPmBGsMhlKyDYcGbmmxtJJemGuY+sbFMInirI DsZuoruWMi+svBj/2Tb9YnvQBrKx7Ie5/Zd+LScfIe8UoPhW3VF/D4YvgJe/iA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696237798; 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=/Fy2cGEFi80uNoaAn207ikUcJcDK9GWUirHoQE/VDxY=; b=CyBqQpWN7q4DCM9DssZCvTwdcW7qqm7Yxb40IcIZ7QQUjmyWRiRo4nR+8toEXenci5B1+d m0NtDRWXGwE06GXoXjsQ9OSNs8vJAOjVdvvU2mRG8s6uS/GsW8GQY3QeT5w0kvhSV2waaX A2D4sc2dCKDDmyjUKF1uHU6WtbC0nJN62oe3I8OGE9cJ1VYNM2orK6jKw/cu5OTp3zepDk U95WWX1Op9wjQ6gzsvrPX4mNHTPrWGeSzaX9PE9INuQEUGYOdiUpTDPxIk0r06pqM5uBzE NhAOjhvPBzLoSfvJl6ZKkKq/oyO+aqug7mXpeOQ+6AdkRM1Jde+pKLexjlYAvg== 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 4RzZsf59RRz15Pv; Mon, 2 Oct 2023 09:09:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39299wPr053739; Mon, 2 Oct 2023 09:09:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39299web053736; Mon, 2 Oct 2023 09:09:58 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:09:58 GMT Message-Id: <202310020909.39299web053736@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: 2d43654e6aa8 - stable/12 - netinet6: Add sysctl flag CTLFLAG_TUN to loader tunables List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/12 X-Git-Reftype: branch X-Git-Commit: 2d43654e6aa8215dff11e5249bdb3518ed0fbdbd Auto-Submitted: auto-generated The branch stable/12 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=2d43654e6aa8215dff11e5249bdb3518ed0fbdbd commit 2d43654e6aa8215dff11e5249bdb3518ed0fbdbd Author: Zhenlei Huang AuthorDate: 2023-09-25 10:10:47 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 09:08:54 +0000 netinet6: Add sysctl flag CTLFLAG_TUN to loader tunables The following sysctl variables are actually loader tunables. Add sysctl flag CTLFLAG_TUN to them so that `sysctl -T` will report them correctly. 1. net.inet6.ip6.auto_linklocal 2. net.inet6.ip6.accept_rtadv 3. net.inet6.ip6.no_radr No functional change intended. Reviewed by: glebius MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41928 (cherry picked from commit 03dac3e37993801dab4418087bfedacce0526e66) (cherry picked from commit da2b630c12ec074673dfc646b2055a31b0d8d6d9) (cherry picked from commit 28a80239fd6ab2ff79af5a2b19e349fa6f1d62e9) --- sys/netinet6/in6_proto.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/netinet6/in6_proto.c b/sys/netinet6/in6_proto.c index 43d99e484fb8..b8895b4aa442 100644 --- a/sys/netinet6/in6_proto.c +++ b/sys/netinet6/in6_proto.c @@ -492,10 +492,10 @@ SYSCTL_VNET_PCPUSTAT(_net_inet6_ip6, IPV6CTL_STATS, stats, struct ip6stat, ip6stat, "IP6 statistics (struct ip6stat, netinet6/ip6_var.h)"); SYSCTL_INT(_net_inet6_ip6, IPV6CTL_ACCEPT_RTADV, accept_rtadv, - CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_accept_rtadv), 0, + CTLFLAG_VNET | CTLFLAG_RWTUN, &VNET_NAME(ip6_accept_rtadv), 0, "Default value of per-interface flag for accepting ICMPv6 RA messages"); SYSCTL_INT(_net_inet6_ip6, IPV6CTL_NO_RADR, no_radr, - CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_no_radr), 0, + CTLFLAG_VNET | CTLFLAG_RWTUN, &VNET_NAME(ip6_no_radr), 0, "Default value of per-interface flag to control whether routers " "sending ICMPv6 RA messages on that interface are added into the " "default router list"); @@ -548,7 +548,7 @@ SYSCTL_INT(_net_inet6_ip6, IPV6CTL_V6ONLY, v6only, CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_v6only), 0, "Restrict AF_INET6 sockets to IPv6 addresses only"); SYSCTL_INT(_net_inet6_ip6, IPV6CTL_AUTO_LINKLOCAL, auto_linklocal, - CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_auto_linklocal), 0, + CTLFLAG_VNET | CTLFLAG_RWTUN, &VNET_NAME(ip6_auto_linklocal), 0, "Default value of per-interface flag for automatically adding an IPv6 " "link-local address to interfaces when attached"); SYSCTL_VNET_PCPUSTAT(_net_inet6_ip6, IPV6CTL_RIP6STATS, rip6stats, From nobody Mon Oct 2 09:09:59 2023 X-Original-To: dev-commits-src-branches@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 4RzZsh1BPpz4vq7k; Mon, 2 Oct 2023 09:10: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzZsh0050z4PFG; Mon, 2 Oct 2023 09:09:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696237800; 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=YnuyjxkIkwqPXBwITYh5raIy/+MmD+yzg/vSjg+e+HE=; b=uCV/Q+uaKjWeXh/V3fnXdxbpIybONBCsLCMWljKXJFEFliEuvKkRkuG0APj4oMgOIMdkEB 014zYg+QkwCkdt5CZThCtk3AHmIM6brT/GUVTmMIFyts4qIFS2ObVmbqb27wnaZkPyH8lt vOV1mbo3RfTU/Oly5dAOw4ayBvqrH5peNSj5UmWzzALYrINy8zsdqFF/8rLuJsQoeXNTlT crmUqvB0VhsB2SF5Zf3o33xbYFHJeAmHISACe4Elvbx+dBDVP7PiRhbLI26ECraRL9RTUa XUFo8CD7VzKSlHfrWN/YOvt2QZN1k4KlOn+uEwP/dHVcLS1X1i0prsx/JTXa2g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696237800; a=rsa-sha256; cv=none; b=gxvh7gN7fNlFUlseNkwjq5VPL4XockSlwoqQfXrWztsuWBGYF6FLKCMZLIiZzLW8LQ+m/i 0RElGxv5P8ga4NulpI61bHigbs43aQ2yWf15NcyQMc6biXOZNDtS0P41jM8LY6JGN96+lN wj80uwyiBumu9ZBuJv1AF6cGL2+glqrHJixAqXH8vwkkT0MDuH4+sbU8AvjIleIahc5MON K8v2dKNu+GJYP5rJCBCRuerLXkwHKSxVT1G42nfCMui2MECV+gmje08xnWzQfdXwL2mOPF dzy8PpD/0uJ176x/jo6CndtjOngqxOI9MEGbPu2edca3CP6Wb9UCZv4DE2sIiQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696237800; 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=YnuyjxkIkwqPXBwITYh5raIy/+MmD+yzg/vSjg+e+HE=; b=GQluYgPMGkgCAd3iPBbMhybX6nFwT2NpOy+h+6xOfPDzwzOTqZIIZIf3boOhELG9nIaUo9 zB5HWex/ozpBM4eSEm7cEwYd0VcwDs6EAfYJhaX18G/9pqH0HZxuCmR6VdLTriGfEqc+ov uVaIw195DGNWCHT2+3T91WEpsvZsChRLtPuSZhnfmCX+CokXkymXHTDv+ocl/eaK3IikdU bq1tCeObC1/uFb5wxOFVhuO9ZrrIaZ5+4sYMuyj6W4f8KkhP644jWbWr848ZSMRXj3xG2E 1eUj5O8St6WDD/cvRm3qt3wzMk7xcmlUI8xsi/X855q8eRiyT53ezqcNGbvCDA== 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 4RzZsg6C9nz15ss; Mon, 2 Oct 2023 09:09:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39299xWs053791; Mon, 2 Oct 2023 09:09:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39299xb3053788; Mon, 2 Oct 2023 09:09:59 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:09:59 GMT Message-Id: <202310020909.39299xb3053788@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: 8d6188b13156 - stable/12 - ipfw: Add sysctl flag CTLFLAG_TUN to loader tunables List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/12 X-Git-Reftype: branch X-Git-Commit: 8d6188b13156a4b88f7bf230eb0ef8bf38bad551 Auto-Submitted: auto-generated The branch stable/12 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=8d6188b13156a4b88f7bf230eb0ef8bf38bad551 commit 8d6188b13156a4b88f7bf230eb0ef8bf38bad551 Author: Zhenlei Huang AuthorDate: 2023-09-25 10:10:47 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 09:08:54 +0000 ipfw: Add sysctl flag CTLFLAG_TUN to loader tunables The following sysctl variables are actually loader tunables. Add sysctl flag CTLFLAG_TUN to them so that `sysctl -T` will report them correctly. 1. net.inet.ip.fw.enable 2. net.inet6.ip6.fw.enable 3. net.link.ether.ipfw No functional change intended. Reviewed by: glebius MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41928 (cherry picked from commit 49197c391b3d49a33bcd08471bf64d533cd10f9d) (cherry picked from commit f5f6da90597cb65ce55c4f17718a200097f6f78f) (cherry picked from commit 09f08dbe248e6ffd031c1eff26aeacef0c6880e9) --- sys/netpfil/ipfw/ip_fw_pfil.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/netpfil/ipfw/ip_fw_pfil.c b/sys/netpfil/ipfw/ip_fw_pfil.c index ca8a9aa1ba13..084be4a60f05 100644 --- a/sys/netpfil/ipfw/ip_fw_pfil.c +++ b/sys/netpfil/ipfw/ip_fw_pfil.c @@ -96,18 +96,18 @@ SYSBEGIN(f1) SYSCTL_DECL(_net_inet_ip_fw); SYSCTL_PROC(_net_inet_ip_fw, OID_AUTO, enable, - CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE3, + CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_SECURE3, &VNET_NAME(fw_enable), 0, ipfw_chg_hook, "I", "Enable ipfw"); #ifdef INET6 SYSCTL_DECL(_net_inet6_ip6_fw); SYSCTL_PROC(_net_inet6_ip6_fw, OID_AUTO, enable, - CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE3, + CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_SECURE3, &VNET_NAME(fw6_enable), 0, ipfw_chg_hook, "I", "Enable ipfw+6"); #endif /* INET6 */ SYSCTL_DECL(_net_link_ether); SYSCTL_PROC(_net_link_ether, OID_AUTO, ipfw, - CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE3, + CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_SECURE3, &VNET_NAME(fwlink_enable), 0, ipfw_chg_hook, "I", "Pass ether pkts through firewall"); From nobody Mon Oct 2 09:10:00 2023 X-Original-To: dev-commits-src-branches@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 4RzZsj2Y13z4vq41; Mon, 2 Oct 2023 09:10: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzZsj0KyWz4PC1; Mon, 2 Oct 2023 09:10:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696237801; 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=0N4ghL047wj8eFjwSB4kbhjMigT4MSk8p8dXv9R1jdc=; b=q0UuK1Y3+MnV+WiI1Mq6rYehNpxzq+tIjPMcAVBCV+rGyzFjgJcW3Sj0jgvFu8RxHtIy3e Y60QZRCENM7F87QzcMpS/bK3lGfH1wVHqKRqialk/XJA0WMX7+kcTnt/zc6f4TZXBN2h5E TPA7FBN1Ulz/FI3z3dJ5x7W07Uw6I3ZOUfCMp/3JT6qtMk5+QBGUjQkl5VMeMkbCKB1bB0 Q1A8CTbiA9NiIyc1k2c8K97jYwBeu4CEKm7ehROBva2tDdG9RYoGt4+M3eyQFM8qn4PQFH FN0M4MMBUu/iQtR16xm6GpmDVLEzfpWs8/42/I4qHTbVwM/eTd0kYEzgJiKz7g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696237801; a=rsa-sha256; cv=none; b=Q5M2T2Xrevz9WoI8h02y32F+ImZUp4hIFwhAP4WsIURKCXMtgvTNb3dT+SQcnOCm2IhqvF VTzKCj9O/UBum0+3MQ1mm/9hA9MBSzi8GYodPyKYRHbXXgt3qGm228RbtuPlNX/WXbtmHf OEvZH02IwdouxdQndFzUcdVLX2MqLndlrvFvU+TEboeOddrBGxrD6NE7nLPz+2rI29biir Ko/qiv3JNxpCBwyUBeRYGEMc2mEjlY7FMQUIX7AnH9nws2pS5KtziJxGKz0msnmwUSWsmX 49r8RpbwerbD7qJt0hgFE4IYt65MWlEdOG/YkC1yL+6SFMhZUiLXSc7J0cQQtg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696237801; 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=0N4ghL047wj8eFjwSB4kbhjMigT4MSk8p8dXv9R1jdc=; b=XROR4BiF6cMglp/ek1oZEki5E2TBhooDVLgo4DJYKZ8lqcMjK9lxSwrCFmcT9l/oqHhUp/ IyDsHCleAWLh3A5HqpuIF1eryXFBxb+ePrZDGbau682MlUmcXj3pRfoUoHqw+ASQndmUry 4yNSFxPCev85ez2N4ak9s/PSXvsSmIKVhW9Af4kgFdU3m3Z53ugISXH5A5PZaAEzN7LlLr ESLEN8MT3aOZ5rv4Z+8AN7iyMoMaE8pCf+EskMpnSwptCEBDz9GEfyXOz28L5rekxsOpX+ DlgPZO+LILnr0WGP/3so5DCQB+jdIv7kr2/2Wizr2tPY2lZnsbPLlmYfnNWnXA== 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 4RzZsh6Y2xz15h5; Mon, 2 Oct 2023 09:10:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929A0x2055590; Mon, 2 Oct 2023 09:10:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929A0SH055587; Mon, 2 Oct 2023 09:10:00 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:10:00 GMT Message-Id: <202310020910.3929A0SH055587@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: 6b8183c70caa - stable/12 - ipfw.8: Adjust section for loader tunables List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/12 X-Git-Reftype: branch X-Git-Commit: 6b8183c70caaa4c8b29e8528d86ff99616da4d47 Auto-Submitted: auto-generated The branch stable/12 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=6b8183c70caaa4c8b29e8528d86ff99616da4d47 commit 6b8183c70caaa4c8b29e8528d86ff99616da4d47 Author: Zhenlei Huang AuthorDate: 2023-09-28 04:58:44 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 09:08:55 +0000 ipfw.8: Adjust section for loader tunables Move the descriptions of loader tunables from section 'SYSCTL VARIABLES' to section 'LOADER TUNABLES'. See also 49197c391b3d (ipfw: Add sysctl flag CTLFLAG_TUN to loader tunables). MFC after: 2 days Differential Revision: https://reviews.freebsd.org/D41981 (cherry picked from commit 12349f38898f231ca803dcf526bac88cb1b5cd2b) (cherry picked from commit bb6f9a95402a6c3ab8167481b81465f8ad5016fc) (cherry picked from commit e31a331ddda6ffcb711bb950794be5d53e537e2a) --- sbin/ipfw/ipfw.8 | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/sbin/ipfw/ipfw.8 b/sbin/ipfw/ipfw.8 index 512ad5baf90e..cdf9cc29fe3b 100644 --- a/sbin/ipfw/ipfw.8 +++ b/sbin/ipfw/ipfw.8 @@ -1,7 +1,7 @@ .\" .\" $FreeBSD$ .\" -.Dd April 25, 2023 +.Dd September 28, 2023 .Dt IPFW 8 .Os .Sh NAME @@ -3683,6 +3683,16 @@ or .Xr kenv 1 before ipfw module gets loaded. .Bl -tag -width indent +.It Va net.inet.ip.fw.enable : No 1 +Enables the firewall. +Setting this variable to 0 lets you run your machine without +firewall even if compiled in. +.It Va net.inet6.ip6.fw.enable : No 1 +provides the same functionality as above for the IPv6 case. +.It Va net.link.ether.ipfw : No 0 +Controls whether layer2 packets are passed to +.Nm . +Default is no. .It Va net.inet.ip.fw.default_to_accept : No 0 Defines ipfw last rule behavior. This value overrides @@ -4076,12 +4086,6 @@ Keep dynamic states on rule/set deletion. States are relinked to default rule (65535). This can be handly for ruleset reload. Turned off by default. -.It Va net.inet.ip.fw.enable : No 1 -Enables the firewall. -Setting this variable to 0 lets you run your machine without -firewall even if compiled in. -.It Va net.inet6.ip6.fw.enable : No 1 -provides the same functionality as above for the IPv6 case. .It Va net.inet.ip.fw.one_pass : No 1 When set, the packet exiting from the .Nm dummynet @@ -4098,10 +4102,6 @@ Enables verbose messages. Limits the number of messages produced by a verbose firewall. .It Va net.inet6.ip6.fw.deny_unknown_exthdrs : No 1 If enabled packets with unknown IPv6 Extension Headers will be denied. -.It Va net.link.ether.ipfw : No 0 -Controls whether layer2 packets are passed to -.Nm . -Default is no. .It Va net.link.bridge.ipfw : No 0 Controls whether bridged packets are passed to .Nm . From nobody Mon Oct 2 09:10:01 2023 X-Original-To: dev-commits-src-branches@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 4RzZsk2DZjz4vplp; Mon, 2 Oct 2023 09:10: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzZsk1CJPz4PG4; Mon, 2 Oct 2023 09:10:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696237802; 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=Nk+Mji7ejtL42aBQCRxPf4BmeEp05g6PG5Ha/qn5W1k=; b=Pa+5lBZbUdmgFIdwPkww+e3QLGkIj3AqNDnp062p390sHpNAx3OuUfGSgfWI7tjL66yB1K GvXUq+IDUrgnAeMpdAI58eQqK9UbQgMgaBQyzybgbHM1OkQ57UujVY+HHoeG8k1RaFT/6I B1++JhHjFx1mtjdA29WWCOU0QxMvwRq1+AqWC+4dYgZwpbIObPn9RNxafdmbp2ySKRLFZb GVNhauqVyXTPizO/iGp9T4zjZ/Xwuphk41q4sacDd1rBxb22u577bbzx/KTyX8C64XRHYI 4c86FT0aJud4kqwm7BX6cI2TN485LZCviFni2Yo7c5BZ3dXieM92BB+9/hdTGA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696237802; a=rsa-sha256; cv=none; b=C0D5cpARn6CBpzcP/8de8CJ+Zb0zIvQso371Tjjo9PlhZ80zZ8h+rswd1oKlWKLKlLNLID RmkshGc2UFyNiD5qBPIETtGsOXNqvqfkuzaIR2gCYNX0dIhxigeMSHJyGpl7iVw0cAk6eo yF+SgNC9p4J1KEFLfyRzAALJ3Y7P8+f/DDyohXNsa/Y7wjCSDBTw70qaRGhRuyUzrlknMs Z+BrVxOFytIuu04Tab5CgULZ4/ZZwAT4/Z590k8zF2UBolWxO4KXMYn07TiQHjA4fykKZE NsksN8soLUpWBiIK6CXA+l/Z2WHOQFnaZXuEfdWs+RZuDOBZ8Q6V8Jyk33Psjg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696237802; 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=Nk+Mji7ejtL42aBQCRxPf4BmeEp05g6PG5Ha/qn5W1k=; b=oNy2BOSC6+jo38GtexfbvU8NSlixuEMrY++esqJkqIYD9r97t8/XOkjuef6AT7SxRbYicd kEtAjU7GdJz/oa7r6cqfSytzgsYEF6yHd9aB1vH5lT1w8WGN8NOAgvs+SMReZD8Rcqduri s63C7jprnDtirw5dkAuXMdT8IF2lNy9/sxjAXWXZrZD4WlpyB70VCErPpxtHqKDu3pVJ0G lCQqOXUHjp1UNC7oLDCyr1P1sCEVTojPC9exAd5UZIAfeoCUsjTWaoxpuO1OYvrNKCJtvW t2r59776H3cgW11Uor57VgzE5rmVz7tSz7I5Lz2fb58bt4+X9LIgdONF1sC1Cw== 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 4RzZsk0FDBz15Rr; Mon, 2 Oct 2023 09:10:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929A1Ms055861; Mon, 2 Oct 2023 09:10:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929A1tv055857; Mon, 2 Oct 2023 09:10:01 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:10:01 GMT Message-Id: <202310020910.3929A1tv055857@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: 6a6202b4cc8c - stable/12 - ip_mroute: Fix sysctl knobs List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/12 X-Git-Reftype: branch X-Git-Commit: 6a6202b4cc8cff663c94a3f78a47d171cfe0938c Auto-Submitted: auto-generated The branch stable/12 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=6a6202b4cc8cff663c94a3f78a47d171cfe0938c commit 6a6202b4cc8cff663c94a3f78a47d171cfe0938c Author: Zhenlei Huang AuthorDate: 2023-09-27 16:23:22 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 09:08:55 +0000 ip_mroute: Fix sysctl knobs The loader tunable `net.inet.ip.mfchashsize` does not have corresponding sysctl MIB entry. Just add it. While here, the sysctl variable `net.inet.pim.squelch_wholepkt` is actually a loader tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` will report it correctly. Reviewed by: kp Fixes: 443fc3176dee Introduce a number of changes to the MROUTING code MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41997 (cherry picked from commit f549e22901b3a391c76659bee55802b1214112fd) (cherry picked from commit b0f026435a150933ecb6f2d1359fd1b4898657f1) (cherry picked from commit ef3edef9ec8b7d19e5f66c385340604ab29ccc78) --- sys/netinet/ip_mroute.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/sys/netinet/ip_mroute.c b/sys/netinet/ip_mroute.c index 92074670cf60..fb96a9ccdb43 100644 --- a/sys/netinet/ip_mroute.c +++ b/sys/netinet/ip_mroute.c @@ -163,7 +163,9 @@ VNET_DEFINE_STATIC(u_long, mfchash); ((g).s_addr >> 20) ^ ((g).s_addr >> 10) ^ (g).s_addr) & V_mfchash) #define MFCHASHSIZE 256 -static u_long mfchashsize; /* Hash size */ +static u_long mfchashsize = MFCHASHSIZE; /* Hash size */ +SYSCTL_ULONG(_net_inet_ip, OID_AUTO, mfchashsize, CTLFLAG_RDTUN, + &mfchashsize, 0, "IPv4 Multicast Forwarding Table hash size"); VNET_DEFINE_STATIC(u_char *, nexpire); /* 0..mfchashsize-1 */ #define V_nexpire VNET(nexpire) VNET_DEFINE_STATIC(LIST_HEAD(mfchashhdr, mfc)*, mfchashtbl); @@ -235,7 +237,7 @@ SYSCTL_VNET_PCPUSTAT(_net_inet_pim, PIMCTL_STATS, stats, struct pimstat, pimstat, "PIM Statistics (struct pimstat, netinet/pim_var.h)"); static u_long pim_squelch_wholepkt = 0; -SYSCTL_ULONG(_net_inet_pim, OID_AUTO, squelch_wholepkt, CTLFLAG_RW, +SYSCTL_ULONG(_net_inet_pim, OID_AUTO, squelch_wholepkt, CTLFLAG_RWTUN, &pim_squelch_wholepkt, 0, "Disable IGMP_WHOLEPKT notifications if rendezvous point is unspecified"); @@ -2876,18 +2878,12 @@ ip_mroute_modevent(module_t mod, int type, void *unused) MFC_LOCK_INIT(); VIF_LOCK_INIT(); - mfchashsize = MFCHASHSIZE; - if (TUNABLE_ULONG_FETCH("net.inet.ip.mfchashsize", &mfchashsize) && - !powerof2(mfchashsize)) { + if (!powerof2(mfchashsize)) { printf("WARNING: %s not a power of 2; using default\n", "net.inet.ip.mfchashsize"); mfchashsize = MFCHASHSIZE; } - pim_squelch_wholepkt = 0; - TUNABLE_ULONG_FETCH("net.inet.pim.squelch_wholepkt", - &pim_squelch_wholepkt); - pim_encap_cookie = ip_encap_attach(&ipv4_encap_cfg, NULL, M_WAITOK); ip_mcast_src = X_ip_mcast_src; From nobody Mon Oct 2 09:10:03 2023 X-Original-To: dev-commits-src-branches@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 4RzZsl2K1bz4vpy2; Mon, 2 Oct 2023 09:10: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzZsl1XrYz4PPB; Mon, 2 Oct 2023 09:10:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696237803; 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=CVvs3I6jWAhtF3J0boYv4rGMZaajQkJP0YfTMxVDG7A=; b=T95emTNqmNs4YU4NH2bqfRNLehXaxJtHdhwuFx+pyZ1pYJyGXwIQHCXqoS1GwhTzVGSbhg +mwidwuCXP0Hlaxo+KfSA22l90K0Go53+EYHfeXNqlPUGjBWeRVddAY91b77TK0gz4fy2N glHx11Mdd0QGev32wGC3CoHNkEYnIZZ1vjc80uGVP8t1DWcRskfjozdfP2fPFvaKEFYNBH FoBbKtBP58k3Ql6b15rw+IBQfAclLdw1kCfF0wLeKv8+MlBlvm530U/hxffZSzMel9+lc5 Od/iKkTlKeLTmjW8Ko8tSkhnicRPhQ60oW4Yhn7YuISp02MD2y1NoxptHlKUbg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696237803; a=rsa-sha256; cv=none; b=OpKlHfFYEhcnSh9L799oL7FepNoglPgCTmBCeoncCk8gkmla11OwasCA2V1phSWHmpELj2 hpfDNYMzwobpboEZvEPlAXjD21PnW4TBw1cRQE7B6mEgUUaXf+hOuaUW/BcG56QLCGOrHC VITJJZloxc0jVZU0AetxduYVaWLJnje/Wdr/yBVW60OOir6XDDtAPTkIabPDl4IwElpPrP OSP+kakLlsBhvqYLazzL9btmQLwiYOCINsKqaQb9EIasz+WPfL+peoyx8qgbJpt2mq5ZMY v1qOh7Fb7zgQTZydowVVe1UrwiGVEzo4rsH3gY6Rq0FpdHeLkWFLRM9lJQEomQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696237803; 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=CVvs3I6jWAhtF3J0boYv4rGMZaajQkJP0YfTMxVDG7A=; b=maX4ugvwH+0eLEcxLL6NPLokfLcj8fXVW5c0vNDB/Dd+s4ZvaVY4oK2CuaCju5tskMQfpU scVxW/m44JQRl+qGPmHultrVeZ82elXTflo+Bv+tfGvtF15vbU2Iu7mfbD4cnofUpYYqXu vcmZZS19HI9h72rkmYApCsPAGSxExvg49/1xF0DkQAEPeHvmE3o31cw82j0Mu2LHZXm2p7 SZLScBu2Y7AKb+tvnPh6on1wYETaYm/5nHCaun7SU2y8bt2QsAl1zMP9hXbqXmExbQd/Q9 4POdjA3W9MfBQ6FCdVDHpPyfCeDduldI0IzBcAGzK6msmRhD/gTFbiDSeWSt/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 4RzZsl0ckvz15h6; Mon, 2 Oct 2023 09:10:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929A34o056151; Mon, 2 Oct 2023 09:10:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929A3X5056147; Mon, 2 Oct 2023 09:10:03 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:10:03 GMT Message-Id: <202310020910.3929A3X5056147@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: 3f44d7870593 - stable/12 - ipfilter: Add sysctl flag CTLFLAG_TUN to loader tunable List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/12 X-Git-Reftype: branch X-Git-Commit: 3f44d7870593bc7fd116a27310138646a00d3fff Auto-Submitted: auto-generated The branch stable/12 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=3f44d7870593bc7fd116a27310138646a00d3fff commit 3f44d7870593bc7fd116a27310138646a00d3fff Author: Zhenlei Huang AuthorDate: 2023-09-29 00:01:43 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-02 09:08:55 +0000 ipfilter: Add sysctl flag CTLFLAG_TUN to loader tunable The sysctl variable `net.inet.ipf.large_nat` is actually a loader tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` will report it correctly. No functional change intended. Reviewed by: cy (for #network) Fixes: a805ffbcbce8 ipfilter: Make LARGE_NAT a tunable MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D42005 (cherry picked from commit ba883e7a5ac43b27a373f2b1b0044fd2eb769d4e) (cherry picked from commit a9359dcde241f17421a71bc8c96dee08625db9dd) (cherry picked from commit 25c371dc559a9ea23905baa5cbfed3f6d9d6eb5c) --- sys/netpfil/ipfilter/netinet/mlfk_ipl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c b/sys/netpfil/ipfilter/netinet/mlfk_ipl.c index 0b37dab558aa..33153cca246e 100644 --- a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c +++ b/sys/netpfil/ipfilter/netinet/mlfk_ipl.c @@ -131,7 +131,7 @@ SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_running, CTLFLAG_RD, &VNET_NAME(ipfmain.ipf_running), 0, "IPF is running"); SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_chksrc, CTLFLAG_RW, &VNET_NAME(ipfmain.ipf_chksrc), 0, ""); SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_minttl, CTLFLAG_RW, &VNET_NAME(ipfmain.ipf_minttl), 0, ""); -SYSCTL_IPF(_net_inet_ipf, OID_AUTO, large_nat, CTLFLAG_RD, &VNET_NAME(ipfmain.ipf_large_nat), 0, "large_nat"); +SYSCTL_IPF(_net_inet_ipf, OID_AUTO, large_nat, CTLFLAG_RDTUN | CTLFLAG_NOFETCH, &VNET_NAME(ipfmain.ipf_large_nat), 0, "large_nat"); #define CDEV_MAJOR 79 #include From nobody Mon Oct 2 09:33:22 2023 X-Original-To: dev-commits-src-branches@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 4RzbNf4ZVcz4vrcL; Mon, 2 Oct 2023 09:33:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNf461Wz4SP5; Mon, 2 Oct 2023 09:33:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239202; 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=XOVb0BZfZtmYchr/ZATklF/RV4TPWQiQaltkkSeArLA=; b=RqxqHH7HaVfENOMeDuPRJz8zFB60TzOeT8K5j+Iy+tfH5q47+xwHktnNHQIPESUop5/jsf WK7V+VVhnObQrIQiIWYnopPavpqZhbAwgebdIrAKCduAW1F7d4Tb1f7Cyb4plUQ4ZTooWH dIq8VNZsrk/iGch6PBGQqHjlOAjsVo/kdH/6nWI7r4wBQ9JS9PUfWMahmEDzgu13AJJbOo 4EqkeNz8WvoaGrFiYVmIxMRU43+qn1Zhu2FzlyDZ7cGeGswlH7CsP+VT9oQDF3wA0Yjewj 0x9YAHa+p/268NoRXkFJhiA3N71OG9JbZbq9rBLiZ4T7qrAodYYEq/6D/SlCeQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239202; a=rsa-sha256; cv=none; b=T3dMPbz2Zmd/x7yo72ObLRSuq3V249y/okP1k+67t5u3C2TSbe1IRJ/pEsrUg4N8f8TtSv G7zLd4ue0kUP2c0XR/+OCBH28dsGKNUzUVtkjnL4vZNbne4TyGTQvqgQSkxp4eg8dUHVIa lAAOge8T5ThI0Czx0LUcoY+Pof8CrOFD7QNiYCkNMeLJfjVDBIAjR0uUfMJRIl5XRvmNuX 1W34wyG/8DKzEG4f2A5B8fyrzab35mViH8h/0ulSoRynLvOMO4jT3a2ykDsj6zsqEUAm+W rDrVvUGgv/YtD8nCmf1oMzFHJ0/Vaj1ZfbkvqrjcN0pvgBXeejoWuXUGPMi5ew== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239202; 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=XOVb0BZfZtmYchr/ZATklF/RV4TPWQiQaltkkSeArLA=; b=ywzVGCsU2liVcdRzNWsFDObGh2l9iIb7ZbivA56ZPZgNMLuGM2pACLyIjtpPVRplqiRhj+ I4g3taArHBNeq6ip0qgCk0918ghpM0FBcolzOIKOKAvnFF5T05j62rHhYVUieGD5+aMl0z guTlZ1Eh2enw4bFxSePZCXc/ZqGaPYB21zjzYQyOfe9/Tvknlm7F1M4JrgnoE5UC2I4LrO dfgl1zOoSgiWMTDIru07UY/RYfyjrBwLo34p1tnlemPkVAbpj2KS09GMfhqxTrh2amQzUA AEWY1kT63K3PbEvJG2ewh4OLj24hSdP+uv9X8VLnumdyAYS5cPnFUtxLUsLD6w== 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 4RzbNf38nvz16c4; Mon, 2 Oct 2023 09:33:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XMMM002646; Mon, 2 Oct 2023 09:33:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XMuR002643; Mon, 2 Oct 2023 09:33:22 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:22 GMT Message-Id: <202310020933.3929XMuR002643@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 0ac8d8d9954f - stable/14 - pf: support SCTP multihoming List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 0ac8d8d9954f2d446d4fa7a5f154d55931f3d1f1 Auto-Submitted: auto-generated The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=0ac8d8d9954f2d446d4fa7a5f154d55931f3d1f1 commit 0ac8d8d9954f2d446d4fa7a5f154d55931f3d1f1 Author: Kristof Provost AuthorDate: 2023-08-02 17:05:00 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 09:32:14 +0000 pf: support SCTP multihoming SCTP may announce additional IP addresses it'll use in the INIT/INIT_ACK chunks, or in ASCONF chunks at any time during the connection. Parse these parameters, evaluate the ruleset for the new connection and if allowed create the corresponding states. MFC after: 3 weeks Sponsored by: Orange Business Services Differential Revision: https://reviews.freebsd.org/D41637 (cherry picked from commit 10aa9ddb4d45ab0c8f56b0e91c7e8de213030c0f) --- sys/net/pfvar.h | 22 +++++- sys/netpfil/pf/pf.c | 186 ++++++++++++++++++++++++++++++++++++++++++++++- sys/netpfil/pf/pf_norm.c | 34 +++++++-- 3 files changed, 231 insertions(+), 11 deletions(-) diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h index f9cb45f696d3..ec72c1079c70 100644 --- a/sys/net/pfvar.h +++ b/sys/net/pfvar.h @@ -1531,6 +1531,9 @@ struct pfi_kkif { #define PFI_IFLAG_SKIP 0x0100 /* skip filtering on interface */ #ifdef _KERNEL +struct pf_sctp_multihome_job; +TAILQ_HEAD(pf_sctp_multihome_jobs, pf_sctp_multihome_job); + struct pf_pdesc { struct { int done; @@ -1578,10 +1581,22 @@ struct pf_pdesc { #define PFDESC_SCTP_SHUTDOWN 0x0010 #define PFDESC_SCTP_SHUTDOWN_COMPLETE 0x0020 #define PFDESC_SCTP_DATA 0x0040 -#define PFDESC_SCTP_OTHER 0x0080 +#define PFDESC_SCTP_ASCONF 0x0080 +#define PFDESC_SCTP_OTHER 0x0100 u_int16_t sctp_flags; u_int32_t sctp_initiate_tag; + + struct pf_sctp_multihome_jobs sctp_multihome_jobs; +}; + +struct pf_sctp_multihome_job { + TAILQ_ENTRY(pf_sctp_multihome_job) next; + struct pf_pdesc pd; + struct pf_addr src; + struct pf_addr dst; + struct mbuf *m; }; + #endif /* flags for RDR options */ @@ -2253,6 +2268,11 @@ void pf_addr_inc(struct pf_addr *, sa_family_t); int pf_refragment6(struct ifnet *, struct mbuf **, struct m_tag *, bool); #endif /* INET6 */ +int pf_multihome_scan_init(struct mbuf *, int, int, struct pf_pdesc *, + struct pfi_kkif *); +int pf_multihome_scan_asconf(struct mbuf *, int, int, struct pf_pdesc *, + struct pfi_kkif *); + u_int32_t pf_new_isn(struct pf_kstate *); void *pf_pull_hdr(struct mbuf *, int, void *, int, u_short *, u_short *, sa_family_t); diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 7cee0833072b..69373b720ad9 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -126,6 +126,8 @@ SDT_PROBE_DEFINE4(pf, ip, test6, done, "int", "int", "struct pf_krule *", SDT_PROBE_DEFINE5(pf, ip, state, lookup, "struct pfi_kkif *", "struct pf_state_key_cmp *", "int", "struct pf_pdesc *", "struct pf_kstate *"); +SDT_PROBE_DEFINE4(pf, sctp, multihome, test, "struct pfi_kkif *", + "struct pf_krule *", "struct mbuf *", "int"); SDT_PROBE_DEFINE3(pf, eth, test_rule, entry, "int", "struct ifnet *", "struct mbuf *"); @@ -307,6 +309,8 @@ static int pf_test_state_udp(struct pf_kstate **, static int pf_test_state_icmp(struct pf_kstate **, struct pfi_kkif *, struct mbuf *, int, void *, struct pf_pdesc *, u_short *); +static void pf_sctp_multihome_delayed(struct pf_pdesc *, int, + struct pfi_kkif *, struct pf_kstate *); static int pf_test_state_sctp(struct pf_kstate **, struct pfi_kkif *, struct mbuf *, int, void *, struct pf_pdesc *, u_short *); @@ -5911,6 +5915,174 @@ pf_test_state_sctp(struct pf_kstate **state, struct pfi_kkif *kif, return (PF_PASS); } +static void +pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, + struct pf_kstate *s) +{ + struct pf_sctp_multihome_job *j, *tmp; + int action;; + struct pf_kstate *sm = NULL; + struct pf_krule *ra = NULL; + struct pf_krule *r = &V_pf_default_rule; + struct pf_kruleset *rs = NULL; + + PF_RULES_RLOCK_TRACKER; + + TAILQ_FOREACH_SAFE(j, &pd->sctp_multihome_jobs, next, tmp) { + PF_RULES_RLOCK(); + action = pf_test_rule(&r, &sm, kif, + j->m, off, &j->pd, &ra, &rs, NULL); + PF_RULES_RUNLOCK(); + SDT_PROBE4(pf, sctp, multihome, test, kif, r, j->m, action); + if (sm) + PF_STATE_UNLOCK(sm); + + free(j, M_PFTEMP); + } +} + +static int +pf_multihome_scan(struct mbuf *m, int start, int len, struct pf_pdesc *pd, + struct pfi_kkif *kif) +{ + int off = 0; + struct pf_sctp_multihome_job *job; + + while (off < len) { + struct sctp_paramhdr h; + + if (!pf_pull_hdr(m, start + off, &h, sizeof(h), NULL, NULL, + pd->af)) + return (PF_DROP); + + /* Parameters are at least 4 bytes. */ + if (ntohs(h.param_length) < 4) + return (PF_DROP); + + switch (ntohs(h.param_type)) { + case SCTP_IPV4_ADDRESS: { + struct in_addr t; + + if (ntohs(h.param_length) != + (sizeof(struct sctp_paramhdr) + sizeof(t))) + return (PF_DROP); + + if (!pf_pull_hdr(m, start + off + sizeof(h), &t, sizeof(t), + NULL, NULL, pd->af)) + return (PF_DROP); + + /* + * Avoid duplicating states. We'll already have + * created a state based on the source address of + * the packet, but SCTP endpoints may also list this + * address again in the INIT(_ACK) parameters. + */ + if (t.s_addr == pd->src->v4.s_addr) + break; + + if (in_nullhost(t)) + t.s_addr = pd->src->v4.s_addr; + + /* + * We hold the state lock (idhash) here, which means + * that we can't acquire the keyhash, or we'll get a + * LOR (and potentially double-lock things too). We also + * can't release the state lock here, so instead we'll + * enqueue this for async handling. + * There's a relatively small race here, in that a + * packet using the new addresses could arrive already, + * but that's just though luck for it. + */ + job = malloc(sizeof(*job), M_PFTEMP, M_NOWAIT | M_ZERO); + if (! job) + return (PF_DROP); + + memcpy(&job->pd, pd, sizeof(*pd)); + + // New source address! + memcpy(&job->src, &t, sizeof(t)); + job->pd.src = &job->src; + memcpy(&job->dst, pd->dst, sizeof(job->dst)); + job->pd.dst = &job->dst; + job->m = m; + + TAILQ_INSERT_TAIL(&pd->sctp_multihome_jobs, job, next); + break; + } +#ifdef INET6 + case SCTP_IPV6_ADDRESS: { + struct in6_addr t; + + if (ntohs(h.param_length) != + (sizeof(struct sctp_paramhdr) + sizeof(t))) + return (PF_DROP); + + if (!pf_pull_hdr(m, start + off + sizeof(h), &t, sizeof(t), + NULL, NULL, pd->af)) + return (PF_DROP); + if (memcmp(&t, &pd->src->v6, sizeof(t)) == 0) + break; + if (memcmp(&t, &in6addr_any, sizeof(t)) == 0) + memcpy(&t, &pd->src->v6, sizeof(t)); + + job = malloc(sizeof(*job), M_PFTEMP, M_NOWAIT | M_ZERO); + if (! job) + return (PF_DROP); + + memcpy(&job->pd, pd, sizeof(*pd)); + memcpy(&job->src, &t, sizeof(t)); + job->pd.src = &job->src; + memcpy(&job->dst, pd->dst, sizeof(job->dst)); + job->pd.dst = &job->dst; + job->m = m; + + TAILQ_INSERT_TAIL(&pd->sctp_multihome_jobs, job, next); + break; + } +#endif + case SCTP_ADD_IP_ADDRESS: { + int ret; + struct sctp_asconf_paramhdr ah; + + if (!pf_pull_hdr(m, start + off, &ah, sizeof(ah), + NULL, NULL, pd->af)) + return (PF_DROP); + + ret = pf_multihome_scan(m, start + off + sizeof(ah), + ntohs(ah.ph.param_length) - sizeof(ah), pd, kif); + if (ret != PF_PASS) + return (ret); + break; + } + default: + break; + } + + off += roundup(ntohs(h.param_length), 4); + } + + return (PF_PASS); +} +int +pf_multihome_scan_init(struct mbuf *m, int start, int len, struct pf_pdesc *pd, + struct pfi_kkif *kif) +{ + start += sizeof(struct sctp_init_chunk); + len -= sizeof(struct sctp_init_chunk); + + return (pf_multihome_scan(m, start, len, pd, kif)); +} + +int +pf_multihome_scan_asconf(struct mbuf *m, int start, int len, + struct pf_pdesc *pd, struct pfi_kkif *kif) +{ + start += sizeof(struct sctp_asconf_chunk); + len -= sizeof(struct sctp_asconf_chunk); + + return (pf_multihome_scan(m, start, len, pd, kif)); +} + static int pf_test_state_icmp(struct pf_kstate **state, struct pfi_kkif *kif, struct mbuf *m, int off, void *h, struct pf_pdesc *pd, u_short *reason) @@ -7411,6 +7583,7 @@ pf_test(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, } memset(&pd, 0, sizeof(pd)); + TAILQ_INIT(&pd.sctp_multihome_jobs); if (default_actions != NULL) memcpy(&pd.act, default_actions, sizeof(pd.act)); pd.pf_mtag = pf_find_mtag(m); @@ -7612,6 +7785,8 @@ pf_test(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, pd.act.log |= PF_LOG_FORCE; goto done; } + pd.p_len = pd.tot_len - off; + pd.sport = &pd.hdr.sctp.src_port; pd.dport = &pd.hdr.sctp.dest_port; if (pd.hdr.sctp.src_port == 0 || pd.hdr.sctp.dest_port == 0) { @@ -7895,7 +8070,7 @@ done: /* pf_route() returns unlocked. */ if (rt) { pf_route(m0, r, kif->pfik_ifp, s, &pd, inp); - return (action); + goto out; } if (pf_dummynet(&pd, s, r, m0) != 0) { action = PF_DROP; @@ -7909,6 +8084,9 @@ done: if (s) PF_STATE_UNLOCK(s); +out: + pf_sctp_multihome_delayed(&pd, off, kif, s); + return (action); } #endif /* INET */ @@ -7958,6 +8136,7 @@ pf_test6(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb } memset(&pd, 0, sizeof(pd)); + TAILQ_INIT(&pd.sctp_multihome_jobs); if (default_actions != NULL) memcpy(&pd.act, default_actions, sizeof(pd.act)); pd.pf_mtag = pf_find_mtag(m); @@ -8440,7 +8619,7 @@ done: /* pf_route6() returns unlocked. */ if (rt) { pf_route6(m0, r, kif->pfik_ifp, s, &pd, inp); - return (action); + goto out; } if (pf_dummynet(&pd, s, r, m0) != 0) { action = PF_DROP; @@ -8457,8 +8636,11 @@ done: (mtag = m_tag_find(m, PACKET_TAG_PF_REASSEMBLED, NULL)) != NULL) action = pf_refragment6(ifp, m0, mtag, pflags & PFIL_FWD); +out: SDT_PROBE4(pf, ip, test6, done, action, reason, r, s); + pf_sctp_multihome_delayed(&pd, off, kif, s); + return (action); } #endif /* INET6 */ diff --git a/sys/netpfil/pf/pf_norm.c b/sys/netpfil/pf/pf_norm.c index 8f532ad08c46..83b94db87a19 100644 --- a/sys/netpfil/pf/pf_norm.c +++ b/sys/netpfil/pf/pf_norm.c @@ -2021,11 +2021,13 @@ pf_normalize_mss(struct mbuf *m, int off, struct pf_pdesc *pd) } static int -pf_scan_sctp(struct mbuf *m, int ipoff, int off, struct pf_pdesc *pd) +pf_scan_sctp(struct mbuf *m, int ipoff, int off, struct pf_pdesc *pd, + struct pfi_kkif *kif) { struct sctp_chunkhdr ch = { }; int chunk_off = sizeof(struct sctphdr); int chunk_start; + int ret; while (off + chunk_off < pd->tot_len) { if (!pf_pull_hdr(m, off + chunk_off, &ch, sizeof(ch), NULL, @@ -2040,7 +2042,8 @@ pf_scan_sctp(struct mbuf *m, int ipoff, int off, struct pf_pdesc *pd) chunk_off += roundup(ntohs(ch.chunk_length), 4); switch (ch.chunk_type) { - case SCTP_INITIATION: { + case SCTP_INITIATION: + case SCTP_INITIATION_ACK: { struct sctp_init_chunk init; if (!pf_pull_hdr(m, off + chunk_start, &init, @@ -2064,17 +2067,24 @@ pf_scan_sctp(struct mbuf *m, int ipoff, int off, struct pf_pdesc *pd) * RFC 9260, Section 3.1, INIT chunks MUST have zero * verification tag. */ - if (pd->hdr.sctp.v_tag != 0) + if (ch.chunk_type == SCTP_INITIATION && + pd->hdr.sctp.v_tag != 0) return (PF_DROP); pd->sctp_initiate_tag = init.init.initiate_tag; - pd->sctp_flags |= PFDESC_SCTP_INIT; + if (ch.chunk_type == SCTP_INITIATION) + pd->sctp_flags |= PFDESC_SCTP_INIT; + else + pd->sctp_flags |= PFDESC_SCTP_INIT_ACK; + + ret = pf_multihome_scan_init(m, off + chunk_start, + ntohs(init.ch.chunk_length), pd, kif); + if (ret != PF_PASS) + return (ret); + break; } - case SCTP_INITIATION_ACK: - pd->sctp_flags |= PFDESC_SCTP_INIT_ACK; - break; case SCTP_ABORT_ASSOCIATION: pd->sctp_flags |= PFDESC_SCTP_ABORT; break; @@ -2092,6 +2102,14 @@ pf_scan_sctp(struct mbuf *m, int ipoff, int off, struct pf_pdesc *pd) case SCTP_DATA: pd->sctp_flags |= PFDESC_SCTP_DATA; break; + case SCTP_ASCONF: + pd->sctp_flags |= PFDESC_SCTP_ASCONF; + + ret = pf_multihome_scan_asconf(m, off + chunk_start, + ntohs(ch.chunk_length), pd, kif); + if (ret != PF_PASS) + return (ret); + break; default: pd->sctp_flags |= PFDESC_SCTP_OTHER; break; @@ -2133,7 +2151,7 @@ pf_normalize_sctp(int dir, struct pfi_kkif *kif, struct mbuf *m, int ipoff, /* Unconditionally scan the SCTP packet, because we need to look for * things like shutdown and asconf chunks. */ - if (pf_scan_sctp(m, ipoff, off, pd) != PF_PASS) + if (pf_scan_sctp(m, ipoff, off, pd, kif) != PF_PASS) goto sctp_drop; r = TAILQ_FIRST(pf_main_ruleset.rules[PF_RULESET_SCRUB].active.ptr); From nobody Mon Oct 2 09:33:23 2023 X-Original-To: dev-commits-src-branches@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 4RzbNg5QQ7z4vrK2; Mon, 2 Oct 2023 09:33: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNg4h9cz4SZF; Mon, 2 Oct 2023 09:33:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239203; 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=RQZr5Y3VMqejz8g73/Z80qaNb3nuUQzgRbGfpjuFxQ8=; b=SfnT8EGSBnotz25V2Ol33M3NjWBY8yh5f764MeHaZoL1CbztW9mZOfE7SEDJrh1/lWZmv7 AmnuvOgXumz2W4CDWB+ukO3rqu0z51U0q4vvaXbfQi18jCAczGYD/ZYt0r22HvG1G3UFDz 4oNl+xr/f6j1qe0BfEdwy3dtcZYVQcV2/cGAUuVggVQ91UC2T8ECQSfmXv4/lcPsHB5A9D 3CeUs18Yv4QAMepkDMN48edLgKw75kYv6fHd7Bo14gg2FWcPNDEqkz2MAqZMj4ZIXPChDc Jhn7PuOLF6SnRHNkb0wlrFOl7UMlbS+Z4H4zdPTDp7ZJFGPXiaTHsJ03+f1W9A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239203; a=rsa-sha256; cv=none; b=iE7HwO3gVxcUrXY58uy7BpC0ok1BtaGH2ffzwJYN559Pp0Pu8LFz40TPzqR5CGZsArb9W7 GTwDIhACh1WKh9L4ehSBEUII4KWDNxGeymsgJpETi0h1dMPC7iCpzLewnntKlzAddDZqqJ xmy9+c/xY4XYA9GAjHOa4vDGMhzudqvw6OgDiIskd8YNXmvMI0pa1XySWPBvntN9t8c0Xc HXOsEVRpJ1r+0xKpI9oq2wr3OknR63DOJzJ/zP3d3rIDsxEOCPDLrJuaZtmCdSDSSVqNOO VvwTm3CxUXgV89hw9lJLp2vkq9x9yXqtlOnd4b40EYQXK8uVjCp2K7KmPuAGvA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239203; 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=RQZr5Y3VMqejz8g73/Z80qaNb3nuUQzgRbGfpjuFxQ8=; b=KyioNCtCWkxGvk4K5ZeQJS1uHpAA+8Fe4E9LIMI9LzfFT4itRsOdGmNw2TxXPqF+4Uw8DG A5YjlbXH58AkbneIszKmnNRGvUIHAmqsVEpMlqnCwT55fRJcofSZo1w4hR+p9cQ9YhtRH5 fnSZJdPe/t0M53SvB/a01MnW/O37JqycK6l74iYU9u2guDg8h1WeXgDZT6MIOGazOzmPed OFITf/p3NS5TxXaBFsUTKUFznVYJXGeyuPwC03l1Aby2HdIac3TBjuOm1q/+sm+izYjoQ6 Q0LXRaN/YW/JDEqgBo4Lzyj4gZ4DbYlsSBeSHZwTQzaZDhwcw5E9R1zwRuYSCA== 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 4RzbNg3m3Rz16YW; Mon, 2 Oct 2023 09:33:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XNZg002728; Mon, 2 Oct 2023 09:33:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XNvK002713; Mon, 2 Oct 2023 09:33:23 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:23 GMT Message-Id: <202310020933.3929XNvK002713@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 2537ad522d85 - stable/14 - pf tests: basic SCTP multihoming test List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 2537ad522d85be44cfe3d61a1fc873bebe0fef28 Auto-Submitted: auto-generated The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=2537ad522d85be44cfe3d61a1fc873bebe0fef28 commit 2537ad522d85be44cfe3d61a1fc873bebe0fef28 Author: Kristof Provost AuthorDate: 2023-08-02 08:44:52 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 09:32:14 +0000 pf tests: basic SCTP multihoming test The SCTP server will announce multiple addresses. Block one of them with pf, connect to the other have the client use the blocked address. pf is expected to have created state for all of the addresses announced by the server. In a separate test case add the secondary (client) IP after the connection has been established. The intent is to verify the functionality of the ASCONF chunk parsing. MFC after: 3 weeks Sponsored by: Orange Business Services Differential Revision: https://reviews.freebsd.org/D41638 (cherry picked from commit 1a28d5fea7edf200c37d14f7ed5865910664ec3d) --- tests/sys/netpfil/pf/Makefile | 1 + tests/sys/netpfil/pf/sctp.py | 442 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 443 insertions(+) diff --git a/tests/sys/netpfil/pf/Makefile b/tests/sys/netpfil/pf/Makefile index 70c0c300d7ad..44fe95680dfb 100644 --- a/tests/sys/netpfil/pf/Makefile +++ b/tests/sys/netpfil/pf/Makefile @@ -40,6 +40,7 @@ ATF_TESTS_SH+= altq \ tos ATF_TESTS_PYTEST+= frag6.py +ATF_TESTS_PYTEST+= sctp.py # Tests reuse jail names and so cannot run in parallel. TEST_METADATA+= is_exclusive=true diff --git a/tests/sys/netpfil/pf/sctp.py b/tests/sys/netpfil/pf/sctp.py new file mode 100644 index 000000000000..b24d0c414ac8 --- /dev/null +++ b/tests/sys/netpfil/pf/sctp.py @@ -0,0 +1,442 @@ +import pytest +import ctypes +import socket +import ipaddress +import re +from atf_python.sys.net.tools import ToolsHelper +from atf_python.sys.net.vnet import VnetTestTemplate + +import time + +SCTP_UNORDERED = 0x0400 + +SCTP_NODELAY = 0x00000004 +SCTP_SET_PEER_PRIMARY_ADDR = 0x00000006 +SCTP_PRIMARY_ADDR = 0x00000007 + +SCTP_BINDX_ADD_ADDR = 0x00008001 +SCTP_BINDX_REM_ADDR = 0x00008002 + +class sockaddr_in(ctypes.Structure): + _fields_ = [ + ('sin_len', ctypes.c_uint8), + ('sin_family', ctypes.c_uint8), + ('sin_port', ctypes.c_uint16), + ('sin_addr', ctypes.c_uint32), + ('sin_zero', ctypes.c_int8 * 8) + ] + +class sockaddr_in6(ctypes.Structure): + _fields_ = [ + ('sin6_len', ctypes.c_uint8), + ('sin6_family', ctypes.c_uint8), + ('sin6_port', ctypes.c_uint16), + ('sin6_flowinfo', ctypes.c_uint32), + ('sin6_addr', ctypes.c_uint8 * 16), + ('sin6_scope_id', ctypes.c_uint32) + ] + +class sockaddr_storage(ctypes.Union): + _fields_ = [ + ("v4", sockaddr_in), + ("v6", sockaddr_in6) + ] + +class sctp_sndrcvinfo(ctypes.Structure): + _fields_ = [ + ('sinfo_stream', ctypes.c_uint16), + ('sinfo_ssn', ctypes.c_uint16), + ('sinfo_flags', ctypes.c_uint16), + ('sinfo_ppid', ctypes.c_uint32), + ('sinfo_context', ctypes.c_uint32), + ('sinfo_timetolive', ctypes.c_uint32), + ('sinfo_tsn', ctypes.c_uint32), + ('sinfo_cumtsn', ctypes.c_uint32), + ('sinfo_assoc_id', ctypes.c_uint32), + ] + +class sctp_setprim(ctypes.Structure): + _fields_ = [ + ('ssp_addr', sockaddr_storage), + ('ssp_pad', ctypes.c_int8 * (128 - 16)), + ('ssp_assoc_id', ctypes.c_uint32), + ('ssp_padding', ctypes.c_uint32) + ] + +def to_sockaddr(ip, port): + ip = ipaddress.ip_address(ip) + + if ip.version == 4: + addr = sockaddr_in() + addr.sin_len = ctypes.sizeof(addr) + addr.sin_family = socket.AF_INET + addr.sin_port = socket.htons(port) + addr.sin_addr = socket.htonl(int.from_bytes(ip.packed, byteorder='big')) + else: + assert ip.version == 6 + + addr = sockaddr_in6() + addr.sin6_len = ctypes.sizeof(addr) + addr.sin6_family = socket.AF_INET6 + addr.sin6_port = socket.htons(port) + for i in range(0, 16): + addr.sin6_addr[i] = ip.packed[i] + + return addr + +class SCTPServer: + def __init__(self, family, port=1234): + self._libc = ctypes.CDLL("libc.so.7", use_errno=True) + + self._listen_fd = self._libc.socket(family, socket.SOCK_STREAM, socket.IPPROTO_SCTP) + if self._listen_fd == -1: + raise Exception("Failed to create socket") + + if family == socket.AF_INET: + srvaddr = sockaddr_in() + srvaddr.sin_len = ctypes.sizeof(srvaddr) + srvaddr.sin_family = socket.AF_INET + srvaddr.sin_port = socket.htons(port) + srvaddr.sin_addr = socket.INADDR_ANY + else: + srvaddr = sockaddr_in6() + srvaddr.sin6_len = ctypes.sizeof(srvaddr) + srvaddr.sin6_family = family + srvaddr.sin6_port = socket.htons(port) + # Leave sin_addr empty, because ANY is zero + + ret = self._libc.bind(self._listen_fd, ctypes.pointer(srvaddr), + ctypes.sizeof(srvaddr)) + if ret == -1: + raise Exception("Failed to bind: %d" % ctypes.get_errno()) + + ret = self._libc.listen(self._listen_fd, 2) + if ret == -1: + raise Exception("Failed to listen") + + def _to_string(self, buf): + return ''.join([chr(int.from_bytes(i, byteorder='big')) for i in buf]).rstrip('\x00') + + def accept(self, vnet): + fd = self._libc.accept(self._listen_fd, 0, 0) + if fd < 0: + raise Exception("Failed to accept") + + print("SCTPServer: connection opened") + while True: + rcvinfo = sctp_sndrcvinfo() + flags = ctypes.c_int() + buf = ctypes.create_string_buffer(128) + + # Receive a single message, and inform the other vnet about it. + ret = self._libc.sctp_recvmsg(fd, ctypes.cast(buf, ctypes.c_void_p), 128, + 0, 0, ctypes.pointer(rcvinfo), ctypes.pointer(flags)) + if ret < 0: + print("SCTPServer: connection closed") + return + if ret == 0: + continue + + rcvd = {} + rcvd['ppid'] = socket.ntohl(rcvinfo.sinfo_ppid) + rcvd['data'] = self._to_string(buf) + rcvd['len'] = ret + print(rcvd) + vnet.pipe.send(rcvd) + +class SCTPClient: + def __init__(self, ip, port=1234, fromaddr=None): + self._libc = ctypes.CDLL("libc.so.7", use_errno=True) + + if ipaddress.ip_address(ip).version == 4: + family = socket.AF_INET + else: + family = socket.AF_INET6 + + self._fd = self._libc.socket(family, socket.SOCK_STREAM, + socket.IPPROTO_SCTP) + if self._fd == -1: + raise Exception("Failed to open socket") + + if fromaddr is not None: + addr = to_sockaddr(fromaddr, 0) + + ret = self._libc.bind(self._fd, ctypes.pointer(addr), ctypes.sizeof(addr)) + if ret != 0: + print("bind() => %d", ctypes.get_errno()) + raise + + addr = to_sockaddr(ip, port) + ret = self._libc.connect(self._fd, ctypes.pointer(addr), ctypes.sizeof(addr)) + if ret == -1: + raise Exception("Failed to connect") + + # Enable NODELAY, because otherwise the sending host may wait for SACK + # on a data chunk we've removed + enable = ctypes.c_int(1) + ret = self._libc.setsockopt(self._fd, socket.IPPROTO_SCTP, + SCTP_NODELAY, ctypes.pointer(enable), 4) + + def newpeer(self, addr): + print("newpeer(%s)" % (addr)) + + setp = sctp_setprim() + a = to_sockaddr(addr, 0) + if type(a) is sockaddr_in: + setp.ssp_addr.v4 = a + else: + assert type(a) is sockaddr_in6 + setp.ssp_addr.v6 = a + + ret = self._libc.setsockopt(self._fd, socket.IPPROTO_SCTP, + SCTP_PRIMARY_ADDR, ctypes.pointer(setp), ctypes.sizeof(setp)) + if ret != 0: + print("errno %d" % ctypes.get_errno()) + raise Exception(ctypes.get_errno()) + + def newprimary(self, addr): + print("newprimary(%s)" % (addr)) + + # Strictly speaking needs to be struct sctp_setpeerprim, but that's + # identical to sctp_setprim + setp = sctp_setprim() + a = to_sockaddr(addr, 0) + if type(a) is sockaddr_in: + setp.ssp_addr.v4 = a + else: + assert type(a) is sockaddr_in6 + setp.ssp_addr.v6 = a + + ret = self._libc.setsockopt(self._fd, socket.IPPROTO_SCTP, + SCTP_SET_PEER_PRIMARY_ADDR, ctypes.pointer(setp), ctypes.sizeof(setp)) + if ret != 0: + print("errno %d" % ctypes.get_errno()) + raise + + def bindx(self, addr, add): + print("bindx(%s, %s)" % (addr, add)) + + addr = to_sockaddr(addr, 0) + + if add: + flag = SCTP_BINDX_ADD_ADDR + else: + flag = SCTP_BINDX_REM_ADDR + ret = self._libc.sctp_bindx(self._fd, ctypes.pointer(addr), 1, flag) + if ret != 0: + print("sctp_bindx() errno %d" % ctypes.get_errno()) + raise + + def send(self, buf, ppid, ordered=False): + flags = 0 + + if not ordered: + flags = SCTP_UNORDERED + + ppid = socket.htonl(ppid) + ret = self._libc.sctp_sendmsg(self._fd, ctypes.c_char_p(buf), len(buf), + ctypes.c_void_p(0), 0, ppid, flags, 0, 0, 0) + if ret < 0: + raise Exception("Failed to send message") + + def close(self): + self._libc.close(self._fd) + self._fd = -1 + +class TestSCTP(VnetTestTemplate): + REQUIRED_MODULES = ["sctp", "pf"] + TOPOLOGY = { + "vnet1": {"ifaces": ["if1"]}, + "vnet2": {"ifaces": ["if1"]}, + "if1": {"prefixes4": [("192.0.2.1/24", "192.0.2.2/24")]}, + } + + def vnet2_handler(self, vnet): + # Give ourself a second IP address, for multihome testing + ifname = vnet.iface_alias_map["if1"].name + ToolsHelper.print_output("/sbin/ifconfig %s inet alias 192.0.2.3/24" % ifname) + + # Start an SCTP server process, pipe the ppid + data back to the other vnet? + srv = SCTPServer(socket.AF_INET, port=1234) + while True: + srv.accept(vnet) + + @pytest.mark.require_user("root") + def test_multihome(self): + srv_vnet = self.vnet_map["vnet2"] + + ToolsHelper.print_output("/sbin/pfctl -e") + ToolsHelper.pf_rules([ + "block proto sctp", + "pass inet proto sctp to 192.0.2.0/24"]) + + # Sanity check, we can communicate with the primary address. + client = SCTPClient("192.0.2.3", 1234) + client.send(b"hello", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "hello" + + try: + client.newpeer("192.0.2.2") + client.send(b"world", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "world" + finally: + # Debug output + ToolsHelper.print_output("/sbin/pfctl -ss") + ToolsHelper.print_output("/sbin/pfctl -sr -vv") + + # Check that we have a state for 192.0.2.3 and 192.0.2.2 to 192.0.2.1 + states = ToolsHelper.get_output("/sbin/pfctl -ss") + assert re.search(r"all sctp 192.0.2.1:.*192.0.2.3:1234", states) + assert re.search(r"all sctp 192.0.2.1:.*192.0.2.2:1234", states) + + @pytest.mark.require_user("root") + def test_multihome_asconf(self): + srv_vnet = self.vnet_map["vnet2"] + + # Assign a second IP to ourselves + ToolsHelper.print_output("/sbin/ifconfig %s inet alias 192.0.2.10/24" + % self.vnet.iface_alias_map["if1"].name) + ToolsHelper.print_output("/sbin/pfctl -e") + ToolsHelper.pf_rules([ + "block proto sctp", + "pass inet proto sctp from 192.0.2.0/24"]) + + # Sanity check, we can communicate with the primary address. + client = SCTPClient("192.0.2.3", 1234, "192.0.2.1") + client.send(b"hello", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "hello" + + # Now add our second address to the connection + client.bindx("192.0.2.10", True) + + # We can still communicate + client.send(b"world", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "world" + + # Now change to a different peer address + try: + client.newprimary("192.0.2.10") + client.send(b"!", 0) + rcvd = self.wait_object(srv_vnet.pipe, 5) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "!" + finally: + # Debug output + ToolsHelper.print_output("/sbin/pfctl -ss -vv") + + # Ensure we have the states we'd expect + states = ToolsHelper.get_output("/sbin/pfctl -ss") + assert re.search(r"all sctp 192.0.2.1:.*192.0.2.3:1234", states) + assert re.search(r"all sctp 192.0.2.10:.*192.0.2.3:1234", states) + +class TestSCTPv6(VnetTestTemplate): + REQUIRED_MODULES = ["sctp", "pf"] + TOPOLOGY = { + "vnet1": {"ifaces": ["if1"]}, + "vnet2": {"ifaces": ["if1"]}, + "if1": {"prefixes6": [("2001:db8::1/64", "2001:db8::2/64")]}, + } + + def vnet2_handler(self, vnet): + # Give ourself a second IP address, for multihome testing + ifname = vnet.iface_alias_map["if1"].name + ToolsHelper.print_output("/sbin/ifconfig %s inet6 alias 2001:db8::3/64" % ifname) + + # Start an SCTP server process, pipe the ppid + data back to the other vnet? + srv = SCTPServer(socket.AF_INET6, port=1234) + while True: + srv.accept(vnet) + + @pytest.mark.require_user("root") + def test_multihome(self): + srv_vnet = self.vnet_map["vnet2"] + + ToolsHelper.print_output("/sbin/pfctl -e") + ToolsHelper.pf_rules([ + "block proto sctp", + "pass inet6 proto sctp to 2001:db8::0/64"]) + + # Sanity check, we can communicate with the primary address. + client = SCTPClient("2001:db8::3", 1234) + client.send(b"hello", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "hello" + + # Now change to a different peer address + try: + client.newpeer("2001:db8::2") + client.send(b"world", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "world" + finally: + # Debug output + ToolsHelper.print_output("/sbin/pfctl -ss -vv") + + # Check that we have the expected states + states = ToolsHelper.get_output("/sbin/pfctl -ss") + assert re.search(r"all sctp 2001:db8::1\[.*2001:db8::3\[1234\]", states) + assert re.search(r"all sctp 2001:db8::1\[.*2001:db8::2\[1234\]", states) + + @pytest.mark.require_user("root") + def test_multihome_asconf(self): + srv_vnet = self.vnet_map["vnet2"] + + # Assign a second IP to ourselves + ToolsHelper.print_output("/sbin/ifconfig %s inet6 alias 2001:db8::10/64" + % self.vnet.iface_alias_map["if1"].name) + ToolsHelper.print_output("/sbin/pfctl -e") + ToolsHelper.pf_rules([ + "block proto sctp", + "pass inet6 proto sctp from 2001:db8::/64"]) + + # Sanity check, we can communicate with the primary address. + client = SCTPClient("2001:db8::3", 1234, "2001:db8::1") + client.send(b"hello", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "hello" + + # Now add our second address to the connection + client.bindx("2001:db8::10", True) + + # We can still communicate + client.send(b"world", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "world" + + # Now change to a different peer address + try: + client.newprimary("2001:db8::10") + client.send(b"!", 0) + rcvd = self.wait_object(srv_vnet.pipe, 5) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "!" + finally: + # Debug output + ToolsHelper.print_output("/sbin/pfctl -ss -vv") + + # Check that we have the expected states + states = ToolsHelper.get_output("/sbin/pfctl -ss") + assert re.search(r"all sctp 2001:db8::1\[.*2001:db8::3\[1234\]", states) + assert re.search(r"all sctp 2001:db8::10\[.*2001:db8::3\[1234\]", states) From nobody Mon Oct 2 09:33:23 2023 X-Original-To: dev-commits-src-branches@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 4RzbNh0NDQz4vrcN; Mon, 2 Oct 2023 09:33:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNg62whz4SZM; Mon, 2 Oct 2023 09:33:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239203; 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=FQ/Lv+ndT5Ocv8/2H3DQS6s5VxFl92j2cHu+SubfDxw=; b=MtGyxAOuruyztIEPhj1c7xEUPGCXzqwfrTMSTrFfmmYGAet5E5pKZ/IS3VACBcw+9fpAok T4L6O0YLSxJebl4Qw2CC76TADoMvqTVaiclGDqpcEMZCslNQHMZnAruR4pNbxf7vgidX0z ZmONyjwgnmbacFXBoRTZk1vzpy84BQRf103bOhzElrKNjQN+VCuPw4W1ElObfn4f9wIZ6M szXKeNLfiUX4Yz+3bZvx0+kDmFmbjR+bSk6J/TZBSa7Vkcx9dSp6QPQaPf8v1fj6u5Xiue JX9Wi9WSzNwlZRawTltW35rtgzzKkj+8aDO/LCs5Arn4//vxBCJ9v3qQidSQRQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239203; a=rsa-sha256; cv=none; b=d7KpnLDVxRDh+MHcQyDoRsIl69eMmlJiLG9jPHIAN7ZmNtzkeu6tyizNhzEaxGgMkbT9kk 20MouKEIsZRZHyrMQud08b3yU9vw4M4TfIIm9HJQJLSNjeaPX2n/u52YWxa9eXGMFDlwGL IysjjPmXXVSIEE7Ye14eZCBcH+Smfb/kLNTrvkw72X7giAITxI4X27FGOnhHiAGoq4wc/+ ISuNADfWiXgHLyAhQzzIDUXqnYijhHLcTwcoy/2aicCKXDeLwbIv1dIWUDDyCUlo1+PPdC SZyJPyjr4roOApqpnbPawPZ8hG4gRqS15boktQzaOY5NPMWnm9BRnvG1ae51QA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239203; 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=FQ/Lv+ndT5Ocv8/2H3DQS6s5VxFl92j2cHu+SubfDxw=; b=Ra679D4lYDS94Pz5Zh1O5T4AGkbeZmbvYxqjdqvXjXJNoxGgXbZaWdSv1kJJFkpfl8mg1L im7sMVEsgSG5BomYMnHukQ1UPMJQljpfytwNYAQzbuaL9SBSwLTazb5Nt8r3xsB7adC10M zuNKuF8j4wtb/C2vhv10qnSRCGARLW1UF9Fw/kTiZqvqCRhW9vWEvz6kEvCousQTDu5cns bXwovcgd5ikyoNOiedSQAqeTTRg0cHbewBPXzGMFw+EGqd+DKJnLugL2cTyjndLOP6SxxP uwO4gg2jHFKbQCJgkBJW34A3EPhpZsxEhvuSCdLwo1m8AGIMmhewsk7ZZl78HA== 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 4RzbNg4kLhz16YX; Mon, 2 Oct 2023 09:33:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XNLS002814; Mon, 2 Oct 2023 09:33:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XNP0002811; Mon, 2 Oct 2023 09:33:23 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:23 GMT Message-Id: <202310020933.3929XNP0002811@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 41cc99739ee6 - stable/13 - pf: support SCTP multihoming List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: 41cc99739ee635b7a6952ee45e1b7c9d995077aa Auto-Submitted: auto-generated The branch stable/13 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=41cc99739ee635b7a6952ee45e1b7c9d995077aa commit 41cc99739ee635b7a6952ee45e1b7c9d995077aa Author: Kristof Provost AuthorDate: 2023-08-02 17:05:00 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 08:51:43 +0000 pf: support SCTP multihoming SCTP may announce additional IP addresses it'll use in the INIT/INIT_ACK chunks, or in ASCONF chunks at any time during the connection. Parse these parameters, evaluate the ruleset for the new connection and if allowed create the corresponding states. MFC after: 3 weeks Sponsored by: Orange Business Services Differential Revision: https://reviews.freebsd.org/D41637 (cherry picked from commit 10aa9ddb4d45ab0c8f56b0e91c7e8de213030c0f) --- sys/net/pfvar.h | 22 ++- sys/netpfil/pf/pf.c | 347 ++++++++++++++++++++++++++++++++++++----------- sys/netpfil/pf/pf_norm.c | 34 +++-- 3 files changed, 312 insertions(+), 91 deletions(-) diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h index 4043bb8e0e54..07a4140e450f 100644 --- a/sys/net/pfvar.h +++ b/sys/net/pfvar.h @@ -1280,6 +1280,9 @@ struct pfi_kkif { #define PFI_IFLAG_SKIP 0x0100 /* skip filtering on interface */ #ifdef _KERNEL +struct pf_sctp_multihome_job; +TAILQ_HEAD(pf_sctp_multihome_jobs, pf_sctp_multihome_job); + struct pf_pdesc { struct { int done; @@ -1327,10 +1330,22 @@ struct pf_pdesc { #define PFDESC_SCTP_SHUTDOWN 0x0010 #define PFDESC_SCTP_SHUTDOWN_COMPLETE 0x0020 #define PFDESC_SCTP_DATA 0x0040 -#define PFDESC_SCTP_OTHER 0x0080 +#define PFDESC_SCTP_ASCONF 0x0080 +#define PFDESC_SCTP_OTHER 0x0100 u_int16_t sctp_flags; u_int32_t sctp_initiate_tag; + + struct pf_sctp_multihome_jobs sctp_multihome_jobs; +}; + +struct pf_sctp_multihome_job { + TAILQ_ENTRY(pf_sctp_multihome_job) next; + struct pf_pdesc pd; + struct pf_addr src; + struct pf_addr dst; + struct mbuf *m; }; + #endif /* flags for RDR options */ @@ -1996,6 +2011,11 @@ void pf_addr_inc(struct pf_addr *, sa_family_t); int pf_refragment6(struct ifnet *, struct mbuf **, struct m_tag *); #endif /* INET6 */ +int pf_multihome_scan_init(struct mbuf *, int, int, struct pf_pdesc *, + struct pfi_kkif *); +int pf_multihome_scan_asconf(struct mbuf *, int, int, struct pf_pdesc *, + struct pfi_kkif *); + u_int32_t pf_new_isn(struct pf_kstate *); void *pf_pull_hdr(struct mbuf *, int, void *, int, u_short *, u_short *, sa_family_t); diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 51f81172bad2..cb4ab2da4633 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -118,6 +118,8 @@ SDT_PROBE_DEFINE4(pf, ip, test6, done, "int", "int", "struct pf_krule *", SDT_PROBE_DEFINE5(pf, ip, state, lookup, "struct pfi_kkif *", "struct pf_state_key_cmp *", "int", "struct pf_pdesc *", "struct pf_kstate *"); +SDT_PROBE_DEFINE4(pf, sctp, multihome, test, "struct pfi_kkif *", + "struct pf_krule *", "struct mbuf *", "int"); /* * Global variables @@ -288,6 +290,8 @@ static int pf_test_state_udp(struct pf_kstate **, int, static int pf_test_state_icmp(struct pf_kstate **, int, struct pfi_kkif *, struct mbuf *, int, void *, struct pf_pdesc *, u_short *); +static void pf_sctp_multihome_delayed(struct pf_pdesc *, int, + struct pfi_kkif *, struct pf_kstate *); static int pf_test_state_sctp(struct pf_kstate **, struct pfi_kkif *, struct mbuf *, int, void *, struct pf_pdesc *, u_short *); @@ -5253,6 +5257,255 @@ pf_test_state_udp(struct pf_kstate **state, int direction, struct pfi_kkif *kif, return (PF_PASS); } +static int +pf_test_state_sctp(struct pf_kstate **state, struct pfi_kkif *kif, + struct mbuf *m, int off, void *h, struct pf_pdesc *pd, u_short *reason) +{ + struct pf_state_key_cmp key; + struct pf_state_peer *src; //, *dst; + struct sctphdr *sh = &pd->hdr.sctp; + u_int8_t psrc; //, pdst; + + bzero(&key, sizeof(key)); + key.af = pd->af; + key.proto = IPPROTO_SCTP; + if (pd->dir == PF_IN) { /* wire side, straight */ + PF_ACPY(&key.addr[0], pd->src, key.af); + PF_ACPY(&key.addr[1], pd->dst, key.af); + key.port[0] = sh->src_port; + key.port[1] = sh->dest_port; + } else { /* stack side, reverse */ + PF_ACPY(&key.addr[1], pd->src, key.af); + PF_ACPY(&key.addr[0], pd->dst, key.af); + key.port[1] = sh->src_port; + key.port[0] = sh->dest_port; + } + + STATE_LOOKUP(kif, &key, pd->dir, *state, pd); + + if (pd->dir == (*state)->direction) { + src = &(*state)->src; + psrc = PF_PEER_SRC; + } else { + src = &(*state)->dst; + psrc = PF_PEER_DST; + } + + /* Track state. */ + if (pd->sctp_flags & PFDESC_SCTP_INIT) { + if (src->state < SCTP_COOKIE_WAIT) { + pf_set_protostate(*state, psrc, SCTP_COOKIE_WAIT); + (*state)->timeout = PFTM_TCP_OPENING; + } + } + if (pd->sctp_flags & PFDESC_SCTP_COOKIE) { + if (src->state < SCTP_ESTABLISHED) { + pf_set_protostate(*state, psrc, SCTP_ESTABLISHED); + (*state)->timeout = PFTM_TCP_ESTABLISHED; + } + } + if (pd->sctp_flags & (PFDESC_SCTP_SHUTDOWN | PFDESC_SCTP_ABORT | + PFDESC_SCTP_SHUTDOWN_COMPLETE)) { + if (src->state < SCTP_SHUTDOWN_PENDING) { + pf_set_protostate(*state, psrc, SCTP_SHUTDOWN_PENDING); + (*state)->timeout = PFTM_TCP_CLOSING; + } + } + + (*state)->expire = time_uptime; + + /* translate source/destination address, if necessary */ + if ((*state)->key[PF_SK_WIRE] != (*state)->key[PF_SK_STACK]) { + uint16_t checksum = 0; + struct pf_state_key *nk = (*state)->key[pd->didx]; + + if (PF_ANEQ(pd->src, &nk->addr[pd->sidx], pd->af) || + nk->port[pd->sidx] != pd->hdr.sctp.src_port) { + pf_change_ap(m, pd->src, &pd->hdr.sctp.src_port, + pd->ip_sum, &checksum, &nk->addr[pd->sidx], + nk->port[pd->sidx], 1, pd->af); + } + + if (PF_ANEQ(pd->dst, &nk->addr[pd->didx], pd->af) || + nk->port[pd->didx] != pd->hdr.sctp.dest_port) { + pf_change_ap(m, pd->dst, &pd->hdr.sctp.dest_port, + pd->ip_sum, &checksum, &nk->addr[pd->didx], + nk->port[pd->didx], 1, pd->af); + } + } + + return (PF_PASS); +} + +static void +pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, + struct pf_kstate *s) +{ + struct pf_sctp_multihome_job *j, *tmp; + int action;; + struct pf_kstate *sm = NULL; + struct pf_krule *ra = NULL; + struct pf_krule *r = &V_pf_default_rule; + struct pf_kruleset *rs = NULL; + + PF_RULES_RLOCK_TRACKER; + + TAILQ_FOREACH_SAFE(j, &pd->sctp_multihome_jobs, next, tmp) { + PF_RULES_RLOCK(); + action = pf_test_rule(&r, &sm, pd->dir, kif, + j->m, off, &j->pd, &ra, &rs, NULL); + PF_RULES_RUNLOCK(); + SDT_PROBE4(pf, sctp, multihome, test, kif, r, j->m, action); + if (sm) + PF_STATE_UNLOCK(sm); + + free(j, M_PFTEMP); + } +} + +static int +pf_multihome_scan(struct mbuf *m, int start, int len, struct pf_pdesc *pd, + struct pfi_kkif *kif) +{ + int off = 0; + struct pf_sctp_multihome_job *job; + + while (off < len) { + struct sctp_paramhdr h; + + if (!pf_pull_hdr(m, start + off, &h, sizeof(h), NULL, NULL, + pd->af)) + return (PF_DROP); + + /* Parameters are at least 4 bytes. */ + if (ntohs(h.param_length) < 4) + return (PF_DROP); + + switch (ntohs(h.param_type)) { + case SCTP_IPV4_ADDRESS: { + struct in_addr t; + + if (ntohs(h.param_length) != + (sizeof(struct sctp_paramhdr) + sizeof(t))) + return (PF_DROP); + + if (!pf_pull_hdr(m, start + off + sizeof(h), &t, sizeof(t), + NULL, NULL, pd->af)) + return (PF_DROP); + + /* + * Avoid duplicating states. We'll already have + * created a state based on the source address of + * the packet, but SCTP endpoints may also list this + * address again in the INIT(_ACK) parameters. + */ + if (t.s_addr == pd->src->v4.s_addr) + break; + + if (in_nullhost(t)) + t.s_addr = pd->src->v4.s_addr; + + /* + * We hold the state lock (idhash) here, which means + * that we can't acquire the keyhash, or we'll get a + * LOR (and potentially double-lock things too). We also + * can't release the state lock here, so instead we'll + * enqueue this for async handling. + * There's a relatively small race here, in that a + * packet using the new addresses could arrive already, + * but that's just though luck for it. + */ + job = malloc(sizeof(*job), M_PFTEMP, M_NOWAIT | M_ZERO); + if (! job) + return (PF_DROP); + + memcpy(&job->pd, pd, sizeof(*pd)); + + // New source address! + memcpy(&job->src, &t, sizeof(t)); + job->pd.src = &job->src; + memcpy(&job->dst, pd->dst, sizeof(job->dst)); + job->pd.dst = &job->dst; + job->m = m; + + TAILQ_INSERT_TAIL(&pd->sctp_multihome_jobs, job, next); + break; + } +#ifdef INET6 + case SCTP_IPV6_ADDRESS: { + struct in6_addr t; + + if (ntohs(h.param_length) != + (sizeof(struct sctp_paramhdr) + sizeof(t))) + return (PF_DROP); + + if (!pf_pull_hdr(m, start + off + sizeof(h), &t, sizeof(t), + NULL, NULL, pd->af)) + return (PF_DROP); + if (memcmp(&t, &pd->src->v6, sizeof(t)) == 0) + break; + if (memcmp(&t, &in6addr_any, sizeof(t)) == 0) + memcpy(&t, &pd->src->v6, sizeof(t)); + + job = malloc(sizeof(*job), M_PFTEMP, M_NOWAIT | M_ZERO); + if (! job) + return (PF_DROP); + + memcpy(&job->pd, pd, sizeof(*pd)); + memcpy(&job->src, &t, sizeof(t)); + job->pd.src = &job->src; + memcpy(&job->dst, pd->dst, sizeof(job->dst)); + job->pd.dst = &job->dst; + job->m = m; + + TAILQ_INSERT_TAIL(&pd->sctp_multihome_jobs, job, next); + break; + } +#endif + case SCTP_ADD_IP_ADDRESS: { + int ret; + struct sctp_asconf_paramhdr ah; + + if (!pf_pull_hdr(m, start + off, &ah, sizeof(ah), + NULL, NULL, pd->af)) + return (PF_DROP); + + ret = pf_multihome_scan(m, start + off + sizeof(ah), + ntohs(ah.ph.param_length) - sizeof(ah), pd, kif); + if (ret != PF_PASS) + return (ret); + break; + } + default: + break; + } + + off += roundup(ntohs(h.param_length), 4); + } + + return (PF_PASS); +} + +int +pf_multihome_scan_init(struct mbuf *m, int start, int len, struct pf_pdesc *pd, + struct pfi_kkif *kif) +{ + start += sizeof(struct sctp_init_chunk); + len -= sizeof(struct sctp_init_chunk); + + return (pf_multihome_scan(m, start, len, pd, kif)); +} + +int +pf_multihome_scan_asconf(struct mbuf *m, int start, int len, + struct pf_pdesc *pd, struct pfi_kkif *kif) +{ + start += sizeof(struct sctp_asconf_chunk); + len -= sizeof(struct sctp_asconf_chunk); + + return (pf_multihome_scan(m, start, len, pd, kif)); +} + static int pf_test_state_icmp(struct pf_kstate **state, int direction, struct pfi_kkif *kif, struct mbuf *m, int off, void *h, struct pf_pdesc *pd, u_short *reason) @@ -5857,86 +6110,6 @@ pf_test_state_icmp(struct pf_kstate **state, int direction, struct pfi_kkif *kif } } -static int -pf_test_state_sctp(struct pf_kstate **state, struct pfi_kkif *kif, - struct mbuf *m, int off, void *h, struct pf_pdesc *pd, u_short *reason) -{ - struct pf_state_key_cmp key; - struct pf_state_peer *src; //, *dst; - struct sctphdr *sh = &pd->hdr.sctp; - u_int8_t psrc; //, pdst; - - bzero(&key, sizeof(key)); - key.af = pd->af; - key.proto = IPPROTO_SCTP; - if (pd->dir == PF_IN) { /* wire side, straight */ - PF_ACPY(&key.addr[0], pd->src, key.af); - PF_ACPY(&key.addr[1], pd->dst, key.af); - key.port[0] = sh->src_port; - key.port[1] = sh->dest_port; - } else { /* stack side, reverse */ - PF_ACPY(&key.addr[1], pd->src, key.af); - PF_ACPY(&key.addr[0], pd->dst, key.af); - key.port[1] = sh->src_port; - key.port[0] = sh->dest_port; - } - - STATE_LOOKUP(kif, &key, pd->dir, *state, pd); - - if (pd->dir == (*state)->direction) { - src = &(*state)->src; - psrc = PF_PEER_SRC; - } else { - src = &(*state)->dst; - psrc = PF_PEER_DST; - } - - /* Track state. */ - if (pd->sctp_flags & PFDESC_SCTP_INIT) { - if (src->state < SCTP_COOKIE_WAIT) { - pf_set_protostate(*state, psrc, SCTP_COOKIE_WAIT); - (*state)->timeout = PFTM_TCP_OPENING; - } - } - if (pd->sctp_flags & PFDESC_SCTP_COOKIE) { - if (src->state < SCTP_ESTABLISHED) { - pf_set_protostate(*state, psrc, SCTP_ESTABLISHED); - (*state)->timeout = PFTM_TCP_ESTABLISHED; - } - } - if (pd->sctp_flags & (PFDESC_SCTP_SHUTDOWN | PFDESC_SCTP_ABORT | - PFDESC_SCTP_SHUTDOWN_COMPLETE)) { - if (src->state < SCTP_SHUTDOWN_PENDING) { - pf_set_protostate(*state, psrc, SCTP_SHUTDOWN_PENDING); - (*state)->timeout = PFTM_TCP_CLOSING; - } - } - - (*state)->expire = time_uptime; - - /* translate source/destination address, if necessary */ - if ((*state)->key[PF_SK_WIRE] != (*state)->key[PF_SK_STACK]) { - uint16_t checksum = 0; - struct pf_state_key *nk = (*state)->key[pd->didx]; - - if (PF_ANEQ(pd->src, &nk->addr[pd->sidx], pd->af) || - nk->port[pd->sidx] != pd->hdr.sctp.src_port) { - pf_change_ap(m, pd->src, &pd->hdr.sctp.src_port, - pd->ip_sum, &checksum, &nk->addr[pd->sidx], - nk->port[pd->sidx], 1, pd->af); - } - - if (PF_ANEQ(pd->dst, &nk->addr[pd->didx], pd->af) || - nk->port[pd->didx] != pd->hdr.sctp.dest_port) { - pf_change_ap(m, pd->dst, &pd->hdr.sctp.dest_port, - pd->ip_sum, &checksum, &nk->addr[pd->didx], - nk->port[pd->didx], 1, pd->af); - } - } - - return (PF_PASS); -} - static int pf_test_state_other(struct pf_kstate **state, int direction, struct pfi_kkif *kif, struct mbuf *m, struct pf_pdesc *pd) @@ -6632,6 +6805,7 @@ pf_test(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb * if (m->m_flags & M_SKIP_FIREWALL) return (PF_PASS); + TAILQ_INIT(&pd.sctp_multihome_jobs); pd.pf_mtag = pf_find_mtag(m); PF_RULES_RLOCK(); @@ -6793,6 +6967,8 @@ pf_test(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb * log = action != PF_PASS; goto done; } + pd.p_len = pd.tot_len - off; + pd.sport = &pd.hdr.sctp.src_port; pd.dport = &pd.hdr.sctp.dest_port; if (pd.hdr.sctp.src_port == 0 || pd.hdr.sctp.dest_port == 0) { @@ -7054,7 +7230,7 @@ done: /* pf_route() returns unlocked. */ if (r->rt) { pf_route(m0, r, dir, kif->pfik_ifp, s, &pd, inp); - return (action); + goto out; } break; } @@ -7064,6 +7240,9 @@ done: if (s) PF_STATE_UNLOCK(s); +out: + pf_sctp_multihome_delayed(&pd, off, kif, s); + return (action); } #endif /* INET */ @@ -7091,6 +7270,7 @@ pf_test6(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb return (PF_PASS); memset(&pd, 0, sizeof(pd)); + TAILQ_INIT(&pd.sctp_multihome_jobs); pd.pf_mtag = pf_find_mtag(m); if (pd.pf_mtag && pd.pf_mtag->flags & PF_TAG_GENERATED) @@ -7535,7 +7715,7 @@ done: /* pf_route6() returns unlocked. */ if (r->rt) { pf_route6(m0, r, dir, kif->pfik_ifp, s, &pd, inp); - return (action); + goto out; } break; } @@ -7548,8 +7728,11 @@ done: (mtag = m_tag_find(m, PF_REASSEMBLED, NULL)) != NULL) action = pf_refragment6(ifp, m0, mtag); +out: SDT_PROBE4(pf, ip, test6, done, action, reason, r, s); + pf_sctp_multihome_delayed(&pd, off, kif, s); + return (action); } #endif /* INET6 */ diff --git a/sys/netpfil/pf/pf_norm.c b/sys/netpfil/pf/pf_norm.c index 7e8baf451891..ec3f63c9f262 100644 --- a/sys/netpfil/pf/pf_norm.c +++ b/sys/netpfil/pf/pf_norm.c @@ -1989,11 +1989,13 @@ pf_normalize_tcpopt(struct pf_krule *r, struct mbuf *m, struct tcphdr *th, } static int -pf_scan_sctp(struct mbuf *m, int ipoff, int off, struct pf_pdesc *pd) +pf_scan_sctp(struct mbuf *m, int ipoff, int off, struct pf_pdesc *pd, + struct pfi_kkif *kif) { struct sctp_chunkhdr ch = { }; int chunk_off = sizeof(struct sctphdr); int chunk_start; + int ret; while (off + chunk_off < pd->tot_len) { if (!pf_pull_hdr(m, off + chunk_off, &ch, sizeof(ch), NULL, @@ -2008,7 +2010,8 @@ pf_scan_sctp(struct mbuf *m, int ipoff, int off, struct pf_pdesc *pd) chunk_off += roundup(ntohs(ch.chunk_length), 4); switch (ch.chunk_type) { - case SCTP_INITIATION: { + case SCTP_INITIATION: + case SCTP_INITIATION_ACK: { struct sctp_init_chunk init; if (!pf_pull_hdr(m, off + chunk_start, &init, @@ -2032,17 +2035,24 @@ pf_scan_sctp(struct mbuf *m, int ipoff, int off, struct pf_pdesc *pd) * RFC 9260, Section 3.1, INIT chunks MUST have zero * verification tag. */ - if (pd->hdr.sctp.v_tag != 0) + if (ch.chunk_type == SCTP_INITIATION && + pd->hdr.sctp.v_tag != 0) return (PF_DROP); pd->sctp_initiate_tag = init.init.initiate_tag; - pd->sctp_flags |= PFDESC_SCTP_INIT; + if (ch.chunk_type == SCTP_INITIATION) + pd->sctp_flags |= PFDESC_SCTP_INIT; + else + pd->sctp_flags |= PFDESC_SCTP_INIT_ACK; + + ret = pf_multihome_scan_init(m, off + chunk_start, + ntohs(init.ch.chunk_length), pd, kif); + if (ret != PF_PASS) + return (ret); + break; } - case SCTP_INITIATION_ACK: - pd->sctp_flags |= PFDESC_SCTP_INIT_ACK; - break; case SCTP_ABORT_ASSOCIATION: pd->sctp_flags |= PFDESC_SCTP_ABORT; break; @@ -2060,6 +2070,14 @@ pf_scan_sctp(struct mbuf *m, int ipoff, int off, struct pf_pdesc *pd) case SCTP_DATA: pd->sctp_flags |= PFDESC_SCTP_DATA; break; + case SCTP_ASCONF: + pd->sctp_flags |= PFDESC_SCTP_ASCONF; + + ret = pf_multihome_scan_asconf(m, off + chunk_start, + ntohs(ch.chunk_length), pd, kif); + if (ret != PF_PASS) + return (ret); + break; default: pd->sctp_flags |= PFDESC_SCTP_OTHER; break; @@ -2101,7 +2119,7 @@ pf_normalize_sctp(int dir, struct pfi_kkif *kif, struct mbuf *m, int ipoff, /* Unconditionally scan the SCTP packet, because we need to look for * things like shutdown and asconf chunks. */ - if (pf_scan_sctp(m, ipoff, off, pd) != PF_PASS) + if (pf_scan_sctp(m, ipoff, off, pd, kif) != PF_PASS) goto sctp_drop; r = TAILQ_FIRST(pf_main_ruleset.rules[PF_RULESET_SCRUB].active.ptr); From nobody Mon Oct 2 09:33:24 2023 X-Original-To: dev-commits-src-branches@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 4RzbNh6qlJz4vrN7; Mon, 2 Oct 2023 09:33:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNh5Ygqz4Sch; Mon, 2 Oct 2023 09:33:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239204; 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=zIKmixR3TY9b7zaRNgCONT5rP20JLfbJ9t1+p3Hy8NE=; b=kmPK0q7kG9+BoL5buUnTJqg2BqhjrmNQ2GsXacyFiRt1P3VyHwKFnIZwQ0lOVoxwFL6jlg xTzGCkgq3PHEdZ6ivUL3TQZcq8oMSB1XANnWgrpzwn1JlehPlcJ0f8Jh1w/I4EVN+Q0Jna U7NNeOLidxMNfnnjJWlW+eXe8B4bpyHEj0h5kp/cbPC711k1SZpONrEMJTYBeoPFgrjix3 H4yR7wOERRUPZ4rOuH1F+LXjlr9wRsws4+O4SEUUv/S5i2nPaDlcH9UlWvZ3QkLaqlpdmU KzytOTTWqdp2831Ds/HrhpLb2fmh1sw+Yb8iE1mV/vE0zaAqpiMvBNeyG5EK0w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239204; a=rsa-sha256; cv=none; b=wV8CIjmtudztcD22UkwlelguzLjhNcChZip2fO+nxy/9JEI2H0eVNhzspNCvjc103KW3i9 6b6fae5PPhBk9I+7IPEDAdrjju2h/K492xoz/oSrReODY9LPSqsElpqEz0jVGZ2Ptk0t8A Uf9qMnwypqeL6Rr+LYT7/gzF0zINKmqGBgZP4nWyQ2kEQc2ST5JNXuW+kXOR+VPDeTWVft tvEU1kewpCun6WtRCgSiPW/Yufl3d+POG5x9kKCfJ4e1I7KMwPdFSRPKEG9QAxs1oa1UU2 qXj4hixbS8X/K2H5GhZntLcMSTXbJTuAYUBqQ4nNWFWaFeZDxAjxTiv63Sn4FQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239204; 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=zIKmixR3TY9b7zaRNgCONT5rP20JLfbJ9t1+p3Hy8NE=; b=O7gAhLk/WTyVok52LNhZpIs9EfXSgik+hNvubjJyIACOj1nFUmFXEMQA88T/HxAhnfpRPm gEFb5tDVCIDFlm5/zU4EBjbGYt7cZKhXmYYyOqqaveVH2TpCpQFltyAnbH3hSVrSgvsJWe 9rCuonbrBjRzfPzAzrWArzPR2m1DFvUTkpA7AOtxQHLmkz93wU34Jt9Gc6EhQ8gzjry9OE i11iz6VLlvo2FscECd0YmhzQw1+16O2TbDJ5dw3+TKxMsZOC8hh37ewNwV9KsA2m8hAoCM A4CUlw1aKFg+ZrhhasUnBuXf1loBVPW8i7XC/tJ8ej8Brc/Vyitoc+RLax041Q== 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 4RzbNh4dhRz16CB; Mon, 2 Oct 2023 09:33:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XOxu002856; Mon, 2 Oct 2023 09:33:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XOVl002853; Mon, 2 Oct 2023 09:33:24 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:24 GMT Message-Id: <202310020933.3929XOVl002853@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 48172aad8143 - stable/14 - pf: improve SCTP state validation List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 48172aad8143d72fa2af363f4b6da0bf1c522789 Auto-Submitted: auto-generated The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=48172aad8143d72fa2af363f4b6da0bf1c522789 commit 48172aad8143d72fa2af363f4b6da0bf1c522789 Author: Kristof Provost AuthorDate: 2023-09-01 11:33:56 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 09:32:14 +0000 pf: improve SCTP state validation Only create new states for INIT chunks, or when we're creating a secondary state for a multihomed association. Store and verify verification tag. MFC after: 3 weeks Sponsored by: Orange Business Services (cherry picked from commit 51a78dd2764beabfd19a58b8a8b04387a547f02e) --- sys/net/pfvar.h | 8 +++++++- sys/netpfil/pf/pf.c | 25 +++++++++++++++---------- sys/netpfil/pf/pf_norm.c | 17 +++++++++++++++++ 3 files changed, 39 insertions(+), 11 deletions(-) diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h index ec72c1079c70..a8567ab74fe3 100644 --- a/sys/net/pfvar.h +++ b/sys/net/pfvar.h @@ -900,7 +900,10 @@ struct pf_state_scrub { #define PFSS_DATA_NOTS 0x0080 /* no timestamp on data packets */ u_int8_t pfss_ttl; /* stashed TTL */ u_int8_t pad; - u_int32_t pfss_ts_mod; /* timestamp modulation */ + union { + u_int32_t pfss_ts_mod; /* timestamp modulation */ + u_int32_t pfss_v_tag; /* SCTP verification tag */ + }; }; struct pf_state_host { @@ -1583,6 +1586,7 @@ struct pf_pdesc { #define PFDESC_SCTP_DATA 0x0040 #define PFDESC_SCTP_ASCONF 0x0080 #define PFDESC_SCTP_OTHER 0x0100 +#define PFDESC_SCTP_ADD_IP 0x0200 u_int16_t sctp_flags; u_int32_t sctp_initiate_tag; @@ -2301,6 +2305,8 @@ int pf_normalize_tcp_init(struct mbuf *, int, struct pf_pdesc *, int pf_normalize_tcp_stateful(struct mbuf *, int, struct pf_pdesc *, u_short *, struct tcphdr *, struct pf_kstate *, struct pf_state_peer *, struct pf_state_peer *, int *); +int pf_normalize_sctp_init(struct mbuf *, int, struct pf_pdesc *, + struct pf_state_peer *, struct pf_state_peer *); int pf_normalize_sctp(int, struct pfi_kkif *, struct mbuf *, int, int, void *, struct pf_pdesc *); u_int32_t diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 69373b720ad9..8958579b7e63 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -4904,11 +4904,7 @@ pf_create_state(struct pf_krule *r, struct pf_krule *nr, struct pf_krule *a, if (s->state_flags & PFSTATE_SCRUB_TCP && pf_normalize_tcp_init(m, off, pd, th, &s->src, &s->dst)) { REASON_SET(&reason, PFRES_MEMORY); - pf_src_tree_remove_state(s); - s->timeout = PFTM_UNLINKED; - STATE_DEC_COUNTERS(s); - pf_free_state(s); - return (PF_DROP); + goto drop; } if (s->state_flags & PFSTATE_SCRUB_TCP && s->src.scrub && pf_normalize_tcp_stateful(m, off, pd, &reason, th, s, @@ -4917,12 +4913,13 @@ pf_create_state(struct pf_krule *r, struct pf_krule *nr, struct pf_krule *a, DPFPRINTF(PF_DEBUG_URGENT, ("pf_normalize_tcp_stateful failed on first " "pkt\n")); - pf_src_tree_remove_state(s); - s->timeout = PFTM_UNLINKED; - STATE_DEC_COUNTERS(s); - pf_free_state(s); - return (PF_DROP); + goto drop; } + } else if (pd->proto == IPPROTO_SCTP) { + if (pf_normalize_sctp_init(m, off, pd, &s->src, &s->dst)) + goto drop; + if (! (pd->sctp_flags & (PFDESC_SCTP_INIT | PFDESC_SCTP_ADD_IP))) + goto drop; } s->direction = pd->dir; @@ -5890,6 +5887,13 @@ pf_test_state_sctp(struct pf_kstate **state, struct pfi_kkif *kif, } } + if (src->scrub != NULL) { + if (src->scrub->pfss_v_tag == 0) { + src->scrub->pfss_v_tag = pd->hdr.sctp.v_tag; + } else if (src->scrub->pfss_v_tag != pd->hdr.sctp.v_tag) + return (PF_DROP); + } + (*state)->expire = time_uptime; /* translate source/destination address, if necessary */ @@ -5930,6 +5934,7 @@ pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, TAILQ_FOREACH_SAFE(j, &pd->sctp_multihome_jobs, next, tmp) { PF_RULES_RLOCK(); + j->pd.sctp_flags |= PFDESC_SCTP_ADD_IP; action = pf_test_rule(&r, &sm, kif, j->m, off, &j->pd, &ra, &rs, NULL); PF_RULES_RUNLOCK(); diff --git a/sys/netpfil/pf/pf_norm.c b/sys/netpfil/pf/pf_norm.c index 83b94db87a19..d63cf0ebe54e 100644 --- a/sys/netpfil/pf/pf_norm.c +++ b/sys/netpfil/pf/pf_norm.c @@ -1565,11 +1565,28 @@ pf_normalize_tcp_init(struct mbuf *m, int off, struct pf_pdesc *pd, void pf_normalize_tcp_cleanup(struct pf_kstate *state) { + /* XXX Note: this also cleans up SCTP. */ uma_zfree(V_pf_state_scrub_z, state->src.scrub); uma_zfree(V_pf_state_scrub_z, state->dst.scrub); /* Someday... flush the TCP segment reassembly descriptors. */ } +int +pf_normalize_sctp_init(struct mbuf *m, int off, struct pf_pdesc *pd, + struct pf_state_peer *src, struct pf_state_peer *dst) +{ + src->scrub = uma_zalloc(V_pf_state_scrub_z, M_ZERO | M_NOWAIT); + if (src->scrub == NULL) + return (1); + + dst->scrub = uma_zalloc(V_pf_state_scrub_z, M_ZERO | M_NOWAIT); + if (dst->scrub == NULL) { + uma_zfree(V_pf_state_scrub_z, src); + return (1); + } + + return (0); +} int pf_normalize_tcp_stateful(struct mbuf *m, int off, struct pf_pdesc *pd, From nobody Mon Oct 2 09:33:24 2023 X-Original-To: dev-commits-src-branches@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 4RzbNh6n1Bz4vrK8; Mon, 2 Oct 2023 09:33:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNh6C9bz4SRp; Mon, 2 Oct 2023 09:33:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239204; 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=OIq8iSt5fMTZg7YJX0VTcDr6c87u+tQAWviaJKHjZC4=; b=ljKH1md+tt6+mlU6KfxlavxXCUW9Z+lXM2wTm0X7D4IVMnr+z/Q78sstg2ddW9S+e3kY7R t+b9Ofw+GghwanpcZDF4q+cCRp6/iQibiAauKwgMoRSTRiEhgWkrdfCAgpLLT9sZ1ON0Xk H56CdGZ9ZUq4ay/Ox2hnuklYHK2s4uZkXZSHIUeoJzsCbpsXsRzhC3vcLIlwy/A2lwDAz4 X6sXNy+Oyyc/KQ/ikYpCib6ao0BRp7QSwaeGlCwZ58KKV0m0XZwdNDbZCWFVNNxoZLuU+t blspsLHmSR8bLDUWgcRZJBHXZPK3CO6nYTD8QtZf8Ro6zGCj69vhghUD/iIgeg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239204; a=rsa-sha256; cv=none; b=Ii36r0tgw87sCgaAf+g65FQPeeyG9CyXflvJLyoHZzZZ5CRAbM0CLuWLW3TjKdtR+KEhiT 110EtU4/rLicSKnN88KKs5snqcwulp8YaOnB+A7fBtI5WsHLQjdUROB+c8k2x4UEN3tbnv 9CxJ1zVHCxpAa4vKgg7SXUcby9RLOCoQivz+EFgC0KPIxv/WkzsPH0/RrYadlPQNowq9Z6 IRsrfMn4C1nqQMAEXJC/FXaHUUUBHSwLm9ZMadvbzmgWmyL0iAesf6EmjBhaAk/bXovmIl aLpF9rC2h1IE3KF2IAH8YtL8e5ORx42pE+ppV+VHu23j/yRkee11ebuKuFkxVg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239204; 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=OIq8iSt5fMTZg7YJX0VTcDr6c87u+tQAWviaJKHjZC4=; b=HApH4wMORnctvknbnt6kh5pXbpzMrn9DTQsW/3vS+Fhr/m43Q/PDMT63V9kZdUyeDM52Uv H3PD4vfvc4X31FLro2z2Kn8uO5PeNt+wQMwoEUYj7hVsNxy0fDF7CU+SRDm9COzAJmtARb zBOMU76jfzra+pjdCEpnU0Xfpo4jAYSsDvSnSNhjB334XueRWL3oZGfGs7K8msik+2qWBC cQ8nQoGvcinzuYH0N1FNPeromy4V+emIx5U0/GsN9hzAnBp4DcPyHz8H7uGcAlMnZN7WsJ 0302fsmwjuqdkjdDekO32RI4m63vEo/i9LIANNHux8T4Lu6V9MEXe2HDYWMFLA== 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 4RzbNh5H8Qz16CC; Mon, 2 Oct 2023 09:33:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XOIR002901; Mon, 2 Oct 2023 09:33:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XOJW002898; Mon, 2 Oct 2023 09:33:24 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:24 GMT Message-Id: <202310020933.3929XOJW002898@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: ccb5fbe99c5e - stable/13 - pf tests: basic SCTP multihoming test List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: ccb5fbe99c5e716dccbaac0cc381847ef48bbfef Auto-Submitted: auto-generated The branch stable/13 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=ccb5fbe99c5e716dccbaac0cc381847ef48bbfef commit ccb5fbe99c5e716dccbaac0cc381847ef48bbfef Author: Kristof Provost AuthorDate: 2023-08-02 08:44:52 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 08:51:43 +0000 pf tests: basic SCTP multihoming test The SCTP server will announce multiple addresses. Block one of them with pf, connect to the other have the client use the blocked address. pf is expected to have created state for all of the addresses announced by the server. In a separate test case add the secondary (client) IP after the connection has been established. The intent is to verify the functionality of the ASCONF chunk parsing. MFC after: 3 weeks Sponsored by: Orange Business Services Differential Revision: https://reviews.freebsd.org/D41638 (cherry picked from commit 1a28d5fea7edf200c37d14f7ed5865910664ec3d) --- tests/sys/netpfil/pf/Makefile | 1 + tests/sys/netpfil/pf/sctp.py | 442 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 443 insertions(+) diff --git a/tests/sys/netpfil/pf/Makefile b/tests/sys/netpfil/pf/Makefile index 16107f1fb1e7..6b61155ec40a 100644 --- a/tests/sys/netpfil/pf/Makefile +++ b/tests/sys/netpfil/pf/Makefile @@ -33,6 +33,7 @@ ATF_TESTS_SH+= altq \ tos ATF_TESTS_PYTEST+= frag6.py +ATF_TESTS_PYTEST+= sctp.py # Tests reuse jail names and so cannot run in parallel. TEST_METADATA+= is_exclusive=true diff --git a/tests/sys/netpfil/pf/sctp.py b/tests/sys/netpfil/pf/sctp.py new file mode 100644 index 000000000000..b24d0c414ac8 --- /dev/null +++ b/tests/sys/netpfil/pf/sctp.py @@ -0,0 +1,442 @@ +import pytest +import ctypes +import socket +import ipaddress +import re +from atf_python.sys.net.tools import ToolsHelper +from atf_python.sys.net.vnet import VnetTestTemplate + +import time + +SCTP_UNORDERED = 0x0400 + +SCTP_NODELAY = 0x00000004 +SCTP_SET_PEER_PRIMARY_ADDR = 0x00000006 +SCTP_PRIMARY_ADDR = 0x00000007 + +SCTP_BINDX_ADD_ADDR = 0x00008001 +SCTP_BINDX_REM_ADDR = 0x00008002 + +class sockaddr_in(ctypes.Structure): + _fields_ = [ + ('sin_len', ctypes.c_uint8), + ('sin_family', ctypes.c_uint8), + ('sin_port', ctypes.c_uint16), + ('sin_addr', ctypes.c_uint32), + ('sin_zero', ctypes.c_int8 * 8) + ] + +class sockaddr_in6(ctypes.Structure): + _fields_ = [ + ('sin6_len', ctypes.c_uint8), + ('sin6_family', ctypes.c_uint8), + ('sin6_port', ctypes.c_uint16), + ('sin6_flowinfo', ctypes.c_uint32), + ('sin6_addr', ctypes.c_uint8 * 16), + ('sin6_scope_id', ctypes.c_uint32) + ] + +class sockaddr_storage(ctypes.Union): + _fields_ = [ + ("v4", sockaddr_in), + ("v6", sockaddr_in6) + ] + +class sctp_sndrcvinfo(ctypes.Structure): + _fields_ = [ + ('sinfo_stream', ctypes.c_uint16), + ('sinfo_ssn', ctypes.c_uint16), + ('sinfo_flags', ctypes.c_uint16), + ('sinfo_ppid', ctypes.c_uint32), + ('sinfo_context', ctypes.c_uint32), + ('sinfo_timetolive', ctypes.c_uint32), + ('sinfo_tsn', ctypes.c_uint32), + ('sinfo_cumtsn', ctypes.c_uint32), + ('sinfo_assoc_id', ctypes.c_uint32), + ] + +class sctp_setprim(ctypes.Structure): + _fields_ = [ + ('ssp_addr', sockaddr_storage), + ('ssp_pad', ctypes.c_int8 * (128 - 16)), + ('ssp_assoc_id', ctypes.c_uint32), + ('ssp_padding', ctypes.c_uint32) + ] + +def to_sockaddr(ip, port): + ip = ipaddress.ip_address(ip) + + if ip.version == 4: + addr = sockaddr_in() + addr.sin_len = ctypes.sizeof(addr) + addr.sin_family = socket.AF_INET + addr.sin_port = socket.htons(port) + addr.sin_addr = socket.htonl(int.from_bytes(ip.packed, byteorder='big')) + else: + assert ip.version == 6 + + addr = sockaddr_in6() + addr.sin6_len = ctypes.sizeof(addr) + addr.sin6_family = socket.AF_INET6 + addr.sin6_port = socket.htons(port) + for i in range(0, 16): + addr.sin6_addr[i] = ip.packed[i] + + return addr + +class SCTPServer: + def __init__(self, family, port=1234): + self._libc = ctypes.CDLL("libc.so.7", use_errno=True) + + self._listen_fd = self._libc.socket(family, socket.SOCK_STREAM, socket.IPPROTO_SCTP) + if self._listen_fd == -1: + raise Exception("Failed to create socket") + + if family == socket.AF_INET: + srvaddr = sockaddr_in() + srvaddr.sin_len = ctypes.sizeof(srvaddr) + srvaddr.sin_family = socket.AF_INET + srvaddr.sin_port = socket.htons(port) + srvaddr.sin_addr = socket.INADDR_ANY + else: + srvaddr = sockaddr_in6() + srvaddr.sin6_len = ctypes.sizeof(srvaddr) + srvaddr.sin6_family = family + srvaddr.sin6_port = socket.htons(port) + # Leave sin_addr empty, because ANY is zero + + ret = self._libc.bind(self._listen_fd, ctypes.pointer(srvaddr), + ctypes.sizeof(srvaddr)) + if ret == -1: + raise Exception("Failed to bind: %d" % ctypes.get_errno()) + + ret = self._libc.listen(self._listen_fd, 2) + if ret == -1: + raise Exception("Failed to listen") + + def _to_string(self, buf): + return ''.join([chr(int.from_bytes(i, byteorder='big')) for i in buf]).rstrip('\x00') + + def accept(self, vnet): + fd = self._libc.accept(self._listen_fd, 0, 0) + if fd < 0: + raise Exception("Failed to accept") + + print("SCTPServer: connection opened") + while True: + rcvinfo = sctp_sndrcvinfo() + flags = ctypes.c_int() + buf = ctypes.create_string_buffer(128) + + # Receive a single message, and inform the other vnet about it. + ret = self._libc.sctp_recvmsg(fd, ctypes.cast(buf, ctypes.c_void_p), 128, + 0, 0, ctypes.pointer(rcvinfo), ctypes.pointer(flags)) + if ret < 0: + print("SCTPServer: connection closed") + return + if ret == 0: + continue + + rcvd = {} + rcvd['ppid'] = socket.ntohl(rcvinfo.sinfo_ppid) + rcvd['data'] = self._to_string(buf) + rcvd['len'] = ret + print(rcvd) + vnet.pipe.send(rcvd) + +class SCTPClient: + def __init__(self, ip, port=1234, fromaddr=None): + self._libc = ctypes.CDLL("libc.so.7", use_errno=True) + + if ipaddress.ip_address(ip).version == 4: + family = socket.AF_INET + else: + family = socket.AF_INET6 + + self._fd = self._libc.socket(family, socket.SOCK_STREAM, + socket.IPPROTO_SCTP) + if self._fd == -1: + raise Exception("Failed to open socket") + + if fromaddr is not None: + addr = to_sockaddr(fromaddr, 0) + + ret = self._libc.bind(self._fd, ctypes.pointer(addr), ctypes.sizeof(addr)) + if ret != 0: + print("bind() => %d", ctypes.get_errno()) + raise + + addr = to_sockaddr(ip, port) + ret = self._libc.connect(self._fd, ctypes.pointer(addr), ctypes.sizeof(addr)) + if ret == -1: + raise Exception("Failed to connect") + + # Enable NODELAY, because otherwise the sending host may wait for SACK + # on a data chunk we've removed + enable = ctypes.c_int(1) + ret = self._libc.setsockopt(self._fd, socket.IPPROTO_SCTP, + SCTP_NODELAY, ctypes.pointer(enable), 4) + + def newpeer(self, addr): + print("newpeer(%s)" % (addr)) + + setp = sctp_setprim() + a = to_sockaddr(addr, 0) + if type(a) is sockaddr_in: + setp.ssp_addr.v4 = a + else: + assert type(a) is sockaddr_in6 + setp.ssp_addr.v6 = a + + ret = self._libc.setsockopt(self._fd, socket.IPPROTO_SCTP, + SCTP_PRIMARY_ADDR, ctypes.pointer(setp), ctypes.sizeof(setp)) + if ret != 0: + print("errno %d" % ctypes.get_errno()) + raise Exception(ctypes.get_errno()) + + def newprimary(self, addr): + print("newprimary(%s)" % (addr)) + + # Strictly speaking needs to be struct sctp_setpeerprim, but that's + # identical to sctp_setprim + setp = sctp_setprim() + a = to_sockaddr(addr, 0) + if type(a) is sockaddr_in: + setp.ssp_addr.v4 = a + else: + assert type(a) is sockaddr_in6 + setp.ssp_addr.v6 = a + + ret = self._libc.setsockopt(self._fd, socket.IPPROTO_SCTP, + SCTP_SET_PEER_PRIMARY_ADDR, ctypes.pointer(setp), ctypes.sizeof(setp)) + if ret != 0: + print("errno %d" % ctypes.get_errno()) + raise + + def bindx(self, addr, add): + print("bindx(%s, %s)" % (addr, add)) + + addr = to_sockaddr(addr, 0) + + if add: + flag = SCTP_BINDX_ADD_ADDR + else: + flag = SCTP_BINDX_REM_ADDR + ret = self._libc.sctp_bindx(self._fd, ctypes.pointer(addr), 1, flag) + if ret != 0: + print("sctp_bindx() errno %d" % ctypes.get_errno()) + raise + + def send(self, buf, ppid, ordered=False): + flags = 0 + + if not ordered: + flags = SCTP_UNORDERED + + ppid = socket.htonl(ppid) + ret = self._libc.sctp_sendmsg(self._fd, ctypes.c_char_p(buf), len(buf), + ctypes.c_void_p(0), 0, ppid, flags, 0, 0, 0) + if ret < 0: + raise Exception("Failed to send message") + + def close(self): + self._libc.close(self._fd) + self._fd = -1 + +class TestSCTP(VnetTestTemplate): + REQUIRED_MODULES = ["sctp", "pf"] + TOPOLOGY = { + "vnet1": {"ifaces": ["if1"]}, + "vnet2": {"ifaces": ["if1"]}, + "if1": {"prefixes4": [("192.0.2.1/24", "192.0.2.2/24")]}, + } + + def vnet2_handler(self, vnet): + # Give ourself a second IP address, for multihome testing + ifname = vnet.iface_alias_map["if1"].name + ToolsHelper.print_output("/sbin/ifconfig %s inet alias 192.0.2.3/24" % ifname) + + # Start an SCTP server process, pipe the ppid + data back to the other vnet? + srv = SCTPServer(socket.AF_INET, port=1234) + while True: + srv.accept(vnet) + + @pytest.mark.require_user("root") + def test_multihome(self): + srv_vnet = self.vnet_map["vnet2"] + + ToolsHelper.print_output("/sbin/pfctl -e") + ToolsHelper.pf_rules([ + "block proto sctp", + "pass inet proto sctp to 192.0.2.0/24"]) + + # Sanity check, we can communicate with the primary address. + client = SCTPClient("192.0.2.3", 1234) + client.send(b"hello", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "hello" + + try: + client.newpeer("192.0.2.2") + client.send(b"world", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "world" + finally: + # Debug output + ToolsHelper.print_output("/sbin/pfctl -ss") + ToolsHelper.print_output("/sbin/pfctl -sr -vv") + + # Check that we have a state for 192.0.2.3 and 192.0.2.2 to 192.0.2.1 + states = ToolsHelper.get_output("/sbin/pfctl -ss") + assert re.search(r"all sctp 192.0.2.1:.*192.0.2.3:1234", states) + assert re.search(r"all sctp 192.0.2.1:.*192.0.2.2:1234", states) + + @pytest.mark.require_user("root") + def test_multihome_asconf(self): + srv_vnet = self.vnet_map["vnet2"] + + # Assign a second IP to ourselves + ToolsHelper.print_output("/sbin/ifconfig %s inet alias 192.0.2.10/24" + % self.vnet.iface_alias_map["if1"].name) + ToolsHelper.print_output("/sbin/pfctl -e") + ToolsHelper.pf_rules([ + "block proto sctp", + "pass inet proto sctp from 192.0.2.0/24"]) + + # Sanity check, we can communicate with the primary address. + client = SCTPClient("192.0.2.3", 1234, "192.0.2.1") + client.send(b"hello", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "hello" + + # Now add our second address to the connection + client.bindx("192.0.2.10", True) + + # We can still communicate + client.send(b"world", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "world" + + # Now change to a different peer address + try: + client.newprimary("192.0.2.10") + client.send(b"!", 0) + rcvd = self.wait_object(srv_vnet.pipe, 5) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "!" + finally: + # Debug output + ToolsHelper.print_output("/sbin/pfctl -ss -vv") + + # Ensure we have the states we'd expect + states = ToolsHelper.get_output("/sbin/pfctl -ss") + assert re.search(r"all sctp 192.0.2.1:.*192.0.2.3:1234", states) + assert re.search(r"all sctp 192.0.2.10:.*192.0.2.3:1234", states) + +class TestSCTPv6(VnetTestTemplate): + REQUIRED_MODULES = ["sctp", "pf"] + TOPOLOGY = { + "vnet1": {"ifaces": ["if1"]}, + "vnet2": {"ifaces": ["if1"]}, + "if1": {"prefixes6": [("2001:db8::1/64", "2001:db8::2/64")]}, + } + + def vnet2_handler(self, vnet): + # Give ourself a second IP address, for multihome testing + ifname = vnet.iface_alias_map["if1"].name + ToolsHelper.print_output("/sbin/ifconfig %s inet6 alias 2001:db8::3/64" % ifname) + + # Start an SCTP server process, pipe the ppid + data back to the other vnet? + srv = SCTPServer(socket.AF_INET6, port=1234) + while True: + srv.accept(vnet) + + @pytest.mark.require_user("root") + def test_multihome(self): + srv_vnet = self.vnet_map["vnet2"] + + ToolsHelper.print_output("/sbin/pfctl -e") + ToolsHelper.pf_rules([ + "block proto sctp", + "pass inet6 proto sctp to 2001:db8::0/64"]) + + # Sanity check, we can communicate with the primary address. + client = SCTPClient("2001:db8::3", 1234) + client.send(b"hello", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "hello" + + # Now change to a different peer address + try: + client.newpeer("2001:db8::2") + client.send(b"world", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "world" + finally: + # Debug output + ToolsHelper.print_output("/sbin/pfctl -ss -vv") + + # Check that we have the expected states + states = ToolsHelper.get_output("/sbin/pfctl -ss") + assert re.search(r"all sctp 2001:db8::1\[.*2001:db8::3\[1234\]", states) + assert re.search(r"all sctp 2001:db8::1\[.*2001:db8::2\[1234\]", states) + + @pytest.mark.require_user("root") + def test_multihome_asconf(self): + srv_vnet = self.vnet_map["vnet2"] + + # Assign a second IP to ourselves + ToolsHelper.print_output("/sbin/ifconfig %s inet6 alias 2001:db8::10/64" + % self.vnet.iface_alias_map["if1"].name) + ToolsHelper.print_output("/sbin/pfctl -e") + ToolsHelper.pf_rules([ + "block proto sctp", + "pass inet6 proto sctp from 2001:db8::/64"]) + + # Sanity check, we can communicate with the primary address. + client = SCTPClient("2001:db8::3", 1234, "2001:db8::1") + client.send(b"hello", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "hello" + + # Now add our second address to the connection + client.bindx("2001:db8::10", True) + + # We can still communicate + client.send(b"world", 0) + rcvd = self.wait_object(srv_vnet.pipe) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "world" + + # Now change to a different peer address + try: + client.newprimary("2001:db8::10") + client.send(b"!", 0) + rcvd = self.wait_object(srv_vnet.pipe, 5) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "!" + finally: + # Debug output + ToolsHelper.print_output("/sbin/pfctl -ss -vv") + + # Check that we have the expected states + states = ToolsHelper.get_output("/sbin/pfctl -ss") + assert re.search(r"all sctp 2001:db8::1\[.*2001:db8::3\[1234\]", states) + assert re.search(r"all sctp 2001:db8::10\[.*2001:db8::3\[1234\]", states) From nobody Mon Oct 2 09:33:25 2023 X-Original-To: dev-commits-src-branches@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 4RzbNk1qXDz4vr3r; Mon, 2 Oct 2023 09:33:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNj6fYyz4SMr; Mon, 2 Oct 2023 09:33:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239206; 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=zbZAT+BID809NzDHo11CdyaNrShAl4KynROZBAeZ6Ho=; b=KEiXjmTDaIyoXyHZt/Ikvyqf9JApXCtv20nb2oqpLjP68Ny/ucQazzJheVRUtU8v4OEGNS ahPmceuNIE7BzvQW2O6sFv47nwKPilss1JjtdLr7rVVhZhSbzwYopGsS/vEcDZiJSOU/3T 4cONMvWZhDV3KqFoMmxs8AKb2Hz1w4GWcRQarmYUloXmf/jxmh+o9HetpFCDXVIrYE6SYc DwwNnWtwXQnuJcvJkVY30y8NQm2HSCpa59N0m/d19gF4MuWZKNnVhRwCL10Z8w18wO7u3R KGqQupkA1qb0m2lqdWCi/gb2Lu/dgFqAfuDpHuwEb6seaf66kE3z3ICorU+gyg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239206; a=rsa-sha256; cv=none; b=rT9A4aJaQ2CspS1WwtsLcA8A/TwBBwhOOtSEiyglub/S7hYPMXGe2YZ6Bfy8oSo2IXvCJB FZ8Cbsnezrr97nYYkWBdPOoHHCdNYLsNEssTuR0H+YruJoD+DDCtzXM++FEUgEirYcpyR5 7Rn0x90Z0V6swOmI3W02uqhVZI5OYoW5qQiQPaHCXfbVIGq1iXy97b5S9lmxzTprjxAh+a zCBkh0m+vDTclEsGGSuCurKRqENmv/vlSKzWOV/1Wb80+6SLbt0nmZ6H6BrEbJMz5ESYGy ZEooCRHyqw5GPf4yS4sVKcJk5l8mcl21MHqI5rL4xP/0HCWMAapambO8IiSsrg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239206; 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=zbZAT+BID809NzDHo11CdyaNrShAl4KynROZBAeZ6Ho=; b=FDzSB/+B19JGo1tlvHZtf+Wy7XFarWtb+ofAawqqdwuOsG4jRzoB/0l/MWbO5bKJqtleYm ZkTmX3BrRwcZVC7/+bEtyMahrMa0QkePrYSkw6QdpDjWQzcR6JHV6vho9LRiYuMTsxauQK jS1dGpNxDkBj4+VqEAkkm4d5+Lu1d4aOx9gM2ppESEVa2sEr2ftu0fpo8n8Ja4Cl4LYwl1 UqxKUzjBw36oL7bBpuZ/rFkN5fHmYXg7q/xMSYk/6cjTphxrbSaLg2q5lJHITcETF6mYuW hmdI7E9048HsR5/BG9jL26sVwMnw/79RXchnIJ+4EBXKh9OggdZauqexzdYbDg== 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 4RzbNj5XJNz16QG; Mon, 2 Oct 2023 09:33:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XPgB002949; Mon, 2 Oct 2023 09:33:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XP4f002946; Mon, 2 Oct 2023 09:33:25 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:25 GMT Message-Id: <202310020933.3929XP4f002946@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 45f475427d8e - stable/14 - pf: inherit v_tag values to multihomed connections List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 45f475427d8e8e1583104350699620fc8aee8735 Auto-Submitted: auto-generated The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=45f475427d8e8e1583104350699620fc8aee8735 commit 45f475427d8e8e1583104350699620fc8aee8735 Author: Kristof Provost AuthorDate: 2023-09-04 16:00:08 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 09:32:14 +0000 pf: inherit v_tag values to multihomed connections When we create a new state for an existing SCTP association inherit the v_tag values from the original connection. MFC after: 3 weeks Sponsored by: Orange Business Services (cherry picked from commit f1cc29af84475b800df5eb94ff7d5b9484ddbdac) --- sys/netpfil/pf/pf.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 8958579b7e63..085ab5827e26 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -5939,8 +5939,12 @@ pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, j->m, off, &j->pd, &ra, &rs, NULL); PF_RULES_RUNLOCK(); SDT_PROBE4(pf, sctp, multihome, test, kif, r, j->m, action); - if (sm) + if (sm) { + /* Inherit v_tag values. */ + sm->src.scrub->pfss_v_tag = s->src.scrub->pfss_flags; + sm->dst.scrub->pfss_v_tag = s->dst.scrub->pfss_flags; PF_STATE_UNLOCK(sm); + } free(j, M_PFTEMP); } From nobody Mon Oct 2 09:33:25 2023 X-Original-To: dev-commits-src-branches@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 4RzbNk1zlvz4vrNB; Mon, 2 Oct 2023 09:33:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNj6vD7z4SVX; Mon, 2 Oct 2023 09:33:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239206; 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=yL8rIlziwLTNTNI4eqyIE8Pq5Au5b3he9ichrC+ZZVs=; b=mNQG82GoUr2ESqReYw8wI/CBnSdwf7/CaqHO0wih+RMf8Pk0c0j/06LH27ffBthWndT4yk 9gEgy5iMSmXOqiIgUpWrMaVDrRgo+AgzNp9xMAR7bUMWNUUEqVdBdZp10OqQ/Xa/cZPiSA 5oXzHzZVCg8Al6M8KKvk/vS2K2/E85XAB68/5eyok8mIPsAQlS1XpLI+l9Tc8x+u7GF5u6 n43drxSwnD/7nG2p0+pvXSA+FrHfO+lXNxA1DT7cPZgykvjnEkP+j8MjyC4fFh6a5LghwN 5QMDqDW/KnuyEzFaT7oUmb4wd0xD4SHctnjrfJDGWFIwuMLNWPiVdU+ncd2gFw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239206; a=rsa-sha256; cv=none; b=JuJmWs/kn3/CMxpMcr0FNKfASV1DxU/W0VZFu7asj5vJjjJyAgrnLjNcNVjhm/3hAc7rIY RM0qp6kCrdVQFIF4X+YNHIY9a9ruT7FKHXuKWpyIqlQfe1JTStgi100lx28y7hAPeTcdIc rgHZQ2QSjLwxuFep8biKXeuVH44g9IIdq6xSzTwdgodDddiHRCySMwgToE+UBYov/0z6q6 +bQXhodzMGQK1UjJYYtrSLJ7wPn3k5Ttm0XzZPNKXonzb/bNas8BCoytBcszb3dnbPxFOs ZOwOuHNLfA914a04S6hJMLm+NfFtihzMrpRUVSGq/NhKD9Y/fn61ffqQHLlkDQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239206; 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=yL8rIlziwLTNTNI4eqyIE8Pq5Au5b3he9ichrC+ZZVs=; b=UaMB9SiPwVelatGymkKEVmE1dWTKCCeBpY1WYdDCj+NoTQaouHryvpB+2Y6r7C5q9WZWEI KV6ybG3cqTPq6O4AFouAsql9U17uiMXNsCk0BsPvcBCJouHMbdY6CxNyhMTGEQ9e1x9HtV 33fxFh6RDouIGqsUd0vWzy1cPFLSQRENRobEhMvMcp/TtzkFfNjJL18BlBiKwoqCH6htcT Rc1tQWf0Zu6v0ChUvHDGI63eh40JmijknUVdloVGxWbXppmqHSvTk9w1H+gBIBkrcNR7vL sso5leSH5Zc3IUVeWoWropLyHC2jE2RdNPVRQw8JkSYeiHzNoy61uKjZlAWJqw== 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 4RzbNj5s4bz16c5; Mon, 2 Oct 2023 09:33:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XPPR002991; Mon, 2 Oct 2023 09:33:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XPPR002988; Mon, 2 Oct 2023 09:33:25 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:25 GMT Message-Id: <202310020933.3929XPPR002988@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 00cd3145d4c6 - stable/13 - pf: improve SCTP state validation List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: 00cd3145d4c650446ae54007ec50745244942ef2 Auto-Submitted: auto-generated The branch stable/13 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=00cd3145d4c650446ae54007ec50745244942ef2 commit 00cd3145d4c650446ae54007ec50745244942ef2 Author: Kristof Provost AuthorDate: 2023-09-01 11:33:56 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 08:51:43 +0000 pf: improve SCTP state validation Only create new states for INIT chunks, or when we're creating a secondary state for a multihomed association. Store and verify verification tag. MFC after: 3 weeks Sponsored by: Orange Business Services (cherry picked from commit 51a78dd2764beabfd19a58b8a8b04387a547f02e) --- sys/net/pfvar.h | 8 +++++++- sys/netpfil/pf/pf.c | 25 +++++++++++++++---------- sys/netpfil/pf/pf_norm.c | 18 ++++++++++++++++++ 3 files changed, 40 insertions(+), 11 deletions(-) diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h index 07a4140e450f..3cb093ba8b02 100644 --- a/sys/net/pfvar.h +++ b/sys/net/pfvar.h @@ -700,7 +700,10 @@ struct pf_state_scrub { #define PFSS_DATA_NOTS 0x0080 /* no timestamp on data packets */ u_int8_t pfss_ttl; /* stashed TTL */ u_int8_t pad; - u_int32_t pfss_ts_mod; /* timestamp modulation */ + union { + u_int32_t pfss_ts_mod; /* timestamp modulation */ + u_int32_t pfss_v_tag; /* SCTP verification tag */ + }; }; struct pf_state_host { @@ -1332,6 +1335,7 @@ struct pf_pdesc { #define PFDESC_SCTP_DATA 0x0040 #define PFDESC_SCTP_ASCONF 0x0080 #define PFDESC_SCTP_OTHER 0x0100 +#define PFDESC_SCTP_ADD_IP 0x0200 u_int16_t sctp_flags; u_int32_t sctp_initiate_tag; @@ -2044,6 +2048,8 @@ int pf_normalize_tcp_init(struct mbuf *, int, struct pf_pdesc *, int pf_normalize_tcp_stateful(struct mbuf *, int, struct pf_pdesc *, u_short *, struct tcphdr *, struct pf_kstate *, struct pf_state_peer *, struct pf_state_peer *, int *); +int pf_normalize_sctp_init(struct mbuf *, int, struct pf_pdesc *, + struct pf_state_peer *, struct pf_state_peer *); int pf_normalize_sctp(int, struct pfi_kkif *, struct mbuf *, int, int, void *, struct pf_pdesc *); u_int32_t diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index cb4ab2da4633..551bfd01732f 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -4340,11 +4340,7 @@ pf_create_state(struct pf_krule *r, struct pf_krule *nr, struct pf_krule *a, if ((pd->flags & PFDESC_TCP_NORM) && pf_normalize_tcp_init(m, off, pd, th, &s->src, &s->dst)) { REASON_SET(&reason, PFRES_MEMORY); - pf_src_tree_remove_state(s); - s->timeout = PFTM_UNLINKED; - STATE_DEC_COUNTERS(s); - pf_free_state(s); - return (PF_DROP); + goto drop; } if ((pd->flags & PFDESC_TCP_NORM) && s->src.scrub && pf_normalize_tcp_stateful(m, off, pd, &reason, th, s, @@ -4353,12 +4349,13 @@ pf_create_state(struct pf_krule *r, struct pf_krule *nr, struct pf_krule *a, DPFPRINTF(PF_DEBUG_URGENT, ("pf_normalize_tcp_stateful failed on first " "pkt\n")); - pf_src_tree_remove_state(s); - s->timeout = PFTM_UNLINKED; - STATE_DEC_COUNTERS(s); - pf_free_state(s); - return (PF_DROP); + goto drop; } + } else if (pd->proto == IPPROTO_SCTP) { + if (pf_normalize_sctp_init(m, off, pd, &s->src, &s->dst)) + goto drop; + if (! (pd->sctp_flags & (PFDESC_SCTP_INIT | PFDESC_SCTP_ADD_IP))) + goto drop; } s->direction = pd->dir; @@ -5312,6 +5309,13 @@ pf_test_state_sctp(struct pf_kstate **state, struct pfi_kkif *kif, } } + if (src->scrub != NULL) { + if (src->scrub->pfss_v_tag == 0) { + src->scrub->pfss_v_tag = pd->hdr.sctp.v_tag; + } else if (src->scrub->pfss_v_tag != pd->hdr.sctp.v_tag) + return (PF_DROP); + } + (*state)->expire = time_uptime; /* translate source/destination address, if necessary */ @@ -5352,6 +5356,7 @@ pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, TAILQ_FOREACH_SAFE(j, &pd->sctp_multihome_jobs, next, tmp) { PF_RULES_RLOCK(); + j->pd.sctp_flags |= PFDESC_SCTP_ADD_IP; action = pf_test_rule(&r, &sm, pd->dir, kif, j->m, off, &j->pd, &ra, &rs, NULL); PF_RULES_RUNLOCK(); diff --git a/sys/netpfil/pf/pf_norm.c b/sys/netpfil/pf/pf_norm.c index ec3f63c9f262..a8ef4dc346b0 100644 --- a/sys/netpfil/pf/pf_norm.c +++ b/sys/netpfil/pf/pf_norm.c @@ -1529,6 +1529,7 @@ pf_normalize_tcp_init(struct mbuf *m, int off, struct pf_pdesc *pd, void pf_normalize_tcp_cleanup(struct pf_kstate *state) { + /* XXX Note: this also cleans up SCTP. */ if (state->src.scrub) uma_zfree(V_pf_state_scrub_z, state->src.scrub); if (state->dst.scrub) @@ -1537,6 +1538,23 @@ pf_normalize_tcp_cleanup(struct pf_kstate *state) /* Someday... flush the TCP segment reassembly descriptors. */ } +int +pf_normalize_sctp_init(struct mbuf *m, int off, struct pf_pdesc *pd, + struct pf_state_peer *src, struct pf_state_peer *dst) +{ + src->scrub = uma_zalloc(V_pf_state_scrub_z, M_ZERO | M_NOWAIT); + if (src->scrub == NULL) + return (1); + + dst->scrub = uma_zalloc(V_pf_state_scrub_z, M_ZERO | M_NOWAIT); + if (dst->scrub == NULL) { + uma_zfree(V_pf_state_scrub_z, src); + return (1); + } + + return (0); +} + int pf_normalize_tcp_stateful(struct mbuf *m, int off, struct pf_pdesc *pd, u_short *reason, struct tcphdr *th, struct pf_kstate *state, From nobody Mon Oct 2 09:33:26 2023 X-Original-To: dev-commits-src-branches@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 4RzbNl2PRvz4vrcd; Mon, 2 Oct 2023 09:33: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNl1YzLz4SSy; Mon, 2 Oct 2023 09:33:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239207; 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=GPsMaasfSX6HEswzQStMLLq8RGjd9q9P0aJeY3zxWno=; b=bS6CDafrMICL2WzYreJQ37YJX8JtGJ9/C6GDNRV9CFl/SSMymtfsUL2HK7ikxbo0oRFrQO dVMGIvIclhkYw7c8xnOXfK9Yrjp/E6X1viWdZ7LomZV80KrKBAToy+XydTNkbjtzIPNePO s7TunL3q+3aKEAij9v+RUCmYujYpNdHlRpe3h7C69VNdsjdHML7JzRIxmnxkhI/CVvzCWj 0y1pNNkkCWz5kuq6aZpBvJFm1/Hci/Ckd8pViUrhjZzbmhOQ4wdYTxHsYdQ8XK3tynAcfZ DGrM20zTT9NRhGoyConvimWAzrH31h4DyCjM9+zmdkuyVVMmfmwtN81X2KB5EQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239207; a=rsa-sha256; cv=none; b=FTzIpYxOCaU5sPYqYV3uAb6n7wgwUjgKEGqvfwf7i6aQSNO96g8MUr6juIE+oD3NzAPbhz Hx9mYeHQrDSWtkx6dBicoFS/rwh/Mk+bbGfY6sJkFU8steI9iGpMikfGqvouLY8fnh3g70 1GfC0APR7sen2iA9XAzv0wGnDkPU5y4iQ8iJKcUo9DkHCkWqHSdybcPkNseL1o57RS6yFX nUC+hjLFdlKbJgqnuZ5gawHvPxWgPfOjg8eyItRxVZXMI9v1Zm+3CWAMQDzUlGd6qlg/Eg uU570i8BCMWXc6cjjDQN1wFiQ5/pvoSWydWbhI3FRiz1xgQ3GHgJ0OzHBRZjKA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239207; 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=GPsMaasfSX6HEswzQStMLLq8RGjd9q9P0aJeY3zxWno=; b=TZjGx9/bnkXjsxKLVb+gKYVzpyP9+GolMRiV8a7mylQYwId02o4Otxg7LT6jHGnWTZi6pG 6ungOb8/YnWeD090IGyePTV3bIs5ofGtqTtSjsKoM7CJs/YDhXosYnIrBGc82XTYuXxmSj MY4/CJVcPoMbLmgv/4Bwt/GaBa5Qu6Om5SsHvlvcQpb/wdUdz4xcfvEEG5N97shiwX0o8d OCvskoHGhuVxkpnoIN3Driyvv+bcE1QXrOjmExoH9KB4o9jXd02VcWM2tTS9AZOtKveljC x9288bc8QPoI//CPEzueBZbXrb3Q96q/VVTJtgrOudMjAwEdoESoSswqwiLKPw== 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 4RzbNk6kfZz16QH; Mon, 2 Oct 2023 09:33:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XQec003099; Mon, 2 Oct 2023 09:33:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XQtt003095; Mon, 2 Oct 2023 09:33:26 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:26 GMT Message-Id: <202310020933.3929XQtt003095@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 9febb2d3576e - stable/13 - pf: inherit v_tag values to multihomed connections List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: 9febb2d3576e695f146a0304faff95853cc92d62 Auto-Submitted: auto-generated The branch stable/13 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=9febb2d3576e695f146a0304faff95853cc92d62 commit 9febb2d3576e695f146a0304faff95853cc92d62 Author: Kristof Provost AuthorDate: 2023-09-04 16:00:08 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 08:51:44 +0000 pf: inherit v_tag values to multihomed connections When we create a new state for an existing SCTP association inherit the v_tag values from the original connection. MFC after: 3 weeks Sponsored by: Orange Business Services (cherry picked from commit f1cc29af84475b800df5eb94ff7d5b9484ddbdac) --- sys/netpfil/pf/pf.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 551bfd01732f..be4fa4273972 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -5361,8 +5361,12 @@ pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, j->m, off, &j->pd, &ra, &rs, NULL); PF_RULES_RUNLOCK(); SDT_PROBE4(pf, sctp, multihome, test, kif, r, j->m, action); - if (sm) + if (sm) { + /* Inherit v_tag values. */ + sm->src.scrub->pfss_v_tag = s->src.scrub->pfss_flags; + sm->dst.scrub->pfss_v_tag = s->dst.scrub->pfss_flags; PF_STATE_UNLOCK(sm); + } free(j, M_PFTEMP); } From nobody Mon Oct 2 09:33:26 2023 X-Original-To: dev-commits-src-branches@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 4RzbNl2RY9z4vrf6; Mon, 2 Oct 2023 09:33: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNl0gf8z4SbL; Mon, 2 Oct 2023 09:33:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239207; 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=V4kIhQTJwJjS0B8IzrkOxDzPF7EyBzXFn4ApqY318lw=; b=j5w/RWfhPmbLyx2yYxYLX/AcyfmGtYWR1t0+8W5Bmn9ibzB55JbxCGQMHEA2PFCRimHGXg QSJT3w/PnlpIW4zh3W7Ld0Ai4fKmjUwz2hHZrzjgSau497YdESJbJDin67zKIZPCojjo+A sMx/uHnzLTA1mHVkqmJrvAROCnGw3Q/7H0RRKO4UYDPoWmOw5BhVvIPTGNvXvtgHQYWnJF E4AQpTxs9mP8ed3/oqTadOjnmKqRtwSV4U7403w6rX2Q4mwfp73rleum8ynIY3kX13BWrn +1iujsap9XBwvEBqzxy9uabpFC5nwVvvq5p5VsuRsor1uSLjZ7ZqZVBrOKxEVw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239207; a=rsa-sha256; cv=none; b=BZxOdQDqEDqjV4v4pWOiIBtmu83qe580ZgmDQ6xRsJCLvRu9Rmh5M2jfRqgqW8CKR1m2Hc ZxkqLRVOC1pFt0Ki7Mb0/secCGLCTIk+eEt7G4GTRVj6R5fKJ+d0hl39hssVuQJAbSpm+X V2p9ZiPMN9VBRoODlBjvTEKR52KwC4R5IOA0awbAoXTAcnNfw/Rzeob48W5v3k1Yix4IGi rRsHdJM+8TlLFjV7Sqat2ajy9m+2akoba6Uv4bUxmtY5m9+JewlleqSLAFjySlZoPDwaIW Vge5qJfgbHR1wE7lXBXD/ZpP/Iy0qeZSNy+5tPX4Ln7+1P4WVkRHgOX8OLEusQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239207; 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=V4kIhQTJwJjS0B8IzrkOxDzPF7EyBzXFn4ApqY318lw=; b=RKTxmmHvCyUsOLQh44fPdm6OWLnOAUmfeIkYWgraljBDFvwZ7ZP35D0mJrdxxkcrwuI5L0 MHat58APdf6YC2xvW+Z2/LCiAbatfJ/CsdVqDcyJnQKobX4GhRucvyPyvOmg4tmgXkYUtg 5B18MNdC0kktQcKlOA2Fxpt20ehJtXmBF8kyxjZTnAJrHIRYDgHSvNmK/VJzd+Iky8SSpF wRXAECOkDtrVD3ZjuzlBMXEwYf4z9gSPkomLGIh4N2Xuf8j/eTyZM0OiRNCObkmQjN9bsX r9A+8vi8vu5xkhfm+OIhz31frgrU26uSjDi08gS/UjbSkJV8pnnIt+q4OoSqQw== 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 4RzbNk6jW1z16c6; Mon, 2 Oct 2023 09:33:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XQG4003098; Mon, 2 Oct 2023 09:33:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XQ8n003071; Mon, 2 Oct 2023 09:33:26 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:26 GMT Message-Id: <202310020933.3929XQ8n003071@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 6d1714a44e63 - stable/14 - pf: mark removed connections within a multihome association as shutting down List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 6d1714a44e634f3063f6cd0a4fab0782ddc87fe7 Auto-Submitted: auto-generated The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=6d1714a44e634f3063f6cd0a4fab0782ddc87fe7 commit 6d1714a44e634f3063f6cd0a4fab0782ddc87fe7 Author: Kristof Provost AuthorDate: 2023-09-05 16:30:42 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 09:32:14 +0000 pf: mark removed connections within a multihome association as shutting down Parse IP removal in ASCONF chunks, find the affected state(s) and mark them as shutting down. This will cause them to time out according to PFTM_TCP_CLOSING timeouts, rather than waiting for the established session timeout. MFC after: 3 weeks Sponsored by: Orange Business Services (cherry picked from commit 4d3af82f78961180149e8a579b481dc382f76eef) --- sys/net/pfvar.h | 1 + sys/netpfil/pf/pf.c | 87 ++++++++++++++++++++++++++++++++++++++++++++--------- 2 files changed, 73 insertions(+), 15 deletions(-) diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h index a8567ab74fe3..15fa671ddcbe 100644 --- a/sys/net/pfvar.h +++ b/sys/net/pfvar.h @@ -1599,6 +1599,7 @@ struct pf_sctp_multihome_job { struct pf_addr src; struct pf_addr dst; struct mbuf *m; + int op; }; #endif diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 085ab5827e26..6a8ba7be56cf 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -5933,17 +5933,57 @@ pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, PF_RULES_RLOCK_TRACKER; TAILQ_FOREACH_SAFE(j, &pd->sctp_multihome_jobs, next, tmp) { - PF_RULES_RLOCK(); - j->pd.sctp_flags |= PFDESC_SCTP_ADD_IP; - action = pf_test_rule(&r, &sm, kif, - j->m, off, &j->pd, &ra, &rs, NULL); - PF_RULES_RUNLOCK(); - SDT_PROBE4(pf, sctp, multihome, test, kif, r, j->m, action); - if (sm) { - /* Inherit v_tag values. */ - sm->src.scrub->pfss_v_tag = s->src.scrub->pfss_flags; - sm->dst.scrub->pfss_v_tag = s->dst.scrub->pfss_flags; - PF_STATE_UNLOCK(sm); + switch (j->op) { + case SCTP_ADD_IP_ADDRESS: { + j->pd.sctp_flags |= PFDESC_SCTP_ADD_IP; + PF_RULES_RLOCK(); + action = pf_test_rule(&r, &sm, kif, + j->m, off, &j->pd, &ra, &rs, NULL); + PF_RULES_RUNLOCK(); + SDT_PROBE4(pf, sctp, multihome, test, kif, r, j->m, action); + if (sm) { + /* Inherit v_tag values. */ + sm->src.scrub->pfss_v_tag = s->src.scrub->pfss_flags; + sm->dst.scrub->pfss_v_tag = s->dst.scrub->pfss_flags; + PF_STATE_UNLOCK(sm); + } + break; + } + case SCTP_DEL_IP_ADDRESS: { + struct pf_state_key_cmp key; + uint8_t psrc; + + bzero(&key, sizeof(key)); + key.af = j->pd.af; + key.proto = IPPROTO_SCTP; + if (j->pd.dir == PF_IN) { /* wire side, straight */ + PF_ACPY(&key.addr[0], j->pd.src, key.af); + PF_ACPY(&key.addr[1], j->pd.dst, key.af); + key.port[0] = j->pd.hdr.sctp.src_port; + key.port[1] = j->pd.hdr.sctp.dest_port; + } else { /* stack side, reverse */ + PF_ACPY(&key.addr[1], j->pd.src, key.af); + PF_ACPY(&key.addr[0], j->pd.dst, key.af); + key.port[1] = j->pd.hdr.sctp.src_port; + key.port[0] = j->pd.hdr.sctp.dest_port; + } + + sm = pf_find_state(kif, &key, j->pd.dir); + if (sm != NULL) { + PF_STATE_LOCK_ASSERT(sm); + if (j->pd.dir == sm->direction) { + psrc = PF_PEER_SRC; + } else { + psrc = PF_PEER_DST; + } + pf_set_protostate(sm, psrc, SCTP_SHUTDOWN_PENDING); + sm->timeout = PFTM_TCP_CLOSING; + PF_STATE_UNLOCK(sm); + } + break; + default: + panic("Unknown op %#x", j->op); + } } free(j, M_PFTEMP); @@ -5952,7 +5992,7 @@ pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, static int pf_multihome_scan(struct mbuf *m, int start, int len, struct pf_pdesc *pd, - struct pfi_kkif *kif) + struct pfi_kkif *kif, int op) { int off = 0; struct pf_sctp_multihome_job *job; @@ -6014,6 +6054,7 @@ pf_multihome_scan(struct mbuf *m, int start, int len, struct pf_pdesc *pd, memcpy(&job->dst, pd->dst, sizeof(job->dst)); job->pd.dst = &job->dst; job->m = m; + job->op = op; TAILQ_INSERT_TAIL(&pd->sctp_multihome_jobs, job, next); break; @@ -6044,6 +6085,7 @@ pf_multihome_scan(struct mbuf *m, int start, int len, struct pf_pdesc *pd, memcpy(&job->dst, pd->dst, sizeof(job->dst)); job->pd.dst = &job->dst; job->m = m; + job->op = op; TAILQ_INSERT_TAIL(&pd->sctp_multihome_jobs, job, next); break; @@ -6058,7 +6100,22 @@ pf_multihome_scan(struct mbuf *m, int start, int len, struct pf_pdesc *pd, return (PF_DROP); ret = pf_multihome_scan(m, start + off + sizeof(ah), - ntohs(ah.ph.param_length) - sizeof(ah), pd, kif); + ntohs(ah.ph.param_length) - sizeof(ah), pd, kif, + SCTP_ADD_IP_ADDRESS); + if (ret != PF_PASS) + return (ret); + break; + } + case SCTP_DEL_IP_ADDRESS: { + int ret; + struct sctp_asconf_paramhdr ah; + + if (!pf_pull_hdr(m, start + off, &ah, sizeof(ah), + NULL, NULL, pd->af)) + return (PF_DROP); + ret = pf_multihome_scan(m, start + off + sizeof(ah), + ntohs(ah.ph.param_length) - sizeof(ah), pd, kif, + SCTP_DEL_IP_ADDRESS); if (ret != PF_PASS) return (ret); break; @@ -6079,7 +6136,7 @@ pf_multihome_scan_init(struct mbuf *m, int start, int len, struct pf_pdesc *pd, start += sizeof(struct sctp_init_chunk); len -= sizeof(struct sctp_init_chunk); - return (pf_multihome_scan(m, start, len, pd, kif)); + return (pf_multihome_scan(m, start, len, pd, kif, SCTP_ADD_IP_ADDRESS)); } int @@ -6089,7 +6146,7 @@ pf_multihome_scan_asconf(struct mbuf *m, int start, int len, start += sizeof(struct sctp_asconf_chunk); len -= sizeof(struct sctp_asconf_chunk); - return (pf_multihome_scan(m, start, len, pd, kif)); + return (pf_multihome_scan(m, start, len, pd, kif, SCTP_ADD_IP_ADDRESS)); } static int From nobody Mon Oct 2 09:33:27 2023 X-Original-To: dev-commits-src-branches@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 4RzbNm2nXsz4vrH3; Mon, 2 Oct 2023 09:33: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNm25Jvz4Sbh; Mon, 2 Oct 2023 09:33:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239208; 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=tMLM5N8tWc43jfTTtwMvD464GBxC5A1uWMf81zWjsso=; b=d6Far1a6xqVJ5hVr72dweJ4nDoQ5tErJV4ZRJRNJXPZK4oiNHLA6TKZqWSgqnK0nutc/nf bvInb45Mr0hjVhpE7kwsrvWDY/YM+daP6n7A7Xar6HREXOAWF/03JTK4k7kvim1GcDYWZl lxbn5/Q42wtj68BNJuPWIWexQPFdS5ozQmDWvddD7RpWKGkkBR0KanQC65ljkGPzeZvnoC oZuvmYPyZj0TS+y8RY6f3SrYNG+vF9QW8Uo+6z8HdH46tx7dYSGCjHRYw0ohvaeLT31kKO P4tv/eQRlIUFx6YhjDO3P8S2eO8StDlu+Oxo+DnhIHgX3Y9TLfF9bNSebpZ0hA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239208; a=rsa-sha256; cv=none; b=V2FfcjktF5/y+8VLfUSrM5PEPa78UI3IMdicqtoQ+9tIpuDRytM28q1Omt18ePt/Fw8NLk bFiFQGCTIQjgVM1UfPQBDQgzNB0uhWR3IOpuXyo6fns1XBbT6YCRmHvC7pNoJRUcvQKKfA Kn32TorHH8HJSvf5LOATM2lm9DWuddm/b99MYVQ3cHsLvganXX8gisdynlbAJ9mZlHC9d7 SEc2FbmHA3OZDfcT0/NVXcKrqJ+AoQOm9G+5+3z3A8qrg7mFbfZ99JxUusY39CFnAplWfM p22VeUUpphEWUvBzJ/0Et5dwmrRBtacTSIff8iNvXa21GnUc0e+3KEzu3N6Yfg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239208; 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=tMLM5N8tWc43jfTTtwMvD464GBxC5A1uWMf81zWjsso=; b=ONLZs4ImMPKFRspsPmFEz9wTrvjUpvvJ18vklj60zB9vAQVK1DvKDkTTwJYTsApr7mqwfS 90Dvauws7Z0VlRBlypsc6Bb30CepFSRYokWsGUSGqMd42uUaO+Lg+NlOF2XCs/jxmxQb14 lPQS1CqkLmj+OD3ZNRMExQixwUVbgoOTSfHidsjephOGmPks0V5UqgIYGcVhzuBl1EQVk2 H9Za+B4+SM2nXM0YHpXidYW5sk12xBhtn3kK1YnkVHbkO8URcksa6BeXPn8ByQDSL2tzEl coXGQScCG3CVpDew4ik/CGzN9Bg5TE8hu7uDLnTSxmbRiZosObl1ii0AqAmEaQ== 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 4RzbNm0cj6z16CD; Mon, 2 Oct 2023 09:33:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XRWu003226; Mon, 2 Oct 2023 09:33:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XRhc003217; Mon, 2 Oct 2023 09:33:27 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:27 GMT Message-Id: <202310020933.3929XRhc003217@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 95f44dd698b0 - stable/13 - pf: mark removed connections within a multihome association as shutting down List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: 95f44dd698b0439b51788951f840b501651ecebf Auto-Submitted: auto-generated The branch stable/13 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=95f44dd698b0439b51788951f840b501651ecebf commit 95f44dd698b0439b51788951f840b501651ecebf Author: Kristof Provost AuthorDate: 2023-09-05 16:30:42 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 08:51:44 +0000 pf: mark removed connections within a multihome association as shutting down Parse IP removal in ASCONF chunks, find the affected state(s) and mark them as shutting down. This will cause them to time out according to PFTM_TCP_CLOSING timeouts, rather than waiting for the established session timeout. MFC after: 3 weeks Sponsored by: Orange Business Services (cherry picked from commit 4d3af82f78961180149e8a579b481dc382f76eef) --- sys/net/pfvar.h | 1 + sys/netpfil/pf/pf.c | 87 ++++++++++++++++++++++++++++++++++++++++++++--------- 2 files changed, 73 insertions(+), 15 deletions(-) diff --git a/sys/net/pfvar.h b/sys/net/pfvar.h index 3cb093ba8b02..9c6f5bccae02 100644 --- a/sys/net/pfvar.h +++ b/sys/net/pfvar.h @@ -1348,6 +1348,7 @@ struct pf_sctp_multihome_job { struct pf_addr src; struct pf_addr dst; struct mbuf *m; + int op; }; #endif diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index be4fa4273972..55942fcf4338 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -5355,17 +5355,57 @@ pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, PF_RULES_RLOCK_TRACKER; TAILQ_FOREACH_SAFE(j, &pd->sctp_multihome_jobs, next, tmp) { - PF_RULES_RLOCK(); - j->pd.sctp_flags |= PFDESC_SCTP_ADD_IP; - action = pf_test_rule(&r, &sm, pd->dir, kif, - j->m, off, &j->pd, &ra, &rs, NULL); - PF_RULES_RUNLOCK(); - SDT_PROBE4(pf, sctp, multihome, test, kif, r, j->m, action); - if (sm) { - /* Inherit v_tag values. */ - sm->src.scrub->pfss_v_tag = s->src.scrub->pfss_flags; - sm->dst.scrub->pfss_v_tag = s->dst.scrub->pfss_flags; - PF_STATE_UNLOCK(sm); + switch (j->op) { + case SCTP_ADD_IP_ADDRESS: { + j->pd.sctp_flags |= PFDESC_SCTP_ADD_IP; + PF_RULES_RLOCK(); + action = pf_test_rule(&r, &sm, pd->dir, kif, + j->m, off, &j->pd, &ra, &rs, NULL); + PF_RULES_RUNLOCK(); + SDT_PROBE4(pf, sctp, multihome, test, kif, r, j->m, action); + if (sm) { + /* Inherit v_tag values. */ + sm->src.scrub->pfss_v_tag = s->src.scrub->pfss_flags; + sm->dst.scrub->pfss_v_tag = s->dst.scrub->pfss_flags; + PF_STATE_UNLOCK(sm); + } + break; + } + case SCTP_DEL_IP_ADDRESS: { + struct pf_state_key_cmp key; + uint8_t psrc; + + bzero(&key, sizeof(key)); + key.af = j->pd.af; + key.proto = IPPROTO_SCTP; + if (j->pd.dir == PF_IN) { /* wire side, straight */ + PF_ACPY(&key.addr[0], j->pd.src, key.af); + PF_ACPY(&key.addr[1], j->pd.dst, key.af); + key.port[0] = j->pd.hdr.sctp.src_port; + key.port[1] = j->pd.hdr.sctp.dest_port; + } else { /* stack side, reverse */ + PF_ACPY(&key.addr[1], j->pd.src, key.af); + PF_ACPY(&key.addr[0], j->pd.dst, key.af); + key.port[1] = j->pd.hdr.sctp.src_port; + key.port[0] = j->pd.hdr.sctp.dest_port; + } + + sm = pf_find_state(kif, &key, j->pd.dir); + if (sm != NULL) { + PF_STATE_LOCK_ASSERT(sm); + if (j->pd.dir == sm->direction) { + psrc = PF_PEER_SRC; + } else { + psrc = PF_PEER_DST; + } + pf_set_protostate(sm, psrc, SCTP_SHUTDOWN_PENDING); + sm->timeout = PFTM_TCP_CLOSING; + PF_STATE_UNLOCK(sm); + } + break; + default: + panic("Unknown op %#x", j->op); + } } free(j, M_PFTEMP); @@ -5374,7 +5414,7 @@ pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, static int pf_multihome_scan(struct mbuf *m, int start, int len, struct pf_pdesc *pd, - struct pfi_kkif *kif) + struct pfi_kkif *kif, int op) { int off = 0; struct pf_sctp_multihome_job *job; @@ -5436,6 +5476,7 @@ pf_multihome_scan(struct mbuf *m, int start, int len, struct pf_pdesc *pd, memcpy(&job->dst, pd->dst, sizeof(job->dst)); job->pd.dst = &job->dst; job->m = m; + job->op = op; TAILQ_INSERT_TAIL(&pd->sctp_multihome_jobs, job, next); break; @@ -5466,6 +5507,7 @@ pf_multihome_scan(struct mbuf *m, int start, int len, struct pf_pdesc *pd, memcpy(&job->dst, pd->dst, sizeof(job->dst)); job->pd.dst = &job->dst; job->m = m; + job->op = op; TAILQ_INSERT_TAIL(&pd->sctp_multihome_jobs, job, next); break; @@ -5480,7 +5522,22 @@ pf_multihome_scan(struct mbuf *m, int start, int len, struct pf_pdesc *pd, return (PF_DROP); ret = pf_multihome_scan(m, start + off + sizeof(ah), - ntohs(ah.ph.param_length) - sizeof(ah), pd, kif); + ntohs(ah.ph.param_length) - sizeof(ah), pd, kif, + SCTP_ADD_IP_ADDRESS); + if (ret != PF_PASS) + return (ret); + break; + } + case SCTP_DEL_IP_ADDRESS: { + int ret; + struct sctp_asconf_paramhdr ah; + + if (!pf_pull_hdr(m, start + off, &ah, sizeof(ah), + NULL, NULL, pd->af)) + return (PF_DROP); + ret = pf_multihome_scan(m, start + off + sizeof(ah), + ntohs(ah.ph.param_length) - sizeof(ah), pd, kif, + SCTP_DEL_IP_ADDRESS); if (ret != PF_PASS) return (ret); break; @@ -5502,7 +5559,7 @@ pf_multihome_scan_init(struct mbuf *m, int start, int len, struct pf_pdesc *pd, start += sizeof(struct sctp_init_chunk); len -= sizeof(struct sctp_init_chunk); - return (pf_multihome_scan(m, start, len, pd, kif)); + return (pf_multihome_scan(m, start, len, pd, kif, SCTP_ADD_IP_ADDRESS)); } int @@ -5512,7 +5569,7 @@ pf_multihome_scan_asconf(struct mbuf *m, int start, int len, start += sizeof(struct sctp_asconf_chunk); len -= sizeof(struct sctp_asconf_chunk); - return (pf_multihome_scan(m, start, len, pd, kif)); + return (pf_multihome_scan(m, start, len, pd, kif, SCTP_ADD_IP_ADDRESS)); } static int From nobody Mon Oct 2 09:33:27 2023 X-Original-To: dev-commits-src-branches@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 4RzbNm2m6nz4vrKN; Mon, 2 Oct 2023 09:33: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNm26B0z4Sms; Mon, 2 Oct 2023 09:33:28 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239208; 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=2DHDPqwEslfbjc6qYeBYmBmaHsXIIgNVxPEi/Ni/PH4=; b=w9S7RP5I9lZ4Dr24t7FTCBeD50eNDTj3xODJOAEYmZoXVvRFez09t+1c5MA/zGMEI/ielX zbiNumR6ApWByLMe7P6MiDPP4d7Ccd3MBE5SHKJIMDj4ghI335zoczhQ/abim06vsnEl2E Mf2kC9HKgcxt1jM7a2cnwEbbS/k1+uIc0cpF0csQUwYAmWbBnH6kROBQBfdvlAgYUeBgei 9s8MMLi3mpRkvJcKJdh6f+FM3p4cew+OwD3WaIyKQP6Zh8igbXHB2AVBZzK9NRK0MLmipq k+MpvinTOKIqeLFrAZuj7YtOxWCrtHUKUlHPLoI+ninRxslG49cq6IwDZJ9Mdg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239208; a=rsa-sha256; cv=none; b=fgzlPT0+G7hsIhvp08ZN1yHEYyDEwH+Wf1w9EeztwHPwX1tCMR5Bzf27nRQheMuyxTExVD 9Q1PKi/BKeaHW6n0ic91cHdFwiOafW5tqXun8GZYXKQS2wZqdX9v0cvivvMEqxed6/DRSh Ht5PuCiDvYVIgRQYYMEM82k1VBCSjCja/jkrM0QB3zd9TrIkf32Df8+oddMqd5rxez7k4P mO3ifaJ2O6FU0NzveJX2PVumGp1q8LQ4+xts3xsvtgPblB64Wr5fCA+ePlZqaX9Zz86E6H AuyrpCy2RAIW1RefFqW6kJdfaD1QWsumlByKLpD3lBSG4n37qBMnlqdLb8SAkg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239208; 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=2DHDPqwEslfbjc6qYeBYmBmaHsXIIgNVxPEi/Ni/PH4=; b=O/4ojy7M1m0JJ59CxZxyEbX36nn4/r+cWxHw3BdO6OpVCb4sfUNCuDF/WzqmoZAI1Oe3j1 QKHjJy0dUBQwj2nKcriFtVLgt6eT9RhtW4xVA4xuCpEfzAgzUzbs425PBb7pgaj00BY13B Dhs9GtR2VSfPMBzeLXCYkaiU26tPJfMbBmsGTYv68emDv1BkHUdUlWvIg+FOeW6D/2n2Lw TAMFI4AAiwSrpUsrnw+HIEj4EMalu0lpC5+vItffHmV5xYRyZJc3K9BobTLF/1xOlv+G4P gIeUl9g0WR53FkbO3eDZNjWYsRUROrcW+PACgVtP2/SG4+/IO5sj24VdDacosw== 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 4RzbNm0NCHz16YY; Mon, 2 Oct 2023 09:33:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XRf8003225; Mon, 2 Oct 2023 09:33:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XRNh003223; Mon, 2 Oct 2023 09:33:27 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:27 GMT Message-Id: <202310020933.3929XRNh003223@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 35dd8c4e7887 - stable/14 - pf tests: extend SCTP tests to test state removal through ASCONF List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 35dd8c4e7887874f883668111e1c58d583d78f4b Auto-Submitted: auto-generated The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=35dd8c4e7887874f883668111e1c58d583d78f4b commit 35dd8c4e7887874f883668111e1c58d583d78f4b Author: Kristof Provost AuthorDate: 2023-09-05 17:00:49 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 09:32:14 +0000 pf tests: extend SCTP tests to test state removal through ASCONF pf can now mark shut down multihomed connections shutting down. Verify that pf does the right thing. MFC after: 3 weeks Sponsored by: Orange Business Services (cherry picked from commit 97340b68d18bbbdebf0f73ed900c5a33894061dd) --- tests/sys/netpfil/pf/sctp.py | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/tests/sys/netpfil/pf/sctp.py b/tests/sys/netpfil/pf/sctp.py index b24d0c414ac8..5e6dca5dd64b 100644 --- a/tests/sys/netpfil/pf/sctp.py +++ b/tests/sys/netpfil/pf/sctp.py @@ -342,6 +342,24 @@ class TestSCTP(VnetTestTemplate): assert re.search(r"all sctp 192.0.2.1:.*192.0.2.3:1234", states) assert re.search(r"all sctp 192.0.2.10:.*192.0.2.3:1234", states) + # Now remove 192.0.2.1 as an address + client.bindx("192.0.2.1", False) + + # We can still communicate + try: + client.send(b"More data", 0) + rcvd = self.wait_object(srv_vnet.pipe, 5) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] =="More data" + finally: + # Debug output + ToolsHelper.print_output("/sbin/pfctl -ss -vv") + + # Verify that state is closing + states = ToolsHelper.get_output("/sbin/pfctl -ss") + assert re.search(r"all sctp 192.0.2.1:.*192.0.2.3:1234.*SHUTDOWN", states) + class TestSCTPv6(VnetTestTemplate): REQUIRED_MODULES = ["sctp", "pf"] TOPOLOGY = { @@ -440,3 +458,21 @@ class TestSCTPv6(VnetTestTemplate): states = ToolsHelper.get_output("/sbin/pfctl -ss") assert re.search(r"all sctp 2001:db8::1\[.*2001:db8::3\[1234\]", states) assert re.search(r"all sctp 2001:db8::10\[.*2001:db8::3\[1234\]", states) + + # Now remove 2001:db8::1 as an address + client.bindx("2001:db8::1", False) + + # Wecan still communicate + try: + client.send(b"More data", 0) + rcvd = self.wait_object(srv_vnet.pipe, 5) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "More data" + finally: + # Debug output + ToolsHelper.print_output("/sbin/pfctl -ss -vv") + + # Verify that the state is closing + states = ToolsHelper.get_output("/sbin/pfctl -ss") + assert re.search(r"all sctp 2001:db8::1\[.*2001:db8::3\[1234\].*SHUTDOWN", states) From nobody Mon Oct 2 09:33:29 2023 X-Original-To: dev-commits-src-branches@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 4RzbNn3TFjz4vrKS; Mon, 2 Oct 2023 09:33: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNn2g9qz4Sdy; Mon, 2 Oct 2023 09:33:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239209; 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=GTYDly9RnXnbRTHVgm/bioyhgKUcspu1bOR7E/bBqIw=; b=topBRKYN7BxzGPj8aApYk4Xw1BdmwTYEp3nItcnNAp/Mv5M+GS2FS4b0VGS/CVr+SI5RcB 6QFwkpcuRZYK3ZQU+WnJJuVQYUQCusDWSxErAjCHu7nTV63/wTYXEnHeYhK2Azf2ggBYc/ QoPFePvyXAyj1NhZSnDZy4bjF8pjOtupwJvI9//FFpmAYsg+uBMHfJHXMks+Li4efJYOoo Gl1vG8HIATc0vpTEim3VTPfmqCT+jBpIhSmwk1Awy4oox2G8ZMujhp9CwieBtnzyQJPje0 J4eMNIz1mq0qr/NZjFfRejdQ3vNeCzOUFqlCOEI6l/x7rE0hh0S0JAUxe/83bQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239209; a=rsa-sha256; cv=none; b=owlXc4fUsGWVJncHk7iUp+0h1LxNe8WttPPnREh6n0E+Jnh08ZT4lJPZd4wlJkq0p9eDLs zgVWOeiDyf+F5KitIi8mah4nXXCNZUwQDpHaGS5U3kSrFyOID197SNGqQB4e9UxRUXAqMM LWv3lgsBp5UQirbOXN5xYAymUUgCwd+yPgvaK6+hh8inmkCX0D0bZiLoIWpYNlAefj8e79 r9H2ItnM0p4ip+jjeNoArg2UvQPMrqG7kbCCn14NprTY/Wl6eki/v4fFKg8i3VR3scc0Fa EU/CJcvgaSFav92g4LGSQW7D5wt5lBhRzTiMsdTOn549MafSk0c4hefEOzl2Xg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239209; 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=GTYDly9RnXnbRTHVgm/bioyhgKUcspu1bOR7E/bBqIw=; b=eC6TsbHAI3NA1trOMkin7l8pRcN6CIRnUXqnnPmXxFVJlhKiobeyx6e0JVP1zIA/MlXWjq xhQkpmEN4mU14duVwftb0GXTfnVHCQazvKzUd/V78KqIxBzOpjxHVsT7C+FaCn2c+ZvUh9 K3K3NvoCd5kF6h5zmCsDvVnadxi6Fl5Fd8Pr9jfpuP6eiDC0B02puYnvi4Bq9HUAYm4N6w CuPnqRjitvYuXl+5DNIznTzR/DUtpX3pASlsGZn3h8XWK4Rr6feaBlNpkt9GDsNBKRsMZ2 +kI0Lc7CC5YaTGEIfOyoehMzLwLjA4UcZ2G2s2rPd3aI6lj1N9FnUgxanLtYpw== 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 4RzbNn1T43z16Y9; Mon, 2 Oct 2023 09:33:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XT8V003337; Mon, 2 Oct 2023 09:33:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XTlq003334; Mon, 2 Oct 2023 09:33:29 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:29 GMT Message-Id: <202310020933.3929XTlq003334@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: a4f506a9a610 - stable/13 - pf tests: extend SCTP tests to test state removal through ASCONF List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: a4f506a9a61034c8bf1dae82e220a11a2c418a66 Auto-Submitted: auto-generated The branch stable/13 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=a4f506a9a61034c8bf1dae82e220a11a2c418a66 commit a4f506a9a61034c8bf1dae82e220a11a2c418a66 Author: Kristof Provost AuthorDate: 2023-09-05 17:00:49 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 08:51:44 +0000 pf tests: extend SCTP tests to test state removal through ASCONF pf can now mark shut down multihomed connections shutting down. Verify that pf does the right thing. MFC after: 3 weeks Sponsored by: Orange Business Services (cherry picked from commit 97340b68d18bbbdebf0f73ed900c5a33894061dd) --- tests/sys/netpfil/pf/sctp.py | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/tests/sys/netpfil/pf/sctp.py b/tests/sys/netpfil/pf/sctp.py index b24d0c414ac8..5e6dca5dd64b 100644 --- a/tests/sys/netpfil/pf/sctp.py +++ b/tests/sys/netpfil/pf/sctp.py @@ -342,6 +342,24 @@ class TestSCTP(VnetTestTemplate): assert re.search(r"all sctp 192.0.2.1:.*192.0.2.3:1234", states) assert re.search(r"all sctp 192.0.2.10:.*192.0.2.3:1234", states) + # Now remove 192.0.2.1 as an address + client.bindx("192.0.2.1", False) + + # We can still communicate + try: + client.send(b"More data", 0) + rcvd = self.wait_object(srv_vnet.pipe, 5) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] =="More data" + finally: + # Debug output + ToolsHelper.print_output("/sbin/pfctl -ss -vv") + + # Verify that state is closing + states = ToolsHelper.get_output("/sbin/pfctl -ss") + assert re.search(r"all sctp 192.0.2.1:.*192.0.2.3:1234.*SHUTDOWN", states) + class TestSCTPv6(VnetTestTemplate): REQUIRED_MODULES = ["sctp", "pf"] TOPOLOGY = { @@ -440,3 +458,21 @@ class TestSCTPv6(VnetTestTemplate): states = ToolsHelper.get_output("/sbin/pfctl -ss") assert re.search(r"all sctp 2001:db8::1\[.*2001:db8::3\[1234\]", states) assert re.search(r"all sctp 2001:db8::10\[.*2001:db8::3\[1234\]", states) + + # Now remove 2001:db8::1 as an address + client.bindx("2001:db8::1", False) + + # Wecan still communicate + try: + client.send(b"More data", 0) + rcvd = self.wait_object(srv_vnet.pipe, 5) + print(rcvd) + assert rcvd['ppid'] == 0 + assert rcvd['data'] == "More data" + finally: + # Debug output + ToolsHelper.print_output("/sbin/pfctl -ss -vv") + + # Verify that the state is closing + states = ToolsHelper.get_output("/sbin/pfctl -ss") + assert re.search(r"all sctp 2001:db8::1\[.*2001:db8::3\[1234\].*SHUTDOWN", states) From nobody Mon Oct 2 09:33:29 2023 X-Original-To: dev-commits-src-branches@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 4RzbNn5Nd4z4vr17; Mon, 2 Oct 2023 09:33: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNn3knRz4Snf; Mon, 2 Oct 2023 09:33:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239209; 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=PBmj+e9Vs71rCMw+1lcyLQ8SZDGYMrVAIdEDg0t3/68=; b=BbApTQI4WpwLpeIsEVuV55EkwkG+ZXNQ9D2M0rzVpwYmDPBbkZzLtfa6iBmKPWST9eIXpN RzigEUdfiu3+nN5UBwFq5wTkGX6eP+pDrZzacvtf6WQ+xvOgjWJytO6lvPy1EbgkR4E/Dx 4rtveTBdMwuzyizYhC1qdK5wzPUv3oKEAQKxhxxjdxLJNNWKBAKRgMijZcQ9+NppAbIvKd JpVlAhlgChm9QOh4ymK7X+cXr3sR1a9eZrtGEYqlWZiIShyd3tELy0/nC4myOLom7kZqvK 1R9fc8f4v/wIvkBFqkZAAl+ruhdmTPbx1bTpmQJ/a5RovY1heLUkC+nmsCZIqw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239209; a=rsa-sha256; cv=none; b=hUggAuTXMzoSD+0/huQNsC3B3Qbhi8/BRRKa6l56FJuk3MeY2O59L/ipDnSFtJ/mzx6Mcy dTLT65Z8KupqGPLTG2Hk3dSFyC+9QaONJArd4YUrXqOPniJVKM+J6SNWdM6db7y3xfVG+I 9ju3n9/+F3KPQa+BSJihBSxXwZLdDtzIJCMinjPU6UtGipa9brFkOh24NyPCk4xyM1BU39 R0oHyH5Tjbzyn32b/FxgLGdEZUc2zTDxTqrp7NehfLArYjM3F0IkXnGDzeKzD4DmACTjE7 8jZwGJT/hv3qYSUTiXjr0iOPAB5cD9EgDsKa366e9Pby/16IekmbJm8mjpGLEA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239209; 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=PBmj+e9Vs71rCMw+1lcyLQ8SZDGYMrVAIdEDg0t3/68=; b=Vauksy6Mh7qobAspwhnQNIHibZr2LfN3K655zZqnpbbflG99a2SAzFqKirL+kTLLe4L1ZD fXZidR9Aq/ijXYjqdaTLRfsbM3vXcYdBwgm6r1xhiTsw9k4f6N5DsaYXGGFLT/S4vAuLKF v4CPfOPBLO3Z0zM1fL4pxmmL85hLifdtEhxGHvrncd4WRTaWeFRTqgIENUzM9WTdEuRcQc Yrfw393i+0DGLvxnOsQiaMQ4oNpEHjgDsy/nctoq7LVwlq0aUj0a+GvmGQJyXdYin694yY JvgqzIKFgeX8gXKsFHSIcWO2dlavTPNinnfeduRqvLUl7o87SCj7zrHGcEtWew== 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 4RzbNn1yX2z15xV; Mon, 2 Oct 2023 09:33:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XTk1003336; Mon, 2 Oct 2023 09:33:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XTHP003326; Mon, 2 Oct 2023 09:33:29 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:29 GMT Message-Id: <202310020933.3929XTHP003326@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: bcad901cbfda - stable/14 - pf: ensure 'off' is always set before use List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: bcad901cbfda785298740cf6e0271b874d348503 Auto-Submitted: auto-generated The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=bcad901cbfda785298740cf6e0271b874d348503 commit bcad901cbfda785298740cf6e0271b874d348503 Author: Kristof Provost AuthorDate: 2023-09-28 07:04:32 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 09:32:14 +0000 pf: ensure 'off' is always set before use If we bail out early from pf_test(6)() we still need to clean up/finish SCTP multihome work, which requires the 'off' value to be set. Set it early enough. MFC after: 3 days Sponsored by: Orange Business Services (cherry picked from commit aefda9c92da6571d405e1b27c5c68333ad8bbc57) --- sys/netpfil/pf/pf.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 6a8ba7be56cf..9e6cd7fae492 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -7698,6 +7698,9 @@ pf_test(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, pd.af = AF_INET; pd.act.rtableid = -1; + h = mtod(m, struct ip *); + off = h->ip_hl << 2; + if (__predict_false(ip_divert_ptr != NULL) && ((ipfwtag = m_tag_locate(m, MTAG_IPFW_RULE, 0, NULL)) != NULL)) { struct ipfw_rule_ref *rr = (struct ipfw_rule_ref *)(ipfwtag+1); @@ -8249,6 +8252,9 @@ pf_test6(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb pd.af = AF_INET6; pd.act.rtableid = -1; + h = mtod(m, struct ip6_hdr *); + off = ((caddr_t)h - m->m_data) + sizeof(struct ip6_hdr); + /* We do IP header normalization and packet reassembly here */ if (pf_normalize_ip6(m0, kif, &reason, &pd) != PF_PASS) { action = PF_DROP; @@ -8256,6 +8262,7 @@ pf_test6(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb } m = *m0; /* pf_normalize messes with m0 */ h = mtod(m, struct ip6_hdr *); + off = ((caddr_t)h - m->m_data) + sizeof(struct ip6_hdr); /* * we do not support jumbogram. if we keep going, zero ip6_plen @@ -8272,7 +8279,6 @@ pf_test6(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb pd.tos = IPV6_DSCP(h); pd.tot_len = ntohs(h->ip6_plen) + sizeof(struct ip6_hdr); - off = ((caddr_t)h - m->m_data) + sizeof(struct ip6_hdr); pd.proto = h->ip6_nxt; do { switch (pd.proto) { From nobody Mon Oct 2 09:33:30 2023 X-Original-To: dev-commits-src-branches@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 4RzbNp5MLWz4vrfJ; Mon, 2 Oct 2023 09:33:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNp3zYvz4SsL; Mon, 2 Oct 2023 09:33:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239210; 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=C3GD4ZxX2R/383VXRLf0pO5gY918xFnS1A0tzZiBfGI=; b=WrvOaYLjXr6u/6UIQpD9tBQN9MetFk/zAFHlniPAz0SDaiingXXPTpxcIKAp45AajP1qVg 66YcwbtBmA2xAwqEL7K4V1VfwwiZ30DCSE8x1gcaMoe2NKkT3fK5uycsDa+8PWdjRkZIDn cB3igCmsVQUP3VH6dQgVWfhgy1nhJYygt4nWX0R6NY1VTgyFC8BhMlcQV+dOnUZYx636CF QvUWFa92J5eT7BPCHHAjmteCgueQfAUNWeEVJcfBXcxonuzd2HIOgvZhZSp59d6b5dDsSN T1+YmLzOxGiPIWxSPuAv1YXuI9CD77ELx+fE6h3FGB1UNCIitnrXAmsl66/4Nw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239210; a=rsa-sha256; cv=none; b=L2yniY/IzsR8+1miAsUBIasujCRyZ2qelwGJ8hqfzR9OV883Ck7M1qcw+Z/78af/QUB6MV xEBSDF9AO6E41ZpFRlAS6zobcuyufpOZaHNAzSkkbBxZGhuzpXbVRcr812e8Ok9V+sJ3DH 8UkZPkWRQNgs2aIh5OdsgyfbSetB7sSSQ7ZJ6clzhDfzo/3bEQPXIu6Qe08oqRf7XFoxJh 3Xov9Wy5mRwBI+Fy1LUaEuR8PCE/qDycMnzhNtf1uD6w4qt/IZEitpr7rES1JyNN2bnhp9 OvmB0TO7dTpLsPLiCtCmfij0NX97IUum6jfy0ZFyV7NFAIA4WMxW/ZWu8+kk2Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239210; 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=C3GD4ZxX2R/383VXRLf0pO5gY918xFnS1A0tzZiBfGI=; b=HD1A0IYVwrZepE9a3rHmjl2yKbiZF27HkrS81Syc2NHxpl33tPxAzech4fzW41InJgJN0C 7Mn7QeZBYR5yiGaeMm5GdLUbv79L9Uqe9SDU8CDms1wfmthj/uBInFiZxH6XEbIQ7TcElF zd1qWbbI3Afko9KV52haqTwjrpjM72aHKWqadpbklT0nLZGM32dpxAdbZisF5NYYR3A61O IzzVjn2k2jXBcCxYm7eiF3NtjkXmZc+F8YyVjRA7vGZxECRbmzmQtmRX+7eNHiKa5kmq+Y aJ6w9hICyhBo4sgV9aZfl1ik0+ywdOitPKxZm6QF2T0hFDw/x2IbD847R3NbBw== 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 4RzbNp2pCdz16CF; Mon, 2 Oct 2023 09:33:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XUOg003448; Mon, 2 Oct 2023 09:33:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XU9c003444; Mon, 2 Oct 2023 09:33:30 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:30 GMT Message-Id: <202310020933.3929XU9c003444@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 3ab984bbe014 - stable/14 - pf: only create sctp multihome states if we pass the packet List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 3ab984bbe0144f029d27a9ca0628b1f47a419688 Auto-Submitted: auto-generated The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=3ab984bbe0144f029d27a9ca0628b1f47a419688 commit 3ab984bbe0144f029d27a9ca0628b1f47a419688 Author: Kristof Provost AuthorDate: 2023-09-29 07:23:43 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 09:32:14 +0000 pf: only create sctp multihome states if we pass the packet If we've decided to drop the packet we shouldn't create additional states based off it. MFC after: 3 days Sponsored by: Orange Business Services (cherry picked from commit 480f62ccd8d998e4db9dc13c354a60f8f5e32a33) --- sys/netpfil/pf/pf.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 9e6cd7fae492..3e1c8d32add9 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -310,7 +310,7 @@ static int pf_test_state_icmp(struct pf_kstate **, struct pfi_kkif *, struct mbuf *, int, void *, struct pf_pdesc *, u_short *); static void pf_sctp_multihome_delayed(struct pf_pdesc *, int, - struct pfi_kkif *, struct pf_kstate *); + struct pfi_kkif *, struct pf_kstate *, int); static int pf_test_state_sctp(struct pf_kstate **, struct pfi_kkif *, struct mbuf *, int, void *, struct pf_pdesc *, u_short *); @@ -5921,10 +5921,10 @@ pf_test_state_sctp(struct pf_kstate **state, struct pfi_kkif *kif, static void pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, - struct pf_kstate *s) + struct pf_kstate *s, int action) { struct pf_sctp_multihome_job *j, *tmp; - int action;; + int ret __unused;; struct pf_kstate *sm = NULL; struct pf_krule *ra = NULL; struct pf_krule *r = &V_pf_default_rule; @@ -5933,11 +5933,14 @@ pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, PF_RULES_RLOCK_TRACKER; TAILQ_FOREACH_SAFE(j, &pd->sctp_multihome_jobs, next, tmp) { + if (s == NULL || action != PF_PASS) + goto free; + switch (j->op) { case SCTP_ADD_IP_ADDRESS: { j->pd.sctp_flags |= PFDESC_SCTP_ADD_IP; PF_RULES_RLOCK(); - action = pf_test_rule(&r, &sm, kif, + ret = pf_test_rule(&r, &sm, kif, j->m, off, &j->pd, &ra, &rs, NULL); PF_RULES_RUNLOCK(); SDT_PROBE4(pf, sctp, multihome, test, kif, r, j->m, action); @@ -5986,6 +5989,7 @@ pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, } } +free: free(j, M_PFTEMP); } } @@ -8154,7 +8158,7 @@ done: PF_STATE_UNLOCK(s); out: - pf_sctp_multihome_delayed(&pd, off, kif, s); + pf_sctp_multihome_delayed(&pd, off, kif, s, action); return (action); } @@ -8711,7 +8715,7 @@ done: out: SDT_PROBE4(pf, ip, test6, done, action, reason, r, s); - pf_sctp_multihome_delayed(&pd, off, kif, s); + pf_sctp_multihome_delayed(&pd, off, kif, s, action); return (action); } From nobody Mon Oct 2 09:33:30 2023 X-Original-To: dev-commits-src-branches@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 4RzbNp5MMWz4vrNJ; Mon, 2 Oct 2023 09:33:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNp3gJNz4ScJ; Mon, 2 Oct 2023 09:33:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239210; 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=S6wojtKVYg9yT4QP6OLLJPVaHnInUN9D1btF0J4fXG0=; b=r7mjATav3+vkqS5LH3WS98r6C8VAV7p5HbZBFhaFIGLkffw9NE+PmTjQwADbd0eNrhUPwa pksT0lpT/S4JQaCBBCbin23i9YL6UYks7EeOoP2FCjqLmvarPp/yjj7EkfmIku9ZCg+B6j xuRV8XkXqsNlsI8N5wATeAjX9hSI/JLMbWISj3TVb9nU00eaz0eYg643V4zSg8zBwSq/p3 72j6btqRcX08/g1gM4jDtoBmpj+SszF1yjT+9OFVH+YIAnpjHQAU5cXJ3W4WCMcMbqIZNr PIUshYiI6SntiG2Oy6LLVEYmwrCNmYat9GwWpF+E4jQMxGmgBiBNCtxRdXjNig== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239210; a=rsa-sha256; cv=none; b=k6miQubbD2WrqRZ1l/exbBjLAj8BCxGwrXTAZi+tzgtLXVI9kejSjrXc6BlMdhW5N7U2pG ywqpc+Tdle+JMr/UmQR2LDMer8Ck9hVx4VBiq/wq6il+UqXP9rNiW/y7sMffiwiQ+uzP4B qmtSo6yFOsAxAgkgsrjZXGM5y1wxrBvS/caB2iC0GhoK9oSMCxOgKwcvfC2/WVrBPyX+ib DYXH0/8oq4hpRKSmzKwqD9zP4A1XluTTVHqBVxzLE5h9zebSyhwrbXgffC2EUijlaTK3k/ O0DQwti1l0yCtY8X8u3BmMMYFDXYYI5vAJHW/Or8R8afBALpwV6tlQ7dNVR2DQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239210; 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=S6wojtKVYg9yT4QP6OLLJPVaHnInUN9D1btF0J4fXG0=; b=s/Fo+Ai3Mt1rNv6dUPadqaFHFbzsAl0jAnw5HaiV/2vQ/s/loltspU5vXBk68pAUjudHfH M5wE2eVAo305NGTkEWGiyrk7zRa7VpE34ta+1cufjbmTRfELpYlVZaT1DbEom01bvZvpRi 8mhxsTgiwnujJUsjccHbEM1zb3FscEdy2PndOX7Von9GOLhZ2qjHaopgfAqg7VrLwytJqR 9c7mb80JfaXmtGRtCmMBJcxATnuQmK/s+SWeRuU3R9jTMipCFSZBvov+4c7RtbY8z1f5Hc IxPSl9/dOpBp0ysNv3jeh4mYD8z+rbux0mn84cmFkaq3AfPeomr27eh+BddG9A== 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 4RzbNp2mznz16YB; Mon, 2 Oct 2023 09:33:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XUD4003447; Mon, 2 Oct 2023 09:33:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XUuo003439; Mon, 2 Oct 2023 09:33:30 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:30 GMT Message-Id: <202310020933.3929XUuo003439@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: cf9e678c1a84 - stable/13 - pf: ensure 'off' is always set before use List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: cf9e678c1a8460531f42997de38c5639f6247194 Auto-Submitted: auto-generated The branch stable/13 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=cf9e678c1a8460531f42997de38c5639f6247194 commit cf9e678c1a8460531f42997de38c5639f6247194 Author: Kristof Provost AuthorDate: 2023-09-28 07:04:32 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 08:51:44 +0000 pf: ensure 'off' is always set before use If we bail out early from pf_test(6)() we still need to clean up/finish SCTP multihome work, which requires the 'off' value to be set. Set it early enough. MFC after: 3 days Sponsored by: Orange Business Services (cherry picked from commit aefda9c92da6571d405e1b27c5c68333ad8bbc57) --- sys/netpfil/pf/pf.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 55942fcf4338..5f94379d58fa 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -6876,6 +6876,9 @@ pf_test(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb * PF_RULES_RLOCK(); + h = mtod(m, struct ip *); + off = h->ip_hl << 2; + if (__predict_false(ip_divert_ptr != NULL) && ((ipfwtag = m_tag_locate(m, MTAG_IPFW_RULE, 0, NULL)) != NULL)) { struct ipfw_rule_ref *rr = (struct ipfw_rule_ref *)(ipfwtag+1); @@ -7356,6 +7359,9 @@ pf_test6(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb PF_RULES_RLOCK(); + h = mtod(m, struct ip6_hdr *); + off = ((caddr_t)h - m->m_data) + sizeof(struct ip6_hdr); + /* We do IP header normalization and packet reassembly here */ if (pf_normalize_ip6(m0, dir, kif, &reason, &pd) != PF_PASS) { action = PF_DROP; @@ -7363,6 +7369,7 @@ pf_test6(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb } m = *m0; /* pf_normalize messes with m0 */ h = mtod(m, struct ip6_hdr *); + off = ((caddr_t)h - m->m_data) + sizeof(struct ip6_hdr); /* * we do not support jumbogram. if we keep going, zero ip6_plen @@ -7386,7 +7393,6 @@ pf_test6(int dir, int pflags, struct ifnet *ifp, struct mbuf **m0, struct inpcb pd.tos = IPV6_DSCP(h); pd.tot_len = ntohs(h->ip6_plen) + sizeof(struct ip6_hdr); - off = ((caddr_t)h - m->m_data) + sizeof(struct ip6_hdr); pd.proto = h->ip6_nxt; do { switch (pd.proto) { From nobody Mon Oct 2 09:33:31 2023 X-Original-To: dev-commits-src-branches@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 4RzbNq6LYnz4vrHB; Mon, 2 Oct 2023 09:33: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzbNq5bKBz4SlB; Mon, 2 Oct 2023 09:33:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239211; 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=8Xhe6IA1r7VJwg0lyiP3xKA2kL48V48tw2LpdcvmXCE=; b=ot6/CTYCxFRHemDh8QJx8RKUTtP0bqlLvOTYCcR9Wglu0BIlH7nTGQVOyHWnqlxo87k9h6 M10QAtxZExCHEo20/S0hZsPlSWCnxLthrjNyjUGhhkVocsWQ1rkA1GTfMVRFShB63YXdbz kuSZZrZ6DTBlqUn1Z3h5/uc4lIVBrzo5UZ/sAv3k6JUFyEGwmLtT6kVjPIErKr5qnYVVH2 Ghggl0Tx02G/0Qq6PYdiwK+IGzd8kAk7as0G5OLeLqNRAvbA52R4aImzR9aFbI+lcJWFoJ 68q7fsH2c1QNzUrGuReBsvgTvXwpKjpqk/41mRODJ1Rj0aKMTYvywgkW1qqjOQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696239211; a=rsa-sha256; cv=none; b=CrQyuVNVcu1S+xP9UrJ1qw4YIJ/MyQZuaW2dfWoZVW1KzVGuLv3UcDPfOrC5B4S4+8++BJ 4PV7v/e/ReRTt6W8NjjB5gnU7yVIpJRTVsb79tvEdOpGY07fVR7ONhpzlysl73DfU+Zjp1 Sa/1zIXYAkWDrB5vicRrt9ZYvCVpy0aIbwZqOIQVUtmqtGV7QhCesBDUJkBOnURLY04y0R oI1QkONPvaPRtknUNI5APkPiNRqA0zj1sFrQU6XXDCoQCsa5DaEhQrAX0mFIPHqnv6Vq0D 5adMTk5A86x551m2Q/lljPRIHkFvwl1uK1kGAm0aX5bI5m8ZDDVXTbmtogX87w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696239211; 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=8Xhe6IA1r7VJwg0lyiP3xKA2kL48V48tw2LpdcvmXCE=; b=cl8sPcEQtQ/BHNPFZTtFPspuMUGBZVXeB31nkp3yXe/Gy39M1DnxCnLxd9nrdF3XJSp8H1 Hmf2Z7RjG323+tslA44dNkH1JfI2zAmnSlwbM8Unmn43jRkS/vd1gDADuWpH0UCEsxcYI9 7YT/bVkhpQ64wc1P6NPqgVBx8S6r20PXuUj6+bVxuTaLzC8ODWTlpho/Yjr6gwWr7BjgEX qOS8jIL72qB2RwgT6BLQOid4IHkylSO6wdTiK3vtevcTnzsDNpe8Z81evpuv4h53Xb6ZX0 lwY+I/dS7NLdVcoZOSDAjlPtPfUpM4fh5WNkGGrSDU2bir8jxoud9rJoRsNTYQ== 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 4RzbNq3tmjz16LT; Mon, 2 Oct 2023 09:33:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3929XV12003559; Mon, 2 Oct 2023 09:33:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3929XVXX003540; Mon, 2 Oct 2023 09:33:31 GMT (envelope-from git) Date: Mon, 2 Oct 2023 09:33:31 GMT Message-Id: <202310020933.3929XVXX003540@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 0ca691ad1612 - stable/13 - pf: only create sctp multihome states if we pass the packet List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: 0ca691ad161253a123d9dac9e65953fe382920a5 Auto-Submitted: auto-generated The branch stable/13 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=0ca691ad161253a123d9dac9e65953fe382920a5 commit 0ca691ad161253a123d9dac9e65953fe382920a5 Author: Kristof Provost AuthorDate: 2023-09-29 07:23:43 +0000 Commit: Kristof Provost CommitDate: 2023-10-02 08:51:44 +0000 pf: only create sctp multihome states if we pass the packet If we've decided to drop the packet we shouldn't create additional states based off it. MFC after: 3 days Sponsored by: Orange Business Services (cherry picked from commit 480f62ccd8d998e4db9dc13c354a60f8f5e32a33) --- sys/netpfil/pf/pf.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 5f94379d58fa..501d9eef57cd 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -291,7 +291,7 @@ static int pf_test_state_icmp(struct pf_kstate **, int, struct pfi_kkif *, struct mbuf *, int, void *, struct pf_pdesc *, u_short *); static void pf_sctp_multihome_delayed(struct pf_pdesc *, int, - struct pfi_kkif *, struct pf_kstate *); + struct pfi_kkif *, struct pf_kstate *, int); static int pf_test_state_sctp(struct pf_kstate **, struct pfi_kkif *, struct mbuf *, int, void *, struct pf_pdesc *, u_short *); @@ -5343,10 +5343,10 @@ pf_test_state_sctp(struct pf_kstate **state, struct pfi_kkif *kif, static void pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, - struct pf_kstate *s) + struct pf_kstate *s, int action) { struct pf_sctp_multihome_job *j, *tmp; - int action;; + int ret __unused;; struct pf_kstate *sm = NULL; struct pf_krule *ra = NULL; struct pf_krule *r = &V_pf_default_rule; @@ -5355,11 +5355,14 @@ pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, PF_RULES_RLOCK_TRACKER; TAILQ_FOREACH_SAFE(j, &pd->sctp_multihome_jobs, next, tmp) { + if (s == NULL || action != PF_PASS) + goto free; + switch (j->op) { case SCTP_ADD_IP_ADDRESS: { j->pd.sctp_flags |= PFDESC_SCTP_ADD_IP; PF_RULES_RLOCK(); - action = pf_test_rule(&r, &sm, pd->dir, kif, + ret = pf_test_rule(&r, &sm, pd->dir, kif, j->m, off, &j->pd, &ra, &rs, NULL); PF_RULES_RUNLOCK(); SDT_PROBE4(pf, sctp, multihome, test, kif, r, j->m, action); @@ -5408,6 +5411,7 @@ pf_sctp_multihome_delayed(struct pf_pdesc *pd, int off, struct pfi_kkif *kif, } } +free: free(j, M_PFTEMP); } } @@ -7310,7 +7314,7 @@ done: PF_STATE_UNLOCK(s); out: - pf_sctp_multihome_delayed(&pd, off, kif, s); + pf_sctp_multihome_delayed(&pd, off, kif, s, action); return (action); } @@ -7803,7 +7807,7 @@ done: out: SDT_PROBE4(pf, ip, test6, done, action, reason, r, s); - pf_sctp_multihome_delayed(&pd, off, kif, s); + pf_sctp_multihome_delayed(&pd, off, kif, s, action); return (action); } From nobody Mon Oct 2 12:56:02 2023 X-Original-To: dev-commits-src-branches@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 4RzgtW0stVz4w3NR; Mon, 2 Oct 2023 12:56: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzgtV6Lymz3RkV; Mon, 2 Oct 2023 12:56:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696251362; 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=I1rFiiXzi/E82UKLNQT2TY/UmFpkqy2FrY+oeFMFAjk=; b=v7FNKAgjA8+fJnErz1QbJC+RWFQlTB7fP/9W+7LLvNrqBXMeIBzvlmbzUKZxGf49aglLON FssxzQU1s5Bz1F2aCVVGTYq7zeBs1cGnf5wy0hKAdEhKb/agy3ONExHY6cibMXnzpKRb3b t/4tC5xVxuzdhsFBiNIbJATIF5XLJj4Q147oEF127sfl7/tTwzuPPltpwaoLyeOFiLAiIz 22vmEjdknLI0gwW5LtywOkFhs5VNIR8BWi8WpBqklivIJGArkzGbIM+2DLPSWOrd5eU9RD DUSRvweIgEmndRjIFO/vVQ+LTZ8ieELlsuDBL2Rg/G+/O9kW/spXWmnmF/Udsw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696251362; a=rsa-sha256; cv=none; b=yNfzTPrQZxbGelf34tYOf2s42NoEM9wqE9mJILg284VZG5XgrI8oBI4xKloZnSyZcvbHar b204lsxKLszSOmQH3tmOqD0DrLr9Qf0kOFdIkedC6b2gkTRrvkxJd8KhNAgBWow6/32qww nP9h3SUPNffQsQvfR56N86F3l7p5vvE9wr22sv2FrNhsH1sZMeZ13nXmbVk7qXs83eff1S NiFiuc91CQRCouZ3cWDDvnueOegQzYZHwhO4OBFE3rOZHFukT/iH+QXhsKss7NNoKB4qH9 PxUMkLQHUBPHSAPW1tNIlS+CUd0dc70r17zrbLaZSMHa6fG0P+wHGajtHakrTg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696251362; 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=I1rFiiXzi/E82UKLNQT2TY/UmFpkqy2FrY+oeFMFAjk=; b=Dw5XvSBam/pYUMgFcAsoRUlxDa2wELAyHJufSEezvHSxdlHCVyyk2dsyFtO1TKXkHUfiSO LL8GYlMsfKHdehluKU9fLQYwZsPPjPU0O99Y0FD6dcinGoD6fIB8jnbjOQGF05Y4udblqp Ixjhz+S7MTo7kXhQBUpSwP220z9GFuN4YYYMJ1KVo8pRWf3Fg8feAlo5MGBxQNt0BPcpjm oqUH2XbsqK9VriNoBv+ezf00ZjpJEm8squ8tOI2eAUlWVwziK9O3f07kXp6+kzAs7saiEQ O1ySvsJpvNv5TLLI6Md/0vXqQ5aejTL8g2p4vVJ1G0Hi2qt4K9+ZltcaJV2wuQ== 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 4RzgtV5Rx7z1CK6; Mon, 2 Oct 2023 12:56:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 392Cu2sg035983; Mon, 2 Oct 2023 12:56:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 392Cu2Zu035980; Mon, 2 Oct 2023 12:56:02 GMT (envelope-from git) Date: Mon, 2 Oct 2023 12:56:02 GMT Message-Id: <202310021256.392Cu2Zu035980@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: ca79521be1b8 - stable/14 - amd64: Add a leaf PTP when pmap_enter(psind=1) creates a wired mapping List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: ca79521be1b87b82381e091e36123471ca5648cc Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=ca79521be1b87b82381e091e36123471ca5648cc commit ca79521be1b87b82381e091e36123471ca5648cc Author: Bojan Novković AuthorDate: 2023-09-15 10:41:10 +0000 Commit: Mark Johnston CommitDate: 2023-10-02 12:55:49 +0000 amd64: Add a leaf PTP when pmap_enter(psind=1) creates a wired mapping This patch reverts the changes made in D19670 and fixes the original issue by allocating and prepopulating a leaf page table page for wired userspace 2M pages. The original issue is an edge case that creates an unmapped, wired region in userspace. Subsequent faults on this region can trigger wired superpage creation, which leads to a panic in pmap_demote_pde_locked() as the pmap does not create a leaf page table page for the wired superpage. D19670 fixed this by disallowing preemptive creation of wired superpage mappings, but that fix is currently interfering with an ongoing effort of speeding up vm_map_wire for large, contiguous entries (e.g. bhyve wiring guest memory). Reviewed by: alc, markj Sponsored by: Google, Inc. (GSoC 2023) MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D41132 (cherry picked from commit aa3bcaad51076ceb346fa0c64ab69a35e5241b20) --- sys/amd64/amd64/pmap.c | 27 +++++++++++++++++++++++++-- 1 file changed, 25 insertions(+), 2 deletions(-) diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c index b10997fd657b..ff83d8749313 100644 --- a/sys/amd64/amd64/pmap.c +++ b/sys/amd64/amd64/pmap.c @@ -7493,9 +7493,8 @@ pmap_enter_pde(pmap_t pmap, vm_offset_t va, pd_entry_t newpde, u_int flags, pd_entry_t oldpde, *pde; pt_entry_t PG_G, PG_RW, PG_V; vm_page_t mt, pdpg; + vm_page_t uwptpg; - KASSERT(pmap == kernel_pmap || (newpde & PG_W) == 0, - ("pmap_enter_pde: cannot create wired user mapping")); PG_G = pmap_global_bit(pmap); PG_RW = pmap_rw_bit(pmap); KASSERT((newpde & (pmap_modified_bit(pmap) | PG_RW)) != PG_RW, @@ -7592,6 +7591,22 @@ pmap_enter_pde(pmap_t pmap, vm_offset_t va, pd_entry_t newpde, u_int flags, } } + /* + * Allocate leaf ptpage for wired userspace pages. + */ + uwptpg = NULL; + if ((newpde & PG_W) != 0 && pmap != kernel_pmap) { + uwptpg = pmap_alloc_pt_page(pmap, pmap_pde_pindex(va), + VM_ALLOC_WIRED); + if (uwptpg == NULL) + return (KERN_RESOURCE_SHORTAGE); + if (pmap_insert_pt_page(pmap, uwptpg, true, false)) { + pmap_free_pt_page(pmap, uwptpg, false); + return (KERN_RESOURCE_SHORTAGE); + } + + uwptpg->ref_count = NPTEPG; + } if ((newpde & PG_MANAGED) != 0) { /* * Abort this mapping if its PV entry could not be created. @@ -7599,6 +7614,14 @@ pmap_enter_pde(pmap_t pmap, vm_offset_t va, pd_entry_t newpde, u_int flags, if (!pmap_pv_insert_pde(pmap, va, newpde, flags, lockp)) { if (pdpg != NULL) pmap_abort_ptp(pmap, va, pdpg); + if (uwptpg != NULL) { + mt = pmap_remove_pt_page(pmap, va); + KASSERT(mt == uwptpg, + ("removed pt page %p, expected %p", mt, + uwptpg)); + uwptpg->ref_count = 1; + pmap_free_pt_page(pmap, uwptpg, false); + } CTR2(KTR_PMAP, "pmap_enter_pde: failure for va %#lx" " in pmap %p", va, pmap); return (KERN_RESOURCE_SHORTAGE); From nobody Mon Oct 2 12:56:03 2023 X-Original-To: dev-commits-src-branches@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 4RzgtX0wmnz4w3W9; Mon, 2 Oct 2023 12:56: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzgtX0H6Xz3Rh9; Mon, 2 Oct 2023 12:56:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696251364; 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=zktQO9aKE1jUtHA5ajl/JWUN5GWPWiR5Ux284IWEGWI=; b=HfKXmjdCfsb3ZAgSLwuW9Wx0ZVIsJGrQBVSX/Sjdq8wZ5kFJqVY1QpGMYfGaZ3usHspPq7 j97bMHEnb4lhx6QonpcJ1DmzRFPSg+cFn8fVrh5MM9a7mBntmyjU4oNu6TOtK8CGyxDNR0 f7Y/y9nsn6YGjJMouNu/cbF/gx8Q9y4ywy1PDNTrD2mSoW+boQ/HvTm/qOQFf14r/x3kLF JPZikuTjj9kTD7lbkhBfQMbw71QRknxRENP9EXrdmCMgQvgWgr9CWiWZF0m0zmMOE4ShC3 brEFAwurEaQB+fILXp+aQELUxy6gS8Etye9yBBi3/WnUiDVsbiQZQ/lZJedslQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696251364; a=rsa-sha256; cv=none; b=LCTqOfzSJP83ty0oGfgd5mJxS+T2gHmXZt8vdIUxhPzj4RgBvG8e2+e9R3eWn5Z4WfqDtq JgR50H3pzJ+388wp695VqF2K7kFtx66W/8zYhE3ZITLlDIrPdVnsPWImH6U4HOMK9Jdtfl DAXAMkcCdxyKNkK41XdilQ5T71s2QRQh7Uxk94tt3nuKpJ5s/4GkJhTEjbk11MNn820IsB kinTeetiENyTTMZcGHZHAzEz7au1r3Ja4hG87RPh8rrEAkBPHUuU8w5rDuhjecmJ/FnWxU o2ql9R/e/C4jwdKTr/BUDDyMwbB5CU1f5jivcvuXEO6/M0YY19dUJTK6lYXFKQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696251364; 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=zktQO9aKE1jUtHA5ajl/JWUN5GWPWiR5Ux284IWEGWI=; b=n6mmyv17AWxMcuD0sT9SNp3xU6BMfeCRZo7two0PadkTHHhUIcy8pH+534Jsc1fgWjBLwR 5ZfHIfhU2+vfRkEt2LQ11DyBh1ouO/8K5QyUTp8FLD9bOjZk2nMF6aiM4Xg8fmt7hHrk1C sP26EecyZkfFDipYqPtyJ3imfyRD58Z0VZd751g8fmaoxy22Nim79cjO8rDgXVPvxlIjWI 6mucdPKVY6Gp0h6oFRyMhlA4tVX6hBgDzlyEVpGHaGxCqqvhIxf7NPpWQk/6+O88ZKxOm8 fAh2CJzYqTfCo51BFXesGj7X62EL3wEVn5KEe+mTB+YlMgsolQheI6ULJWgp0Q== 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 4RzgtW6FRYz1Bqd; Mon, 2 Oct 2023 12:56:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 392Cu3Je036028; Mon, 2 Oct 2023 12:56:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 392Cu3rH036025; Mon, 2 Oct 2023 12:56:03 GMT (envelope-from git) Date: Mon, 2 Oct 2023 12:56:03 GMT Message-Id: <202310021256.392Cu3rH036025@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 98504b647138 - stable/14 - mlock tests: Add a regression test List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 98504b647138897f9c171b6e6d348c4f7bdb3a0d Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=98504b647138897f9c171b6e6d348c4f7bdb3a0d commit 98504b647138897f9c171b6e6d348c4f7bdb3a0d Author: Mark Johnston AuthorDate: 2023-09-15 16:28:42 +0000 Commit: Mark Johnston CommitDate: 2023-10-02 12:55:49 +0000 mlock tests: Add a regression test The test tries to trigger creation of a superpage mapping in an mlock()ed region. MFC after: 2 weeks (cherry picked from commit 8f26ed01bd74aab21309ac04ae1d1368a6346c90) --- tests/sys/vm/mlock_test.c | 114 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 114 insertions(+) diff --git a/tests/sys/vm/mlock_test.c b/tests/sys/vm/mlock_test.c index f0c76fe86b56..8c8ce4a2e8de 100644 --- a/tests/sys/vm/mlock_test.c +++ b/tests/sys/vm/mlock_test.c @@ -28,11 +28,15 @@ #include #include #include +#include #include #include +#include #include +#include #include +#include #include #include @@ -161,12 +165,122 @@ ATF_TC_BODY(mlock__truncate_and_unlock, tc) ATF_REQUIRE(munlock(addr, len) == 0); } +/* + * Exercise a corner case involving an interaction between mlock() and superpage + * creation: a truncation of the object backing a mapping results in the + * truncated region being unmapped by the pmap, but does not affect the logical + * mapping. In particular, the truncated region remains mlock()ed. If the + * mapping is later extended, a page fault in the formerly truncated region can + * result in superpage creation via a call to pmap_enter(psind = 1). + */ +ATF_TC(mlock__superpage_fault); +ATF_TC_HEAD(mlock__superpage_fault, tc) +{ + atf_tc_set_md_var(tc, "require.user", "root"); +} +ATF_TC_BODY(mlock__superpage_fault, tc) +{ + struct rlimit rlim; + void *addr1, *addr2; + size_t len, pagesizes[MAXPAGESIZES]; + int count, error, shmfd; + char vec; + + count = getpagesizes(pagesizes, MAXPAGESIZES); + ATF_REQUIRE_MSG(count >= 1, + "failed to get page sizes: %s", strerror(errno)); + if (count == 1) + atf_tc_skip("system does not support multiple page sizes"); + len = pagesizes[1]; + + error = getrlimit(RLIMIT_MEMLOCK, &rlim); + ATF_REQUIRE_MSG(error == 0, "getrlimit: %s", strerror(errno)); + rlim.rlim_cur += len; + rlim.rlim_max += len; + error = setrlimit(RLIMIT_MEMLOCK, &rlim); + ATF_REQUIRE_MSG(error == 0, "setrlimit: %s", strerror(errno)); + + shmfd = shm_open(SHM_ANON, O_RDWR | O_CREAT, 0600); + ATF_REQUIRE_MSG(shmfd >= 0, "shm_open: %s", strerror(errno)); + error = ftruncate(shmfd, len); + ATF_REQUIRE_MSG(error == 0, "ftruncate: %s", strerror(errno)); + + addr1 = mmap(NULL, len, PROT_READ | PROT_WRITE, + MAP_SHARED | MAP_ALIGNED_SUPER, shmfd, 0); + ATF_REQUIRE_MSG(addr1 != MAP_FAILED, "mmap: %s", strerror(errno)); + ATF_REQUIRE_MSG(((uintptr_t)addr1 & (len - 1)) == 0, + "addr %p is misaligned", addr1); + addr2 = mmap(NULL, len, PROT_READ, + MAP_SHARED | MAP_ALIGNED_SUPER, shmfd, 0); + ATF_REQUIRE_MSG(addr2 != MAP_FAILED, "mmap: %s", strerror(errno)); + ATF_REQUIRE_MSG(((uintptr_t)addr2 & (len - 1)) == 0, + "addr %p is misaligned", addr2); + + memset(addr1, 0x42, len); + error = mincore(addr1, pagesizes[0], &vec); + ATF_REQUIRE_MSG(error == 0, "mincore: %s", strerror(errno)); + if ((vec & MINCORE_SUPER) == 0) + atf_tc_skip("initial superpage promotion failed"); + + error = mlock(addr2, len); + ATF_REQUIRE_MSG(error == 0, "mlock: %s", strerror(errno)); + error = mincore(addr2, pagesizes[0], &vec); + ATF_REQUIRE_MSG(error == 0, "mincore: %s", strerror(errno)); + ATF_REQUIRE((vec & MINCORE_SUPER) != 0); + + /* + * Free a page back to the superpage reservation, demoting both + * mappings. + */ + error = ftruncate(shmfd, len - pagesizes[0]); + ATF_REQUIRE_MSG(error == 0, "ftruncate: %s", strerror(errno)); + + /* + * Extend the mapping back to its original size. + */ + error = ftruncate(shmfd, len); + ATF_REQUIRE_MSG(error == 0, "ftruncate: %s", strerror(errno)); + + /* + * Trigger re-promotion. + */ + error = mincore(addr1, pagesizes[0], &vec); + ATF_REQUIRE_MSG(error == 0, "mincore: %s", strerror(errno)); + ATF_REQUIRE((vec & MINCORE_SUPER) == 0); + memset((char *)addr1 + len - pagesizes[0], 0x43, pagesizes[0]); + error = mincore(addr1, pagesizes[0], &vec); + ATF_REQUIRE_MSG(error == 0, "mincore: %s", strerror(errno)); + ATF_REQUIRE((vec & MINCORE_SUPER) != 0); + + /* + * Trigger a read fault, which should install a superpage mapping + * without promotion. + */ + error = mincore(addr2, pagesizes[0], &vec); + ATF_REQUIRE_MSG(error == 0, "mincore: %s", strerror(errno)); + ATF_REQUIRE((vec & MINCORE_SUPER) == 0); + (void)atomic_load( + (_Atomic int *)(void *)((char *)addr2 + len - pagesizes[0])); + error = mincore(addr2, pagesizes[0], &vec); + ATF_REQUIRE_MSG(error == 0, "mincore: %s", strerror(errno)); + ATF_REQUIRE((vec & MINCORE_SUPER) != 0); + + /* + * Trigger demotion of the wired mapping. + */ + error = munlock(addr2, pagesizes[0]); + ATF_REQUIRE_MSG(error == 0, "munlock: %s", strerror(errno)); + + ATF_REQUIRE(close(shmfd) == 0); +} + ATF_TP_ADD_TCS(tp) { ATF_TP_ADD_TC(tp, mlock__copy_on_write_anon); ATF_TP_ADD_TC(tp, mlock__copy_on_write_vnode); ATF_TP_ADD_TC(tp, mlock__truncate_and_resize); ATF_TP_ADD_TC(tp, mlock__truncate_and_unlock); + ATF_TP_ADD_TC(tp, mlock__superpage_fault); return (atf_no_error()); } From nobody Mon Oct 2 14:32:06 2023 X-Original-To: dev-commits-src-branches@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 4Rzk1X1cZSz4w87L; Mon, 2 Oct 2023 14:32:16 +0000 (UTC) (envelope-from zlei@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Rzk1X1C15z3dV0; Mon, 2 Oct 2023 14:32:16 +0000 (UTC) (envelope-from zlei@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696257136; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=cWD9FljEZyM2hTfh534tZIMs2asjawHFVPq62pmT5kk=; b=pZynMQlRAp/IyxTWcPeeBB9/XbIMugsGVniaDqqnmo7ueMBp6Aj+HPw0V3JEZOCQbsurB3 haqBJ0XjBWFQAaHyD4APKLuk6mMRBpMc38Hga5m2vJTEScn/UwJsnYRl7WojlzVOVopqRi Ly0FuBinE9BrPva1WRHTq+5GDewdkmwREj9hcxvP+n6/DNTvvgDMzBYU+1wVyJqzCoC12U Bun8N2okUvlKMkIzUx0s6qzoY4UEzZ6nDXWknHPdQt95gtaIjHRoHnJIVZlptQZkgOXaFG Kbj+UwmiJob0g1e0DKRpIthYA3bMWz4GrXehGPBSzXi5Xv9lTW66sqtT86r7eQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696257136; a=rsa-sha256; cv=none; b=aTWxPGJ6NBE62o+0XsOgRRARBzhevxLUNrYLY20PxZVQML9c9OTCqbOo7WEIQ5duV/5BzF ArbM9zz8Ov3C9llwPoHVjsnIS1L30rZU0cZz6r0c+DqdwKbQEi3Ok2tjPY49NXjgjjS/on H5BMtJNhJMjXnbqItsPwzDxmcjURJZeS8/95JAw8K1FOZrqWu0U5NlDzDVgwim64/RuAU9 OxNWb7Dzo0b6OCzOkj3qfovZoylESZCotX7BVRpuiP8kWPYessgorBzY35Yd63m/QJI26M D2ZVoPy9dopr4iu6jjWYRCYIHVQfvWLgUrV1agS7D/zigvG4xmheDo6msRO5yw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696257136; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=cWD9FljEZyM2hTfh534tZIMs2asjawHFVPq62pmT5kk=; b=iUCKjuv17gIXKG0KLfy5hFlMn9Nu3kAfDm7DVPO6QK6lpse7iLHSNe/QJjM3n+OdgOyURF A1mhp4yUsbFPNzDuRR9De1DLxwvv3Pn5pn5tWS0SSZEpK8G8isu/1ToIFMtfviAc3ZIOi6 k9gWwwDnybNdIXgTtUuG/jsMG/s9+wLI7lOCE1irfYVJZgOKTATBM/QWYbT5ijy3jMR9b2 ot8U+GIkbsEOIafz9BLM5QFG0vNbO8ZRWm9rzRGNzhocblHnmR6e+u2obY5dund3OEqpgo CnVwM+VKyrttJrPVYsc72j1YcAA73yuUAzfZUD6nfCAG3aA9M/qHetHl66HLFg== Received: from smtpclient.apple (ns1.oxydns.net [45.32.91.63]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) (Authenticated sender: zlei/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4Rzk1V3kGYzqh; Mon, 2 Oct 2023 14:32:14 +0000 (UTC) (envelope-from zlei@FreeBSD.org) Content-Type: text/plain; charset=utf-8 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3696.120.41.1.4\)) Subject: Re: git: a9359dcde241 - stable/14 - ipfilter: Add sysctl flag CTLFLAG_TUN to loader tunable From: Zhenlei Huang In-Reply-To: <20231002025315.41C99A7C@slippy.cwsent.com> Date: Mon, 2 Oct 2023 22:32:06 +0800 Cc: "src-committers@freebsd.org" , "dev-commits-src-all@freebsd.org" , "dev-commits-src-branches@freebsd.org" Content-Transfer-Encoding: quoted-printable Message-Id: References: <202310020050.3920omhH029460@gitrepo.freebsd.org> <20231002025315.41C99A7C@slippy.cwsent.com> To: Cy Schubert X-Mailer: Apple Mail (2.3696.120.41.1.4) > On Oct 2, 2023, at 10:53 AM, Cy Schubert = wrote: >=20 > In message <202310020050.3920omhH029460@gitrepo.freebsd.org>, Zhenlei = Huang=20 > wri > tes: >> The branch stable/14 has been updated by zlei: >>=20 >> URL: = https://cgit.FreeBSD.org/src/commit/?id=3Da9359dcde241f17421a71bc8c96dee08= >> 625db9dd >>=20 >> commit a9359dcde241f17421a71bc8c96dee08625db9dd >> Author: Zhenlei Huang >> AuthorDate: 2023-09-29 00:01:43 +0000 >> Commit: Zhenlei Huang >> CommitDate: 2023-10-02 00:49:38 +0000 >>=20 >> ipfilter: Add sysctl flag CTLFLAG_TUN to loader tunable >>=20 >> The sysctl variable `net.inet.ipf.large_nat` is actually a loader >> tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` = will >> report it correctly. >>=20 >> No functional change intended. >>=20 >> Reviewed by: cy (for #network) >> Fixes: a805ffbcbce8 ipfilter: Make LARGE_NAT a tunable >> MFC after: 3 days >> Differential Revision: https://reviews.freebsd.org/D42005 >>=20 >> (cherry picked from commit = ba883e7a5ac43b27a373f2b1b0044fd2eb769d4e) >> --- >> sys/netpfil/ipfilter/netinet/mlfk_ipl.c | 2 +- >> 1 file changed, 1 insertion(+), 1 deletion(-) >>=20 >> diff --git a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c = b/sys/netpfil/ipfilter/n >> etinet/mlfk_ipl.c >> index 35daad4715bf..69be4abb2485 100644 >> --- a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c >> +++ b/sys/netpfil/ipfilter/netinet/mlfk_ipl.c >> @@ -134,7 +134,7 @@ SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_running, = CTLFLAG_R >> D, >> &VNET_NAME(ipfmain.ipf_running), 0, "IPF is running"); >> SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_chksrc, CTLFLAG_RW, = &VNET_NAME(ipfmai >> n.ipf_chksrc), 0, ""); >> SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_minttl, CTLFLAG_RW, = &VNET_NAME(ipfmai >> n.ipf_minttl), 0, ""); >> -SYSCTL_IPF(_net_inet_ipf, OID_AUTO, large_nat, CTLFLAG_RD, = &VNET_NAME(ipfmai >> n.ipf_large_nat), 0, "large_nat"); >> +SYSCTL_IPF(_net_inet_ipf, OID_AUTO, large_nat, CTLFLAG_RDTUN | = CTLFLAG_NOFET >> CH, &VNET_NAME(ipfmain.ipf_large_nat), 0, "large_nat"); >>=20 >> #define CDEV_MAJOR 79 >> #include >>=20 >=20 > Can you also please MFC to stable/13 and 12? Done! Well, I just have a ( long ) break after MFCing to stable/14 ;) >=20 >=20 > --=20 > Cheers, > Cy Schubert > FreeBSD UNIX: Web: https://FreeBSD.org > NTP: Web: https://nwtime.org >=20 > e^(i*pi)+1=3D0 >=20 >=20 >=20 > X-B=C2=9D=C4=B6=17 From nobody Mon Oct 2 16:02:34 2023 X-Original-To: dev-commits-src-branches@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 4Rzm1k3Lsjz4wDNF; Mon, 2 Oct 2023 16:02: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Rzm1k2tfTz4JDq; Mon, 2 Oct 2023 16:02:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696262554; 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=ByPDq3R3koidvE6i+l6FqlX6aNRx4UAHlebq9R3DWqA=; b=T+2mG9ERme1GGsUzHGXF/Btks88E1jUJBVmfDKXuKyMhKzYWPYhjhbc+zPuCjW3cR2Eh0a oERRI7JyKCXkHtAwiBiV16hFHoVoxjIwfAAgum+O9fcKn4zZ7NKbfaHmdIyDK6HL5Jd7EL 3+rBPT0nBJd/4LEBNBfmzrK9a8zC8Xa8FkyYoMfQsdzQJhNQadn2lpQNpsFVcRoYznwIHI +xOBt2w02r2svlz6YxJDSQ8/efW3gjrlr2Df5I+kYgRy5Ya3CQiM9I88HvorVkhXoY21hm Aq8FeJ6an4fTboWr4F0gKxcsFumEZIe/L8NaQOfFjO//kZbvSgjl2Sx98ncPwA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696262554; a=rsa-sha256; cv=none; b=TqWlH3g/anaieOJK3RbuceB1fsS9FUYSL/ig0xHz/KnB0BJQFpL86dCz7NUwuxHloKtiH1 CCZ2a7euIzKQwTTvVYL9NKFtwY3h45BP9NYnovHjk5uh/gZYUgUcoaBWWFuNpL+OkBwEvF oFXR9mBfCqfXl3QriF5HcSxKDhpf78pn7LAzNvzvxTQTb3lja41uSKnxdQKLG5qWqkIeNl IY0mKp8iCFa/b1UEihHMQjcgLaGUi1YO4E7dY1HIQgYHkn/ircYJUndIi0QvrusBFQtbwj Lct4eWc0irjCaBhBGmOSZ/BMcOq0RwcaYjJ5rvGe0HCjI5VJWUlK0y3hEL2Zxw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696262554; 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=ByPDq3R3koidvE6i+l6FqlX6aNRx4UAHlebq9R3DWqA=; b=mh5lDnS7KFJbD0vGADhh7tx6pSfnxINZgy35g8xt+EsoE26swY2qHm8kH7zYyug0+d8BGj 4s93iBpXtDXeWk6RykyP5FqFTFc9llqF4mfnB2ALSjk3HWQCsBC1p1pBX9z0jm680iU0Nz mYZFtasG5txEhIKxjVKOoaKCA10ZxufBr8DrgoGj6lEM8l+NZlR7xUP8f80JNEh0Q/yRFw VnbnhwiM2/A7hWMgJrKiRHP048XL2hMLlWxSQcgbjwdXc/UwCBAolHQhFHZmQdJwBno/qx 7udqIme9aG0VdfUA+QMA0Sc+BFADJiVRPzs659b41JdjVJ1DC99bjJ4thO08xw== 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 4Rzm1k1z0Jz45Y; Mon, 2 Oct 2023 16:02:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 392G2Ype052399; Mon, 2 Oct 2023 16:02:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 392G2YTT052396; Mon, 2 Oct 2023 16:02:34 GMT (envelope-from git) Date: Mon, 2 Oct 2023 16:02:34 GMT Message-Id: <202310021602.392G2YTT052396@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: 3f0ce63828dc - stable/13 - copy_file_range: require CAP_SEEK capability List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: 3f0ce63828dc3d4030b32ad0effb4e588af49c03 Auto-Submitted: auto-generated The branch stable/13 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=3f0ce63828dc3d4030b32ad0effb4e588af49c03 commit 3f0ce63828dc3d4030b32ad0effb4e588af49c03 Author: Mariusz Zaborski AuthorDate: 2023-09-28 13:24:39 +0000 Commit: Ed Maste CommitDate: 2023-10-02 16:00:27 +0000 copy_file_range: require CAP_SEEK capability When using copy_file_range(2) with an offset parameter, the CAP_SEEK capability should be required. This requirement is similar to the behavior observed with pread(2)/pwrite(2). Reported by: theraven Reviewed by: emaste, theraven, kib, markj Approved by: secteam Differential Revision: https://reviews.freebsd.org/D41967 (cherry picked from commit 15a51d3abaef27ddea66320cac7caa549738a1a6) --- sys/kern/vfs_syscalls.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 594c4f5ef23a..cf733133bec0 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -4886,7 +4886,8 @@ kern_copy_file_range(struct thread *td, int infd, off_t *inoffp, int outfd, len = SSIZE_MAX; /* Get the file structures for the file descriptors. */ - error = fget_read(td, infd, &cap_read_rights, &infp); + error = fget_read(td, infd, + inoffp != NULL ? &cap_pread_rights : &cap_read_rights, &infp); if (error != 0) goto out; if (infp->f_ops == &badfileops) { @@ -4897,7 +4898,8 @@ kern_copy_file_range(struct thread *td, int infd, off_t *inoffp, int outfd, error = EINVAL; goto out; } - error = fget_write(td, outfd, &cap_write_rights, &outfp); + error = fget_write(td, outfd, + outoffp != NULL ? &cap_pwrite_rights : &cap_write_rights, &outfp); if (error != 0) goto out; if (outfp->f_ops == &badfileops) { From nobody Mon Oct 2 19:23:41 2023 X-Original-To: dev-commits-src-branches@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 4RzrTn6WQYz4wPRQ; Mon, 2 Oct 2023 19:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RzrTn5xjKz4dtT; Mon, 2 Oct 2023 19:23:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696274621; 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=OZcS0OQ8nrgDlpzkZzP6+LWAJdwKtRaugBXvr+4dTEo=; b=f/B06cBB6L/gWKVvjBYtFQUkcrUo3dk/W86enXzYo3dD7+Q/PbK+hzbUBulWP3VTiUq9zc Y8usvcwnTyTeOvtPrrmTzvrxmPp//mbxyLy8LaxNVe7It21vi3kBBqSP7bDXD09WvJwViU qURWrmYPFKiAtwWmL51l//FTFPhLdWcsBGSNX/XphJ1Eg8j84Td/YoOt4KGUgr1C3IKao7 6Fv1ib7wQO4ddzsWdxBlbEKu4HxN0BLRBWwdAvp4emImfFaFE127gwxCYAa/Je+HYTlojL ktd7irV9NR9uhF0j5f2ROO+a0x3r0wKC+///HdMdduv2bSQlwOqQ0tqopM0fFQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696274621; a=rsa-sha256; cv=none; b=wiQphUzXv3o5mJ2QfcB92TbTla/aAm2ugbBvkEP81RCD56Kbr3Eu5ORAxOS9mZiV8GpJpP gjwarkAYQF9H2l4Oi6gycTtV3oDpoY7mdyFVICeqLrMaH2jEgG13FfcXzpE/bJHYhhX8dd JQhm8FqmtxbEEDrcLr1dyXgq2h1fNBQrC5PISRK+7x1Q1bwXNA+l5tNYmEsNq0OeWd3es6 kPRF8maFh1y2q7gbdwzXRm6iuRpLA+I1BYMNKkRrqeMEJw5KdJ/Gzw2gwAMOBFNJD2qoNK eZ+U4m5ZmjK00O/v1mCTsK3xRJXyAFvHtNErVcY1S156fIg33deaTypnSlIBVg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696274621; 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=OZcS0OQ8nrgDlpzkZzP6+LWAJdwKtRaugBXvr+4dTEo=; b=bayoDbI5bdop26jtN2LU6vl2HheBkQVkggafS3+Jj0a/Akp3mZJBf0IgNX1TkVdBWKXgoY Rnds+xtknU7x89bywijs10VWEtkdRrkdDdv2nya5iPhNFEtQ5RCI83GdG/jAjaX/6x/ikw 8UK8xQYiy3wakue/3r2/5ZnkNt74ERqX13is1AFnZqK4FRt52dkGG5Krj9A0tzIma6rWdZ 5VWqOuLWP/6d7zuSJqVgaXSNuGdQuuEM6e0kZiczCNHM+sw/iMD4him2bKJQGCNNmkaOgu RFEK6Kl1PFV9aejd8e8AJwQkPZFiYcJRqnSVU8PVJYqtNxlkBsVQ9/8MHg32bQ== 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 4RzrTn4yrPz9MS; Mon, 2 Oct 2023 19:23:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 392JNfSW085071; Mon, 2 Oct 2023 19:23:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 392JNftV085068; Mon, 2 Oct 2023 19:23:41 GMT (envelope-from git) Date: Mon, 2 Oct 2023 19:23:41 GMT Message-Id: <202310021923.392JNftV085068@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Jamie Gritton Subject: git: 6a5113a8a1df - releng/14.0 - MFS jail: avoid a clash with /etc/jail.conf.d between rc and jail(8) List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jamie X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 6a5113a8a1df5f93541d2e9af48fd2127bae0793 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by jamie: URL: https://cgit.FreeBSD.org/src/commit/?id=6a5113a8a1df5f93541d2e9af48fd2127bae0793 commit 6a5113a8a1df5f93541d2e9af48fd2127bae0793 Author: Jamie Gritton AuthorDate: 2023-09-25 00:03:09 +0000 Commit: Jamie Gritton CommitDate: 2023-10-02 19:22:52 +0000 MFS jail: avoid a clash with /etc/jail.conf.d between rc and jail(8) Since 13.1, /etc/rc.d/jail has looked for a per-jail config file in /etc/jail.conf.d. For RELENG 14, the ".include" directive was added to jail(8), with a sample line in the jail.conf(5) man page that includes "/etc/jail.conf.d/*.conf". These two use cases don't work together. When the jail.conf.d files are included from a master jail.conf, the files in jail.conf.d are likely to hold only partial configurations, and shouldn't be directly loaded by rc.d/jail. But there are existing configurations that depend on the current rc.d behavior. While users could be advised not to include from /etc/jail.conf.d, it's the natural choice even if not mentioned in jail.conf.5. The workaround is for rc.d/jail to continue to load the individual files, but only when /etc/jail.conf doesn't include from that directory (via a simple grep test), This allows the current use while not breaking the previous use. Approved by: re (gjb) Reported by: antranigv at freebsd.am Differential Revision: https://reviews.freebsd.org/D41962 (cherry picked from commit a2440348eed75bb7682579af0905b652747fd016) (cherry picked from commit c96d5c97bb65a1b0bc135b452f13d0ca6a8d60c9) --- libexec/rc/rc.d/jail | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libexec/rc/rc.d/jail b/libexec/rc/rc.d/jail index f8995c7e3b00..f12dae280bb0 100755 --- a/libexec/rc/rc.d/jail +++ b/libexec/rc/rc.d/jail @@ -126,7 +126,9 @@ parse_options() if [ -r "$_jconf" ]; then _conf="$_jconf" return 0 - elif [ -r "$_jconfdir" ]; then + elif [ -r "$_jconfdir" ] && ! egrep -q \ + '^\s*\.include\s*["'\'']?/etc/jail.conf.d/' "$jail_conf" \ + 2>/dev/null; then _conf="$_jconfdir" return 0 elif [ -r "$jail_conf" ]; then From nobody Tue Oct 3 01:10:35 2023 X-Original-To: dev-commits-src-branches@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 4S00B35Xd6z4vTFk; Tue, 3 Oct 2023 01:10: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S00B352VPz4HyH; Tue, 3 Oct 2023 01:10:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696295435; 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=D2STM9gUgRX3t+m/wA3HrK/artSCmHui56UNreVl4aA=; b=RneMIWMmYQnGrERRrsDNT/DLzuV2MJW9nJQe2pfu8Ago7taTwZgRXQG3ksm5dSKTtlP0GC 6Smxp26U+1CwpdbjYTS+cwAMWyYDfvAIPJgYirMhNAjFOdr4xZKueL3MsOKKQjkIxiBOIG OkInjiqSnI3Rn9omHH60zDugW1+25S4QltRNY46RGaBigcpQCAJsaxsZxXaX/rWbcRzaOa t1y3PAxnExNslJ7oyDKNwg2GudWtCSGUjbzRuq8+wJKsTir1VRRggiWrgRNRXN6tl6Z/z3 yZPBHtUDBkLgirwrEIauJmiEqb0oHcb7xxET7m/O4vfvW6TkiODG6IrFCMAG5Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696295435; a=rsa-sha256; cv=none; b=JxTUSXQLOtVTfhLgQYThLmEaIQWr/GtV0xVs1rw8VFalDMi/Ye/ZyORw5l/HnwQ3E7rAV8 HSN7/UXnUnEJHI6iZGUl6okbG4vMZJWmEaUblW04wTUKayWFYpVsSxNaWu3e2Q2zaJu2/t IZj4L/961nXArVcyuSnkA/eA7Pxeej5bIeozYlHnIWN7w3OmAdsiyVOiz0tyGsbscJj9nh 8zTOGMEramAAyht5mZZidcTK1uGwZmK4rLt7Avzj2zDoDEuBK2KkdJLcFjMFnBzCwiHS1R BBvUP3C2rOH6gOSCKviY52yhG5eZ3eQCtmLWvX4TWUOAHHxYfN2oka6v8AlAag== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696295435; 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=D2STM9gUgRX3t+m/wA3HrK/artSCmHui56UNreVl4aA=; b=OON9vn9+IuYnzwS3rrjX3mesdJSizT/0u3VJ1ifDDQJyfVVsxYiYehE36RnLQvcBObdojS C6DOoL7WO+1nxF+zzD1g9iq573lKDQTtLMT/peuu1lZ/F5sgEdKuqT5sS7uFucNBzAP2e5 0UEtCAX+xKjFmXeMi+A0cN/bENwdDMXtf6X8+AXRvQSThbYl/8Vt6YGzzTG/XNldVV2IeC dXKG+3AquYsukAuRVuPzJYiseIljsl1EwOd7VGCVa3YX/3mCFGTp1AnLw/gZlAuVDn/lUr j4EUKqlrHrjqtf87ABhTWTT9ZPFNTyXYYzPGAQLXn+IXJcqsY/YSkIBvi8Jn7A== 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 4S00B345LtzZ81; Tue, 3 Oct 2023 01:10:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3931AZdq061336; Tue, 3 Oct 2023 01:10:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3931AZa6061333; Tue, 3 Oct 2023 01:10:35 GMT (envelope-from git) Date: Tue, 3 Oct 2023 01:10:35 GMT Message-Id: <202310030110.3931AZa6061333@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alan Somers Subject: git: 13f188ce0b51 - stable/14 - fusefs: fix some bugs updating atime during close List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: asomers X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 13f188ce0b51908c292cdbb85ef26962528af87b Auto-Submitted: auto-generated The branch stable/14 has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=13f188ce0b51908c292cdbb85ef26962528af87b commit 13f188ce0b51908c292cdbb85ef26962528af87b Author: Alan Somers AuthorDate: 2023-09-20 21:37:31 +0000 Commit: Alan Somers CommitDate: 2023-10-03 01:10:13 +0000 fusefs: fix some bugs updating atime during close When using cached attributes, we must update a file's atime during close, if it has been read since the last attribute refresh. But, * Don't update atime if we lack write permissions to the file or if the file system is readonly. * If the daemon fails our atime update request for any reason, don't report this as a failure for VOP_CLOSE. PR: 270749 Reported by: Jamie Landeg-Jones Sponsored by: Axcient Reviewed by: pfg Differential Revision: https://reviews.freebsd.org/D41925 (cherry picked from commit fb619c94c679e939496fe0cf94b8d2cba95e6e63) fusefs: fix unused variables from fb619c94c67 PR: 270749 Reported by: cy Sponsored by: Axcient (cherry picked from commit e5236d25f2c0709acf3547e6af45f4bb4eec4f02) --- sys/fs/fuse/fuse_vnops.c | 27 ++++++++-- tests/sys/fs/fusefs/access.cc | 2 +- tests/sys/fs/fusefs/default_permissions.cc | 41 ++++++++++++++- tests/sys/fs/fusefs/read.cc | 83 ++++++++++++++++++++++++++++++ 4 files changed, 147 insertions(+), 6 deletions(-) diff --git a/sys/fs/fuse/fuse_vnops.c b/sys/fs/fuse/fuse_vnops.c index be2885528570..21ee378b24c6 100644 --- a/sys/fs/fuse/fuse_vnops.c +++ b/sys/fs/fuse/fuse_vnops.c @@ -779,6 +779,7 @@ static int fuse_vnop_close(struct vop_close_args *ap) { struct vnode *vp = ap->a_vp; + struct mount *mp = vnode_mount(vp); struct ucred *cred = ap->a_cred; int fflag = ap->a_fflag; struct thread *td = ap->a_td; @@ -794,12 +795,30 @@ fuse_vnop_close(struct vop_close_args *ap) return 0; err = fuse_flush(vp, cred, pid, fflag); - if (err == 0 && (fvdat->flag & FN_ATIMECHANGE)) { + if (err == 0 && (fvdat->flag & FN_ATIMECHANGE) && !vfs_isrdonly(mp)) { struct vattr vap; + struct fuse_data *data; + int dataflags; + int access_e = 0; - VATTR_NULL(&vap); - vap.va_atime = fvdat->cached_attrs.va_atime; - err = fuse_internal_setattr(vp, &vap, td, NULL); + data = fuse_get_mpdata(mp); + dataflags = data->dataflags; + if (dataflags & FSESS_DEFAULT_PERMISSIONS) { + struct vattr va; + + fuse_internal_getattr(vp, &va, cred, td); + access_e = vaccess(vp->v_type, va.va_mode, va.va_uid, + va.va_gid, VWRITE, cred); + } + if (access_e == 0) { + VATTR_NULL(&vap); + vap.va_atime = fvdat->cached_attrs.va_atime; + /* + * Ignore errors setting when setting atime. That + * should not cause close(2) to fail. + */ + fuse_internal_setattr(vp, &vap, td, NULL); + } } /* TODO: close the file handle, if we're sure it's no longer used */ if ((fvdat->flag & FN_SIZECHANGE) != 0) { diff --git a/tests/sys/fs/fusefs/access.cc b/tests/sys/fs/fusefs/access.cc index 3d6cddb9417b..5762269fac7b 100644 --- a/tests/sys/fs/fusefs/access.cc +++ b/tests/sys/fs/fusefs/access.cc @@ -55,7 +55,7 @@ void expect_lookup(const char *relpath, uint64_t ino) } /* - * Expect tha FUSE_ACCESS will never be called for the given inode, with any + * Expect that FUSE_ACCESS will never be called for the given inode, with any * bits in the supplied access_mask set */ void expect_noaccess(uint64_t ino, mode_t access_mask) diff --git a/tests/sys/fs/fusefs/default_permissions.cc b/tests/sys/fs/fusefs/default_permissions.cc index 1a1ee5a54aed..4b04297d97ac 100644 --- a/tests/sys/fs/fusefs/default_permissions.cc +++ b/tests/sys/fs/fusefs/default_permissions.cc @@ -30,7 +30,7 @@ /* * Tests for the "default_permissions" mount option. They must be in their own - * file so they can be run as an unprivileged user + * file so they can be run as an unprivileged user. */ extern "C" { @@ -163,6 +163,7 @@ class Fspacectl: public DefaultPermissions {}; class Lookup: public DefaultPermissions {}; class Open: public DefaultPermissions {}; class PosixFallocate: public DefaultPermissions {}; +class Read: public DefaultPermissions {}; class Setattr: public DefaultPermissions {}; class Unlink: public DefaultPermissions {}; class Utimensat: public DefaultPermissions {}; @@ -1239,6 +1240,44 @@ TEST_F(Rename, ok_to_remove_src_because_of_stickiness) ASSERT_EQ(0, rename(FULLSRC, FULLDST)) << strerror(errno); } +// Don't update atime during close after read, if we lack permissions to write +// that file. +TEST_F(Read, atime_during_close) +{ + const char FULLPATH[] = "mountpoint/some_file.txt"; + const char RELPATH[] = "some_file.txt"; + uint64_t ino = 42; + int fd; + ssize_t bufsize = 100; + uint8_t buf[bufsize]; + const char *CONTENTS = "abcdefgh"; + ssize_t fsize = sizeof(CONTENTS); + + expect_getattr(FUSE_ROOT_ID, S_IFDIR | 0755, UINT64_MAX, 1); + FuseTest::expect_lookup(RELPATH, ino, S_IFREG | 0755, fsize, + 1, UINT64_MAX, 0, 0); + expect_open(ino, 0, 1); + expect_read(ino, 0, fsize, fsize, CONTENTS); + EXPECT_CALL(*m_mock, process( + ResultOf([&](auto in) { + return (in.header.opcode == FUSE_SETATTR); + }, Eq(true)), + _) + ).Times(0); + expect_flush(ino, 1, ReturnErrno(0)); + expect_release(ino, FuseTest::FH); + + fd = open(FULLPATH, O_RDONLY); + ASSERT_LE(0, fd) << strerror(errno); + + /* Ensure atime will be different than during lookup */ + nap(); + + ASSERT_EQ(fsize, read(fd, buf, bufsize)) << strerror(errno); + + close(fd); +} + TEST_F(Setattr, ok) { const char FULLPATH[] = "mountpoint/some_file.txt"; diff --git a/tests/sys/fs/fusefs/read.cc b/tests/sys/fs/fusefs/read.cc index cf2159df646b..3df0420facb9 100644 --- a/tests/sys/fs/fusefs/read.cc +++ b/tests/sys/fs/fusefs/read.cc @@ -57,6 +57,14 @@ void expect_lookup(const char *relpath, uint64_t ino, uint64_t size) } }; +class RofsRead: public Read { +public: +virtual void SetUp() { + m_ro = true; + Read::SetUp(); +} +}; + class Read_7_8: public FuseTest { public: virtual void SetUp() { @@ -454,6 +462,47 @@ TEST_F(Read, atime_during_close) close(fd); } +/* + * When not using -o default_permissions, the daemon may make its own decisions + * regarding access permissions, and these may be unpredictable. If it rejects + * our attempt to set atime, that should not cause close(2) to fail. + */ +TEST_F(Read, atime_during_close_eacces) +{ + const char FULLPATH[] = "mountpoint/some_file.txt"; + const char RELPATH[] = "some_file.txt"; + const char *CONTENTS = "abcdefgh"; + uint64_t ino = 42; + int fd; + ssize_t bufsize = strlen(CONTENTS); + uint8_t buf[bufsize]; + + expect_lookup(RELPATH, ino, bufsize); + expect_open(ino, 0, 1); + expect_read(ino, 0, bufsize, bufsize, CONTENTS); + EXPECT_CALL(*m_mock, process( + ResultOf([&](auto in) { + uint32_t valid = FATTR_ATIME; + return (in.header.opcode == FUSE_SETATTR && + in.header.nodeid == ino && + in.body.setattr.valid == valid); + }, Eq(true)), + _) + ).WillOnce(Invoke(ReturnErrno(EACCES))); + expect_flush(ino, 1, ReturnErrno(0)); + expect_release(ino, FuseTest::FH); + + fd = open(FULLPATH, O_RDONLY); + ASSERT_LE(0, fd) << strerror(errno); + + /* Ensure atime will be different than during lookup */ + nap(); + + ASSERT_EQ(bufsize, read(fd, buf, bufsize)) << strerror(errno); + + ASSERT_EQ(0, close(fd)); +} + /* A cached atime should be flushed during FUSE_SETATTR */ TEST_F(Read, atime_during_setattr) { @@ -1321,6 +1370,40 @@ INSTANTIATE_TEST_SUITE_P(RA, ReadAhead, tuple(true, 1), tuple(true, 2))); +/* With read-only mounts, fuse should never update atime during close */ +TEST_F(RofsRead, atime_during_close) +{ + const char FULLPATH[] = "mountpoint/some_file.txt"; + const char RELPATH[] = "some_file.txt"; + const char *CONTENTS = "abcdefgh"; + uint64_t ino = 42; + int fd; + ssize_t bufsize = strlen(CONTENTS); + uint8_t buf[bufsize]; + + expect_lookup(RELPATH, ino, bufsize); + expect_open(ino, 0, 1); + expect_read(ino, 0, bufsize, bufsize, CONTENTS); + EXPECT_CALL(*m_mock, process( + ResultOf([&](auto in) { + return (in.header.opcode == FUSE_SETATTR); + }, Eq(true)), + _) + ).Times(0); + expect_flush(ino, 1, ReturnErrno(0)); + expect_release(ino, FuseTest::FH); + + fd = open(FULLPATH, O_RDONLY); + ASSERT_LE(0, fd) << strerror(errno); + + /* Ensure atime will be different than during lookup */ + nap(); + + ASSERT_EQ(bufsize, read(fd, buf, bufsize)) << strerror(errno); + + close(fd); +} + /* fuse_init_out.time_gran controls the granularity of timestamps */ TEST_P(TimeGran, atime_during_setattr) { From nobody Tue Oct 3 01:31:18 2023 X-Original-To: dev-commits-src-branches@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 4S00dz0C4wz4vVlQ; Tue, 3 Oct 2023 01:31: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S00dy6pWwz4KMG; Tue, 3 Oct 2023 01: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=1696296679; 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=z7pNO3Eh+YkwAQjzJ2PHm1dkPBiAfoDzYMoBfNWo2Sg=; b=s/y4O9GbKIMwJVBKvGHSyXvLb9k1Cctbz/mgr/Ricy22RBRBL9q0afxRsINMInb2WnJ7h7 I4V+xyzBTxpYOF43QrBGsZ/yQhjLJa0q0FeS2KBpsa1z/dXpGPxWMvKV23OAtg9cfzmJTC OIDu2qTYiAyOKuo5AGLaCnEHon9pJa6KZHom6JBYzLDaZibjtNMlYMtiWHJ7sV9K9OuI/P Gh2uaXy5a+jWOdGWfgpluIqTnVBqQemNKmSb0wz9e1K1+M7ShTy97G5VDBwyjMoxeGcKdE r+vmMGfOjoLl9fbTfV5FufuGIee5HPwoNEZOVbfkOQq6hrKtHYsI8upUQECjww== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696296679; a=rsa-sha256; cv=none; b=eTJK1XvzgKF3+cbu1GDvt5PMD762LHaj7NukhVo4soMXYfzHYhVcfX5LvyrUFLpPa4hZm7 N/3GYGzzGgopQMzAWUwA26HZoGZr+N4xLAmtN98lZPafYQUtUw9BB39Atg6LitYHQbZ4hU rvuCKlSRlwx5tTIdLZzHXMAe0odI4WThwWV3+3cxX9RFZOySDX8ErQcy6EIMxqq9kMvBmV GoD/eHYgHislazujiuOE1QXZmXStsRO9CZXOlctNBZdXsi5cvM95T/ktJQfjkE8/6nBvWC pnRRKBlHHOUyhhhqRzWAm0jWS49494Ec+4dLYPwyCciZUmVPoDitPROB6UlCHg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696296679; 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=z7pNO3Eh+YkwAQjzJ2PHm1dkPBiAfoDzYMoBfNWo2Sg=; b=seb4FKCFrDMy26i/ILeJg9yY9/s7NEbZTNfOzoAl1HcveS+NDYDSKcB5QnX/VMjHHWBSSH H+Y1EUJ8oIQRGQQMzqaicTHFzoIpN/r6GC5E5uPNO+2h5bSExjRCd2twVE+Y8wMuTcqnFI I3uf28r1vLCl3grqKzcmYtwF/jzosO6z+GY+e9Ou2+Ij2OfLR3sOyw+UOMcZTYSQVXtFxI NCSgNIFMD2xTOLZWQ9ecNJEnTkYJkaeGVzb/F4DsoP+qJ6LLaEI9BU7g7k+nZwVE2eQ+g3 bx1fsN8EedV8J8ZFxgQMf8zHksa81/+0rJ4Ixx/4j4o7pk9n4OmvG2s6wl4bew== 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 4S00dy5rx2zZk0; Tue, 3 Oct 2023 01:31:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3931VIYC096243; Tue, 3 Oct 2023 01:31:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3931VIst096240; Tue, 3 Oct 2023 01:31:18 GMT (envelope-from git) Date: Tue, 3 Oct 2023 01:31:18 GMT Message-Id: <202310030131.3931VIst096240@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alan Somers Subject: git: c70a4185c637 - stable/14 - mprutil: "fix user reply buffer (64)..." warnings List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: asomers X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c70a4185c637754428f36536af3bdc9181fa5155 Auto-Submitted: auto-generated The branch stable/14 has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=c70a4185c637754428f36536af3bdc9181fa5155 commit c70a4185c637754428f36536af3bdc9181fa5155 Author: Alan Somers AuthorDate: 2023-02-22 22:06:43 +0000 Commit: Alan Somers CommitDate: 2023-10-03 01:31:12 +0000 mprutil: "fix user reply buffer (64)..." warnings Depending on the card's firmware version, it may return different length responses for MPI2_FUNCTION_IOC_FACTS. But the first part of the response contains the length of the rest, so query it first to get the length and then use that to size the buffer for the full response. Also, correctly zero-initialize MPI2_IOC_FACTS_REQUEST. It only worked by luck before. PR: 264848 Reported by: Julien Cigar Sponsored by: Axcient Reviewed by: scottl, imp Differential Revision: https://reviews.freebsd.org/D38739 (cherry picked from commit 7d154c4dc64e61af7ca536c4e9927fa07c675a83) --- sys/dev/mpr/mpr.c | 2 +- sys/dev/mpr/mpr_user.c | 4 ++-- sys/dev/mps/mps.c | 2 +- sys/dev/mps/mps_user.c | 4 ++-- usr.sbin/mpsutil/mps_cmd.c | 40 +++++++++++++++++++++++++++------------- 5 files changed, 33 insertions(+), 19 deletions(-) diff --git a/sys/dev/mpr/mpr.c b/sys/dev/mpr/mpr.c index 72993be8834e..23f7ff0c3e9a 100644 --- a/sys/dev/mpr/mpr.c +++ b/sys/dev/mpr/mpr.c @@ -1871,7 +1871,7 @@ mpr_setup_sysctl(struct mpr_softc *sc) SYSCTL_ADD_STRING(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), OID_AUTO, "msg_version", CTLFLAG_RD, sc->msg_version, - strlen(sc->msg_version), "message interface version"); + strlen(sc->msg_version), "message interface version (deprecated)"); SYSCTL_ADD_INT(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), OID_AUTO, "io_cmds_active", CTLFLAG_RD, diff --git a/sys/dev/mpr/mpr_user.c b/sys/dev/mpr/mpr_user.c index d9dc3d2377a2..f2847ae36d66 100644 --- a/sys/dev/mpr/mpr_user.c +++ b/sys/dev/mpr/mpr_user.c @@ -852,7 +852,7 @@ mpr_user_pass_thru(struct mpr_softc *sc, mpr_pass_thru_t *data) rpl = (MPI2_DEFAULT_REPLY *)cm->cm_reply; sz = rpl->MsgLength * 4; - if (sz > data->ReplySize) { + if (bootverbose && sz > data->ReplySize) { mpr_printf(sc, "%s: user reply buffer (%d) " "smaller than returned buffer (%d)\n", __func__, data->ReplySize, sz); @@ -1077,7 +1077,7 @@ mpr_user_pass_thru(struct mpr_softc *sc, mpr_pass_thru_t *data) rpl = (MPI2_DEFAULT_REPLY *)cm->cm_reply; sz = rpl->MsgLength * 4; - if (sz > data->ReplySize) { + if (bootverbose && sz > data->ReplySize) { mpr_printf(sc, "%s: user reply buffer (%d) smaller " "than returned buffer (%d)\n", __func__, data->ReplySize, sz); diff --git a/sys/dev/mps/mps.c b/sys/dev/mps/mps.c index 43362b96b7b6..f358ab8a73a9 100644 --- a/sys/dev/mps/mps.c +++ b/sys/dev/mps/mps.c @@ -1719,7 +1719,7 @@ mps_setup_sysctl(struct mps_softc *sc) SYSCTL_ADD_STRING(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), OID_AUTO, "msg_version", CTLFLAG_RD, sc->msg_version, - strlen(sc->msg_version), "message interface version"); + strlen(sc->msg_version), "message interface version (deprecated)"); SYSCTL_ADD_INT(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), OID_AUTO, "io_cmds_active", CTLFLAG_RD, diff --git a/sys/dev/mps/mps_user.c b/sys/dev/mps/mps_user.c index cf2fdb2b2adb..3d1b478d81b1 100644 --- a/sys/dev/mps/mps_user.c +++ b/sys/dev/mps/mps_user.c @@ -851,7 +851,7 @@ mps_user_pass_thru(struct mps_softc *sc, mps_pass_thru_t *data) rpl = (MPI2_DEFAULT_REPLY *)cm->cm_reply; sz = rpl->MsgLength * 4; - if (sz > data->ReplySize) { + if (bootverbose && sz > data->ReplySize) { mps_printf(sc, "%s: user reply buffer (%d) " "smaller than returned buffer (%d)\n", __func__, data->ReplySize, sz); @@ -1005,7 +1005,7 @@ mps_user_pass_thru(struct mps_softc *sc, mps_pass_thru_t *data) rpl = (MPI2_DEFAULT_REPLY *)cm->cm_reply; sz = rpl->MsgLength * 4; - if (sz > data->ReplySize) { + if (bootverbose && sz > data->ReplySize) { mps_printf(sc, "%s: user reply buffer (%d) smaller " "than returned buffer (%d)\n", __func__, data->ReplySize, sz); diff --git a/usr.sbin/mpsutil/mps_cmd.c b/usr.sbin/mpsutil/mps_cmd.c index 448e4cea602f..2101bbba73b0 100644 --- a/usr.sbin/mpsutil/mps_cmd.c +++ b/usr.sbin/mpsutil/mps_cmd.c @@ -721,25 +721,39 @@ mps_pass_command(int fd, void *req, uint32_t req_len, void *reply, return (0); } +/* Return the length in bytes of the device's MPI2_IOC_FACTS reply */ +static size_t +mps_get_ioc_factslen(int fd) +{ + MPI2_IOC_FACTS_REQUEST req; + const size_t factslen = 4; + char factsbuf[4] = {0}; + MPI2_IOC_FACTS_REPLY *facts = (MPI2_IOC_FACTS_REPLY*)factsbuf; + int error; + + bzero(&req, sizeof(req)); + req.Function = MPI2_FUNCTION_IOC_FACTS; + error = mps_pass_command(fd, &req, sizeof(MPI2_IOC_FACTS_REQUEST), + factsbuf, factslen, NULL, 0, NULL, 0, 10); + + if (error) + return (0); + + /* The card's response is measured in dwords */ + return (facts->MsgLength * 4); +} + MPI2_IOC_FACTS_REPLY * mps_get_iocfacts(int fd) { MPI2_IOC_FACTS_REPLY *facts; MPI2_IOC_FACTS_REQUEST req; - char msgver[8], sysctlname[128]; - size_t len, factslen; + size_t factslen; int error; - snprintf(sysctlname, sizeof(sysctlname), "dev.%s.%d.msg_version", - is_mps ? "mps" : "mpr", mps_unit); - - factslen = sizeof(MPI2_IOC_FACTS_REPLY); - len = sizeof(msgver); - error = sysctlbyname(sysctlname, msgver, &len, NULL, 0); - if (error == 0) { - if (strncmp(msgver, "2.6", sizeof(msgver)) == 0) - factslen += 4; - } + factslen = mps_get_ioc_factslen(fd); + if (factslen == 0) + return (NULL); facts = malloc(factslen); if (facts == NULL) { @@ -747,7 +761,7 @@ mps_get_iocfacts(int fd) return (NULL); } - bzero(&req, factslen); + bzero(&req, sizeof(req)); req.Function = MPI2_FUNCTION_IOC_FACTS; #if 1 From nobody Tue Oct 3 03:37:21 2023 X-Original-To: dev-commits-src-branches@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 4S03RQ0kLxz4vdhg; Tue, 3 Oct 2023 03:37:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S03RQ0Dgjz4T5n; Tue, 3 Oct 2023 03:37:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696304242; 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=jbrgW7as+VY57qeRi8psSK6PbWFeAo2hyCm1hU5hl5I=; b=D43SrgmQlERHgkvfydT6i8K4L1fuMoiFYkje4WD6XVv6e0l8Ut1A9ALjb4Sl+YnseAm7L2 p0QUqO3WDnitGKikiodAYniOcqTfJjL/mxnM+OmLWFVBXwLNkx9grY4BpMb+1xPJ1ia6hY GM3CK9fK9TxPLgv0FGaealnt579TR4FVoHRZgBk+RhtkdcgfiEtdJCycs16pQk3ySuA60O nM+L3leTymeN23GCEKMCZvEJgBZ7DsZvhI9yQKjRRCaJtzUdlL/44asGUnKxoVOL1hK3NC 5Uo+TV64jfsrNykWJfskoR+mZ01yVd4zixz7DQ5eKb0krckFXr2qwVsTs02X2w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696304242; a=rsa-sha256; cv=none; b=oh1t14PujIb/vkOpNTuLqWx0T1UNTT7jkYXUAV9eiCZPtU9YytQb7Rom+q6msYRvNAj3FT 4MQ/b6J114gK9c/9wiVNOSh/ibA4BuR/PgsgwDW7L/csW4yl+xz+tdX8nLw0nlNEFtLqTj W+fLAerWa1knz3YEOkMZHKOSFFif47odlZP4RvCp2w2rnOmDS2RhqScR2xPzFbTiMnGU1y 9K1/O7zcBWOTedEGvR7if3gQqwF8MZP+NWknSFZLJCREaSSwDzcj16YSWzAg7CQ//I8WvY piZkLY61lXSqar6xmwY6xdBkgXmeBM9yixykLatvgoFoTvaleETvcQ4EEgEsEA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696304242; 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=jbrgW7as+VY57qeRi8psSK6PbWFeAo2hyCm1hU5hl5I=; b=dbk8veHxnmqcW12x4LAluOROIwrQZ62It+cO7rh3EC8m7bAytIs6jut72eMRuzdUAM2ALd Cc0PBT8l3iIoPpa4k432eKGDwNJ8qOPKsZmL2dq9jPTln5D0qJPdvwljmUu/MD/r7aOgQ+ yINm+a8yviX3kwJoFRleWdhSijMgAZwv0taKhNcrm0rxx0GpihEjSRpWD0Gpg8Qv1Y5fnP Pag71nBsJI1/bQfdbHf8cvYaDuhZbWQt2rWKVK3H7U255ZHhYjRbgZ1lxRg1rr4hkkaSxl txYqLHg05QiY+pTX4v7N/tJsoOjmUYEbR8+y0Oa/KBRcvuDgIylYVEGvxtv96w== 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 4S03RP6PMjzfPN; Tue, 3 Oct 2023 03:37:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3933bL5f002930; Tue, 3 Oct 2023 03:37:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3933bLah002927; Tue, 3 Oct 2023 03:37:21 GMT (envelope-from git) Date: Tue, 3 Oct 2023 03:37:21 GMT Message-Id: <202310030337.3933bLah002927@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: 535c90cdbcd9 - releng/14.0 - rtsock: Add sysctl flag CTLFLAG_TUN to loader tunable List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 535c90cdbcd9eed3e0e46ad90a886ac6d0e53386 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=535c90cdbcd9eed3e0e46ad90a886ac6d0e53386 commit 535c90cdbcd9eed3e0e46ad90a886ac6d0e53386 Author: Zhenlei Huang AuthorDate: 2023-09-25 10:10:46 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-03 03:34:16 +0000 rtsock: Add sysctl flag CTLFLAG_TUN to loader tunable The sysctl variable `net.route.netisr_maxqlen` is actually a loader tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` will report it correctly. No functional change intended. Reviewed by: glebius Approved by: re (gjb) MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41928 (cherry picked from commit 21a722d9593eb477f4ccdad011a2b4df0727fc62) (cherry picked from commit bffb01eda9bffc3307ea8bf70f91087ed316e01c) --- sys/net/rtsock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/net/rtsock.c b/sys/net/rtsock.c index 1a83fc2d8abe..019b9e80291c 100644 --- a/sys/net/rtsock.c +++ b/sys/net/rtsock.c @@ -241,7 +241,7 @@ sysctl_route_netisr_maxqlen(SYSCTL_HANDLER_ARGS) return (netisr_setqlimit(&rtsock_nh, qlimit)); } SYSCTL_PROC(_net_route, OID_AUTO, netisr_maxqlen, - CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_MPSAFE, + CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_MPSAFE, 0, 0, sysctl_route_netisr_maxqlen, "I", "maximum routing socket dispatch queue length"); From nobody Tue Oct 3 03:37:22 2023 X-Original-To: dev-commits-src-branches@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 4S03RR27vMz4vdyW; Tue, 3 Oct 2023 03:37: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S03RR1L9kz4T6R; Tue, 3 Oct 2023 03:37:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696304243; 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=ySNtv7cOYWdCHhs00Y0HLEAu9K89zUqrMDbxom+1rJM=; b=mBm9SOWAkr6sFxcpnmtQP9Bj/KMM9hcAlYVtlXVamglo4E1nGXIfeuEPwLHD7Fie1PoSQh G9VdaxWz/B9IVDA/ytCHWsl5bc2YozGBXDWq7dcwFCps6Ap/0H/dxeESTmL8PMxffyTXqy 5Ap9bIFZCrsJtQy2759kJOFDbesSEyKSMz3O4CZaE6VLQ7jEVSXFbIkrDbhM3WzqrjvaU+ 9JRqwcfQ4kHBAFhtzqZ65YGPL9nQ205bSxTttHEDILRA689i4tATBcpJej8wIvnyQey8Zf 60NSg6441bnJPzjDTVgdzToQNwNAm+16MvZ9wIzIGp3NcKoHCt0a5KMb4olW/w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696304243; a=rsa-sha256; cv=none; b=KUftpMNzHIAAvsi5NBn7uhe89MPRH9Vq5Qr6rssZI8rGwwes065jX/otzXcOox42FFQe5N Rzt0zCM2M0Y5KMnTYHKZIfzD3cpL6cG6nUBDsqP1XgaSSWSM+gkNKebDudVb9p5Kaoeumt Dblj/qKM0AqK3lJRDOLjH+ZVbhXYu9SvrHZwKi/6eL5kSRkV2EdPOAeq1JKaLYwtVYcO4Z O1XzGQ9ehtMIkiuvkEpZZMSk1rb0DAjS8JHpfn1hHqVoBwLNpwNb9WVQkVMMu82CykoAH2 sE6MNgNc7ODl9mhdAhtbARtGL4fgUaMw8orNJ0qnVTrcnNNeCeN94tNGlTV25A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696304243; 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=ySNtv7cOYWdCHhs00Y0HLEAu9K89zUqrMDbxom+1rJM=; b=PdsTkBreV4NlSmUPCe4vG5yVObnqmNk2hBe2CKY2WBRrDJCWjzdgZACvvFXzirTZW5rvIi mQ1WqW4N0QwyciM1xGMWVhfqL8qLD7ia3dkD2JDd0sfiOyw56seQVAabMyVeZGzK9IvCri zBuGLORfF8JaULRxgQQdo5bfLedTE09A44VYs4UTVGoQgcKjC4PFkXt7fDC3B6CYs1NQL2 a5/Rtn2tbbnnuusSiJKqsdxlWfVBFJlfbCXUbn7KZHBxH/hvVxEa9ztQD+UW5F6X3p2FNA abYExCO1MQrWs5YaPPqvtUAJR0gYR1aTZT3lb9qh1+UWUSda6/M2iEbhTtmNoA== 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 4S03RR0KgrzfPP; Tue, 3 Oct 2023 03:37:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3933bMLP002981; Tue, 3 Oct 2023 03:37:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3933bMvd002978; Tue, 3 Oct 2023 03:37:22 GMT (envelope-from git) Date: Tue, 3 Oct 2023 03:37:22 GMT Message-Id: <202310030337.3933bMvd002978@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: abd4f7d8bc57 - releng/14.0 - netinet6: Add sysctl flag CTLFLAG_TUN to loader tunables List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: abd4f7d8bc57249b6d09be253411aecb26095d0f Auto-Submitted: auto-generated The branch releng/14.0 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=abd4f7d8bc57249b6d09be253411aecb26095d0f commit abd4f7d8bc57249b6d09be253411aecb26095d0f Author: Zhenlei Huang AuthorDate: 2023-09-25 10:10:47 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-03 03:34:16 +0000 netinet6: Add sysctl flag CTLFLAG_TUN to loader tunables The following sysctl variables are actually loader tunables. Add sysctl flag CTLFLAG_TUN to them so that `sysctl -T` will report them correctly. 1. net.inet6.ip6.auto_linklocal 2. net.inet6.ip6.accept_rtadv 3. net.inet6.ip6.no_radr No functional change intended. Reviewed by: glebius Approved by: re (gjb) MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41928 (cherry picked from commit 03dac3e37993801dab4418087bfedacce0526e66) (cherry picked from commit da2b630c12ec074673dfc646b2055a31b0d8d6d9) --- sys/netinet6/in6_proto.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/netinet6/in6_proto.c b/sys/netinet6/in6_proto.c index 1d67577f8055..6e7ffedc3dcd 100644 --- a/sys/netinet6/in6_proto.c +++ b/sys/netinet6/in6_proto.c @@ -278,10 +278,10 @@ SYSCTL_VNET_PCPUSTAT(_net_inet6_ip6, IPV6CTL_STATS, stats, struct ip6stat, ip6stat, "IP6 statistics (struct ip6stat, netinet6/ip6_var.h)"); SYSCTL_INT(_net_inet6_ip6, IPV6CTL_ACCEPT_RTADV, accept_rtadv, - CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_accept_rtadv), 0, + CTLFLAG_VNET | CTLFLAG_RWTUN, &VNET_NAME(ip6_accept_rtadv), 0, "Default value of per-interface flag for accepting ICMPv6 RA messages"); SYSCTL_INT(_net_inet6_ip6, IPV6CTL_NO_RADR, no_radr, - CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_no_radr), 0, + CTLFLAG_VNET | CTLFLAG_RWTUN, &VNET_NAME(ip6_no_radr), 0, "Default value of per-interface flag to control whether routers " "sending ICMPv6 RA messages on that interface are added into the " "default router list"); @@ -334,7 +334,7 @@ SYSCTL_INT(_net_inet6_ip6, IPV6CTL_V6ONLY, v6only, CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_v6only), 0, "Restrict AF_INET6 sockets to IPv6 addresses only"); SYSCTL_INT(_net_inet6_ip6, IPV6CTL_AUTO_LINKLOCAL, auto_linklocal, - CTLFLAG_VNET | CTLFLAG_RW, &VNET_NAME(ip6_auto_linklocal), 0, + CTLFLAG_VNET | CTLFLAG_RWTUN, &VNET_NAME(ip6_auto_linklocal), 0, "Default value of per-interface flag for automatically adding an IPv6 " "link-local address to interfaces when attached"); SYSCTL_VNET_PCPUSTAT(_net_inet6_ip6, IPV6CTL_RIP6STATS, rip6stats, From nobody Tue Oct 3 03:37:24 2023 X-Original-To: dev-commits-src-branches@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 4S03RS4HVSz4vdWT; Tue, 3 Oct 2023 03:37:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S03RS2NB4z4Tbx; Tue, 3 Oct 2023 03:37:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696304244; 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=kh9ovaDRZlRmzp7l7PXxoVpj6gfdKWCQyh9r2+vTrDo=; b=vNLRShU/ARbrM/7RwqXp1QbvekDVesRnrHD8iEvm6lSUIpUon5IbfkSrWPXRf09S4BrjFe +oO0yaIMYNVvSWS84FPd9wIkI5K4P3dnXJDOvcm0WmgYpWcKo1WSIbdtZI5wfDaZNDcKJd qkzbluZ788H1Z6W1iK1CCTUFChufFL588j7Q+P2r2oDOr+eoFwmhKfWf8YOvPuJe7XbW2Z sxiXHhFG8Sf+D8t+1iDsbP4zd2kM//sf4wwAAhjEbFkQtZew9vgQrE9TM8WxTxVGq3y62B 0Xml/PnZ1e2ucY4OtrqhRAvOzbTA2cRu3LWXUNYOeaLXZm8nN2VWMGUHGfJ3sw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696304244; a=rsa-sha256; cv=none; b=XuuicP94MCKw21tUNMUzfhJenxBwyJi4di+xNsqUpxW9ZqsfEJMAEwRX9w634Pu9Tq3Rfv wZjVY5qlPjTeLQWqRRKf+FBBN8DaiF6zxKLlZelu52NT8tzMIsbR4uBeqm3hS0pWIEshc2 7WqF52dTAuPeqPnB2S6rSvDuGQsKCjAr+OAN7t25iBz9fkvenpfl4K+cpRS1pYxDr8W9kf Osi7+V4H/EMjRyuKzKpLsIHAn5zjSwR7Yy3Qpvok3S06Y9UFmtoDd8NqBC8GOiAR+9grdp Yo9PCxyEOi5k2vAkZKgdPBUmI1Ptxy/dLuw+oneS3Q03jblyaArxoa74nnRpPw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696304244; 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=kh9ovaDRZlRmzp7l7PXxoVpj6gfdKWCQyh9r2+vTrDo=; b=cRjwqHdefdu5Dy48xmMkXTIw+FsG3Ei3k6ztJcnkB3MpZI1SDbKm7/zsmY0bSG5LGqaEyQ As3/SMS6OK29lvBeuqLvV/3HXkxuUV48smozaZfZDsk1QImxi7YbwybxJkq1uTCJLfacFP rOWmzSn1Pd6n+k4F0WiG+bDu2Ef8xm2D47Ln676Y5XlzPfs8c+IE33Xl2ZeCGZ/Q1oj19J EuTMrGeZxe00xYxb9TLFMuKXYCm09BLNqOdPgj0XF7lf11gcCwIJ+sNpcEi/07LZTcAWtE 4JUbFH1qw2xq8lksHI4xQWDUmOb5STdpsnqJU1fifj6YdbZT/752Dnyj2oPkBQ== 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 4S03RS1NZfzfLd; Tue, 3 Oct 2023 03:37:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3933bOk7003036; Tue, 3 Oct 2023 03:37:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3933bOge003033; Tue, 3 Oct 2023 03:37:24 GMT (envelope-from git) Date: Tue, 3 Oct 2023 03:37:24 GMT Message-Id: <202310030337.3933bOge003033@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: e19407fe9a63 - releng/14.0 - ipfw: Add sysctl flag CTLFLAG_TUN to loader tunables List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: e19407fe9a63a16a5e8c6a0ad94e325d5289d301 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=e19407fe9a63a16a5e8c6a0ad94e325d5289d301 commit e19407fe9a63a16a5e8c6a0ad94e325d5289d301 Author: Zhenlei Huang AuthorDate: 2023-09-25 10:10:47 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-03 03:34:16 +0000 ipfw: Add sysctl flag CTLFLAG_TUN to loader tunables The following sysctl variables are actually loader tunables. Add sysctl flag CTLFLAG_TUN to them so that `sysctl -T` will report them correctly. 1. net.inet.ip.fw.enable 2. net.inet6.ip6.fw.enable 3. net.link.ether.ipfw No functional change intended. Reviewed by: glebius Approved by: re (gjb) MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41928 (cherry picked from commit 49197c391b3d49a33bcd08471bf64d533cd10f9d) (cherry picked from commit f5f6da90597cb65ce55c4f17718a200097f6f78f) --- sys/netpfil/ipfw/ip_fw_pfil.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/netpfil/ipfw/ip_fw_pfil.c b/sys/netpfil/ipfw/ip_fw_pfil.c index 1cfff1870d7f..4dae28aa0544 100644 --- a/sys/netpfil/ipfw/ip_fw_pfil.c +++ b/sys/netpfil/ipfw/ip_fw_pfil.c @@ -91,20 +91,20 @@ SYSBEGIN(f1) SYSCTL_DECL(_net_inet_ip_fw); SYSCTL_PROC(_net_inet_ip_fw, OID_AUTO, enable, - CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE3 | + CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_SECURE3 | CTLFLAG_NEEDGIANT, &VNET_NAME(fw_enable), 0, ipfw_chg_hook, "I", "Enable ipfw"); #ifdef INET6 SYSCTL_DECL(_net_inet6_ip6_fw); SYSCTL_PROC(_net_inet6_ip6_fw, OID_AUTO, enable, - CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE3 | + CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_SECURE3 | CTLFLAG_NEEDGIANT, &VNET_NAME(fw6_enable), 0, ipfw_chg_hook, "I", "Enable ipfw+6"); #endif /* INET6 */ SYSCTL_DECL(_net_link_ether); SYSCTL_PROC(_net_link_ether, OID_AUTO, ipfw, - CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE3 | + CTLFLAG_VNET | CTLTYPE_INT | CTLFLAG_RWTUN | CTLFLAG_NOFETCH | CTLFLAG_SECURE3 | CTLFLAG_NEEDGIANT, &VNET_NAME(fwlink_enable), 0, ipfw_chg_hook, "I", "Pass ether pkts through firewall"); From nobody Tue Oct 3 03:37:25 2023 X-Original-To: dev-commits-src-branches@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 4S03RT3wxnz4vdcT; Tue, 3 Oct 2023 03: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S03RT3LZXz4TWR; Tue, 3 Oct 2023 03: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=1696304245; 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=2ghrNR5ZmxhsmLRoi/ES58RFHptSMgj0g+P3TlySjkQ=; b=izuSCiZTwjGJ2f1Q2V2TRQbnoFvLyL2IJQKxnrpasWcsVDGvfmqP1By4D3mUDK6QaVTAxj 1nDmh3zYT3Y+kIU0MBbHo9vzjmIfNw3aDn57qK7DggY1JoNNg4mOZAyQa17x9iIzomxVU8 fPAS7HQaLNcjawWe+Js5ESiwDsbBJGHqiFtlh4fMQvFgMf4hT70vaZ7mRhNkKi0wg++KzZ /7GZa0N+GgllGy6EHIGCkkoSIRXNfd/yQiZE/kfemTsrgOth14HZdyW/9XbGo9nNa+EjR5 wmmIHHQC3Hd57qyuqNpUmNuCw2WLHQIax/LYouwvUflDEIc9ZbUDVDD+KAeo9w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696304245; a=rsa-sha256; cv=none; b=yEIJktroEAiMcbraNnO+kYJXwroIX9JrLZIDJXD2yLC1ziMC+OrtcmDbhUawKhSFMUarWG 2N+jhvr3m53/m52KJb+IEfpoUbbIeSQlmXSBDDPcHtxA0l/vRNQ6rkvme5aSphLGKjc/fb dVM/Gb7WntpeK+4L/V/v2EDUr7VvpEbItHq6UF+XxMRN+zlU+gZ4Ai4ZnkcWwLsuoO72wm e8Kw3IHZy7xI77ZIfOkydpQr/bocKUM2TyQ4E7F10bIXd4IUoQjCrk3xtKOWcNx+0s2NbQ c3KSH2BTW1BlrkRAFOdVW/3hlhSm2/h6BI0/nCDl0gK8TwFaHH9WirikNAmLdw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696304245; 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=2ghrNR5ZmxhsmLRoi/ES58RFHptSMgj0g+P3TlySjkQ=; b=N50psH3HNBZFYqW8iT89rZNUtR185c1VXCtUaX1wXl2GhA0u289RRJzm5FJARApg2hX1aP qIrlq/ZXh4TEOKMK1Iks3HatULtnZnD9JRI1aur/MVom3f8rbeFeTrYSzfPG2B3J/1Kxx/ kdUufpFgVFbL2pKIumPcqnSv2FRHoMCExGb+u2jJZItdpR/8oc/SmXwC80FRs+7T0qqMyg zj/ON7C1diQqD9k4EdAIL92kx+AERf1+b9rgxUAUl6rdvDN1d1+fM7NoFMwVSJ3pCV33EB HVtr+TOHRGyJmxCGgYNy+dUW7Jui1N75tWTeADPWUcrWLacZsvrWS5p2z6hjnA== 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 4S03RT2PX7zfPQ; Tue, 3 Oct 2023 03:37:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3933bPL0003086; Tue, 3 Oct 2023 03:37:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3933bPeJ003083; Tue, 3 Oct 2023 03:37:25 GMT (envelope-from git) Date: Tue, 3 Oct 2023 03:37:25 GMT Message-Id: <202310030337.3933bPeJ003083@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: cc30510aeb78 - releng/14.0 - ipfw.8: Adjust section for loader tunables List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: cc30510aeb78d6013dfa9c137144543c2db0e4c8 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=cc30510aeb78d6013dfa9c137144543c2db0e4c8 commit cc30510aeb78d6013dfa9c137144543c2db0e4c8 Author: Zhenlei Huang AuthorDate: 2023-09-28 04:58:44 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-03 03:34:16 +0000 ipfw.8: Adjust section for loader tunables Move the descriptions of loader tunables from section 'SYSCTL VARIABLES' to section 'LOADER TUNABLES'. See also 49197c391b3d (ipfw: Add sysctl flag CTLFLAG_TUN to loader tunables). MFC after: 2 days Approved by: re (gjb) Differential Revision: https://reviews.freebsd.org/D41981 (cherry picked from commit 12349f38898f231ca803dcf526bac88cb1b5cd2b) (cherry picked from commit bb6f9a95402a6c3ab8167481b81465f8ad5016fc) --- sbin/ipfw/ipfw.8 | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/sbin/ipfw/ipfw.8 b/sbin/ipfw/ipfw.8 index 1a042ae2bbbf..e62b8d6efc95 100644 --- a/sbin/ipfw/ipfw.8 +++ b/sbin/ipfw/ipfw.8 @@ -1,5 +1,5 @@ .\" -.Dd April 25, 2023 +.Dd September 28, 2023 .Dt IPFW 8 .Os .Sh NAME @@ -3761,6 +3761,16 @@ or .Xr kenv 1 before ipfw module gets loaded. .Bl -tag -width indent +.It Va net.inet.ip.fw.enable : No 1 +Enables the firewall. +Setting this variable to 0 lets you run your machine without +firewall even if compiled in. +.It Va net.inet6.ip6.fw.enable : No 1 +provides the same functionality as above for the IPv6 case. +.It Va net.link.ether.ipfw : No 0 +Controls whether layer2 packets are passed to +.Nm . +Default is no. .It Va net.inet.ip.fw.default_to_accept : No 0 Defines ipfw last rule behavior. This value overrides @@ -4154,12 +4164,6 @@ Keep dynamic states on rule/set deletion. States are relinked to default rule (65535). This can be handly for ruleset reload. Turned off by default. -.It Va net.inet.ip.fw.enable : No 1 -Enables the firewall. -Setting this variable to 0 lets you run your machine without -firewall even if compiled in. -.It Va net.inet6.ip6.fw.enable : No 1 -provides the same functionality as above for the IPv6 case. .It Va net.inet.ip.fw.one_pass : No 1 When set, the packet exiting from the .Nm dummynet @@ -4176,10 +4180,6 @@ Enables verbose messages. Limits the number of messages produced by a verbose firewall. .It Va net.inet6.ip6.fw.deny_unknown_exthdrs : No 1 If enabled packets with unknown IPv6 Extension Headers will be denied. -.It Va net.link.ether.ipfw : No 0 -Controls whether layer2 packets are passed to -.Nm . -Default is no. .It Va net.link.bridge.ipfw : No 0 Controls whether bridged packets are passed to .Nm . From nobody Tue Oct 3 03:37:26 2023 X-Original-To: dev-commits-src-branches@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 4S03RV4nqcz4vf26; Tue, 3 Oct 2023 03:37:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S03RV455pz4TlL; Tue, 3 Oct 2023 03:37:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696304246; 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=zCkG3EwHw0OAuoT6L+kxC+WFKd/fdwSeV0KNY0gOjX0=; b=dzKP/zfTrhqx0XS9KBkebWonMhgCQULzBdOBHKJZGiz9U7zHO39l1pFB1tUUaQ5cwKMUMG gI2egONJup21xBuxdxEbTtt2DSAkU6O/QWl2hxCB985XCKRqRha5cHBkDqekbm4GSan29C yFnUYsvJL5vfjF4A4dUQ3hBclvUEhXz9pNnmvETahtKDXhEf7qnWORdqJ+Z83kgyWw2mbu VIBIdrkJQ6TKRD6QA9dv/721xFxdlE/+EHdd83961DvS19NCZTpVd1eBWspgUyJkRZ+i9o iM2B0RX91OsBB0U5KRc06ILzINLfsbUmzdVcXnoekBpi71tDJpJLPsAoopo5gQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696304246; a=rsa-sha256; cv=none; b=CsHHgnmO78ppsTiJFFVWq2mbgNHfA0xNFVWf67jJl7rpVUOzcet7V/1U3yddsRXmH1bDKz LXCaQ+AZ1rkCHdGUmwM51IGOFfE5amBdhxkkCd1vHizBqk9tYwQt4NyCB7d7jvOgNZdzvR jTJvY/4veP8BqD8FPIlz3LD980r9/Epb9CBuakNAM9TiD+kVfiLL+Q4vBafSaz4BdSRY96 R/mIRskXVndOa9a9y32Nh8Ag6Qf1qrM21mLBPlwf9OFAJOUiZnGb5sQWv+GklkkYnaAsK7 nLelX8NTK5yHATHsMLof7sdo0SnVC9E2O2YqfIG7cqyqzHV0u/leMiT9tM8PEQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696304246; 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=zCkG3EwHw0OAuoT6L+kxC+WFKd/fdwSeV0KNY0gOjX0=; b=MUijPEVZTyeCzeO8SQW7FUedayu2tw/hRse/WxS9El3U8H1aut/yadZsu76RpsTqDxPHQn H0ImyxEbMzd9nLKM6ynBPACo+u1/q/dzBOykUffi9yFyoz2WuuJOCuR5Oi1bjMcKeWklD4 rGDfpneeOw3V6sJdx82v3Iybd5w2Vjg2+5Nsi/rTdSfIQGDgoT+9uuXOVn9SxmV5DsJSQI VrDMuVaB3H4k22LV5/QSswSfl4aXPQUPTIfodjNpvRBBJAiNE8UTBpeVi4afUL3dUl+zKP pWmbQ2PEzTp5JNsbdyKsDkmec1pqK9NxANRwSF/Jb/G7XD2mBVpX960tdqndgQ== 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 4S03RV37XxzfVK; Tue, 3 Oct 2023 03:37:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3933bQ67003125; Tue, 3 Oct 2023 03:37:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3933bQ68003122; Tue, 3 Oct 2023 03:37:26 GMT (envelope-from git) Date: Tue, 3 Oct 2023 03:37:26 GMT Message-Id: <202310030337.3933bQ68003122@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: ea3e5ee58560 - releng/14.0 - ip_mroute: Fix sysctl knobs List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: ea3e5ee5856008ea469fe4e90d231a36d5b432b5 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=ea3e5ee5856008ea469fe4e90d231a36d5b432b5 commit ea3e5ee5856008ea469fe4e90d231a36d5b432b5 Author: Zhenlei Huang AuthorDate: 2023-09-27 16:23:22 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-03 03:34:16 +0000 ip_mroute: Fix sysctl knobs The loader tunable `net.inet.ip.mfchashsize` does not have corresponding sysctl MIB entry. Just add it. While here, the sysctl variable `net.inet.pim.squelch_wholepkt` is actually a loader tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` will report it correctly. Reviewed by: kp Approved by: re (gjb) Fixes: 443fc3176dee Introduce a number of changes to the MROUTING code MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D41997 (cherry picked from commit f549e22901b3a391c76659bee55802b1214112fd) (cherry picked from commit b0f026435a150933ecb6f2d1359fd1b4898657f1) --- sys/netinet/ip_mroute.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/sys/netinet/ip_mroute.c b/sys/netinet/ip_mroute.c index 2444fd9686f7..cda5f160e8fb 100644 --- a/sys/netinet/ip_mroute.c +++ b/sys/netinet/ip_mroute.c @@ -172,7 +172,9 @@ VNET_DEFINE_STATIC(u_long, mfchash); ((g).s_addr >> 20) ^ ((g).s_addr >> 10) ^ (g).s_addr) & V_mfchash) #define MFCHASHSIZE 256 -static u_long mfchashsize; /* Hash size */ +static u_long mfchashsize = MFCHASHSIZE; /* Hash size */ +SYSCTL_ULONG(_net_inet_ip, OID_AUTO, mfchashsize, CTLFLAG_RDTUN, + &mfchashsize, 0, "IPv4 Multicast Forwarding Table hash size"); VNET_DEFINE_STATIC(u_char *, nexpire); /* 0..mfchashsize-1 */ #define V_nexpire VNET(nexpire) VNET_DEFINE_STATIC(LIST_HEAD(mfchashhdr, mfc)*, mfchashtbl); @@ -226,7 +228,7 @@ SYSCTL_VNET_PCPUSTAT(_net_inet_pim, PIMCTL_STATS, stats, struct pimstat, pimstat, "PIM Statistics (struct pimstat, netinet/pim_var.h)"); static u_long pim_squelch_wholepkt = 0; -SYSCTL_ULONG(_net_inet_pim, OID_AUTO, squelch_wholepkt, CTLFLAG_RW, +SYSCTL_ULONG(_net_inet_pim, OID_AUTO, squelch_wholepkt, CTLFLAG_RWTUN, &pim_squelch_wholepkt, 0, "Disable IGMP_WHOLEPKT notifications if rendezvous point is unspecified"); @@ -2817,18 +2819,12 @@ ip_mroute_modevent(module_t mod, int type, void *unused) return (EINVAL); } - mfchashsize = MFCHASHSIZE; - if (TUNABLE_ULONG_FETCH("net.inet.ip.mfchashsize", &mfchashsize) && - !powerof2(mfchashsize)) { + if (!powerof2(mfchashsize)) { printf("WARNING: %s not a power of 2; using default\n", "net.inet.ip.mfchashsize"); mfchashsize = MFCHASHSIZE; } - pim_squelch_wholepkt = 0; - TUNABLE_ULONG_FETCH("net.inet.pim.squelch_wholepkt", - &pim_squelch_wholepkt); - pim_encap_cookie = ip_encap_attach(&ipv4_encap_cfg, NULL, M_WAITOK); ip_mcast_src = X_ip_mcast_src; From nobody Tue Oct 3 03:37:27 2023 X-Original-To: dev-commits-src-branches@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 4S03RW62SCz4vdtY; Tue, 3 Oct 2023 03: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S03RW5MZWz4TgK; Tue, 3 Oct 2023 03: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=1696304247; 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=TyxrqQTEKI/gVre2+gAIIGIf0FoKnq2C0I+hlTpXY9I=; b=u/o60xMbQFwCmF7n/DuLrWDZG97mm0Xeplwn0SYGppozEfknBSV4lbf7kfi123IuboNqRr FQTeKpdsJl8KmU0iMC4ub6gBTcCF7d+B3KLnAJHUrzelMUWNgDPvy/fdzhtmkss7vQCecd 1iLtEcdDO9/mjLfcjCUfJlyFeFSoGNo9h89YiIbSeVd8GuGQWoSLS5tDjebgtjDzmQm3Va rkXiEwTP+jtEk2/0qalAMLIu0bIy/WxGDky5nEmhTLI99jqR6+/KoGIKu+W1WHRr1VcoO+ GIJGhDw5KQ4GNqOY8pRhR3UK3sosw9xpvzxP1fY7Va0tgTTD2RiKLbmlbfs2cg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696304247; a=rsa-sha256; cv=none; b=le3RH4enNjil0iihUbC/2SZSFCqiadM/0YWTA1uEuYPQGYtE9C9uEPBMU4n2r5YU6I4mdR fZ04otdruVHQYdnzKg9ecWuCEeqVvSRS7kMSzsazAImgimSAOvGyYJciIByrkOMmWVklqr IxZ1EEofIqDdMpt7XXZjDx41HybNb2WFaN9X/aAGRu6nor0OjwQfKtKbn/nVWf+Y6RfSek lyQTQPtzGRtFIxJYQ3c7e60tLjKm+qOfQeZ9NDF3TAapCP8cAUaKulxYe1w7wMYQ71N0kQ ukhgLCY9GGo3q/YeK74Fg0zfafFsSkLBsX7KNLKaRfLiAFyW59JqwnGw/3pL/A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696304247; 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=TyxrqQTEKI/gVre2+gAIIGIf0FoKnq2C0I+hlTpXY9I=; b=nEmmYjF8Wqbb6+hAVmZqu98RCl2e85LkkiwBMOrZ2aGg1Bu3+BtbltaunzTeCe/CxNTZZK 1XJEPQIdvsjZUu21PeJ3Okn1hqf4g952q/kMU1G9+lX348niMsTIC4IFa+UuXnC70HZRFa +ybDVgzkbhcdTI460f/GVmQwPRwKgvs+qaN4Zid9MTNJOrCpz0IeD+N+ArTF3sxDNmu+Ik HFc+2apvAXa4Fw4hKafZ1CVHPKmOeCfHA0s86PvRdLvw5QiAhlP4oDSksESVsf8783AxNj PI9tQw5OvAO3xNb4KR43RreX6mXyQive98v48HvzLITpIOyvfmgkGyJaj88KPA== 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 4S03RW4QdWzfSB; Tue, 3 Oct 2023 03:37:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3933bR5U003182; Tue, 3 Oct 2023 03:37:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3933bRGl003179; Tue, 3 Oct 2023 03:37:27 GMT (envelope-from git) Date: Tue, 3 Oct 2023 03:37:27 GMT Message-Id: <202310030337.3933bRGl003179@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: c920810743c6 - releng/14.0 - ipfilter: Add sysctl flag CTLFLAG_TUN to loader tunable List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: c920810743c6de1f1d78936726af29752e7a0095 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=c920810743c6de1f1d78936726af29752e7a0095 commit c920810743c6de1f1d78936726af29752e7a0095 Author: Zhenlei Huang AuthorDate: 2023-09-29 00:01:43 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-03 03:34:17 +0000 ipfilter: Add sysctl flag CTLFLAG_TUN to loader tunable The sysctl variable `net.inet.ipf.large_nat` is actually a loader tunable. Add sysctl flag CTLFLAG_TUN to it so that `sysctl -T` will report it correctly. No functional change intended. Reviewed by: cy (for #network) Approved by: re (gjb) Fixes: a805ffbcbce8 ipfilter: Make LARGE_NAT a tunable MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D42005 (cherry picked from commit ba883e7a5ac43b27a373f2b1b0044fd2eb769d4e) (cherry picked from commit a9359dcde241f17421a71bc8c96dee08625db9dd) --- sys/netpfil/ipfilter/netinet/mlfk_ipl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c b/sys/netpfil/ipfilter/netinet/mlfk_ipl.c index 35daad4715bf..69be4abb2485 100644 --- a/sys/netpfil/ipfilter/netinet/mlfk_ipl.c +++ b/sys/netpfil/ipfilter/netinet/mlfk_ipl.c @@ -134,7 +134,7 @@ SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_running, CTLFLAG_RD, &VNET_NAME(ipfmain.ipf_running), 0, "IPF is running"); SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_chksrc, CTLFLAG_RW, &VNET_NAME(ipfmain.ipf_chksrc), 0, ""); SYSCTL_IPF(_net_inet_ipf, OID_AUTO, fr_minttl, CTLFLAG_RW, &VNET_NAME(ipfmain.ipf_minttl), 0, ""); -SYSCTL_IPF(_net_inet_ipf, OID_AUTO, large_nat, CTLFLAG_RD, &VNET_NAME(ipfmain.ipf_large_nat), 0, "large_nat"); +SYSCTL_IPF(_net_inet_ipf, OID_AUTO, large_nat, CTLFLAG_RDTUN | CTLFLAG_NOFETCH, &VNET_NAME(ipfmain.ipf_large_nat), 0, "large_nat"); #define CDEV_MAJOR 79 #include From nobody Tue Oct 3 14:07:44 2023 X-Original-To: dev-commits-src-branches@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 4S0KQn03sLz4wHgW; Tue, 3 Oct 2023 14:07:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0KQm6dhjz3Dq0; Tue, 3 Oct 2023 14:07:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696342064; 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=u+/zBUudgXZx+CzvliJYLsrKpQHuyQYQG1PL3sWvKMI=; b=q9UYuI2GdtZUa0gQlXy6ex5N6zYXHf/YR61priw9T7aiYp1YcWkXaqHwcIIzRNUj+iQbaU 3rzmR3dIzma2a05EWfDwz1Ir6OZTipcdX4r8wAnXRhOky0kIaN4wYX5KlmRT1QAK9VKM/3 uUWoAEc50I9ptwZCQIdSxJxmSXxOSotM/mEVOb1EoKwBGbYAw4QSzQ3rYkOS1ChFZhzRDM ls5MA6lyXT1dJYRQ36UQte1foKcEqxj7XP+hwnaxo3lmicfx9agPBsOhr7YoSPitCTfozf Q4RebY+sA9UTDx1p8wsl8z3s6TXreQelwNgDwSPU8E0mPe5z1/WiEfqcOftxVg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696342064; a=rsa-sha256; cv=none; b=E3GZJl/ati42MKHccs5xwj//NLMfiOz5gIFNLzsJTAkHIAxirOvh3qaRJ4lzgU9/TK6pQn 03X51K1UKdoMQfrTsLFuBA5fYeJSB0Yr/dBiWtg3qWuYur2IID+/0tIA65xuGPv/5S/7Pv 9cozaL48m5tjn3Ao3bMoQHed6MpZYQS1+wrpAFgUCoQ/BIGGMegm0Pv8exC+Qy/+oQbqkh 5ToZvC5/hrdyg/XNArn5R6vDWNUQgrjwjsKUBGiWeOOlgHLOdls/kc2iEp3/acTqK7F9az Yx852YiQOWVfk8z+CRdIWPhFq2GfHLwso9RE2IKKMwq2mH5AHjnaduqsTdVdTg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696342064; 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=u+/zBUudgXZx+CzvliJYLsrKpQHuyQYQG1PL3sWvKMI=; b=LSHEdPIKuhtfvGC77j6YXncqzxRDlomGakjqUu4QZVgNPqPAfePzHguBdUxvotMc/KqOW/ PsR2J9F49iMusDiAx0xkWgCRhc0p1oeCRa4wGSUrQp3dfb+L4H7AEukmgc0tfzgYAZ+9Ax CQQ6bnnx+f7MzGGCybALZKy8cOeWf6OfDid8md2CNXKRsunuXHBfiiJbkLPJt7bJN2mG+h wmm4OF3Rigv3SaKVHsOthfMV5Saruo48NvXcMKEH6OlZZbUl1fBwUj61CdaUl1jejFxrlB Ja+vb/pPw1dsOJgLAXRRT4p8Y7qqQhtLnuJwv72W9RE2YyAp3gC98EMwZQ77yQ== 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 4S0KQm5h5Zzxd7; Tue, 3 Oct 2023 14:07:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393E7iXI052919; Tue, 3 Oct 2023 14:07:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393E7iIh052916; Tue, 3 Oct 2023 14:07:44 GMT (envelope-from git) Date: Tue, 3 Oct 2023 14:07:44 GMT Message-Id: <202310031407.393E7iIh052916@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alexander Motin Subject: git: 2ed56a7bfe8d - stable/14 - Untie strchrnul() from gdb. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 2ed56a7bfe8ddf960709478430710c20b1222c03 Auto-Submitted: auto-generated The branch stable/14 has been updated by mav: URL: https://cgit.FreeBSD.org/src/commit/?id=2ed56a7bfe8ddf960709478430710c20b1222c03 commit 2ed56a7bfe8ddf960709478430710c20b1222c03 Author: Alexander Motin AuthorDate: 2023-09-24 03:17:29 +0000 Commit: Alexander Motin CommitDate: 2023-10-03 13:57:16 +0000 Untie strchrnul() from gdb. MFC after: 10 days (cherry picked from commit 2373e704aa1a5dcb7609badfdb0be4ceb4966d74) --- sys/conf/files | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/conf/files b/sys/conf/files index 8d38b9cc8a2e..2b4bebaa6831 100644 --- a/sys/conf/files +++ b/sys/conf/files @@ -4037,7 +4037,7 @@ libkern/strcasecmp.c standard libkern/strcasestr.c standard libkern/strcat.c standard libkern/strchr.c standard -libkern/strchrnul.c optional gdb +libkern/strchrnul.c standard libkern/strcpy.c standard libkern/strcspn.c standard libkern/strdup.c standard From nobody Tue Oct 3 14:07:53 2023 X-Original-To: dev-commits-src-branches@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 4S0KQx4SHVz4wHxT; Tue, 3 Oct 2023 14:07: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0KQx3ZMwz3FFQ; Tue, 3 Oct 2023 14:07:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696342073; 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=JAh+iEHJxL/rv7qVY8mcR5kwRp3xSi6BrzXqeIT1ilU=; b=wslA0omqCn/UCz1T7SyBAhFp1VHYOOFpz1F/0+R1XWgiXP3Bt7JeSEconW0j4Sk558SyvV e70v58Py8lmVgPwdq+KU9R0afmd/pdST1WlEK+kstXJf0CWiNfYrSPsAq8Si7TjEaSh6hF EEEm+d7JwLdDPJqFFHTagUb1Tw0wvRxiRsWQeZ/XJjVVQsrz7hwdIDHZ4su21D6d3y2+96 7jTlc92RIryiNN7SzgfgG6pcGIeiKn4axTLdeig0ltWAYQ4QMp1krVuZczyluwKG/zqlwY mcqPhd/DIoCcynduPWWvoEvuStqqLJqEetUaiSrV4qHBBWn/lok2kEWqD4DqCg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696342073; a=rsa-sha256; cv=none; b=l+XlJDTge7cjDt9NKUWpflRtnRQhaCiUdaKo5cWMySIfANul4zaEwvx6+oFcOmsBekYm9S f2oBnx38QItACWP/3iJKxKMGi5lwHicuVqtm0N2ccNY5r70yBuceckbKbQK4fWHLCobiHe hXURWJ3PlVfUC7z27zSqVBrwVpeN4aE96kDrHCTaXeT9QII9qNsJZoDmCOmFkLJMxCFO2P phZjJAbgfn9gHnWWDz+HoP1SOhiHioWeqbIGh2tCDh1sT3/+/oQ17MXVMgPoC7MlWt5WMw dtMxy+/+uZ/6zf3IotqT+9U/c49zzIzNtTfee2mlAfi+Cv6nnNCGMVc/gP556Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696342073; 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=JAh+iEHJxL/rv7qVY8mcR5kwRp3xSi6BrzXqeIT1ilU=; b=js9uue4dfDJOPxawr54mDOPtIXkPcAIn28qoc89jbFkIeSXyBcyNRUxvuqjfEEFfQwL5Vp c5CD/DLpxcofxj3WUY3Xh1opSX274Y5MUC6BHK8xs9aadMraJrqkAAU1SAP5yOVfwJFndw 6JvzyHAhUFnendLkF8rjVP+JCyMpV6qQPRjdpd7uH4YvAdOrLGw482qYgnHQdqJtJEpDiL yLsEiVENDPg9Ob8AvfEMSmziA0jy0gdmnf7V24iwp6pj4cpZPZnd9eSy2/4Tra1Y8fUZcU 8tMJMuxK2JHlA8FHzaskywVIPIWSQjBh6gkTZfTOlYlUe553KHZZJ2vU/NleVg== 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 4S0KQx2db3zxxQ; Tue, 3 Oct 2023 14:07:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393E7rCE053056; Tue, 3 Oct 2023 14:07:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393E7r1K053053; Tue, 3 Oct 2023 14:07:53 GMT (envelope-from git) Date: Tue, 3 Oct 2023 14:07:53 GMT Message-Id: <202310031407.393E7r1K053053@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alexander Motin Subject: git: 31b1ceddb1d3 - stable/13 - Untie strchrnul() from gdb. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: 31b1ceddb1d317f165c310ba50262c566e3ce74c Auto-Submitted: auto-generated The branch stable/13 has been updated by mav: URL: https://cgit.FreeBSD.org/src/commit/?id=31b1ceddb1d317f165c310ba50262c566e3ce74c commit 31b1ceddb1d317f165c310ba50262c566e3ce74c Author: Alexander Motin AuthorDate: 2023-09-24 03:17:29 +0000 Commit: Alexander Motin CommitDate: 2023-10-03 14:01:35 +0000 Untie strchrnul() from gdb. MFC after: 10 days (cherry picked from commit 2373e704aa1a5dcb7609badfdb0be4ceb4966d74) --- sys/conf/files | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/conf/files b/sys/conf/files index 904584885db6..5f2e09eb8c2f 100644 --- a/sys/conf/files +++ b/sys/conf/files @@ -4126,7 +4126,7 @@ libkern/strcasecmp.c standard libkern/strcasestr.c standard libkern/strcat.c standard libkern/strchr.c standard -libkern/strchrnul.c optional gdb +libkern/strchrnul.c standard libkern/strcmp.c standard libkern/strcpy.c standard libkern/strcspn.c standard From nobody Tue Oct 3 17:28:37 2023 X-Original-To: dev-commits-src-branches@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 4S0PtZ0QS6z4vm82; Tue, 3 Oct 2023 17: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0PtY71lNz4KKJ; Tue, 3 Oct 2023 17: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=1696354118; 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=sKhdgEAswwuVSPRMl0DXAdzHVJ36RhXQFTVhXJrbIAM=; b=Hf3tn4BwU169UmDhsLfEmROAaZ74m5nwTJh0My0WwzSwGqzFfD9MCtX0QiLf6Qf+Vb4Jzh m7Vy9YZBxosJDMRrDgcozsGchiMhTzhxNAORrzMKSKTiST76Tbuxlqsi5LKqdJn5V42OGn hBrmKxsh/8PlQfcaikdH9SJbxJ7s+9hGsd62ZCyYmU8FORqBkBGlq0aZjK7zSczXDfjQ24 pkRpm5W6e3vomjK7lgLcRT9WFfiJ2qmcF96UOJFwuA2M4HJrQxjthzeg6KDNgltiiYlH5T z2ISJGfRwopioSdqu6CL613vy+HyR677NcdSnsneOi6BLiVejM6QhllEugFTrQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696354118; a=rsa-sha256; cv=none; b=iByDoYFHX2AYV6A+ZaoWaQ5+KlSiyAZteNX5hXvk1yAvkaudEInBiQWfI8WXzWtq/Kd5P4 fMBaNt6xyap5k9naGrx1Am7F8ceLOQJLqCX/wVnjk4QSxD7D2bbnBqik1Qs2XEi3vWllJ4 9/ugSHag88AkZzbdyJHcHO/6vCjQJz4HcLvTyneJzo3rx+SZTGY+jDbDOS1Bs016hQRhQu liLaw8uPoO5U/5ULvZd2gdDmJ2ODQ/x95nahCv/fYHemfBttQnapc8LiOIehCPdZzDaEJx GlKmq3UAvJiFkiEio/7pIMLSISHZ9n012ZJrIHM+2jIHGnE+MJhAtD4vXsn+5A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696354118; 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=sKhdgEAswwuVSPRMl0DXAdzHVJ36RhXQFTVhXJrbIAM=; b=cOScnEdRSob26dA4pcIl2covNozciKGpDhuJJUrMPDO0UKWwBeVvOf6o7PCWKN46+VdHEm GNboMxDa8Afx6PRLn0+TCTfc91D8SkujIYjViWMHDpXr+Ba0La/8Xqn+eazywPMWbjC/3/ sJ1RdhBCpQ6buTGMbeYTxc7MS1E5IkrOUdSYEsjMJRYPmIsAulWFadVVQfadDCjsquaB0L EjhfW0K8K3LSAw+w7pQkw0sQ0yBZWb4KucYDfq2cH6sGrzAqa6b0Nvn7/iPsS6TsYEw9S+ QEpD95SS1Ya8Un3mXsecnj2kO9dUZTUsSRpl9Dp4V8sBryeAtDv1R1Sz6IDyYA== 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 4S0PtY644Jz141X; Tue, 3 Oct 2023 17:28:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393HSb9d085443; Tue, 3 Oct 2023 17:28:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393HSb0I085440; Tue, 3 Oct 2023 17:28:37 GMT (envelope-from git) Date: Tue, 3 Oct 2023 17:28:37 GMT Message-Id: <202310031728.393HSb0I085440@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: 1cc968931bef - stable/14 - release/ec2: Remove references to portsnap List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 1cc968931bef915dd700b5eaefc8e6bd13fdb8a0 Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=1cc968931bef915dd700b5eaefc8e6bd13fdb8a0 commit 1cc968931bef915dd700b5eaefc8e6bd13fdb8a0 Author: Mark Johnston AuthorDate: 2023-09-27 22:02:36 +0000 Commit: Colin Percival CommitDate: 2023-10-03 17:28:17 +0000 release/ec2: Remove references to portsnap We no longer install a default portsnap.conf, so the sed invocation just generates an error. Reviewed by: cperciva MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D42003 (cherry picked from commit 63aa2e91342ead0495eada5667f413f0cf8eb56a) --- release/tools/ec2.conf | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/release/tools/ec2.conf b/release/tools/ec2.conf index 71f9f5c330cb..d033739adc26 100644 --- a/release/tools/ec2.conf +++ b/release/tools/ec2.conf @@ -126,11 +126,9 @@ EOF 's/^#KbdInteractiveAuthentication yes/KbdInteractiveAuthentication no/' \ ${DESTDIR}/etc/ssh/sshd_config - # Use FreeBSD Update and Portsnap mirrors hosted in AWS + # Use FreeBSD Update mirrors hosted in AWS sed -i '' -e 's/update.FreeBSD.org/aws.update.FreeBSD.org/' \ ${DESTDIR}/etc/freebsd-update.conf - sed -i '' -e 's/portsnap.FreeBSD.org/aws.portsnap.FreeBSD.org/' \ - ${DESTDIR}/etc/portsnap.conf # Use the NTP service provided by Amazon sed -i '' -e 's/^pool/#pool/' \ From nobody Tue Oct 3 17:28:38 2023 X-Original-To: dev-commits-src-branches@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 4S0Ptb1SQ8z4vm86; Tue, 3 Oct 2023 17: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0Ptb12D8z4Kbr; Tue, 3 Oct 2023 17: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=1696354119; 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=udeVRkeWmxKtdYVjz1fwTe9OSiyxR5PTM2mjDyv/nuU=; b=uVrRM1QpGW7HgFTY5AWz3ixH6QsHYv5AfW5l2nzm/Ito8UjsEdLhy0bcdweGe1EjEv2fC7 OZkjaxSX0uAuEI4ZWAxYUtCmlKS5Zq0xB98UssUJrYFy4d8j4rWQXGJLDFBh81BJpWRLKu /4tYTrCeW5OkrfiOXb1xXupXmk08bKztdNA5A5avQkodxUQh1JK6pOYsmkZNec4n3SQopl C/A+w4+AZ1fjmABlkkj9fS/8YnssSoDU+gUOpMXagq2tB7+l51cUNs6rtZjjm2+QNCIDZX Rig3E7Er7vYc4PkQ298hxmzDYUILSA6Crnqxs0xG11juUesiqLf4REDTDMvwKg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696354119; a=rsa-sha256; cv=none; b=v1zOj/dk6kV1oGM0uKch/MwziHOT3quFvBR+TniDCoqViwmQeASQLJuhjkHjdY6pDhYJXU FSQ+pOCVc64zBGlUSjdpjtWx93+kGnkIM/u5STVRMg+pBlROzODvZ0CHbNWqwEWevAKnOE lY8oWler63aW5wMcIVuzldAoqUMbSxOuLjfTSseAEyDrDUAxznS8E5GVWdjBAuQuSaOCVF bREtxAIc+QpPp+4ktEcsDEyl3gEjZzyRf9a7NjzhBQmxrzqftVNm2Jj2ROcwofX7QqjVHh ngYR+CGA4vM/x4OVTcaV2tV9tEIU+vQul4CBaM0o2EabPhQEzeQdd5q0VQeZpQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696354119; 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=udeVRkeWmxKtdYVjz1fwTe9OSiyxR5PTM2mjDyv/nuU=; b=e5EFlJquz2vFSScmBUOFD6hbxgbKTyhqJ/0/1N8FQYuHLNjrJIJ31k9DRIgxUDMAmxLluX SjwhOeqy9z5EP22qIRiRvszB8p732loX+STL6lxQByG2n24gQfkYtWlv2yseKUOGcYZpwD ZD9c+zsy6qr2MgNYpSA2Wo7l4FBz6dj+7P4CzCdb5aJH2VPLsJbso46CfTPowByHdxJuqk URuWAmsBdwwpOueEeIAIvOiR8ujRZRKaGBs8wtiP2XAumFp9Jaa1WHwJAS3gDKiplv+xn9 TTW9IkhGPtQI3E9k8ylFZKhPzEemf0t1x08t5n+w2Jy2EyTbyWL/TsVUZhLTUg== 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 4S0PtZ7242z13k6; Tue, 3 Oct 2023 17:28:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393HScYi085485; Tue, 3 Oct 2023 17:28:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393HScnJ085482; Tue, 3 Oct 2023 17:28:38 GMT (envelope-from git) Date: Tue, 3 Oct 2023 17:28:38 GMT Message-Id: <202310031728.393HScnJ085482@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: b9013d75c853 - stable/14 - release/Makefile.vm: Garbage collect unused bits List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: b9013d75c8531e1eaa993321a22eb7714af10f68 Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=b9013d75c8531e1eaa993321a22eb7714af10f68 commit b9013d75c8531e1eaa993321a22eb7714af10f68 Author: Colin Percival AuthorDate: 2023-09-09 00:49:35 +0000 Commit: Colin Percival CommitDate: 2023-10-03 17:28:17 +0000 release/Makefile.vm: Garbage collect unused bits The cw*-package targets were introduced in February 2015 as part of adding support for building GCE images; but GCE support was reworked in June 2015 and the cw*-package targets were in fact never used. Remove them. The *_DISK variables were introduced in February 2015 as part of adding the cloudware-install target; this was removed in May 2016 as the cloudware images are published via the respective cloud systems and not published as disk images via the FreeBSD FTP site. As such, the *_DISK variables are not unused; remove them. releng/14.0 candidate. Discussed with: gjb Reviewed by: imp MFC after: 5 days Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D41789 (cherry picked from commit fcbeeb5ff456b2f21d19d4fc6221774b512e30b7) --- release/Makefile.vm | 23 +---------------------- 1 file changed, 1 insertion(+), 22 deletions(-) diff --git a/release/Makefile.vm b/release/Makefile.vm index fb00804a81ec..4041ae14e2f3 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -26,35 +26,27 @@ CLOUDWARE?= BASIC-CI \ AZURE_FORMAT= vhdf AZURE_FSLIST= ufs AZURE_DESC= Microsoft Azure platform image -AZURE_DISK= ${OSRELEASE}.${AZURE_FORMAT} BASIC-CI_FORMAT= raw BASIC-CI_FSLIST= ufs BASIC-CI_DESC= Image for CI -BASIC-CI_DISK= ${OSRELEASE}.${BASIC-CI_FORMAT} EC2_FORMAT= raw EC2_FSLIST= ufs zfs EC2_DESC= Amazon EC2 image -EC2_DISK= ${OSRELEASE}.${EC2_FORMAT} GCE_FORMAT= raw GCE_FSLIST= ufs GCE_DESC= Google Compute Engine image -GCE_DISK= disk.${GCE_FORMAT} OCI_FORMAT= qcow2 OCI_FSLIST= ufs OCI_DESC= Oracle Cloud Infrastructure image -OCI_DISK= ${OSRELEASE}.${OCI_FORMAT} OPENSTACK_FORMAT=qcow2 OPENSTACK_FSLIST= ufs OPENSTACK_DESC= OpenStack platform image -OPENSTACK_DISK= ${OSRELEASE}.${OPENSTACK_FORMAT} VAGRANT-VIRTUALBOX_FORMAT= vmdk VAGRANT-VIRTUALBOX_FSLIST= ufs VAGRANT-VIRTUALBOX_DESC= Vagrant Image for VirtualBox -VAGRANT-VIRTUALBOX_DISK= ${OSRELEASE}.vbox.${VAGRANT_FORMAT} VAGRANT-VMWARE_FORMAT= vmdk VAGRANT-VMWARE_FSLIST= ufs VAGRANT-VMWARE_DESC= Vagrant Image for VMWare -VAGRANT-VMWARE_DISK= ${OSRELEASE}.vmware.${VAGRANT_FORMAT} .for _V in TYPE BRANCH REVISION . if !defined(${_V}) || empty(${_V}) @@ -90,9 +82,7 @@ CLOUDTARGETS+= cw-${_CW:tl}-${_FS} CLEANDIRS+= cw-${_CW:tl}-${_FS} CLEANFILES+= ${_CW:tl}.${_FS}.img \ ${_CW:tl}.${_FS}.${${_CW:tu}_FORMAT} \ - ${_CW:tl}.${_FS}.${${_CW:tu}_FORMAT}.raw \ - cw${_CW:tl}-package -CLOUDPACKAGE+= cw${_CW:tl}-package + ${_CW:tl}.${_FS}.${${_CW:tu}_FORMAT}.raw ${_CW:tu}${_FS:tu}IMAGE= ${_CW:tl}.${_FS}.${${_CW:tu}_FORMAT} cw-${_CW:tl}-${_FS}: emulator-portinstall @@ -114,17 +104,6 @@ CLEANFILES+= ${_CW:tl}.${${_CW:tu}_FORMAT} ${_CW:tu}IMAGE= ${_CW:tl}.${${_CW:tu}_FORMAT} cw-${_CW:tl}: cw-${_CW:tl}-${VMFS} ln -f ${${_CW:tu}${VMFS:tu}IMAGE} ${${_CW:tu}IMAGE} - -cw${_CW:tl}-package: - @# Special target to handle packaging cloud images in the formats - @# specific to each hosting provider. -.if exists(${.CURDIR}/tools/${_CW:tl}-package.sh) - env TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} \ - ${.CURDIR}/tools/${_CW:tl}-package.sh \ - -D ${DESTDIR} -I ${${_CW}_DISK} -S ${WORLDDIR} -.endif - touch ${.TARGET} - . endfor .endif From nobody Tue Oct 3 17:28:40 2023 X-Original-To: dev-commits-src-branches@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 4S0Ptc2l0xz4vmH5; Tue, 3 Oct 2023 17:28:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0Ptc2GJCz4Kfx; Tue, 3 Oct 2023 17:28:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696354120; 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=ajair3VlsEsK4LPGwNW12Vp2rVZOFHkgKJVbeKSAzUw=; b=TDGgniYXtCzl82adkwjO74Cdj8Fubflm+viLJuveNAVSskbbfZ6ekQHb7w2BONbJWffO86 baGGfEPfByNOQ3J2hMxBKBGVBbTDfNWPzMBnaeTUnEqtQifvu8kMaxZ67xBEYzxpaQ9oyZ /E6mvjzFXayOEQhQo2JewskfmiNftz5NOM3u4Hqhjx+7BQUS3mfWhRNBAlxY2okD5cMQ8R tvjtw3etm8XhFpTFB4dKBYyruUyjKj5fuITqTLDrAt2QZaalCAkY5f2Gm0LWTCwEBDW6m+ ZRFgxpunoJ7t+HEzfh5yhV77xBN0AY1125O0xPsLSkl/HAYrdhFS5UY2dJsYuw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696354120; a=rsa-sha256; cv=none; b=SW3m55Rs5soAsDk4Y+PDtGI9lFchUknl1sBvwOnOSzQ7ZkLQ9eNusUPkejBaz5mFVOoTsS lPGCuJ+UYlha/ohHrwdLmuqzEJhiMMXeA6qe12VYCV1pIGjSLTYI91UK0yH5lhr9qlaUH0 NeuNnDFbxkHPXmMA+6dw5BxrrxLAGkyzL9vo8hW0I4bQzKh2qd33D5GywFU4oImbA9viqP ++EAmuApdvUfZCRdvgje8IztJ84Qk01X2foyCNWD9ebrwlwYdj2pzexEsFpG7A/cXIIqnt XRbGNf28V+MlgA5yVLrN70iewz9ewefOj6I9XCDOOqRPy/n0iZgcQSn8kzFQ2g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696354120; 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=ajair3VlsEsK4LPGwNW12Vp2rVZOFHkgKJVbeKSAzUw=; b=HhAImxyiljQgT0+OruWYcKZPWU20zKWPgZoIiJof4l41H/nGJfSwVW7PyEdNKxsmNRQLI1 WEhuhHeANtVw+9Sz45A72H2sAolzUIt6JuKMZBZNk5SIhUACUxtLwO52mLEjt2nZFCFrpS TvBn4P7BRCjKM6aJ+wOaUCzDE7A+xBEeJVYpO33/abKxuNZlGKii+K3f8kBWuZ/7SzM5mk Ze0M+L+0fNTMSCZJQ1MY/PKcOkF31oTytHbNsQsct1g9dWZg13prGv/yT1dEmclHUhyUvn Rpp7Rwc2K1uFZ3noaKAiB3i1nJtdsZLGcnOpDsXuLRJG+0GX2mFccP9tKVToAw== 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 4S0Ptc0jhRz13q1; Tue, 3 Oct 2023 17:28:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393HSeYl085530; Tue, 3 Oct 2023 17:28:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393HSebx085527; Tue, 3 Oct 2023 17:28:40 GMT (envelope-from git) Date: Tue, 3 Oct 2023 17:28:40 GMT Message-Id: <202310031728.393HSebx085527@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: fec4f6a7c377 - stable/14 - release/Makefile.vm: Add support for CW flavours List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: fec4f6a7c377f576c78dabe16bc632ecf20058b4 Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=fec4f6a7c377f576c78dabe16bc632ecf20058b4 commit fec4f6a7c377f576c78dabe16bc632ecf20058b4 Author: Colin Percival AuthorDate: 2023-09-09 00:51:08 +0000 Commit: Colin Percival CommitDate: 2023-10-03 17:28:17 +0000 release/Makefile.vm: Add support for CW flavours There are two "Vagrant" images right now: "Vagrant Image for VirtualBox" and "Vagrant Image for VMWare". Rather than listing these separately in a CLOUDWARE list, place "VAGRANT" into a CLOUDWARE_TYPES list and then use a VAGRANT_FLAVOURS variable to identify the two versions. Add make logic to allow defaults (in this case, image format and filesystem) to be specified once for VAGRANT and inherited by both flavours. This will make future work to add flavoured EC2 images simpler. releng/14.0 candidate. Discussed with: gjb Reviewed by: imp MFC after: 5 days Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D41790 (cherry picked from commit e6eeac9b71795252b12a6b94e7a06633a9ff6e4e) --- release/Makefile.vm | 26 +++++++++++++++++++------- 1 file changed, 19 insertions(+), 7 deletions(-) diff --git a/release/Makefile.vm b/release/Makefile.vm index 4041ae14e2f3..e7ff86c28df3 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -17,12 +17,11 @@ VMDK_DESC= VMWare, VirtualBox disk image QCOW2_DESC= Qemu, KVM disk image RAW_DESC= Unformatted raw disk image -CLOUDWARE?= BASIC-CI \ +CLOUDWARE_TYPES?= BASIC-CI \ EC2 \ GCE \ OCI \ - VAGRANT-VIRTUALBOX \ - VAGRANT-VMWARE + VAGRANT AZURE_FORMAT= vhdf AZURE_FSLIST= ufs AZURE_DESC= Microsoft Azure platform image @@ -41,13 +40,26 @@ OCI_DESC= Oracle Cloud Infrastructure image OPENSTACK_FORMAT=qcow2 OPENSTACK_FSLIST= ufs OPENSTACK_DESC= OpenStack platform image -VAGRANT-VIRTUALBOX_FORMAT= vmdk -VAGRANT-VIRTUALBOX_FSLIST= ufs +VAGRANT_FORMAT= vmdk +VAGRANT_FSLIST= ufs +VAGRANT_FLAVOURS= VIRTUALBOX VMWARE VAGRANT-VIRTUALBOX_DESC= Vagrant Image for VirtualBox -VAGRANT-VMWARE_FORMAT= vmdk -VAGRANT-VMWARE_FSLIST= ufs VAGRANT-VMWARE_DESC= Vagrant Image for VMWare +.for _CWT in ${CLOUDWARE_TYPES} +. if defined(${_CWT}_FLAVOURS) +. for _CWF in ${${_CWT}_FLAVOURS} +CLOUDWARE_GEN+= ${_CWT}-${_CWF} +${_CWT}-${_CWF}_FORMAT?= ${${_CWT}_FORMAT} +${_CWT}-${_CWF}_FSLIST?= ${${_CWT}_FSLIST} +${_CWT}-${_CWF}_DESC?= ${${_CWT}_DESC} +. endfor +. else +CLOUDWARE_GEN+= ${_CWT} +. endif +.endfor +CLOUDWARE?= ${CLOUDWARE_GEN} + .for _V in TYPE BRANCH REVISION . if !defined(${_V}) || empty(${_V}) ${_V}!= eval $$(awk '/^${_V}=/{print}' ${.CURDIR}/../sys/conf/newvers.sh); echo $$${_V} From nobody Tue Oct 3 17:28:41 2023 X-Original-To: dev-commits-src-branches@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 4S0Ptd6Krmz4vm8D; Tue, 3 Oct 2023 17:28: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0Ptd2vQ3z4KZS; Tue, 3 Oct 2023 17:28:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696354121; 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=Z9MKB/gdkJkUmS+XINyuVuqApocKyYNmS3Gjb6TfGaU=; b=snLWxEuozdZ+wlE/FqbynU5dTSbMaxjLQTHLaUD7sd1njvK5DAi1dbEYM9yrM0k7EPXEKY ZCa/UIZXX4DhB8jzhJ2EqS/LtORk5B7/d+ptDukni5KlrUl3KQiccwEPhWkem/+TJJLPfb ugAhQuo87cIP1xSRqQGz7afvyJFeL8r/YBGRXjYAaIaDBmzxpBNdE34AYds7R6040WJrQC /pjzmNf36uhzhPnab+jKrSGq1XBgeqjq8DYvlkRwhEjXCbThEtXGUjPyvGNF0gf0MZ5dsx 49osTNo+0Q9S8GD1Hcaikir7HEiUiVqYEeFuh5ouAWr8x2Cnlvy8lHtCB2gP1A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696354121; a=rsa-sha256; cv=none; b=ivok6vYSBmnRax4Zyyo4VUcQWU/lbRUc0QNJKvdiSYzam5UGyEBkL4s8RJTD29IqJXg3SI k6RU8QbTNhZxmWPWOlhfRKb8zdok7xKEwMk2qmmnDqleP+Rp+phNFQgV1GGMWrkfdoH5CG AXhHidzOTwtNcJ1RUsBfYG2KyB7/u+ZHkKqSLhrGmhP6BO/NNrK9gi0PkvDG/zJ6YXIuJp mT43WfeN5Up29MYxF4As/Z0Ke2IglfWBYWlFzdY6RT6qYVf7CHgG662WZHopbEYQszPrUH wgDF7K2hek26bwpW95EZ6IByd0pt93oWAbBJY1srx0U+XsTwtAzZOpWywgcxsg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696354121; 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=Z9MKB/gdkJkUmS+XINyuVuqApocKyYNmS3Gjb6TfGaU=; b=xaqy3XX+mVbyousnukIX/iNuA7Ri0m5yvVUnmaOc1gfdLROeV/D3gD8QaefBXwk6mCwm5S uDLtZ7r0ApX3Rx3z6toTJJfuOJdMBT9FR8lPbqDGHvewWmEJQrQRvlshZtiavTRqdUttRW En7X/GTL+I7ANqsnO+uAt+n3CWl0/L6YKp/gaudQ8tNYBYNbBJabrbNYoVABlFlqUHwSiu 4LatdDCsFIy5zbLnO32Tc37b75grG00kaP4OKPuHXHpuZ9thTSiwJezJQBqYTRu81rY0dO WAvUcr5PcPx+AbQAZVyEQIBkZmavpTXyDYu/1D7KsqyIOeI8sLf56al9/hnn5Q== 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 4S0Ptd1ybPz13Fl; Tue, 3 Oct 2023 17:28:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393HSf7T085575; Tue, 3 Oct 2023 17:28:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393HSfCb085572; Tue, 3 Oct 2023 17:28:41 GMT (envelope-from git) Date: Tue, 3 Oct 2023 17:28:41 GMT Message-Id: <202310031728.393HSfCb085572@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: a18905a9bfcc - stable/14 - EC2: Flavour existing AMIs as "base" List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: a18905a9bfccc962f67b8a6067e7cbd4eb2bba17 Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=a18905a9bfccc962f67b8a6067e7cbd4eb2bba17 commit a18905a9bfccc962f67b8a6067e7cbd4eb2bba17 Author: Colin Percival AuthorDate: 2023-09-09 00:51:57 +0000 Commit: Colin Percival CommitDate: 2023-10-03 17:28:18 +0000 EC2: Flavour existing AMIs as "base" Using the recently-added "cloudware flavours" mechanism, turn the existing EC2 AMIs into a new "base" flavour. The only user-visible change is that AMI names now include the word "base". releng/14.0 candidate. Discussed with: gjb Reviewed by: imp MFC after: 5 days Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D41791 (cherry picked from commit 7494fb6b7d809257d4eb9eff06ce226143f27add) --- release/Makefile.ec2 | 16 +++++++++------- release/Makefile.vm | 1 + release/tools/{ec2.conf => ec2-base.conf} | 0 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/release/Makefile.ec2 b/release/Makefile.ec2 index b3f32d0e3efb..c674c967ff57 100644 --- a/release/Makefile.ec2 +++ b/release/Makefile.ec2 @@ -51,11 +51,12 @@ cw-ec2-portinstall: @touch ${.TARGET} .for _FS in ${EC2_FSLIST} +.for _FL in ${EC2_FLAVOURS:tl} .if defined(SSMPREFIX) && !empty(SSMPREFIX) -SSMOPTS_${_FS}= --ssm-name ${SSMPREFIX}/${TARGET_ARCH:S/aarch64/arm64/}/base/${_FS}/${REVISION}/${BRANCH} +SSMOPTS_${_FL}_${_FS}= --ssm-name ${SSMPREFIX}/${TARGET_ARCH:S/aarch64/arm64/}/${_FL}/${_FS}/${REVISION}/${BRANCH} .endif -EC2AMILIST+= ec2ami-${_FS} -ec2ami-${_FS}: cw-ec2-${_FS} ${CW_EC2_PORTINSTALL} +EC2AMILIST+= ec2ami-${_FL}-${_FS} +ec2ami-${_FL}-${_FS}: cw-ec2-${_FL}-${_FS} ${CW_EC2_PORTINSTALL} .if !defined(AWSKEYFILE) || !exists(${AWSKEYFILE}) @echo "--------------------------------------------------------------" @echo ">>> AWSKEYFILE must point at AWS keys for EC2 AMI creation" @@ -75,14 +76,15 @@ ec2ami-${_FS}: cw-ec2-${_FS} ${CW_EC2_PORTINSTALL} @false .endif /usr/local/bin/bsdec2-image-upload ${PUBLISH} ${PUBLICSNAP} \ - ${EC2ARCH} ${SSMOPTS_${_FS}} ${BOOTMODEOPT} --sriov --ena \ - ${.OBJDIR}/${EC2${_FS:tu}IMAGE} \ - "${TYPE} ${REVISION}-${BRANCH}-${TARGET}${AMINAMESUFFIX} ${AMIBOOTMETHOD} ${_FS:tu}" \ + ${EC2ARCH} ${SSMOPTS_${_FL}_${_FS}} ${BOOTMODEOPT} --sriov --ena \ + ${.OBJDIR}/${EC2-${_FL:tu}${_FS:tu}IMAGE} \ + "${TYPE} ${REVISION}-${BRANCH}-${TARGET}${AMINAMESUFFIX} ${AMIBOOTMETHOD} ${_FL} ${_FS:tu}" \ "${TYPE}/${TARGET} ${GITBRANCH}@${GITREV}" \ ${AWSREGION} ${AWSBUCKET} ${AWSKEYFILE} \ ${EC2SNSTOPIC} ${EC2SNSREL} ${EC2SNSVERS} @touch ${.TARGET} .endfor +.endfor -ec2ami: ec2ami-${VMFS} +ec2ami: ec2ami-base-${VMFS} ec2amis: ${EC2AMILIST} diff --git a/release/Makefile.vm b/release/Makefile.vm index e7ff86c28df3..8828b99599e7 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -31,6 +31,7 @@ BASIC-CI_DESC= Image for CI EC2_FORMAT= raw EC2_FSLIST= ufs zfs EC2_DESC= Amazon EC2 image +EC2_FLAVOURS= BASE GCE_FORMAT= raw GCE_FSLIST= ufs GCE_DESC= Google Compute Engine image diff --git a/release/tools/ec2.conf b/release/tools/ec2-base.conf similarity index 100% rename from release/tools/ec2.conf rename to release/tools/ec2-base.conf From nobody Tue Oct 3 17:28:42 2023 X-Original-To: dev-commits-src-branches@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 4S0Ptf4HrVz4vmH8; Tue, 3 Oct 2023 17:28: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0Ptf44GHz4KwG; Tue, 3 Oct 2023 17:28:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696354122; 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=UZx8YS8XpLNcoWNqZxQuGwDqtvelS3BO4w6afNPkNLc=; b=neImuwvlwAc/a4/h9Tzi8o8TnFTXkGJMIIgyr3NCdkEZzRnfmV45I+PazyuWCEKJ7cfb4L diry0aqdao7bD+4fCdGa4nDylI2i+mfEIMdKORndIUxn87ZhGA4O5VqJ3x40hLOh9IgSjR U+YV1q1weaUpNJMO2VhLBjdtqFprf7KBFeVuxUfzVsI4BY9CslArvT3jYsHkeGdKo128s9 r17H/LF9ies4SItStUaf9qarNf1kYuvppjUfC5k997Ik+pM6RbsPhSbGBSLzFcY1QKl07Q 8NgfRxNNl21CIvqfxCHzPkBhKemgNgdDi/TInO3ACNZLZTVN3WvxgHjYtgp8Ow== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696354122; a=rsa-sha256; cv=none; b=pBBBkf/X3x3b9DJf2s69XmdvkWaHMXHc+gGTl/x38VtANS4Kt2zpw+P4FmId9Qt5vFL8vZ HKqWRrfnIj4GcTpZrtwKQ+1oqGKinRZ0+kip3dcSNC/Vhl75UPbnktLn7a2bQq+X1fLRBw O/1SQ02FuxdcWkTv2DnhfcCqUEzjrnDT7Z9veNHi3qLjYgjAyY2mJD3uSvA0vhKNIQZlOr I6nd1/0J8SeUQGohPSjxEsrwqGog8qCBTmt6WgrMgdMCU24o7B2qp/0zqa5gjTxUBuMdna PstjOgo0kEPlHb3CazMtFh40trteoWAw2GQapcu28HOz5S/ThpKsAiqN/5rO3w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696354122; 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=UZx8YS8XpLNcoWNqZxQuGwDqtvelS3BO4w6afNPkNLc=; b=IqrZ4SYCNextRapDXyzEqUMLa4foCHc6Yp/oqk+P1nA4JNNUpqewEkdtof7DKofhpuZnOe 3dnyK4xQXbswKqu81ac2KHNS+xQiuE3ChL9ULbkVTzW60JGSWl+plPIRNVm/5CazO1wkW7 NxUUAcbGS44tGnYFAd5jVJJa4EBw1k1AC+blboYlKHZAO/b7djjPnFdhx3m/QzN4aqBE+V i0PsZ0JDHEjQn4dQtWcR0wjUOhAE6WS24XrU8xk/Xg98t7j8MJhjibmmjcNaWDxpXh1aNU RuzlVqRZJ/LAhQ/g5abBM9p7q0HPKDVgIU/JDwsUFIcRxBHNKlDHD403fLLrDA== 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 4S0Ptf2kv5z13q2; Tue, 3 Oct 2023 17:28:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393HSgif085626; Tue, 3 Oct 2023 17:28:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393HSgsv085623; Tue, 3 Oct 2023 17:28:42 GMT (envelope-from git) Date: Tue, 3 Oct 2023 17:28:42 GMT Message-Id: <202310031728.393HSgsv085623@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: f4576ea0d5bc - stable/14 - EC2: Split off reusable configuration bits List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: f4576ea0d5bcc26d8ffdf033cab36c651a5f0885 Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=f4576ea0d5bcc26d8ffdf033cab36c651a5f0885 commit f4576ea0d5bcc26d8ffdf033cab36c651a5f0885 Author: Colin Percival AuthorDate: 2023-09-09 00:54:11 +0000 Commit: Colin Percival CommitDate: 2023-10-03 17:28:18 +0000 EC2: Split off reusable configuration bits Split ec2-base.conf into ec2-base.conf and a reusable ec2.conf, similar to how Vagrant flavours share a common vagrant.conf. releng/14.0 candidate. Discussed with: gjb MFC after: 5 days Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D41792 (cherry picked from commit fada6e2389fb62ff621a98fab7319e426da58b0b) --- release/tools/ec2-base.conf | 161 ++++++-------------------------------------- release/tools/ec2.conf | 111 ++++++++++++++++++++++++++++++ 2 files changed, 130 insertions(+), 142 deletions(-) diff --git a/release/tools/ec2-base.conf b/release/tools/ec2-base.conf index d033739adc26..f4c46fe285cd 100644 --- a/release/tools/ec2-base.conf +++ b/release/tools/ec2-base.conf @@ -1,78 +1,36 @@ #!/bin/sh -# -# -# Packages to install into the image we're creating. This is a deliberately -# minimalist set, providing only the packages necessary to bootstrap further -# package installation as specified via EC2 user-data. -export VM_EXTRA_PACKAGES="${VM_EXTRA_PACKAGES} ec2-scripts \ - firstboot-freebsd-update firstboot-pkgs isc-dhcp44-client \ - ebsnvme-id" - -# Include the amazon-ssm-agent package in amd64 images, since some users want -# to be able to use it on systems which are not connected to the Internet. -# (It is not enabled by default, however.) This package does not exist for -# aarch64, so we have to be selective about when we install it. -if [ "${TARGET_ARCH}" = "amd64" ]; then - export VM_EXTRA_PACKAGES="${VM_EXTRA_PACKAGES} amazon-ssm-agent" -fi - -# Set to a list of third-party software to enable in rc.conf(5). -export VM_RC_LIST="ec2_configinit ec2_fetchkey ec2_loghostkey firstboot_freebsd_update firstboot_pkgs ntpd dev_aws_disk ec2_ephemeral_swap" +. ${WORLDDIR}/release/tools/ec2.conf -# Build with a 4.9 GB partition; the growfs rc.d script will expand -# the partition to fill the root disk after the EC2 instance is launched. -# Note that if this is set to G, we will end up with an GB disk -# image since VMSIZE is the size of the filesystem partition, not the disk -# which it resides within. -export VMSIZE=5000m +# Packages to install into the image we're creating. In addition to packages +# present on all EC2 AMIs, we install: +# * ec2-scripts, which provides a range of EC2ification startup scripts, +# * firstboot-freebsd-update, to install security updates at first boot, +# * firstboot-pkgs, to install packages at first boot, and +# * isc-dhcp44-client, used for IPv6 network setup. +export VM_EXTRA_PACKAGES="${VM_EXTRA_PACKAGES} ec2-scripts \ + firstboot-freebsd-update firstboot-pkgs isc-dhcp44-client" -# No swap space; the ec2_ephemeralswap rc.d script will allocate swap -# space on EC2 ephemeral disks. (If they exist -- the T2 low-cost instances -# and the C4 compute-optimized instances don't have ephemeral disks. But -# it would be silly to bloat the image and increase costs for every instance -# just for those two families, especially since instances ranging in size -# from 1 GB of RAM to 60 GB of RAM would need different sizes of swap space -# anyway.) -export NOSWAP=YES +# Services to enable in rc.conf(5). +export VM_RC_LIST="${VM_RC_LIST} ec2_configinit ec2_ephemeral_swap \ + ec2_fetchkey ec2_loghostkey firstboot_freebsd_update firstboot_pkgs \ + growfs sshd" vm_extra_pre_umount() { - # The firstboot_pkgs rc.d script will download the repository - # catalogue and install or update pkg when the instance first - # launches, so these files would just be replaced anyway; removing - # them from the image allows it to boot faster. - mount -t devfs devfs ${DESTDIR}/dev - chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \ - /usr/sbin/pkg delete -f -y pkg - umount ${DESTDIR}/dev - rm ${DESTDIR}/var/db/pkg/repo-*.sqlite - - # The size of the EC2 root disk can be configured at instance launch - # time; expand our filesystem to fill the disk. - echo 'growfs_enable="YES"' >> ${DESTDIR}/etc/rc.conf - - # EC2 instances use DHCP to get their network configuration. IPv6 - # requires accept_rtadv. - echo 'ifconfig_DEFAULT="SYNCDHCP accept_rtadv"' >> ${DESTDIR}/etc/rc.conf - - # Unless the system has been configured via EC2 user-data, the user - # will need to SSH in to do anything. - echo 'sshd_enable="YES"' >> ${DESTDIR}/etc/rc.conf - # The AWS CLI tools are generally useful, and small enough that they # will download quickly; but users will often override this setting # via EC2 user-data. echo 'firstboot_pkgs_list="devel/py-awscli"' >> ${DESTDIR}/etc/rc.conf + # EC2 instances use DHCP to get their network configuration. IPv6 + # requires accept_rtadv. + echo 'ifconfig_DEFAULT="SYNCDHCP accept_rtadv"' >> ${DESTDIR}/etc/rc.conf + # Enable IPv6 on all interfaces, and spawn DHCPv6 via rtsold echo 'ipv6_activate_all_interfaces="YES"' >> ${DESTDIR}/etc/rc.conf echo 'rtsold_enable="YES"' >> ${DESTDIR}/etc/rc.conf echo 'rtsold_flags="-M /usr/local/libexec/rtsold-M -a"' >> ${DESTDIR}/etc/rc.conf - # Turn off IPv6 Duplicate Address Detection; the EC2 networking - # configuration makes it unnecessary. - echo 'net.inet6.ip6.dad_count=0' >> ${DESTDIR}/etc/sysctl.conf - # Provide a script which rtsold can use to launch DHCPv6 mkdir -p ${DESTDIR}/usr/local/libexec cat > ${DESTDIR}/usr/local/libexec/rtsold-M <<'EOF' @@ -82,94 +40,13 @@ vm_extra_pre_umount() { EOF chmod 755 ${DESTDIR}/usr/local/libexec/rtsold-M - # The EC2 console is output-only, so while printing a backtrace can - # be useful, there's no point dropping into a debugger or waiting - # for a keypress. - echo 'debug.trace_on_panic=1' >> ${DESTDIR}/boot/loader.conf - echo 'debug.debugger_on_panic=0' >> ${DESTDIR}/boot/loader.conf - echo 'kern.panic_reboot_wait_time=0' >> ${DESTDIR}/boot/loader.conf - - # The console is not interactive, so we might as well boot quickly. - echo 'autoboot_delay="-1"' >> ${DESTDIR}/boot/loader.conf - echo 'beastie_disable="YES"' >> ${DESTDIR}/boot/loader.conf - - # Tell gptboot not to wait 3 seconds for a keypress which won't - # arrive either. - printf -- "-n\n" > ${DESTDIR}/boot.config - - # The emulated keyboard attached to EC2 instances is inaccessible to - # users, and there is no mouse attached at all; disable to keyboard - # and the keyboard controller (to which the mouse would attach, if - # one existed) in order to save time in device probing. - echo 'hint.atkbd.0.disabled=1' >> ${DESTDIR}/boot/loader.conf - echo 'hint.atkbdc.0.disabled=1' >> ${DESTDIR}/boot/loader.conf - - # EC2 has two consoles: An emulated serial port ("system log"), - # which has been present since 2006; and a VGA console ("instance - # screenshot") which was introduced in 2016. - echo 'boot_multicons="YES"' >> ${DESTDIR}/boot/loader.conf - - # Some older EC2 hardware used a version of Xen with a bug in its - # emulated serial port. It is not clear if EC2 still has any such - # nodes, but apply the workaround just in case. - echo 'hw.broken_txfifo="1"' >> ${DESTDIR}/boot/loader.conf - - # Load the kernel module for the Amazon "Elastic Network Adapter" - echo 'if_ena_load="YES"' >> ${DESTDIR}/boot/loader.conf - - # Use the "nda" driver for accessing NVMe disks rather than the - # historical "nvd" driver. - echo 'hw.nvme.use_nvd="0"' >> ${DESTDIR}/boot/loader.conf - - # Disable KbdInteractiveAuthentication according to EC2 requirements. - sed -i '' -e \ - 's/^#KbdInteractiveAuthentication yes/KbdInteractiveAuthentication no/' \ - ${DESTDIR}/etc/ssh/sshd_config - - # Use FreeBSD Update mirrors hosted in AWS - sed -i '' -e 's/update.FreeBSD.org/aws.update.FreeBSD.org/' \ - ${DESTDIR}/etc/freebsd-update.conf - - # Use the NTP service provided by Amazon - sed -i '' -e 's/^pool/#pool/' \ - -e '1,/^#server/s/^#server.*/server 169.254.169.123 iburst/' \ - ${DESTDIR}/etc/ntp.conf - - # Provide a map for accessing Elastic File System mounts - cat > ${DESTDIR}/etc/autofs/special_efs <<'EOF' -#!/bin/sh - -if [ $# -eq 0 ]; then - # No way to know which EFS filesystems exist and are - # accessible to this EC2 instance. - exit 0 -fi - -# Provide instructions on how to mount the requested filesystem. -FS=$1 -REGION=`fetch -qo- http://169.254.169.254/latest/meta-data/placement/availability-zone | sed -e 's/[a-z]$//'` -echo "-nfsv4,minorversion=1,oneopenown ${FS}.efs.${REGION}.amazonaws.com:/" -EOF - chmod 755 ${DESTDIR}/etc/autofs/special_efs - - # The first time the AMI boots, the installed "first boot" scripts - # should be allowed to run: - # * ec2_configinit (download and process EC2 user-data) - # * ec2_fetchkey (arrange for SSH using the EC2-provided public key) - # * growfs (expand the filesystem to fill the provided disk) - # * firstboot_freebsd_update (install critical updates) - # * firstboot_pkgs (install packages) - touch ${DESTDIR}/firstboot - # Any EC2 ephemeral disks seen when the system first boots will # be "new" disks; there is no "previous boot" when they might have # been seen and used already. touch ${DESTDIR}/var/db/ec2_ephemeral_diskseen - if ! [ -z "${QEMUSTATIC}" ]; then - rm -f ${DESTDIR}/${EMULATOR} - fi - rm -f ${DESTDIR}/etc/resolv.conf + # Configuration common to all EC2 AMIs + ec2_common return 0 } diff --git a/release/tools/ec2.conf b/release/tools/ec2.conf new file mode 100644 index 000000000000..a233bf5981c1 --- /dev/null +++ b/release/tools/ec2.conf @@ -0,0 +1,111 @@ +#!/bin/sh + +# Packages which should be installed onto all EC2 AMIs: +# * ebsnvme-id, which is very minimal and provides important EBS-specific +# functionality, +# * amazon-ssm-agent (not enabled by default, but some users need to use +# it on systems not connected to the internet). +export VM_EXTRA_PACKAGES="${VM_EXTRA_PACKAGES} ebsnvme-id amazon-ssm-agent" + +# Services which should be enabled by default in rc.conf(5). +export VM_RC_LIST="dev_aws_disk ntpd" + +# Build with a 4.9 GB partition; the growfs rc.d script will expand +# the partition to fill the root disk after the EC2 instance is launched. +# Note that if this is set to G, we will end up with an GB disk +# image since VMSIZE is the size of the filesystem partition, not the disk +# which it resides within. +export VMSIZE=5000m + +# No swap space; it doesn't make sense to provision any as part of the disk +# image when we could be launching onto a system with anywhere between 0.5 +# and 4096 GB of RAM. +export NOSWAP=YES + +ec2_common() { + # Delete the pkg package and the repo database; they will likely be + # long out of date before the EC2 instance is launched. + mount -t devfs devfs ${DESTDIR}/dev + chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \ + /usr/sbin/pkg delete -f -y pkg + umount ${DESTDIR}/dev + rm ${DESTDIR}/var/db/pkg/repo-*.sqlite + + # Turn off IPv6 Duplicate Address Detection; the EC2 networking + # configuration makes it unnecessary. + echo 'net.inet6.ip6.dad_count=0' >> ${DESTDIR}/etc/sysctl.conf + + # Booting quickly is more important than giving users a chance to + # access the boot loader via the serial port. + echo 'autoboot_delay="-1"' >> ${DESTDIR}/boot/loader.conf + echo 'beastie_disable="YES"' >> ${DESTDIR}/boot/loader.conf + + # Tell gptboot not to wait 3 seconds for a keypress which will + # never arrive. + printf -- "-n\n" > ${DESTDIR}/boot.config + + # The emulated keyboard attached to EC2 instances is inaccessible to + # users, and there is no mouse attached at all; disable to keyboard + # and the keyboard controller (to which the mouse would attach, if + # one existed) in order to save time in device probing. + echo 'hint.atkbd.0.disabled=1' >> ${DESTDIR}/boot/loader.conf + echo 'hint.atkbdc.0.disabled=1' >> ${DESTDIR}/boot/loader.conf + + # EC2 has two consoles: An emulated serial port ("system log"), + # which has been present since 2006; and a VGA console ("instance + # screenshot") which was introduced in 2016. + echo 'boot_multicons="YES"' >> ${DESTDIR}/boot/loader.conf + + # Some older EC2 hardware used a version of Xen with a bug in its + # emulated serial port. It is not clear if EC2 still has any such + # nodes, but apply the workaround just in case. + echo 'hw.broken_txfifo="1"' >> ${DESTDIR}/boot/loader.conf + + # Load the kernel module for the Amazon "Elastic Network Adapter" + echo 'if_ena_load="YES"' >> ${DESTDIR}/boot/loader.conf + + # Use the "nda" driver for accessing NVMe disks rather than the + # historical "nvd" driver. + echo 'hw.nvme.use_nvd="0"' >> ${DESTDIR}/boot/loader.conf + + # Disable KbdInteractiveAuthentication according to EC2 requirements. + sed -i '' -e \ + 's/^#KbdInteractiveAuthentication yes/KbdInteractiveAuthentication no/' \ + ${DESTDIR}/etc/ssh/sshd_config + + # Use FreeBSD Update mirrors hosted in AWS + sed -i '' -e 's/update.FreeBSD.org/aws.update.FreeBSD.org/' \ + ${DESTDIR}/etc/freebsd-update.conf + + # Use the NTP service provided by Amazon + sed -i '' -e 's/^pool/#pool/' \ + -e '1,/^#server/s/^#server.*/server 169.254.169.123 iburst/' \ + ${DESTDIR}/etc/ntp.conf + + # Provide a map for accessing Elastic File System mounts + cat > ${DESTDIR}/etc/autofs/special_efs <<'EOF' +#!/bin/sh + +if [ $# -eq 0 ]; then + # No way to know which EFS filesystems exist and are + # accessible to this EC2 instance. + exit 0 +fi + +# Provide instructions on how to mount the requested filesystem. +FS=$1 +REGION=`fetch -qo- http://169.254.169.254/latest/meta-data/placement/availability-zone | sed -e 's/[a-z]$//'` +echo "-nfsv4,minorversion=1,oneopenown ${FS}.efs.${REGION}.amazonaws.com:/" +EOF + chmod 755 ${DESTDIR}/etc/autofs/special_efs + + # The first time the AMI boots, run "first boot" scripts. + touch ${DESTDIR}/firstboot + + if ! [ -z "${QEMUSTATIC}" ]; then + rm -f ${DESTDIR}/${EMULATOR} + fi + rm -f ${DESTDIR}/etc/resolv.conf + + return 0 +} From nobody Tue Oct 3 17:28:43 2023 X-Original-To: dev-commits-src-branches@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 4S0Ptg5Gj8z4vmKh; Tue, 3 Oct 2023 17:28: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0Ptg4Jqrz4L59; Tue, 3 Oct 2023 17:28:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696354123; 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=5h8lbvQW9RHSTkMww4l4OTvxnPosv6dmjnizcfrgoRA=; b=P560mI/G/+aAU0KYhtoQbBo/jjHltDYZvPk4SDZGiWP0fzzp4LTNOz55zifvezwR3YzA58 qUm4uaJQ3hdgmBIWMpVOMihtUwpstbgj1a44H/Jby01Syau2RLYhKyY/zIlsK+G48T7jyH tSSJoYqMTv1WX8DiF3T+J17mcB2YyUpNESnXW5gdOJKW55jHNb4ioOK/IziBeY9VH12WJF 9FcrqALlDzzyP6bw9uPqMh+VbCvck86c5kV8i9M3gd+0vfYDI3QAoAiDcoWoNG3MztoXsx g6Q5Pw518/YnIaI2W1E/nO4q38xc3dJQNBPB5AhbDRH3zqhOWcBzAYe5YgnhOQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696354123; a=rsa-sha256; cv=none; b=TmKZbqw6OcIyN0cP72UcvhDEFdWYO2YtSpOvMm/uSHYnOvOPtYz31iauWkNpZPRSHDTXBm 7FiidxjMoekBmCXs3ElgWbgzI0k5AUqn73nBpmUP3IQjh6NMfvRB24MJREs7o16WyNW8PK hWG09JhWHuD4eq66Jg3dJHxL/fyC8J6Bzrs504Q9tBRygyiCMTjgNs8eQfZRsCa2ZfVVBb 40TSecB1sR9zX5kiegjJqlDbqrpBldl9jaSaKWdKfZK7cF3pYnRGEBEofczHSkSFmbJd02 flt4J1pp1Z26VQTi2xg4Dsv7PeuIBraxnRkB00BZlrcGIqB+QocTMy54EMPSHg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696354123; 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=5h8lbvQW9RHSTkMww4l4OTvxnPosv6dmjnizcfrgoRA=; b=bby9iGzjYIfgtOE0GMsvZVhRnNS8utFEUnnCXLWrJvbmIdy9VBdfmifVAaawS74y9+0Aqe DjUzwGqIJghbj3zf/56izUeK/5CqxBfKwHqolOerQI16L/HRbIH/aKUH+joH0hSGHzSS89 CcdIBjz+Qo0EwPadGRIBLjtrQLrGwtZhFgqJ30xSwtd3Bp8LePxk79LQy9TGWZMSNGmPRp sjvqf82lO/ZQDS0kbb8Vi6XnBiM3V03Hrxw4wRHjo3ubZdzgH6Ka0U5ubc367ddVRxM9dp tKv1SRGGrN4pnzqo43nvTtOI2MTxeFFFn4CeRylR/ILQPiQuqLjXYiXcOQSp3A== 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 4S0Ptg3L7Wz13s7; Tue, 3 Oct 2023 17:28:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393HShIc085669; Tue, 3 Oct 2023 17:28:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393HShbV085666; Tue, 3 Oct 2023 17:28:43 GMT (envelope-from git) Date: Tue, 3 Oct 2023 17:28:43 GMT Message-Id: <202310031728.393HShbV085666@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: d9243c1ab3cd - stable/14 - EC2: Add experimental cloud-init images List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: d9243c1ab3cd8e744aaf54177232cdbffa07392d Auto-Submitted: auto-generated The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=d9243c1ab3cd8e744aaf54177232cdbffa07392d commit d9243c1ab3cd8e744aaf54177232cdbffa07392d Author: Colin Percival AuthorDate: 2023-09-09 00:55:16 +0000 Commit: Colin Percival CommitDate: 2023-10-03 17:28:18 +0000 EC2: Add experimental cloud-init images Known issues: 1. The ec2-user user is created with a homedir of /usr/home/ec2-user instead of /home/ec2-user; this appears to be a bug in cloud-init's FreeBSD support. 2. Cloud-init configures IPv4 networking but not IPv6 networking. releng/14.0 candidate. Discussed with: gjb Reviewed by: imp MFC after: 5 days Relnotes: yes Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D41793 (cherry picked from commit 1f4ce7a39f0f4b0621ff55d228014ccddb366d37) --- release/Makefile.vm | 5 +++-- release/tools/ec2-cloud-init.conf | 31 +++++++++++++++++++++++++++++++ 2 files changed, 34 insertions(+), 2 deletions(-) diff --git a/release/Makefile.vm b/release/Makefile.vm index 8828b99599e7..09e31e3c0b6f 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -30,8 +30,9 @@ BASIC-CI_FSLIST= ufs BASIC-CI_DESC= Image for CI EC2_FORMAT= raw EC2_FSLIST= ufs zfs -EC2_DESC= Amazon EC2 image -EC2_FLAVOURS= BASE +EC2_FLAVOURS= BASE CLOUD-INIT +EC2-BASE_DESC= Amazon EC2 image +EC2-CLOUD-INIT_DESC= Amazon EC2 Cloud-Init image GCE_FORMAT= raw GCE_FSLIST= ufs GCE_DESC= Google Compute Engine image diff --git a/release/tools/ec2-cloud-init.conf b/release/tools/ec2-cloud-init.conf new file mode 100644 index 000000000000..2dd4df390fa3 --- /dev/null +++ b/release/tools/ec2-cloud-init.conf @@ -0,0 +1,31 @@ +#!/bin/sh + +. ${WORLDDIR}/release/tools/ec2.conf + +# Packages to install into the image we're creating. In addition to packages +# present on all EC2 AMIs, we install cloud-init. +export VM_EXTRA_PACKAGES="${VM_EXTRA_PACKAGES} net/cloud-init" + +# Services to enable in rc.conf(5). +export VM_RC_LIST="${VM_RC_LIST} cloudinit sshd" + +vm_extra_pre_umount() { + # Configuration common to all EC2 AMIs + ec2_common + + # Configure cloud-init + cat <<-'EOF' > ${DESTDIR}/usr/local/etc/cloud/cloud.cfg.d/98_ec2.cfg + disable_root: true + system_info: + distro: freebsd + default_user: + name: ec2-user + lock_passwd: True + groups: [wheel] + shell: /bin/sh + # Currently broken, cloud-init hard-codes to /usr/home/* + homedir: /home/ec2-user + EOF + + return 0 +} From nobody Tue Oct 3 17:54:25 2023 X-Original-To: dev-commits-src-branches@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 4S0QSK3q8vz4vn8H; Tue, 3 Oct 2023 17:54: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0QSK3Bgjz4NXk; Tue, 3 Oct 2023 17:54:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696355665; 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=vXxiQxMPH3WID9q6EsJUg+u0SbjHTP2fNXclRTTkJ9Y=; b=jPkvfe6paJ3mdGqdNkakfM21MXEDDQTUOrwgmlwsicv212Mwou+Z/Jza6rfZ7619qrnUko TfzVcRLevpkUYz+6GTlRly6qqT2lPBMaGvFBOVy7qAhfYLalviZhRCrNmX7moXiX7Md9YF pui0r+rvmewlqGktDupUZgPXGLXCfza2W+lsIzZE6u2qMBRKtMR7MM8+YXjz5BTrZQkarL 3iPbLPwOhlmVbXD6jXb09asZvsYTdx4WqO8AM2nVraeIyuu24OEPt/lGA4idLaGlD0XDS7 OlCn4n3z5nATsA+iLnbDoMVvutV8HOrQGmDWPLiVle7jM2vXbhq0mPHrUSCK8A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696355665; a=rsa-sha256; cv=none; b=S9HlHgXlONnz7ke1o3pA6s1y+gA+risKfaRItARA2sE95a9wkBuUOVpRgVUis/MNvpWTm/ QC1gGpVeTxxImce+fykKttzaxif3106vnpyK0YdfheXUbGcxYqGAikwrELE8XRUUP2Aorx f048fbychU8HHzZ5ayTwmEdfyNVdo1F5a1W1ZIA92r3+IFnH2wLsHVsjxWASAmGjEKzGnq oH3AHskPXNgh8dzAB5qEhyRF/teBGC4WvqZwOiel5LtycAd5k9MOvOcblvt6RNK45AHajF 0ctHT8Lp8vwwtyFdAatXvyfDO4TTJn9wCDBcVUGAgnFQPj49ZyZeEBeIuxlAIA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696355665; 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=vXxiQxMPH3WID9q6EsJUg+u0SbjHTP2fNXclRTTkJ9Y=; b=fwP6tWHB3+5s7tA1xHezWRhdwKoeLvv+svjjcOFGW21cGdOQakFlwVrWMks/CfARp4F1HV dqTcN8PMwgc6fK0XLq1tPsjL6psMvC6ieOQ4xOGUIinUkh6VKWbjzY9Jhhh5WSwhfHHoNf JgK+gyxJuo4BC5muA1iz2hRqgQtCQsbQd2bgr8CBsUh4I0fvVgik+0eb3Tcc6JPclhXmnS MyUW8zTFU2Q+UpCMplu3qfLuQY/InTINp6g4dP97ZQVP9Lp8sgHXWc37exQ3MBCu2Z1et2 E9SlbJL6Z9G0XL2Ey8Qsihdyfbyn/tMvEAjuRXpX0V2YOlfXjHGR+jlH7EiXwA== 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 4S0QSK2FHJz14HJ; Tue, 3 Oct 2023 17:54:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393HsPGT034954; Tue, 3 Oct 2023 17:54:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393HsP0B034951; Tue, 3 Oct 2023 17:54:25 GMT (envelope-from git) Date: Tue, 3 Oct 2023 17:54:25 GMT Message-Id: <202310031754.393HsP0B034951@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: 2d5eb9b95a9d - stable/14 - ObsoleteFiles: remove duplicated and incorrect libclang_rt powerpc64le entries List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: 2d5eb9b95a9d99c0a80994fc932f6ad0589f69ed Auto-Submitted: auto-generated The branch stable/14 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=2d5eb9b95a9d99c0a80994fc932f6ad0589f69ed commit 2d5eb9b95a9d99c0a80994fc932f6ad0589f69ed Author: Dimitry Andric AuthorDate: 2023-09-29 18:41:52 +0000 Commit: Dimitry Andric CommitDate: 2023-10-03 17:53:44 +0000 ObsoleteFiles: remove duplicated and incorrect libclang_rt powerpc64le entries PR: 273776 MFC after: 3 days (cherry picked from commit e2d3168d1207561df2e1cf0a2a8d13c198e5f8d3) --- ObsoleteFiles.inc | 2 -- 1 file changed, 2 deletions(-) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index df9d286cd039..589f6b968e9d 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -442,8 +442,6 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64le.a -OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64le.a -OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64lele.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.safestack-aarch64.a From nobody Tue Oct 3 17:58:09 2023 X-Original-To: dev-commits-src-branches@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 4S0QXd2NN3z4vnLj; Tue, 3 Oct 2023 17:58: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0QXd1vCWz4Psk; Tue, 3 Oct 2023 17:58:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696355889; 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=I19ZkBiUPT+Uyarf2bXZmuUrX5pkGsBx4MJO2LLoF8Q=; b=SFFXmIKrSRW4WLozfssu4gCd8PpvU/yTOMChbKGnig7eega2CaMtKHBR5QjrpFfwjOj87P BzhFxIMhrzVPAdn3xFx7EoZBGhd6nekBsb5RQPhOalEkM3SsZzGFlrvWpmvkFajwznqn5h T4/mHbuAuMBoN2CD/u/OkD4kyvVrYB6U1aR+LyKfGWLBlzJKs+CQv7Sp5GQIu15CDYJro7 oXKnm5zp8nMO1GDhBTZLdd9ksiOTp9l0S4s2pXi9lmwEiykBwyNmCbuL0HsoPHSiYg/Kui /eGswP+sasyDn74sAedb6v82VJ/7/ZA76RDzUVrkh6YiuqhaY5/UxIhRpDE4ag== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696355889; a=rsa-sha256; cv=none; b=nQZkqRCCk/ccVjuhXxEvzl1bkEQPCAaUI5MzVkRIm8vrfy4NfZq5t5CGHepQJy8OBusbYp a4LFtPHGVUAnLYDuHQnYgSl4HoEQZAqaaSrGEbynsE3tzJfRiKcpzLmyMUAWKh5gP0cbRT Yl10K559SpVVxJSP6gkKXpsROqDfovhoeaInQPEt76UtVz6JiXd9dOq2lVqVcQda61mnnD uXm2mTw5bM5X2mEQ+9z9YAehcHjngY81GWxchszh1JcIdOR5NSiIs8di7Ctmgtm2LogXuX qXCM0tXD6tDBA5FqJqpUlpOpQS7pm2sJjnK0+OF4NzAuv7lNErfVjBJbSBMDPA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696355889; 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=I19ZkBiUPT+Uyarf2bXZmuUrX5pkGsBx4MJO2LLoF8Q=; b=cSW08jZtOzobRbhIOEVwObp9bcadX65EtdqbHkpUrmqj6SF3WoC28UtKYBurnAUHcJkJ3R +fv9JsGvZNQkzGD2/1qMLH3eVthPKre45uXgT2lo/hYZopeMX6R+7etpvZxZnO30lfI3RI IsQ05EfNguUEfkjsqq3RV8TJ3OpWKVrYYwiCg7LVIhxG/GLKgHFUh9f1OSwdGwG4FYNHyz 0H5UPreMcGk8YvTKhz367t0vk2CpNWhwmkqQR8uBW2UV3Dn3IRrTk+ScQ1woTsF+E6ZbqK FKVdxI+KDcOqK0FD2oZV4XCsyzF33V+ABf6OgvU6rp/l8M3lJA78NJnK1bTtiQ== 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 4S0QXd0z8Sz14QV; Tue, 3 Oct 2023 17:58:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393Hw9iZ035600; Tue, 3 Oct 2023 17:58:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393Hw9rW035597; Tue, 3 Oct 2023 17:58:09 GMT (envelope-from git) Date: Tue, 3 Oct 2023 17:58:09 GMT Message-Id: <202310031758.393Hw9rW035597@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: 03b6464b29fe - stable/13 - ObsoleteFiles: remove duplicated and incorrect libclang_rt powerpc64le entries List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: 03b6464b29fe3687b17a7338a440f3bf6bd9251f Auto-Submitted: auto-generated The branch stable/13 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=03b6464b29fe3687b17a7338a440f3bf6bd9251f commit 03b6464b29fe3687b17a7338a440f3bf6bd9251f Author: Dimitry Andric AuthorDate: 2023-09-29 18:41:52 +0000 Commit: Dimitry Andric CommitDate: 2023-10-03 17:53:49 +0000 ObsoleteFiles: remove duplicated and incorrect libclang_rt powerpc64le entries PR: 273776 MFC after: 3 days (cherry picked from commit e2d3168d1207561df2e1cf0a2a8d13c198e5f8d3) --- ObsoleteFiles.inc | 2 -- 1 file changed, 2 deletions(-) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index 55e0645f2d3a..9fa227b121a9 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -355,8 +355,6 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64le.a -OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64le.a -OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64lele.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.safestack-aarch64.a From nobody Tue Oct 3 21:46:12 2023 X-Original-To: dev-commits-src-branches@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 4S0Wbm52X0z4w2bK; Tue, 3 Oct 2023 21:46:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0Wbm3SGLz4nht; Tue, 3 Oct 2023 21:46:12 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696369572; 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=U4I+KVoGjafDyDLFElG/SbvilUybYJChk1Ng1UzIXVA=; b=eYwkciy9gEzpvkxj0SwhkEeU9jf01ywdiakOSCYLB6w20SKRPxuTXGiDPHxitHG/JVshlU ha9970b88PRHhnlNillxry4xTeDr0lqiraTOY265N39lmksHZkenCJ3hf5ibAnmwg37xtm /J5EgMkQH2uWMY6i++X/maOcRTQfh2jEfBZP5whYjhVlCGl6n3kxs9V9kh5mycrGSqeynm EelZ9wyc0riV7aR6QGbNUUs+qLHyMsRq2BM4QwwAFFXv1muidKVocfXxzvvd0VKfLMZLjX fJ3rPHHjSMdE1PbWp5x9NYheauE8F+B6G+L1qB2gJ32eA6F6yIds7n/Ka8Rvsg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696369572; a=rsa-sha256; cv=none; b=P+l+M51/bQNwA6woB1AOobH+/+ogtDW1A+3pPjvFtJuQ1Zb9uHr3pBvmxjozli1wqNlDiN Ku/FFNHTGCdZp4hp9i4H1d/b6sdVHEj2/aJ2niOC0fCbeX83mIR9zJdvApxFIjgRyhKuVi GGItzvz/wP2jQRXJ8Vk8El4Kiv346GW+2npvQk/xYFfpnyRGOFKvjKFq5SYU1Fu8Si5/Cd 8tt1FobC6zNLwKYnpr9+pxuSr5QyebQF2L0xUtx+talXo9jAyGn7P6X1npN/jho+J3DXtV 14S0k0p+/CstBkfz3yUdiWyI3JWbuKFL/uugr3Hh52whtyGeVP2kF4Yz9emCXQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696369572; 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=U4I+KVoGjafDyDLFElG/SbvilUybYJChk1Ng1UzIXVA=; b=VgEzbMVoZgD7DoHHURW6+lxKBDx99pjPWljMgy1npyYE+8jPVUAX8vMCvGg3T/YVvnEEWa jwhvF3O00X1LP1hSrhtNnYAGcZze9WibPjfSPPs9noni56WsHl59Na99S+1zbA9pl86f0H +tDadm3AJnHkln9R+LYgRCf1brDTodYv6oarCx9hCu74ccDfIp87115GTq8Uk/0rFGZI37 cTL9adk5atBJ0p/EctIU0iyTgmPvlD+GGN+WhBaEHxX7NDujktk9fVldvuLKT13mAgInb1 aEVFWYKTWFFnW54id2tuhIR286IgPwiexFLk92Jq84I5X9z+YPWpvB1Ch76zGA== 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 4S0Wbm2YHNz19lW; Tue, 3 Oct 2023 21:46:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393LkCiB020525; Tue, 3 Oct 2023 21:46:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393LkCVM020522; Tue, 3 Oct 2023 21:46:12 GMT (envelope-from git) Date: Tue, 3 Oct 2023 21:46:12 GMT Message-Id: <202310032146.393LkCVM020522@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 1e766ebc27c6 - stable/13 - style.Makefile.5: Remove $FreeBSD$ from examples List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 1e766ebc27c6272b169c639c3574d69c4d3e5ab3 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=1e766ebc27c6272b169c639c3574d69c4d3e5ab3 commit 1e766ebc27c6272b169c639c3574d69c4d3e5ab3 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2023-07-17 13:01:52 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-03 21:46:05 +0000 style.Makefile.5: Remove $FreeBSD$ from examples MFC after: 3 days (cherry picked from commit 22faf70d7e137f39b6afe7da967679a7cdbe3507) --- share/man/man5/style.Makefile.5 | 4 ---- 1 file changed, 4 deletions(-) diff --git a/share/man/man5/style.Makefile.5 b/share/man/man5/style.Makefile.5 index b85fa763642e..a6162b0701eb 100644 --- a/share/man/man5/style.Makefile.5 +++ b/share/man/man5/style.Makefile.5 @@ -241,8 +241,6 @@ The simplest program .Pa Makefile is: .Bd -literal -offset indent -# $FreeBSD\&$ - PROG= foo \&.include @@ -252,8 +250,6 @@ The simplest library .Pa Makefile is: .Bd -literal -offset indent -# $FreeBSD\&$ - LIB= foo SHLIB_MAJOR= 1 MAN= libfoo.3 From nobody Tue Oct 3 21:46:13 2023 X-Original-To: dev-commits-src-branches@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 4S0Wbn589Nz4w2dZ; Tue, 3 Oct 2023 21:46:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0Wbn4Xtmz4nRk; Tue, 3 Oct 2023 21:46:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696369573; 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=AcXmHSnf2NDPhIagwEhBF3B8hhzXbaso47rUs6yRHk8=; b=ihNPb4QvV61S0irUKYwiS5GLQ7dV52aDL4JgywLTFKzbfHsu74J3WslOtvsKxu2OiDYeDL Re/wV2qy+/4D8swQR2ueLn1vBaps1cxeBMhps+za7dsofG4qNun2uG0bl5FlVcI75v5nOY Fld/sR3YnlPQok6xz3xkrcI58xlRMOVxcizT0F1cKAcZNfq2+bjiBbqv1pcJ5lxLx9eqk7 +bmJR6qotehJgjmdWD7o20y3M2Nrdm7MXoDG7bQCZJyI5vcfMzoPVvEMgAL9T3r+tQZsYB 9sCBER7+SUT5OY8SRqaqVeub6FXk4IH1xEPS6VM86J7PK0kjZmGJ9Y6+I69gQw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696369573; a=rsa-sha256; cv=none; b=Dq5D9RJbGpdl1kmjBP9s+KvvkrwqzznSuATgxdFwCtF9hklgJPUefuw0bVTXjjMHXHOyKH jYyVk8z701uI0a3eM4+8FwQLeOGINJ763taI71mfiABcGwnOaAkx0T4bM0DEH44CC8/Lhi 0HOCmvjCCnseOtjPVQanwARwyhAF/yBoKqG4DZ5RWpQoucx2AXxVyTNG/1GhLQmIl8nhYv TFqslRH4ZpPO63F0eyynCq2WehPwhGNNdMtnROEFGWK50j66Lid8StV8qL0W0GMtmncNcX FntxqbuCov7pK20VhKPnu1nkAiUPn+vLzo64VkadV9VVaqZvubMOM1YWO9dygw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696369573; 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=AcXmHSnf2NDPhIagwEhBF3B8hhzXbaso47rUs6yRHk8=; b=Z3Pt3QDxIUHJVLgYmHqnondk1Z8YcJl5L37ptuiSemvArKQAgr1FQCef7wukd7DgjET8Ne wrlvPcv7ca+l7/iuRL/AuA+ue9WkT7ZHFMPpG8P/t2a0bdGiuJiPRL1zOWaEQ1is1W4yTr 9FwEFueMxig8JXn86xSCMBpdPDP6OWAAlbtzF4eUqA0lYrF2Ca8j+EC2wqNsm1OVgTfowO RkurofToMqFgN46O2F1J8os4OAEWmwGdSG/hazIDHVJShNJg+aq7tsYSBEw7W3ey8ru/Vs U0+g+dRiIeIKUZ56paJLItG4ynb3Qq1/AU15NvL0yW1e4+SyLFCOlWyv/YLiWw== 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 4S0Wbn3YRpz19wS; Tue, 3 Oct 2023 21:46:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393LkDtO020574; Tue, 3 Oct 2023 21:46:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393LkDCn020571; Tue, 3 Oct 2023 21:46:13 GMT (envelope-from git) Date: Tue, 3 Oct 2023 21:46:13 GMT Message-Id: <202310032146.393LkDCn020571@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 8f9d8decd448 - stable/13 - style.Makefile.5: Wordsmith .PATH description List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 8f9d8decd448dc1d0102379bd429bb9726133e75 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=8f9d8decd448dc1d0102379bd429bb9726133e75 commit 8f9d8decd448dc1d0102379bd429bb9726133e75 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2023-07-17 13:06:02 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-03 21:46:05 +0000 style.Makefile.5: Wordsmith .PATH description MFC after: 3 days Fixes: 1ac5586c6d86 style.Makefile.5: Do not require $FreeBSD$ SCM IDs (cherry picked from commit 9e850513daf9cd1db7980f1f38ef7051331293fd) --- share/man/man5/style.Makefile.5 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/man/man5/style.Makefile.5 b/share/man/man5/style.Makefile.5 index a6162b0701eb..083847bb513c 100644 --- a/share/man/man5/style.Makefile.5 +++ b/share/man/man5/style.Makefile.5 @@ -41,7 +41,7 @@ source tree. .Bl -bullet .It .Cm .PATH : -comes next if needed, and is spelled +comes first if needed, and is spelled .Dq Li ".PATH: " , with a single .Tn ASCII From nobody Tue Oct 3 21:46:14 2023 X-Original-To: dev-commits-src-branches@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 4S0Wbp2NMYz4w2vL; Tue, 3 Oct 2023 21:46:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0Wbp1nTqz4njf; Tue, 3 Oct 2023 21:46:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696369574; 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=MpCTKU2uTDkDtnurt4mYH2sXL3Jg2uGsRuft5W7XAzc=; b=HJ6nNhzfbQ3VBdO4ql+xlRp6gl3BTLKvUanOnqR9AqiJDD/a1XIge8dQ/VbCFex3zS1O2+ ZqgN0HphhT3btuuEEPJngWeYwN39Uj+dISU/g/1WfsZVKVk0ZFUA3lXFV4Kmq1k+OE3Zhl iSwULJOXCKP7SjGhBx6I/BPlHq/8woYiSH6dslGZfmpur+ax7p5ocDmxI6ZSholCnVgUWj Vrfc4UAdh+CqAlwStcYFq4DR5gasDyllbVRLKYlHHKJ22PQm5b31uykvjJO9kovwuwkjfW xJxkVyu4L4tmxPWFeQV3OiIRrD1TPTBzja6Fj9P5DRT40reNt0DZMP+spk0KbQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696369574; a=rsa-sha256; cv=none; b=hnlIYHg81M3zYAANSOIx+vSkJSs7+ntM3SaevQQXVBF19F+VU4w8soDy97xAMxTa0dz8Aj IeUxye5pPo5tK4Yh74fZM4yN/zGXAt6wYYJRvcmVoh6LgHyJ+PbAUymhtIs8+2+JeRlfDk KUprwKwovOKbT6lopGZff3xnuMwXng15EHNHg6HFsySBWSkybuNiQr426Rit8LB+XIq4d0 zAxxByRP9/0JXPjCbfB9BJXRWQgzAJSXB/hA4+Qml2dPXZGoJYj9Nw0rSgXTgX3KJK2wjL pIVdLtAk4GlyXJhEf/i8AVawgPM5xOaTBHMnrDBHVmIVGho/HIlpmTz/bsUHmA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696369574; 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=MpCTKU2uTDkDtnurt4mYH2sXL3Jg2uGsRuft5W7XAzc=; b=Gb6J4BbCXAZ3UdhNWm14fdDo3oIekhmosqBwERSE/DWFI0rHfJV4pNO6jgsdPb1ODHJewz /LjaiGWmfkBVQuqePESg4/FG1SLkLWmtsbnAGYI7lyInCd0n4Q1CXar1KK3Q09yww/Dy+o ZfLjlm6iMNIUjS1KvoYwF51Fg2oK3Vpr8YfAyg9Pnrl+du2amYGIBJ9WJj1/oiN34AdbnV zsDOgZMJilufTuJ3xKw1jvBrFZmM89LErD4IrlTTS9Y1+4e2GEZpExr8/tLuKhZF0sRi5z UoN7+TzU4cz+EZBQfO7o//Eyzl4ywZG9UGqZQyzlk8vtOLOSiORI7SSd6ToRdw== 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 4S0Wbp0tN3z1B9S; Tue, 3 Oct 2023 21:46:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393LkEIS020681; Tue, 3 Oct 2023 21:46:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393LkEKV020678; Tue, 3 Oct 2023 21:46:14 GMT (envelope-from git) Date: Tue, 3 Oct 2023 21:46:14 GMT Message-Id: <202310032146.393LkEKV020678@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alan Somers Subject: git: 63c0b60063c7 - releng/14.0 - fusefs: fix some bugs updating atime during close List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: asomers X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 63c0b60063c7ce1022b07879e63fcef26fc0259a Auto-Submitted: auto-generated The branch releng/14.0 has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=63c0b60063c7ce1022b07879e63fcef26fc0259a commit 63c0b60063c7ce1022b07879e63fcef26fc0259a Author: Alan Somers AuthorDate: 2023-09-20 21:37:31 +0000 Commit: Alan Somers CommitDate: 2023-10-03 21:45:28 +0000 fusefs: fix some bugs updating atime during close When using cached attributes, we must update a file's atime during close, if it has been read since the last attribute refresh. But, * Don't update atime if we lack write permissions to the file or if the file system is readonly. * If the daemon fails our atime update request for any reason, don't report this as a failure for VOP_CLOSE. PR: 270749 Reported by: Jamie Landeg-Jones Sponsored by: Axcient Reviewed by: pfg Approved by: re (gjb) Differential Revision: https://reviews.freebsd.org/D41925 (cherry picked from commit fb619c94c679e939496fe0cf94b8d2cba95e6e63) fusefs: fix unused variables from fb619c94c67 PR: 270749 Reported by: cy Sponsored by: Axcient Approved by: re (gjb) (cherry picked from commit e5236d25f2c0709acf3547e6af45f4bb4eec4f02) (cherry picked from commit 13f188ce0b51908c292cdbb85ef26962528af87b) --- sys/fs/fuse/fuse_vnops.c | 27 ++++++++-- tests/sys/fs/fusefs/access.cc | 2 +- tests/sys/fs/fusefs/default_permissions.cc | 41 ++++++++++++++- tests/sys/fs/fusefs/read.cc | 83 ++++++++++++++++++++++++++++++ 4 files changed, 147 insertions(+), 6 deletions(-) diff --git a/sys/fs/fuse/fuse_vnops.c b/sys/fs/fuse/fuse_vnops.c index be2885528570..21ee378b24c6 100644 --- a/sys/fs/fuse/fuse_vnops.c +++ b/sys/fs/fuse/fuse_vnops.c @@ -779,6 +779,7 @@ static int fuse_vnop_close(struct vop_close_args *ap) { struct vnode *vp = ap->a_vp; + struct mount *mp = vnode_mount(vp); struct ucred *cred = ap->a_cred; int fflag = ap->a_fflag; struct thread *td = ap->a_td; @@ -794,12 +795,30 @@ fuse_vnop_close(struct vop_close_args *ap) return 0; err = fuse_flush(vp, cred, pid, fflag); - if (err == 0 && (fvdat->flag & FN_ATIMECHANGE)) { + if (err == 0 && (fvdat->flag & FN_ATIMECHANGE) && !vfs_isrdonly(mp)) { struct vattr vap; + struct fuse_data *data; + int dataflags; + int access_e = 0; - VATTR_NULL(&vap); - vap.va_atime = fvdat->cached_attrs.va_atime; - err = fuse_internal_setattr(vp, &vap, td, NULL); + data = fuse_get_mpdata(mp); + dataflags = data->dataflags; + if (dataflags & FSESS_DEFAULT_PERMISSIONS) { + struct vattr va; + + fuse_internal_getattr(vp, &va, cred, td); + access_e = vaccess(vp->v_type, va.va_mode, va.va_uid, + va.va_gid, VWRITE, cred); + } + if (access_e == 0) { + VATTR_NULL(&vap); + vap.va_atime = fvdat->cached_attrs.va_atime; + /* + * Ignore errors setting when setting atime. That + * should not cause close(2) to fail. + */ + fuse_internal_setattr(vp, &vap, td, NULL); + } } /* TODO: close the file handle, if we're sure it's no longer used */ if ((fvdat->flag & FN_SIZECHANGE) != 0) { diff --git a/tests/sys/fs/fusefs/access.cc b/tests/sys/fs/fusefs/access.cc index 3d6cddb9417b..5762269fac7b 100644 --- a/tests/sys/fs/fusefs/access.cc +++ b/tests/sys/fs/fusefs/access.cc @@ -55,7 +55,7 @@ void expect_lookup(const char *relpath, uint64_t ino) } /* - * Expect tha FUSE_ACCESS will never be called for the given inode, with any + * Expect that FUSE_ACCESS will never be called for the given inode, with any * bits in the supplied access_mask set */ void expect_noaccess(uint64_t ino, mode_t access_mask) diff --git a/tests/sys/fs/fusefs/default_permissions.cc b/tests/sys/fs/fusefs/default_permissions.cc index 1a1ee5a54aed..4b04297d97ac 100644 --- a/tests/sys/fs/fusefs/default_permissions.cc +++ b/tests/sys/fs/fusefs/default_permissions.cc @@ -30,7 +30,7 @@ /* * Tests for the "default_permissions" mount option. They must be in their own - * file so they can be run as an unprivileged user + * file so they can be run as an unprivileged user. */ extern "C" { @@ -163,6 +163,7 @@ class Fspacectl: public DefaultPermissions {}; class Lookup: public DefaultPermissions {}; class Open: public DefaultPermissions {}; class PosixFallocate: public DefaultPermissions {}; +class Read: public DefaultPermissions {}; class Setattr: public DefaultPermissions {}; class Unlink: public DefaultPermissions {}; class Utimensat: public DefaultPermissions {}; @@ -1239,6 +1240,44 @@ TEST_F(Rename, ok_to_remove_src_because_of_stickiness) ASSERT_EQ(0, rename(FULLSRC, FULLDST)) << strerror(errno); } +// Don't update atime during close after read, if we lack permissions to write +// that file. +TEST_F(Read, atime_during_close) +{ + const char FULLPATH[] = "mountpoint/some_file.txt"; + const char RELPATH[] = "some_file.txt"; + uint64_t ino = 42; + int fd; + ssize_t bufsize = 100; + uint8_t buf[bufsize]; + const char *CONTENTS = "abcdefgh"; + ssize_t fsize = sizeof(CONTENTS); + + expect_getattr(FUSE_ROOT_ID, S_IFDIR | 0755, UINT64_MAX, 1); + FuseTest::expect_lookup(RELPATH, ino, S_IFREG | 0755, fsize, + 1, UINT64_MAX, 0, 0); + expect_open(ino, 0, 1); + expect_read(ino, 0, fsize, fsize, CONTENTS); + EXPECT_CALL(*m_mock, process( + ResultOf([&](auto in) { + return (in.header.opcode == FUSE_SETATTR); + }, Eq(true)), + _) + ).Times(0); + expect_flush(ino, 1, ReturnErrno(0)); + expect_release(ino, FuseTest::FH); + + fd = open(FULLPATH, O_RDONLY); + ASSERT_LE(0, fd) << strerror(errno); + + /* Ensure atime will be different than during lookup */ + nap(); + + ASSERT_EQ(fsize, read(fd, buf, bufsize)) << strerror(errno); + + close(fd); +} + TEST_F(Setattr, ok) { const char FULLPATH[] = "mountpoint/some_file.txt"; diff --git a/tests/sys/fs/fusefs/read.cc b/tests/sys/fs/fusefs/read.cc index cf2159df646b..3df0420facb9 100644 --- a/tests/sys/fs/fusefs/read.cc +++ b/tests/sys/fs/fusefs/read.cc @@ -57,6 +57,14 @@ void expect_lookup(const char *relpath, uint64_t ino, uint64_t size) } }; +class RofsRead: public Read { +public: +virtual void SetUp() { + m_ro = true; + Read::SetUp(); +} +}; + class Read_7_8: public FuseTest { public: virtual void SetUp() { @@ -454,6 +462,47 @@ TEST_F(Read, atime_during_close) close(fd); } +/* + * When not using -o default_permissions, the daemon may make its own decisions + * regarding access permissions, and these may be unpredictable. If it rejects + * our attempt to set atime, that should not cause close(2) to fail. + */ +TEST_F(Read, atime_during_close_eacces) +{ + const char FULLPATH[] = "mountpoint/some_file.txt"; + const char RELPATH[] = "some_file.txt"; + const char *CONTENTS = "abcdefgh"; + uint64_t ino = 42; + int fd; + ssize_t bufsize = strlen(CONTENTS); + uint8_t buf[bufsize]; + + expect_lookup(RELPATH, ino, bufsize); + expect_open(ino, 0, 1); + expect_read(ino, 0, bufsize, bufsize, CONTENTS); + EXPECT_CALL(*m_mock, process( + ResultOf([&](auto in) { + uint32_t valid = FATTR_ATIME; + return (in.header.opcode == FUSE_SETATTR && + in.header.nodeid == ino && + in.body.setattr.valid == valid); + }, Eq(true)), + _) + ).WillOnce(Invoke(ReturnErrno(EACCES))); + expect_flush(ino, 1, ReturnErrno(0)); + expect_release(ino, FuseTest::FH); + + fd = open(FULLPATH, O_RDONLY); + ASSERT_LE(0, fd) << strerror(errno); + + /* Ensure atime will be different than during lookup */ + nap(); + + ASSERT_EQ(bufsize, read(fd, buf, bufsize)) << strerror(errno); + + ASSERT_EQ(0, close(fd)); +} + /* A cached atime should be flushed during FUSE_SETATTR */ TEST_F(Read, atime_during_setattr) { @@ -1321,6 +1370,40 @@ INSTANTIATE_TEST_SUITE_P(RA, ReadAhead, tuple(true, 1), tuple(true, 2))); +/* With read-only mounts, fuse should never update atime during close */ +TEST_F(RofsRead, atime_during_close) +{ + const char FULLPATH[] = "mountpoint/some_file.txt"; + const char RELPATH[] = "some_file.txt"; + const char *CONTENTS = "abcdefgh"; + uint64_t ino = 42; + int fd; + ssize_t bufsize = strlen(CONTENTS); + uint8_t buf[bufsize]; + + expect_lookup(RELPATH, ino, bufsize); + expect_open(ino, 0, 1); + expect_read(ino, 0, bufsize, bufsize, CONTENTS); + EXPECT_CALL(*m_mock, process( + ResultOf([&](auto in) { + return (in.header.opcode == FUSE_SETATTR); + }, Eq(true)), + _) + ).Times(0); + expect_flush(ino, 1, ReturnErrno(0)); + expect_release(ino, FuseTest::FH); + + fd = open(FULLPATH, O_RDONLY); + ASSERT_LE(0, fd) << strerror(errno); + + /* Ensure atime will be different than during lookup */ + nap(); + + ASSERT_EQ(bufsize, read(fd, buf, bufsize)) << strerror(errno); + + close(fd); +} + /* fuse_init_out.time_gran controls the granularity of timestamps */ TEST_P(TimeGran, atime_during_setattr) { From nobody Tue Oct 3 21:46:14 2023 X-Original-To: dev-commits-src-branches@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 4S0Wbp5vQVz4w2bR; Tue, 3 Oct 2023 21:46:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0Wbp5JB8z4ntd; Tue, 3 Oct 2023 21:46:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696369574; 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=1MG5i9R0Ljh9RFC2eX2KIIZYTKQszE+Gw8HLFqnDc4M=; b=aIFefLLhDXe1OOCQrthGA5QT53uFnR7puTetxTV5bZYfSiNV74EkxMm2MHXzq4om41pVUM VyvK8YSNwpnJscEbknY0w8zqA+s4iSHIVFyRBJ1vLcIQo5u7dmzOw7wvaVpb0d83u6J1V1 96vX0K4A32jfRw6l/XkQM67JOle2QlBad1M8/Fd2Ve+JErXaszbkIPfjieW0JYdYtc6qjC RqdYVEMG4KXstDmJzQYIs2sYAuz9ASNoF5prBha9+EO2YpKUuPrCFETEFSwvVQ7yDzXhCz emEC0Xl9zrWi+51zlhx77biV6dhLTO05Qv28RlqW5sAFy1juHwHee23oJf/FXQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696369574; a=rsa-sha256; cv=none; b=RPgc/2TeCtRcjmRg20cOkCpZmdshV6KGyxCzsV6hR8KcNuwWlnT7ZY7Hgd9+m78MaPXfcU PuylkgVlDEvc1vmqgFdYH7s/6X76adULWfOIbppeSngHJNdxrK9S5m2Ku4YbfIrrmlY9vh rzWweslANMmL+CBQ967f2scwKJf6cxGTs3gNRX9Yrc3xkzVM6gvM18BVvPUJ5A4yYFZOfM xKIqmqnX5P6CGrB0g3w5oYezP1ZzTQpf0Z/U+aohP9hHnEXCMpDyPDQ6S7rdiONq9I12VL z2kPfa0jabG+G8dhUP8V18ABm/hjqhR4rIg3Lr9oS+OassXKFknZwVUmJ7e0AA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696369574; 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=1MG5i9R0Ljh9RFC2eX2KIIZYTKQszE+Gw8HLFqnDc4M=; b=fIqZnSH6I0XozcbKdyqpI3CF8ak0AK0MGBn7NDo6aZtaQzKaiW5v6DqVcyWyAmBr3DYfix dbgrDRRqz1GvoL8v4xfvmIB6nZq9hTEFyQzqqOv/rjI3luCUD48fudgi/CwK/7KVvU9mvz xmwbRbxpg6gPE99Qt9VRk/A4MTxafv3JRKUlHMhU5TRknYZc1f7IdZZkpZNNW7YSCjtON1 FH7LmmyKh9wWpq3TRkI1VsE6dE6ipI3TV0Fi15HbTwHr/VLnFy4ra4MmDguSGNLOCuHbiv hp80QTVRoHpvoN2M5XXoUQaIB/okc9fhalw4R0AHCMbeuq2253y8+GkGOOfq/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 4S0Wbp4DS1z1B9T; Tue, 3 Oct 2023 21:46:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393LkEnj020726; Tue, 3 Oct 2023 21:46:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393LkEl8020723; Tue, 3 Oct 2023 21:46:14 GMT (envelope-from git) Date: Tue, 3 Oct 2023 21:46:14 GMT Message-Id: <202310032146.393LkEl8020723@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 6101f8ec954d - stable/13 - style.Makefile.5: Stop documenting NO_MAN List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 6101f8ec954d3f56db044fc9a3bc92ce658812cc Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=6101f8ec954d3f56db044fc9a3bc92ce658812cc commit 6101f8ec954d3f56db044fc9a3bc92ce658812cc Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2023-07-17 12:50:33 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-03 21:46:05 +0000 style.Makefile.5: Stop documenting NO_MAN NO_MAN has been an error since 2020 according to UPDATING. PR: 231357 MFC after: 3 days (cherry picked from commit 73fb7a7a7342bb590ba53e406b564df0d90c3304) --- share/man/man5/style.Makefile.5 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/share/man/man5/style.Makefile.5 b/share/man/man5/style.Makefile.5 index 083847bb513c..122b38cb19a4 100644 --- a/share/man/man5/style.Makefile.5 +++ b/share/man/man5/style.Makefile.5 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd November 18, 2021 +.Dd July 17, 2023 .Dt STYLE.MAKEFILE 5 .Os .Sh NAME @@ -64,7 +64,7 @@ order is: .Va PROG Ns / Ns Oo Va SH Oc Ns Va LIB Ns / Ns Va SCRIPTS .Va FILES .Va LINKS -.Oo Va NO_ Oc Ns Va MAN +.Va MAN .Va MLINKS .Va INCS .Va SRCS @@ -86,7 +86,7 @@ order is: .Va INCS .Va FILES .Va LINKS -.Oo Va NO_ Oc Ns Va MAN +.Va MAN .Va MLINKS . .It Omit From nobody Tue Oct 3 22:13:56 2023 X-Original-To: dev-commits-src-branches@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 4S0XCm6HCNz4w4Qn; Tue, 3 Oct 2023 22:13: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0XCm5lgrz4rBq; Tue, 3 Oct 2023 22:13:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371236; 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=pNLgg52i+8zMWfrjOSHpq5/d1TJ75+SWTuGeYtG2T3M=; b=mfHbvtLtnEzZtXZ73b6A/C+tOfSUml6GZ0dnig9kqMhLUBrWdRUZPMKQxqyFDTC5ARqvtS EW354jZK7sK7JHYugQmTyLLKy76qArLFyQ8ehq4C2U1z526YxOFryQH5WshVax9Il0iJtR V+P+XSRa9m5RF1ZOMVHxOTkmaYMkskKMoqpjDHGixGBXexwjJXSPapn07p/peu8HBQxmyc 0fSixYw5wE2EE0amjDzUHXPPgxyQULWX6Vaf2N9x12Y0Gw5i60B9kbRWVV7uXg6slxzqii B04tT2TiFPd7tuwPe5/RQZFIuL7krHCgew2eSaHF3KSlhE3YkReF7Z3WxgnxaA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696371236; a=rsa-sha256; cv=none; b=vus02HJEri3Gqy9ft1xJ88/iYqq/C6bSGJms0U4imA1FEmP/UZB3HsEJb6uebhxILwMU/M 9hND/qn2dzQuG81FQtOfkdBA828+3kHT+6UOLTvoiWEXQcR7qZMtI3Q1rUi/qMlaUBPedC VP4Xe8/JI3TclPVIbsXzRac2JIhIRYgG4dOwX0XR5cAzmhjrNBxt1ZFfhMcpNG+1YWhjr8 +dHewCwc5Efi09tcqwvqtmbftQZtC6TZ63YL8znaOOQ3BymousfGIv7EVYQo6JXto5Heng /WgIsm3qw9m6gxmSjkOi0v8fmNdKUad+VVywlcz+6SCcy/vwnu83/uaFKC7IBA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371236; 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=pNLgg52i+8zMWfrjOSHpq5/d1TJ75+SWTuGeYtG2T3M=; b=EDWMxLtI9HgUQ05YyT3T8TcofPbiI3dglupzopxKR4shcPVDvYvpSqpQQPmzY/aWJ3qxy+ UWWExDtsUsWeLaQmGGjeM2igWg0j2P6UqnI+Mk4jx/vx8bAsDrKB4utrEzngkSEjW6BsQK Qy75sQIgpmdAtx7pvKqsO/rDtr8sipYP2FVVUToT0E10ydd9HwI/7pC+OlJbQujoOEQWFN cWAYR+bvX2Nq2V+M6qMPxWtLS7HPPphg6jQfEd89twXFyJs6McPypcaZtM8vMnjswgWcEa YDqGHRMeA/st9+fw2jYo9wDWes7gq6hFUNNCJsxMac4pCRicLyj3qFZkQ7SGuQ== 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 4S0XCm4qBhz1BZT; Tue, 3 Oct 2023 22:13:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393MDutr070936; Tue, 3 Oct 2023 22:13:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393MDu1J070933; Tue, 3 Oct 2023 22:13:56 GMT (envelope-from git) Date: Tue, 3 Oct 2023 22:13:56 GMT Message-Id: <202310032213.393MDu1J070933@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: cfb624d7e250 - releng/13.2 - freebsd-update: handle file -> directory on upgrade List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/13.2 X-Git-Reftype: branch X-Git-Commit: cfb624d7e2507c81441bb01e0078abad25ef235d Auto-Submitted: auto-generated The branch releng/13.2 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=cfb624d7e2507c81441bb01e0078abad25ef235d commit cfb624d7e2507c81441bb01e0078abad25ef235d Author: Ed Maste AuthorDate: 2023-09-27 13:36:33 +0000 Commit: Gordon Tetlow CommitDate: 2023-10-03 21:22:19 +0000 freebsd-update: handle file -> directory on upgrade Upgrading from FreeBSD 13.2 to 14.0 failed with install: ///usr/include/c++/v1/__string exists but is not a directory because __string changed from a file to a directory with an LLVM upgrade. Now, remove the existing file when the type conflicts. Note that this is only an interim fix to facilitate upgrades from 13.2 for 14.0 BETA testing. This change does not handle the directory -> file case and further work is needed. PR: 273661 Reviewed by: dim, gordon Approved by: so Security: FreeBSD-EN-23:12.freebsd-update Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D41893 (cherry picked from commit f6d37c9ca13f8ab0ef32cf5344daecb8122d1e85) (cherry picked from commit 774cc6348a50c13b952e9f36ef8395f9b48733db) --- usr.sbin/freebsd-update/freebsd-update.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/usr.sbin/freebsd-update/freebsd-update.sh b/usr.sbin/freebsd-update/freebsd-update.sh index 4f779270926d..0c4053715b70 100644 --- a/usr.sbin/freebsd-update/freebsd-update.sh +++ b/usr.sbin/freebsd-update/freebsd-update.sh @@ -2905,7 +2905,13 @@ install_from_index () { while read FPATH TYPE OWNER GROUP PERM FLAGS HASH LINK; do case ${TYPE} in d) - # Create a directory + # Create a directory. A file may change to a directory + # on upgrade (PR273661). If that happens, remove the + # file first. + if [ -e "${BASEDIR}/${FPATH}" ] && \ + ! [ -d "${BASEDIR}/${FPATH}" ]; then + rm -f -- "${BASEDIR}/${FPATH}" + fi install -d -o ${OWNER} -g ${GROUP} \ -m ${PERM} ${BASEDIR}/${FPATH} ;; From nobody Tue Oct 3 22:13:57 2023 X-Original-To: dev-commits-src-branches@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 4S0XCp0sG2z4w4Ks; Tue, 3 Oct 2023 22:13: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0XCp054jz4rF5; Tue, 3 Oct 2023 22:13:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371238; 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=DjbxGuMErZSJSiCmQ+JaBhzTJDSzA+RwCwqnWW8HrW8=; b=A/i0e4CLBwfFUZOIpvvOI+OZVXAPV4BREoci0kBoYbYBwgWc8nXDkpeWPlg+RxInY+WsPp YUzdII1SUyivM4AKWcHeo2iuEaRk055LYVy0ZiEilV2di74cQDvFRAhrE9jfINHV4jUoRp rY8xOrRisPNFJr71jKXN0+RRk+z6TfccJGvBcBgJYbjkvf8pNmRDzIrbmzPbasjiDEUCNo 3lV2aK58fjHA9mAYkBVg5FyTO+o3uairasZ0CUsna9SVVqVFMANigEU4d68CRsLOXIk3/b /FRV82XinDtJIjWg06gm9P8QCL1HLFXwNaIUkFF1xa2tEtwpzSjYx/3g/3Q8zQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696371238; a=rsa-sha256; cv=none; b=I1XF2AyD0NxyaFCkk51ZUoyKQ3LJJYCLPPIQHbjre5muHkt7Debs8xovsIczWGqSSqaK7W zkOaHrmA4TSeZmVLOcJlVu0buOHPVoGQV9hj3jq5jVeZO3D7KJU4/xUcPeoT3Z8z6jhLIX YDIqh+xvMzBJ3VPZCCBNxxZ6ubK6ptT1G3rlFOjID5vw4dr8MRkVLi7PDeHElCHqex4DSv VLmUHxrbqYrdkI7UJnbLgD9exvaeGrq6V/+YvjVjegs2kZNE43iC7vDKwxxDJaFgDVpulB 9/zhu3gwNYdVaOSVFORS6cgt+IuCFh6AkZPUBW94s1Og9wrs8QFxTgKTOStg0w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371238; 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=DjbxGuMErZSJSiCmQ+JaBhzTJDSzA+RwCwqnWW8HrW8=; b=gJfRcCi4uWRVtjylSlA7D6O0E+64KQRdYIKxs+uwLKZ6oGRnYHmmTXMRzW/TxTKzs9IhEI aR9U47YtO2PpS8oWM+yXGhxvDJTPgAjoslWrak9VP87Z8Rd239Klbl2Cn+P/tI7v7YNUVr o5Q9+KqKf+3D2afS4wjdPw0h5HB6i5s00uiqOtMxWIc9Bzp9l8Qbr+5gP9vAM6eupeBtYb Ty5Ddc2rgovrYCKDLU2R2+wyG/Hv7ilPn1A+sPztH5al8oTuo12fxszpELPqxzD+Ep6MU5 ce37+9OR2+lwJv/WD6LKFWouzecKeCuTxD8i8pnkxdvIys/DZkBrD78RV9GV4Q== 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 4S0XCn6Frzz1BXJ; Tue, 3 Oct 2023 22:13:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393MDvDe070981; Tue, 3 Oct 2023 22:13:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393MDvgD070978; Tue, 3 Oct 2023 22:13:57 GMT (envelope-from git) Date: Tue, 3 Oct 2023 22:13:57 GMT Message-Id: <202310032213.393MDvgD070978@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: 7d08a7e6908b - releng/13.2 - msdosfs: zero partially valid extended cluster List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/13.2 X-Git-Reftype: branch X-Git-Commit: 7d08a7e6908b3ffb72061b7517ed29814d62355b Auto-Submitted: auto-generated The branch releng/13.2 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=7d08a7e6908b3ffb72061b7517ed29814d62355b commit 7d08a7e6908b3ffb72061b7517ed29814d62355b Author: Gordon Tetlow AuthorDate: 2023-10-03 21:23:40 +0000 Commit: Gordon Tetlow CommitDate: 2023-10-03 21:23:40 +0000 msdosfs: zero partially valid extended cluster Approved by: so Security: FreeBSD-SA-23:12.msdosfs Security: CVE-2023-5368 --- sys/fs/msdosfs/msdosfs_denode.c | 53 +++++++++++++++++++++++++++++++++-------- 1 file changed, 43 insertions(+), 10 deletions(-) diff --git a/sys/fs/msdosfs/msdosfs_denode.c b/sys/fs/msdosfs/msdosfs_denode.c index 030c96d6d354..37d23f2ce60b 100644 --- a/sys/fs/msdosfs/msdosfs_denode.c +++ b/sys/fs/msdosfs/msdosfs_denode.c @@ -384,10 +384,8 @@ detrunc(struct denode *dep, u_long length, int flags, struct ucred *cred) return (EINVAL); } - if (dep->de_FileSize < length) { - vnode_pager_setsize(DETOV(dep), length); + if (dep->de_FileSize < length) return (deextend(dep, length, cred)); - } /* * If the desired length is 0 then remember the starting cluster of @@ -496,13 +494,16 @@ int deextend(struct denode *dep, u_long length, struct ucred *cred) { struct msdosfsmount *pmp = dep->de_pmp; + struct vnode *vp = DETOV(dep); + struct buf *bp; + off_t eof_clusteroff; u_long count; int error; /* * The root of a DOS filesystem cannot be extended. */ - if ((DETOV(dep)->v_vflag & VV_ROOT) && !FAT32(pmp)) + if ((vp->v_vflag & VV_ROOT) != 0 && !FAT32(pmp)) return (EINVAL); /* @@ -522,15 +523,47 @@ deextend(struct denode *dep, u_long length, struct ucred *cred) if (count > pmp->pm_freeclustercount) return (ENOSPC); error = extendfile(dep, count, NULL, NULL, DE_CLEAR); - if (error) { - /* truncate the added clusters away again */ - (void) detrunc(dep, dep->de_FileSize, 0, cred); - return (error); - } + if (error != 0) + goto rewind; } + + /* + * For the case of cluster size larger than the page size, we + * need to ensure that the possibly dirty partial buffer at + * the old end of file is not filled with invalid pages by + * extension. Otherwise it has a contradictory state of + * B_CACHE | B_DELWRI but with invalid pages, and cannot be + * neither written out nor validated. + * + * Fix it by proactively clearing extended pages. Need to do + * both vfs_bio_clrbuf() to mark pages valid, and to zero + * actual buffer content which might exist in the tail of the + * already valid cluster. + */ + error = bread(vp, de_cluster(pmp, dep->de_FileSize), pmp->pm_bpcluster, + NOCRED, &bp); + if (error != 0) + goto rewind; + vfs_bio_clrbuf(bp); + eof_clusteroff = de_cn2off(pmp, de_cluster(pmp, dep->de_FileSize)); + vfs_bio_bzero_buf(bp, dep->de_FileSize - eof_clusteroff, + pmp->pm_bpcluster - dep->de_FileSize + eof_clusteroff); + if (!DOINGASYNC(vp)) + (void)bwrite(bp); + else if (vm_page_count_severe() || buf_dirty_count_severe()) + bawrite(bp); + else + bdwrite(bp); + + vnode_pager_setsize(vp, length); dep->de_FileSize = length; dep->de_flag |= DE_UPDATE | DE_MODIFIED; - return (deupdat(dep, !DOINGASYNC(DETOV(dep)))); + return (deupdat(dep, !DOINGASYNC(vp))); + +rewind: + /* truncate the added clusters away again */ + (void)detrunc(dep, dep->de_FileSize, 0, cred); + return (error); } /* From nobody Tue Oct 3 22:13:58 2023 X-Original-To: dev-commits-src-branches@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 4S0XCq1r6Tz4w4Ng; Tue, 3 Oct 2023 22:13: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0XCq0wBHz4rFY; Tue, 3 Oct 2023 22:13:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371239; 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=1k9V5kW7d3YOiF6lgdMIAOfXUxC0uomfnbRIZ3nYbxY=; b=ThzNvVRqfzGEQuWwB22OpIyxwmunu+WNl8fq/Nq1G0Nd2nlLYvv+qTZbQToFnmbBtD8r5k RBrfqnjzgEdvsSjsey3dUOuwNf5wXawBIb6Xa1Nyo7uArrbHnNqee/lkOc5nd1sYe5NuKP pwMjOPGmpGhEvqUGnZuUDYjXm922zOYUPzIhbGQT1ro+qW7et7VO9myrVPPHOZAmheCoaw trQaUstcW8lu6lFsaP2ma14UQm4yXAl94kFHQeSP9DbOnOoqdbeAeWAeoGxucuww2E92os HNdlr++uUDQ7o/s0deYgerCU0rcz4A+d/sNkAjt7w6k0bKSUAMa/ltWXrg3xtA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696371239; a=rsa-sha256; cv=none; b=LaM/hfJLv+x8YOYReqQOwVGXtxmSjNyRFzy9pia+c/Da60+iIVoatnOH2KeSE2OR7rorSw pt08qNXZwpGFZIYV4aEyXuSQqtGg5a2jcfQajSzjaRGfKvKXv4JI1+I4cbwmNP/T17IXzZ eXTTY+lrNUuwRXN3oQzyZ1LCZbnlIO1GZhjcb2A6jzQ5rDzM2cpAkHTeJvQhnGxZau/u/m dASy8XIYi7Ys1J2K/fd/YZN46uEIrNDPwu7iIfvLMsHEWXo0qVm6aj2rKvLMpXgDZ4o7LR lEZ+6bqcJp9RhyHJew8ab51gFWP3Q8cz+deGCbGmn1UC0m4mOt1EtrsqXgHoSA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371239; 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=1k9V5kW7d3YOiF6lgdMIAOfXUxC0uomfnbRIZ3nYbxY=; b=wPIkbzokatnv0axGw15mjfDCnxq4rUrF94yGfP+LBwqX5hdr/Lck9qa7RJEnRowGLMmgHO AahXQEuNbrRxy1KdBqIRbPmpyIv9MFUV8WgQqA88EgrbRyNhyt6+CimRp6IGQ8bk/+hrY7 +xfjZz9u5nxS5k+osa0Fq78yUyV6u0EMiNPFDQqUVegSrfnX7OPK58qJibM7e5FdXrc0JD MS9vwpoinAeGiUS/ouv0dP7YTJ5RU/qFlbLdINmSUQClvv0cxNuXiHeBT95VNNkHA7Pkw0 6lirDYE/PnfoNwIOnCI5T5cnPSggiC7Cmbcl940uGQgb39vqMjTQtO2X2MOr3Q== 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 4S0XCp6tZXz1Blx; Tue, 3 Oct 2023 22:13:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393MDw8E071029; Tue, 3 Oct 2023 22:13:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393MDwGc071026; Tue, 3 Oct 2023 22:13:58 GMT (envelope-from git) Date: Tue, 3 Oct 2023 22:13:58 GMT Message-Id: <202310032213.393MDwGc071026@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: 2d23f6c33431 - releng/13.2 - copy_file_range: require CAP_SEEK capability List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/13.2 X-Git-Reftype: branch X-Git-Commit: 2d23f6c33431b19d8f91ad4832db01aa25062d43 Auto-Submitted: auto-generated The branch releng/13.2 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=2d23f6c33431b19d8f91ad4832db01aa25062d43 commit 2d23f6c33431b19d8f91ad4832db01aa25062d43 Author: Mariusz Zaborski AuthorDate: 2023-09-28 13:24:39 +0000 Commit: Gordon Tetlow CommitDate: 2023-10-03 21:24:41 +0000 copy_file_range: require CAP_SEEK capability When using copy_file_range(2) with an offset parameter, the CAP_SEEK capability should be required. This requirement is similar to the behavior observed with pread(2)/pwrite(2). Reported by: theraven Reviewed by: emaste, theraven, kib, markj Approved by: so Security: FreeBSD-SA-23:13.capsicum Security: CVE-2023-5369 Differential Revision: https://reviews.freebsd.org/D41967 (cherry picked from commit 15a51d3abaef27ddea66320cac7caa549738a1a6) (cherry picked from commit 3f0ce63828dc3d4030b32ad0effb4e588af49c03) --- sys/kern/vfs_syscalls.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 3b3947b2ccb7..449c5ace6094 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -4896,7 +4896,8 @@ kern_copy_file_range(struct thread *td, int infd, off_t *inoffp, int outfd, len = SSIZE_MAX; /* Get the file structures for the file descriptors. */ - error = fget_read(td, infd, &cap_read_rights, &infp); + error = fget_read(td, infd, + inoffp != NULL ? &cap_pread_rights : &cap_read_rights, &infp); if (error != 0) goto out; if (infp->f_ops == &badfileops) { @@ -4907,7 +4908,8 @@ kern_copy_file_range(struct thread *td, int infd, off_t *inoffp, int outfd, error = EINVAL; goto out; } - error = fget_write(td, outfd, &cap_write_rights, &outfp); + error = fget_write(td, outfd, + outoffp != NULL ? &cap_pwrite_rights : &cap_write_rights, &outfp); if (error != 0) goto out; if (outfp->f_ops == &badfileops) { From nobody Tue Oct 3 22:14:00 2023 X-Original-To: dev-commits-src-branches@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 4S0XCr2Xvxz4w4Bh; Tue, 3 Oct 2023 22:14: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0XCr1bK1z4rXF; Tue, 3 Oct 2023 22:14:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371240; 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=Kc+UCTzy0YX8bEHQHrZSDvQxk1hjCK72V0IivmHurX0=; b=YuGlu+epNq6dCk+MOGqCSjZ4PxJslmQWS3sEFvkBIu0/hz2zxfeUBpZm31A6fu0K53R9NB tCq8x/Dz0nxtWwj3b/R8VLcVUCSOWGnN+AOgryzsQtQQpFTqyLb+dAM5z3E5fBnkBYXzoN x5BVHdbO/ShShEuMyvT8QQjkYrG54g+M2JZMhFI/dj38q0bOCRLHj4rDRq3xsu7Qxgsmru siFSXGZLLp0jb2CdiWucm+zn09vCz+eXJ1wxdvSzimccOQCFMLKrmM0We4W8k6Vb59ET46 3WMnSc2qecC2dPAeQhye9bsIDatjydkjEugIjErneWH/V9wNczhhF/W+WGlPew== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696371240; a=rsa-sha256; cv=none; b=W1Hxx8ywFvHsuOOTOH/bwlichNaMaPS0yeo+lJnyOphsbSBRGfrKgYUaciDumAzxFFdHy2 GR4LvxojRaLa8xDIkiXO6NIuF1w5w3Q8MhLyx4f5HRkgx1nZZdBpcRwQ/7ECVHd7Fwu/MT VLFusZLhqLgCWWiMUb9yTyKI+fsWKzg7nmOilqfFJttuRX8lsPHu1+LcIbF/iLjoUngi2U 1aopv79zwK+vDIDItQOawYGuXchNvN8uY3+TGqGNmRUyVmbaKiRHT1Y0Y9YcIKFUaFPo/I a7wAxKAIWbbbbWVaWlkC0iLIteKUQZ7wFboigOMyD2G6UttPQltiq5Q1jvfLZQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371240; 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=Kc+UCTzy0YX8bEHQHrZSDvQxk1hjCK72V0IivmHurX0=; b=ks2GD9SwTNYgPE2G04uaq6jtQCNuYrDrBy8vczPNW1I2/RGcnCVNS0ihbLqGQSE7YW7Qy1 lhD+b5GORbxH+ubFJ7BclOWw0ZqGHw6bNQyPPhCxBj+D5MCUQr1GmjJQXmofWzlWuFagXl bd0xtg6O+gRfTC2YshCyxlfWMxl7t4CUqzqZv+OVEztgtc/KQmlPe/vd9OiokLrzhYZjfC luogW+Dwd5VVgQuiLWdGd8WNS1tyXjdSmqgw2GUaHE53RGFXASF4pnhXHawJjn40cmquxT Q5mPj/X671kxF4Pvue3xlDQlFSMMLxX8iHqGGz37bjawdc9dz+Me5jN5ysWAsw== 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 4S0XCr0h9kz1BZV; Tue, 3 Oct 2023 22:14:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393ME0UP071083; Tue, 3 Oct 2023 22:14:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393ME09A071078; Tue, 3 Oct 2023 22:14:00 GMT (envelope-from git) Date: Tue, 3 Oct 2023 22:14:00 GMT Message-Id: <202310032214.393ME09A071078@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: 485912e051bb - releng/13.2 - arm64: Fix errata workarounds that depend on smccc List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/13.2 X-Git-Reftype: branch X-Git-Commit: 485912e051bbea273a480a24d7f321cc7c06f335 Auto-Submitted: auto-generated The branch releng/13.2 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=485912e051bbea273a480a24d7f321cc7c06f335 commit 485912e051bbea273a480a24d7f321cc7c06f335 Author: Andrew Turner AuthorDate: 2023-09-18 16:34:51 +0000 Commit: Gordon Tetlow CommitDate: 2023-10-03 21:29:11 +0000 arm64: Fix errata workarounds that depend on smccc Some arm64 errata depend on calling into the firmware via the SMCCC interface. This needs to happen after the psci driver has attached as they share the interface. Fix this by allowing the workarounds to mark when they depend on device drivers attaching. This is only an issue on CPU 0 as the workarounds are applied later for the non-boot CPUs. Reviewed by: emaste Approved by: so Security: FreeBSD-SA-23:14.smccc Security: CVE-2023-5370 Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D41916 (cherry picked from commit c643e82dba0b17b2716de4c9d44a3c9c547cbbd5) (cherry picked from commit 843bea18711d726cd2f0a3c3f9144b218e4de3e8) (cherry picked from commit 4df1447f2c76d0db988197f3a05d48e15f976c7c) --- sys/arm64/arm64/cpu_errata.c | 50 +++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 47 insertions(+), 3 deletions(-) diff --git a/sys/arm64/arm64/cpu_errata.c b/sys/arm64/arm64/cpu_errata.c index 9879e645b827..dfe93a503191 100644 --- a/sys/arm64/arm64/cpu_errata.c +++ b/sys/arm64/arm64/cpu_errata.c @@ -49,6 +49,9 @@ struct cpu_quirks { cpu_quirk_install *quirk_install; u_int midr_mask; u_int midr_value; +#define CPU_QUIRK_POST_DEVICE (1 << 0) /* After device attach */ + /* e.g. needs SMCCC */ + u_int flags; }; static enum { @@ -66,32 +69,38 @@ static struct cpu_quirks cpu_quirks[] = { .midr_mask = CPU_IMPL_MASK | CPU_PART_MASK, .midr_value = CPU_ID_RAW(CPU_IMPL_ARM, CPU_PART_CORTEX_A57,0,0), .quirk_install = install_psci_bp_hardening, + .flags = CPU_QUIRK_POST_DEVICE, }, { .midr_mask = CPU_IMPL_MASK | CPU_PART_MASK, .midr_value = CPU_ID_RAW(CPU_IMPL_ARM, CPU_PART_CORTEX_A72,0,0), .quirk_install = install_psci_bp_hardening, + .flags = CPU_QUIRK_POST_DEVICE, }, { .midr_mask = CPU_IMPL_MASK | CPU_PART_MASK, .midr_value = CPU_ID_RAW(CPU_IMPL_ARM, CPU_PART_CORTEX_A73,0,0), .quirk_install = install_psci_bp_hardening, + .flags = CPU_QUIRK_POST_DEVICE, }, { .midr_mask = CPU_IMPL_MASK | CPU_PART_MASK, .midr_value = CPU_ID_RAW(CPU_IMPL_ARM, CPU_PART_CORTEX_A75,0,0), .quirk_install = install_psci_bp_hardening, + .flags = CPU_QUIRK_POST_DEVICE, }, { .midr_mask = CPU_IMPL_MASK | CPU_PART_MASK, .midr_value = CPU_ID_RAW(CPU_IMPL_CAVIUM, CPU_PART_THUNDERX2, 0,0), .quirk_install = install_psci_bp_hardening, + .flags = CPU_QUIRK_POST_DEVICE, }, { .midr_mask = 0, .midr_value = 0, .quirk_install = install_ssbd_workaround, + .flags = CPU_QUIRK_POST_DEVICE, }, { .midr_mask = CPU_IMPL_MASK | CPU_PART_MASK, @@ -175,8 +184,8 @@ install_thunderx_bcast_tlbi_workaround(void) } } -void -install_cpu_errata(void) +static void +install_cpu_errata_flags(u_int mask, u_int flags) { u_int midr; size_t i; @@ -185,8 +194,43 @@ install_cpu_errata(void) for (i = 0; i < nitems(cpu_quirks); i++) { if ((midr & cpu_quirks[i].midr_mask) == - cpu_quirks[i].midr_value) { + cpu_quirks[i].midr_value && + (cpu_quirks[i].flags & mask) == flags) { cpu_quirks[i].quirk_install(); } } } + +/* + * Install any CPU errata we need. On CPU 0 we only install the errata that + * don't depend on device drivers as this is called early in the boot process. + * On other CPUs the device drivers have already attached so install all + * applicable errata. + */ +void +install_cpu_errata(void) +{ + /* + * Only install early CPU errata on CPU 0, device drivers may not + * have attached and some workarounds depend on them, e.g. to query + * SMCCC. + */ + if (PCPU_GET(cpuid) == 0) { + install_cpu_errata_flags(CPU_QUIRK_POST_DEVICE, 0); + } else { + install_cpu_errata_flags(0, 0); + } +} + +/* + * Install any errata workarounds that depend on device drivers, e.g. use + * SMCCC to install a workaround. + */ +static void +install_cpu_errata_late(void *dummy __unused) +{ + MPASS(PCPU_GET(cpuid) == 0); + install_cpu_errata_flags(CPU_QUIRK_POST_DEVICE, CPU_QUIRK_POST_DEVICE); +} +SYSINIT(install_cpu_errata_late, SI_SUB_CONFIGURE, SI_ORDER_MIDDLE, + install_cpu_errata_late, NULL); From nobody Tue Oct 3 22:14:01 2023 X-Original-To: dev-commits-src-branches@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 4S0XCs2wKPz4w3kH; Tue, 3 Oct 2023 22:14: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0XCs258kz4rm8; Tue, 3 Oct 2023 22:14:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371241; 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=E3u+lM7vDkSUyk4CAw9lMIABDM5JWIiMq0jhai/Tcmk=; b=ysTnmFxOgNV2HOsY8RawCcr788D6HUrfXmD4u+5q/j1Rpfmd5NPUhdZ28vf8wEAng+90HT P9sRMlYnMM1CLtdV8zTf617uwDQ7IBITjJBmACVcULEKNlW+WTV1xnApctfhJ7/ee+eSCc MEZgKKhdXSIbAji1N9HY2cnnPDDfLMboQnjQCJi6crQk533JtfQpG5XEaoOsAL/YEhATJK 96zVXH5rO1iTqC98Tuug0eoXAMo//1EFxdhE7YKHR2euoh7evcYvg7spWuOugopQnrxGJl NC20BcOQFqCkYkRX8sZ7nSBJ5vivWQM+OANclgfxO1WWqAPvVbblpHpfVsQ1lQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696371241; a=rsa-sha256; cv=none; b=Y531fpKzBW3UpAPexnVy1HkCZD77LLuplbX9a4FcEN5GILXerJbQ662C1+kq6g3XIMEuAS WW/898VVIPG1Ki0hQpbNmA9ZFUcFSpPkZvB6AEcBs0bKeycOyxJ+q2gOSglONxfJSoeo0i MgJmEOYMGBzySaQDdGxvTIbcMQcprGPQpoRDa8o++4nMoeufPiM0rG7jVuiNqt6JBI/PL1 C41LwgSg/qRISGbHCnK8V7/NzsijM7j0OI3iwacOh3cunXSPiBLlqHNeeXdRRUuA/B3xnd zxyKS+DWIHqBjWjEHk8Y8Km2rifI8EvFQJ1nx/NCoAu4hd0fGSKJCaDuA4p83g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371241; 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=E3u+lM7vDkSUyk4CAw9lMIABDM5JWIiMq0jhai/Tcmk=; b=uCh5zH/aUOspoUB3JX/A6L1sdSeJcbm9csC4FyYj874Wl8w/13pqjybolAnWJBysdKRF3s XnSl21+X5U/i/WQvBEKwFjuENB93SxK+pWKEFxbKRbNMVjpsAq64GSCKBKo/fMS1MXB0Kr jJdH4hwFXo1+jRrv8OVIEc66aRrBiOBOEEkDkvWWIoC4M+cm8oeR9hjxIifKdNvlVvUh8G Jz5qhRzdZIjhWbVYP0tPaiCFSoLGgamqBTNDZnIACsZoiTUxg1+QsN2k8F7cWuZKg7jitM vEB2AfgVYVD2Wxe1FbSnjeQhLVvg9JDmhaJ26jcU5yUh2VHqnUUbqJkmzfvDwg== 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 4S0XCs17vmz1BP7; Tue, 3 Oct 2023 22:14:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393ME1lU071136; Tue, 3 Oct 2023 22:14:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393ME151071133; Tue, 3 Oct 2023 22:14:01 GMT (envelope-from git) Date: Tue, 3 Oct 2023 22:14:01 GMT Message-Id: <202310032214.393ME151071133@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: d20ece445acf - releng/13.2 - Add UPDATING entries and bump version. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/13.2 X-Git-Reftype: branch X-Git-Commit: d20ece445acfc5d29ca096b38e30e4c0cb0b0d95 Auto-Submitted: auto-generated The branch releng/13.2 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=d20ece445acfc5d29ca096b38e30e4c0cb0b0d95 commit d20ece445acfc5d29ca096b38e30e4c0cb0b0d95 Author: Gordon Tetlow AuthorDate: 2023-10-03 21:51:35 +0000 Commit: Gordon Tetlow CommitDate: 2023-10-03 21:51:35 +0000 Add UPDATING entries and bump version. Approved by: so --- UPDATING | 14 ++++++++++++++ sys/conf/newvers.sh | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/UPDATING b/UPDATING index ff18a91feaf9..a31fdd8cb027 100644 --- a/UPDATING +++ b/UPDATING @@ -12,6 +12,20 @@ Items affecting the ports and packages system can be found in /usr/ports/UPDATING. Please read that file before updating system packages and/or ports. +20231003: + 13.2-RELEASE-p4 FreeBSD-EN-23:12.freebsd-update + FreeBSD-SA-23:12.msdosfs + FreeBSD-SA-23:13.capsicum + FreeBSD-SA-23:14.smccc + + freebsd-update to 14.0 fails [EN-23:12.freebsd-update] + + Fix msdosfs data disclosure [SA-23:12.msdosfs] + + copy_file_range insufficient capability rights check [SA-23:13.capsicum] + + arm64 boot CPUs may lack speculative execution protections [SA-23:14.smccc] + 20230906: 13.2-RELEASE-p3 FreeBSD-EN-23:09.freebsd-update FreeBSD-EN-23:10.pci diff --git a/sys/conf/newvers.sh b/sys/conf/newvers.sh index 31ce004e1417..c5c5d09070b8 100644 --- a/sys/conf/newvers.sh +++ b/sys/conf/newvers.sh @@ -54,7 +54,7 @@ TYPE="FreeBSD" REVISION="13.2" -BRANCH="RELEASE-p3" +BRANCH="RELEASE-p4" if [ -n "${BRANCH_OVERRIDE}" ]; then BRANCH=${BRANCH_OVERRIDE} fi From nobody Tue Oct 3 22:14:09 2023 X-Original-To: dev-commits-src-branches@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 4S0XD16CTxz4w4F9; Tue, 3 Oct 2023 22:14: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0XD15MBbz4s7F; Tue, 3 Oct 2023 22:14:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371249; 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=HDS74KMeLxvXnPYvZ/7X8C/1pnB2QK+YnREtvtRhHV0=; b=rUBbV1BkeKJlFVVZQn3vQgIbykkdomGFWcwrXVVlEGkPaUFeLy3IYKE5FeZhzhDk4Q1YrF CL/sALYxwbBKYM2uT2BX+Arulrb+vgr8Sfun9/72aM4maVnNSwLOjsv3UN3tbQTM6BNclH IIw/2Te//ru5jAVtMHl8C66Hqs519BnXCaS1r3uLcPtWHkmECST3mxRi7nNtF4Q0HT2lEi iGpPgt21a6mezYG2GbCil0nV9J3PbTlf9AYF0mAbeIr8HN8+EVL/PKmdrPPkrqzCtnjGnZ 3rRkKZ8eBHDxpSk2WYZNNWdM4uE0JeqRpfLY/2c6AOvnl9Zr1TktLCKeW7V4Aw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696371249; a=rsa-sha256; cv=none; b=AORZn1A3FZyW0inzxF46bMJWgVfnhF3pHV9TUZ/vc58b2Y0x4AfrivVKU7pqYmAN3XybRY vO2B/SGuHb+sz4+Vm/gR2vZ23KOB2uRuL8mUtaqHMqhUYLpDL83YEbqMNy9Lpu/6xaQrPL jpWTWUKrNJyxFfkmBXEk3lOVEkE6I5tidV1xqUlE0+kbaOgQvjWh/p5E5i9pNSITRMPbT9 94GhLS3TThk3nKoctbpRG3zJ/Xp2qvUG5l9PRNIJAmsNq92KSfHPs/K6WWkF/bNFpu8pvt UZYJNNF9X3Gm9ES8Num2UhmawwMabNocP53k0yD/R9A4NT/uHHz64x+0BntlhQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371249; 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=HDS74KMeLxvXnPYvZ/7X8C/1pnB2QK+YnREtvtRhHV0=; b=RpG4iatoOP6xgdvJDZzv377x9TcZ3yv90jrvCloWnWN4HXqsDuSkEXP0kTz1S5sUByXkhH +F7d9tcUkMgGLOs0gIJHf9LL0UeWS0knYwc6WigjTpOMOIVec45dzcTcX+L/NOLn+kwhrj 2JMXXsldPDCDkzqdOsZrS8j1q69pg7zxE9OQFDQ4N3M/Ywx82eCLJZMEesJzJOXaoGR16/ A1JX7FtCvCMrXoXrC/vWJrZx8W7LzmKLGD3vCIUVImlivef2zRpwpk2wxF/xhkZX+O3/fV x2c6m7RuAZyCSMS/35p7hKizp37BTOoMm4JzVRRNT5a/8SdIAB6yAs2pYHlGIA== 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 4S0XD14Rt3z1BrC; Tue, 3 Oct 2023 22:14:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393ME9So071326; Tue, 3 Oct 2023 22:14:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393ME9dY071323; Tue, 3 Oct 2023 22:14:09 GMT (envelope-from git) Date: Tue, 3 Oct 2023 22:14:09 GMT Message-Id: <202310032214.393ME9dY071323@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: 193b7e3d0af5 - releng/12.4 - freebsd-update: Fix merging already-updated files List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/12.4 X-Git-Reftype: branch X-Git-Commit: 193b7e3d0af5205f770c30620711889eff324ae8 Auto-Submitted: auto-generated The branch releng/12.4 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=193b7e3d0af5205f770c30620711889eff324ae8 commit 193b7e3d0af5205f770c30620711889eff324ae8 Author: Colin Percival AuthorDate: 2023-05-05 03:00:58 +0000 Commit: Gordon Tetlow CommitDate: 2023-10-03 21:08:36 +0000 freebsd-update: Fix merging already-updated files When performing an "upgrade" (moving between FreeBSD releases, as opposed to "update" which merely applies security/errata updates to the installed release) FreeBSD Update: 1. Generates a list of "files needing to be merged", namely those files which don't match the version installed in the "old" release and have paths matching the MergeChanges configuration directive (by default, /boot/device.hints and everything under /etc/). and later on, 2. Compares the currently-installed files to the versions in the "new" release, removing index entries for files which "don't need to be updated because they're not changing". Unfortunately if a file falls into both of these categories -- that is to say, if a file in /etc/ is the same as the version in the new release and not the same as the version in the old release -- the resulting "merge" step saw that the file was no longer listed as being part of the new release, resulting in the file being deleted. For the first 18 years of FreeBSD Update's existence, this never happened, since $FreeBSD$ tags resulted in "new release" files always being different from any files systems would already have installed. This commit fixes this behaviour by only placing a file into the "files needing to be merged" list if it does not match the version in the old release *or* the version in the new release. Reported by: des Reviewed by: delphij (earlier version), des, emaste Approved by: so Security: FreeBSD-EN-23:09.freebsd-update Differential Revision: https://reviews.freebsd.org/D39973 (cherry picked from commit c55b7e522629cb78adeb54bd9964304481d55eab) (cherry picked from commit 5f446a12dac2a8be8a1b4fc53a383d18896df611) --- usr.sbin/freebsd-update/freebsd-update.sh | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/usr.sbin/freebsd-update/freebsd-update.sh b/usr.sbin/freebsd-update/freebsd-update.sh index 9743cd652d16..57d94a25881a 100644 --- a/usr.sbin/freebsd-update/freebsd-update.sh +++ b/usr.sbin/freebsd-update/freebsd-update.sh @@ -1677,11 +1677,12 @@ fetch_inspect_system () { echo "done." } -# For any paths matching ${MERGECHANGES}, compare $1 and $2 and find any -# files which differ; generate $3 containing these paths and the old hashes. +# For any paths matching ${MERGECHANGES}, compare $2 against $1 and $3 and +# find any files with values unique to $2; generate $4 containing these paths +# and their corresponding hashes from $1. fetch_filter_mergechanges () { # Pull out the paths and hashes of the files matching ${MERGECHANGES}. - for F in $1 $2; do + for F in $1 $2 $3; do for X in ${MERGECHANGES}; do grep -E "^${X}" ${F} done | @@ -1689,9 +1690,10 @@ fetch_filter_mergechanges () { sort > ${F}-values done - # Any line in $2-values which doesn't appear in $1-values and is a - # file means that we should list the path in $3. - comm -13 $1-values $2-values | + # Any line in $2-values which doesn't appear in $1-values or $3-values + # and is a file means that we should list the path in $3. + sort $1-values $3-values | + comm -13 - $2-values | fgrep '|f|' | cut -f 1 -d '|' > $2-paths @@ -1703,10 +1705,10 @@ fetch_filter_mergechanges () { while read X; do look "${X}|" $1-values | head -1 - done < $2-paths > $3 + done < $2-paths > $4 # Clean up - rm $1-values $2-values $2-paths + rm $1-values $2-values $3-values $2-paths } # For any paths matching ${UPDATEIFUNMODIFIED}, remove lines from $[123] @@ -2698,7 +2700,7 @@ upgrade_run () { # Based on ${MERGECHANGES}, generate a file tomerge-old with the # paths and hashes of old versions of files to merge. - fetch_filter_mergechanges INDEX-OLD INDEX-PRESENT tomerge-old + fetch_filter_mergechanges INDEX-OLD INDEX-PRESENT INDEX-NEW tomerge-old # Based on ${UPDATEIFUNMODIFIED}, remove lines from INDEX-* which # correspond to lines in INDEX-PRESENT with hashes not appearing From nobody Tue Oct 3 22:14:10 2023 X-Original-To: dev-commits-src-branches@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 4S0XD30cbWz4w4Bm; Tue, 3 Oct 2023 22:14: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0XD26WG1z4s7n; Tue, 3 Oct 2023 22:14:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371251; 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=BR/p81fNWkPFFZ9ELo3+l2Jr25F8ZKnEggakkoOf6dA=; b=pgA7XNxmyL5t5Z4REuCd6+Q7VOENGxzKtSRWJscTi5opAmrXhR+QKShGyO/E2liaxPEKWR S+DgR7LEC98pNLQ71OaHnwKIHG8s88s8sjVZNG/OJqqqkMvye+9xZNMn/p6Ib98zkfBq4P QVgEZza1sAsVKlPFl8/kOICOOKag7A3bydUpYX4kxnB7JWgjqDBnqBzXnjhW6ABQDMBWr+ q6p/Za+lFEP2KSz6JiWBJqI3NEDUL3aAV3nHMod5cCnJbgqerzM6/zjsLeteEJIVn9dHCm SrskP0w931Iemtm1F24v/7TzyNNNY4ddLHs4XP8MiWgCelG313HdOJGr2Vf5Ww== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696371251; a=rsa-sha256; cv=none; b=QsxVYoBUtwFfkegC7nrrsl7odglfW6rtw6HWg9MAZlXDY9qzpGdCsPGqlPkDvlVqZz0fFy +18Apa8QBDd8T4Gfm117Pz0QsjxSZxyThokC12HevgPGLdLf0KdJXaDu/3EDCHBRImkh4U wC9ph4GqHg2ztU04u6kWoFiLW7T1YauDT+rgQC55/NdSz7XI/5IM4zZyGs7MHMX87eVZTt 46gWxhUKzkD2KrQsurOIzlXWu3qfySJwTnPdQrtdcMzRcdIizlQBM4TB2/YszAAg9NF+RD rxieA7Zxqw9U2mQO62/XGMJr+IlTHWrqOVkopn1guESaU+gImn+KCWJqan+tWw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371251; 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=BR/p81fNWkPFFZ9ELo3+l2Jr25F8ZKnEggakkoOf6dA=; b=fFySlpNIXsfo8qoT5K/iGAsjgK+Jobu03O/E17e1br4qT/J1Lctc6EwdrYYaDmadWbNzc+ w8cAFFOKlg/wrgvehEpOxeF4RiU/4b2bQAbyqiwYIp3jo7P8Xu7FF+BRcW90xNryMtK00i rU5tlT6/Eu0pxPczs/zPn7V01Pl6rRD5DRjuAFeEuSH4WjgUEiuC5j2YUJW+sp/jpBOdDP c2dy6lgMckpQ14c0BzKqhcvvvDs3XnGyl4b7yICFmwfbnaO9WPUGACXNBxs5Rsx1Qgo+6k QdxQDOK2RrAHWtrfuBN3id6PVPzACt82taDNrlCExoPDYjD+nf60OIDbAZa87g== 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 4S0XD25ZjFz1BrD; Tue, 3 Oct 2023 22:14:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393MEA4f071374; Tue, 3 Oct 2023 22:14:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393MEAxG071371; Tue, 3 Oct 2023 22:14:10 GMT (envelope-from git) Date: Tue, 3 Oct 2023 22:14:10 GMT Message-Id: <202310032214.393MEAxG071371@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: 0eb6c273622d - releng/12.4 - freebsd-update: handle file -> directory on upgrade List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/12.4 X-Git-Reftype: branch X-Git-Commit: 0eb6c273622d77a89115e7d4f01609eefc50b33c Auto-Submitted: auto-generated The branch releng/12.4 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=0eb6c273622d77a89115e7d4f01609eefc50b33c commit 0eb6c273622d77a89115e7d4f01609eefc50b33c Author: Ed Maste AuthorDate: 2023-09-27 13:36:33 +0000 Commit: Gordon Tetlow CommitDate: 2023-10-03 21:10:42 +0000 freebsd-update: handle file -> directory on upgrade Upgrading from FreeBSD 13.2 to 14.0 failed with install: ///usr/include/c++/v1/__string exists but is not a directory because __string changed from a file to a directory with an LLVM upgrade. Now, remove the existing file when the type conflicts. Note that this is only an interim fix to facilitate upgrades from 13.2 for 14.0 BETA testing. This change does not handle the directory -> file case and further work is needed. PR: 273661 Reviewed by: dim, gordon Approved by: so Security: FreeBSD-EN-23:12.freebsd-update Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D41893 (cherry picked from commit f6d37c9ca13f8ab0ef32cf5344daecb8122d1e85) (cherry picked from commit 274281864fc03c62443677751bf3036fbbf9d778) --- usr.sbin/freebsd-update/freebsd-update.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/usr.sbin/freebsd-update/freebsd-update.sh b/usr.sbin/freebsd-update/freebsd-update.sh index 57d94a25881a..324e838fd8a7 100644 --- a/usr.sbin/freebsd-update/freebsd-update.sh +++ b/usr.sbin/freebsd-update/freebsd-update.sh @@ -2892,7 +2892,13 @@ install_from_index () { while read FPATH TYPE OWNER GROUP PERM FLAGS HASH LINK; do case ${TYPE} in d) - # Create a directory + # Create a directory. A file may change to a directory + # on upgrade (PR273661). If that happens, remove the + # file first. + if [ -e "${BASEDIR}/${FPATH}" ] && \ + ! [ -d "${BASEDIR}/${FPATH}" ]; then + rm -f -- "${BASEDIR}/${FPATH}" + fi install -d -o ${OWNER} -g ${GROUP} \ -m ${PERM} ${BASEDIR}/${FPATH} ;; From nobody Tue Oct 3 22:14:11 2023 X-Original-To: dev-commits-src-branches@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 4S0XD42qpFz4w3kM; Tue, 3 Oct 2023 22:14:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0XD374Pnz4sRD; Tue, 3 Oct 2023 22:14:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371252; 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=70wGmAoku8H9gO49mTIpzrx2sCYQ2H8Gui4zLBy/zwI=; b=KBgBClaKsKHJKzhRs3KVmR4M9/SxND7hko0u1GhCrsszzfuJW7Xft0bfMC5ucGVPxPEXaC 6d+OYj+cXgxL9LaHEq4HMMwvhPggISIzW7MfURonzmoipnW+YEpFOYHPrvzDHkIlhlIzsx HqjPJSk4qnTsmQAQ9cwICmrwe4rZkh5Hsx4QxM0PSQaQxUXOwEZ8JqSYampnzlBQus6H6Z 8NYn8CoPQ17ihMgujCmH0hJxVIT7uKGaHpNF0nPss04pCH50ppPQERmhkaYLE+iGEqxKuS /B47r7oPzojBjVbKuWwUcFnP8cnzlNAmNiN5RhWV+HPXkrS+M/UaiYNR/8UM4Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696371252; a=rsa-sha256; cv=none; b=BJpaqp/TxwS3TLeq+3zxv/ZhMTvA9tHbbOE0ONmthYVQaSBvite/aq7c/CDeEXWklav79W FZpUVoKCWbXr2Cx5Hfpf5wYZs7j8lmCePsfs22k/OMMAhF146AfvrKp9T/0KrfiZSDRIPx vdln5O1+MtLP4lvU+NCTlyjqasNSaFYpo6oG5G2jV2SETx9Ceold44ABfir/nk663sV1kg AUBrD4o432VBaEydX2TW6gnqPk+4/rY53H9MLFQdN9ZlPKD85SpqCkVYfThw5GkH9Dthm2 XvDnQyj9g5DWv6CTU/prK7qKolKy6sjCTm+0hGOxOdlaDO3y2NBeXXcsNL3OlQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371252; 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=70wGmAoku8H9gO49mTIpzrx2sCYQ2H8Gui4zLBy/zwI=; b=olS64llP7GqF4Y6WszF63SxpPPDmCqszwOKOxqbASW26wL5efM2Zwrw2zNJaBloy7u7GVi Dpll8zEyiCqjeDN8nHJUbxFqz362h8h0phWUuEhZX35mL2ue0yKWB+QkOwXsckDwcJYZmH qdRkTRh+1GLKDkJzlmmRrCmOjubQjCIj86ypHbpz7mkM06I/gVJACFgRorSqv4bMTpYNT6 gGVKSX2AxfNrhZL31iU0GzMyMhKRYcmpwhULeSETNHiRWnRypZh6+9vioemcrT9mZYvhS5 j7WsEPCQEXXdiiXlfPJCQ8nPzB9qAsswBLjskDhoQaol5ddjoXQYd19lR+XrFw== 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 4S0XD36BHdz1C0X; Tue, 3 Oct 2023 22:14:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393MEBIX071419; Tue, 3 Oct 2023 22:14:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393MEBoB071416; Tue, 3 Oct 2023 22:14:11 GMT (envelope-from git) Date: Tue, 3 Oct 2023 22:14:11 GMT Message-Id: <202310032214.393MEBoB071416@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: bb2ccf50d7f7 - releng/12.4 - msdosfs: zero partially valid extended cluster List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/12.4 X-Git-Reftype: branch X-Git-Commit: bb2ccf50d7f7c740743b29a26e2444e364df431e Auto-Submitted: auto-generated The branch releng/12.4 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=bb2ccf50d7f7c740743b29a26e2444e364df431e commit bb2ccf50d7f7c740743b29a26e2444e364df431e Author: Gordon Tetlow AuthorDate: 2023-10-03 21:14:47 +0000 Commit: Gordon Tetlow CommitDate: 2023-10-03 21:14:47 +0000 msdosfs: zero partially valid extended cluster Approved by: so Security: FreeBSD-SA-23:12.msdosfs Security: CVE-2023-5368 --- sys/fs/msdosfs/msdosfs_denode.c | 53 +++++++++++++++++++++++++++++++++-------- 1 file changed, 43 insertions(+), 10 deletions(-) diff --git a/sys/fs/msdosfs/msdosfs_denode.c b/sys/fs/msdosfs/msdosfs_denode.c index db9e0712d2b1..3b4e809d6196 100644 --- a/sys/fs/msdosfs/msdosfs_denode.c +++ b/sys/fs/msdosfs/msdosfs_denode.c @@ -365,10 +365,8 @@ detrunc(struct denode *dep, u_long length, int flags, struct ucred *cred) return (EINVAL); } - if (dep->de_FileSize < length) { - vnode_pager_setsize(DETOV(dep), length); + if (dep->de_FileSize < length) return deextend(dep, length, cred); - } /* * If the desired length is 0 then remember the starting cluster of @@ -477,13 +475,16 @@ int deextend(struct denode *dep, u_long length, struct ucred *cred) { struct msdosfsmount *pmp = dep->de_pmp; + struct vnode *vp = DETOV(dep); + struct buf *bp; + off_t eof_clusteroff; u_long count; int error; /* * The root of a DOS filesystem cannot be extended. */ - if ((DETOV(dep)->v_vflag & VV_ROOT) && !FAT32(pmp)) + if ((vp->v_vflag & VV_ROOT) != 0 && !FAT32(pmp)) return (EINVAL); /* @@ -503,15 +504,47 @@ deextend(struct denode *dep, u_long length, struct ucred *cred) if (count > pmp->pm_freeclustercount) return (ENOSPC); error = extendfile(dep, count, NULL, NULL, DE_CLEAR); - if (error) { - /* truncate the added clusters away again */ - (void) detrunc(dep, dep->de_FileSize, 0, cred); - return (error); - } + if (error != 0) + goto rewind; } + + /* + * For the case of cluster size larger than the page size, we + * need to ensure that the possibly dirty partial buffer at + * the old end of file is not filled with invalid pages by + * extension. Otherwise it has a contradictory state of + * B_CACHE | B_DELWRI but with invalid pages, and cannot be + * neither written out nor validated. + * + * Fix it by proactively clearing extended pages. Need to do + * both vfs_bio_clrbuf() to mark pages valid, and to zero + * actual buffer content which might exist in the tail of the + * already valid cluster. + */ + error = bread(vp, de_cluster(pmp, dep->de_FileSize), pmp->pm_bpcluster, + NOCRED, &bp); + if (error != 0) + goto rewind; + vfs_bio_clrbuf(bp); + eof_clusteroff = de_cn2off(pmp, de_cluster(pmp, dep->de_FileSize)); + vfs_bio_bzero_buf(bp, dep->de_FileSize - eof_clusteroff, + pmp->pm_bpcluster - dep->de_FileSize + eof_clusteroff); + if (!DOINGASYNC(vp)) + (void)bwrite(bp); + else if (vm_page_count_severe() || buf_dirty_count_severe()) + bawrite(bp); + else + bdwrite(bp); + + vnode_pager_setsize(vp, length); dep->de_FileSize = length; dep->de_flag |= DE_UPDATE | DE_MODIFIED; - return (deupdat(dep, !DOINGASYNC(DETOV(dep)))); + return (deupdat(dep, !DOINGASYNC(vp))); + +rewind: + /* truncate the added clusters away again */ + (void)detrunc(dep, dep->de_FileSize, 0, cred); + return (error); } /* From nobody Tue Oct 3 22:14:12 2023 X-Original-To: dev-commits-src-branches@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 4S0XD52wckz4w3wC; Tue, 3 Oct 2023 22:14:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0XD51Bvrz4sV1; Tue, 3 Oct 2023 22:14:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371253; 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=/mpP2sgNXJ8h1/FY+KAepxCnpumk3b9Q/F1Y0XH3Nik=; b=eJwvkw9oj46O+th/vJP8r5jHoCDwUmacwXtX/ivuC6mE8WWnXxyNm89yx4JtJsb8mMphOj bptaZIqrYRpke415+eueXFz6v5K7sNQZsuxqb6ub906bdr7TH0iXstdTyTXThjSymnJXEA T8U5YxInEujYbWTVMR9u5FacQ9BxSTo8SEBH8xgOTykhF5hrAm8Sjiwn+B1KW376/3m8uU QfVLQZ63qyThWOpv9D5HL42x4Umo3UMZolIfifYiVlvQOccIZoR0F0kuXH+c/+7hOQ1The pjazdePRHF5NduGiEN3dRI1z2+tHkK61bSZ92hg4AapVHgPPbPWKDV9E80pQnQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696371253; a=rsa-sha256; cv=none; b=yjjHdZ2we69vAZCX791rLXndwKzHlOh/RBumoKiXmoz1FAfh5/f7qpbODd+5Wriz34Ni/b IEIwFzV25StQIFGG2E7WA6v1Ntn00e9NvAP5DhwynaH3PKeBp0TFCzVDY27hTDAua1E2pS ZzfAhXzzgiWZjnrUiID5Yf7bC2DrXPRV7TmhnKwdM5awM/gUo7J/mqkkUmB9iXrnY4G6xW KKd52cMR4+n0jvW+29AyYn+Ix8sisWq2qh+auKoSJ1sLWiheb/OnRbx3LVb8zPp2ITlqox MT1WnU7yV/oiao2BUTo+tJ4X70lriN/2W+Tz+LRLE004+bGi6Il9H3+Ux8jgGA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696371253; 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=/mpP2sgNXJ8h1/FY+KAepxCnpumk3b9Q/F1Y0XH3Nik=; b=qSObZfM6Cq9Ej6HWJ+vDzAj66m72+FYetPMIefcGXheYXKGV9MUkm9VuFBUQo5OBSy9D4n VqGSoCDra/zXlUnWMbSR21XvpKmYVefcFJHVPjPAUpB/LlC+a2LAASFuXk8oLYiEzMJO+h MGljYkebVWIN25D8U7Wci7W1HxGqg6sIIiszN7Nt0f2LG2dRPi6HWSXhqLJKeJieLmM2Tk 4rcYsS/41Qcl1jlQF/kJ7c2a0+nWf5MUTV2/J+h4OoYQ6B8mSpbsvwbXbbpY9nl7B5m5yM GFgrmtLFT6apOP7vlKUCM7LLCY8e+AIW697LkgOynzoTIBH8uAAP7qqD39+sIA== 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 4S0XD50FRFz1BZW; Tue, 3 Oct 2023 22:14:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 393MECwU071472; Tue, 3 Oct 2023 22:14:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 393MECwh071469; Tue, 3 Oct 2023 22:14:12 GMT (envelope-from git) Date: Tue, 3 Oct 2023 22:14:12 GMT Message-Id: <202310032214.393MECwh071469@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Gordon Tetlow Subject: git: b1b39c2f2fe4 - releng/12.4 - Add UPDATING entries and bump version. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gordon X-Git-Repository: src X-Git-Refname: refs/heads/releng/12.4 X-Git-Reftype: branch X-Git-Commit: b1b39c2f2fe4067527d96dfcda70e556a817ff41 Auto-Submitted: auto-generated The branch releng/12.4 has been updated by gordon: URL: https://cgit.FreeBSD.org/src/commit/?id=b1b39c2f2fe4067527d96dfcda70e556a817ff41 commit b1b39c2f2fe4067527d96dfcda70e556a817ff41 Author: Gordon Tetlow AuthorDate: 2023-10-03 21:19:27 +0000 Commit: Gordon Tetlow CommitDate: 2023-10-03 21:19:27 +0000 Add UPDATING entries and bump version. Approved by: so --- UPDATING | 11 +++++++++++ sys/conf/newvers.sh | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/UPDATING b/UPDATING index ecde75536cbc..100c281c3786 100644 --- a/UPDATING +++ b/UPDATING @@ -17,6 +17,17 @@ from older versions of FreeBSD, try WITHOUT_CLANG and WITH_GCC to bootstrap to the tip of head, and then rebuild without this option. The bootstrap process from older version of current across the gcc/clang cutover is a bit fragile. +20231003: + 12.4-RELEASE-p6 FreeBSD-EN-23:09.freebsd-update + FreeBSD-EN-23:12.freebsd-update + FreeBSD-SA-23:12.msdosfs + + freebsd-update incorrectly merges files on upgrade [EN-23:09.freebsd-update] + + freebsd-update to 14.0 fails [EN-23:12.freebsd-update] + + Fix msdosfs data disclosure [SA-23:12.msdosfs] + 20230906: 12.4-RELEASE-p5 FreeBSD-SA-23:10.pf FreeBSD-SA-23:11.wifi diff --git a/sys/conf/newvers.sh b/sys/conf/newvers.sh index bb919a38da7d..fa6d3e9340b8 100644 --- a/sys/conf/newvers.sh +++ b/sys/conf/newvers.sh @@ -49,7 +49,7 @@ TYPE="FreeBSD" REVISION="12.4" -BRANCH="RELEASE-p5" +BRANCH="RELEASE-p6" if [ -n "${BRANCH_OVERRIDE}" ]; then BRANCH=${BRANCH_OVERRIDE} fi From nobody Wed Oct 4 00:42:44 2023 X-Original-To: dev-commits-src-branches@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 4S0bWS5mf0z4wHZQ; Wed, 4 Oct 2023 00:42: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0bWS4nc7z4VdC; Wed, 4 Oct 2023 00:42:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696380164; 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=UjlXti0T8FOimFChp6e1wZ3e7ObQM/YOqXuy3tFKHgk=; b=PfJDtSYEXa9gM8Q0lQJnDaiYsW/J2G+K5S5VFJF4k+CfVCCIVYrJVZkS4kf177P+Vu9Zp9 plmPl5ao2r9J719pTnAyPmQGJ+Pn9YYfGTfn4XhNhiDrOVaSipYlMun4RSAjlf9xSZtj9n 2/g5vNjp2BGxOzn4QPeAsMe/rmfh9SPpDOStn2ORFK69diAeFB7CRpn4RLviLLWm8n8KFf Cv21x6h/sKP+y8eQnIPFWMZ+9IpgaIp9vtmuRxHKdXrUNvx2k0j+3a6BYQVWwenCuBfEmR 8zLa9mRZI1XWgqixx/csrwcaPuH4JVvM+nh10olhAT8eg7CwqyRpiWyzHIIcKg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696380164; a=rsa-sha256; cv=none; b=VvtuvEP7pQ1mtrhBQ2YPgw9kpLhuf9MDRBrDpOeBIxObjvYVlhSEasRLNTGIRiQJ7Sm1fw /j5ZQkawYkb+Mvc4+yRDKIM6w/jrfNb3fjk/YpuODWXHvlMPM46soRoJsgDbLF80goGtPw 3jIJasTLShxaUAstbJxkAGJgo8mY+aJrzqf9eVHOomEAUUUJHHqt5Um+jT15DNDrEp0G0G lpTWutiF8KLIDa6S0qXr+QAo5AVPl6pcWKxYZDn7RZ7M1GJiJAFguXFXPq9XUMhmzqhgyk U5pO3FY46LsVLghTYPzFNMh91kE9UFJns/E+tdFM3c2nwZFtZmwoRD0b6UIuZA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696380164; 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=UjlXti0T8FOimFChp6e1wZ3e7ObQM/YOqXuy3tFKHgk=; b=aUHPX21MPk9CWu/cCF2uuipAcqJ1vG/z6pyoC6PqkRyIZdns78p3lbyEbScYf8IemEl/kM jR9rLRLQte07ZN8HimeoOp31D4Vmz1P3+w5JfMNKiwwufipRu8y2WrSH3pX/+cr68+gS9p QhkUR3zup7AZAnNvpJg3z4tZ2Stdg4YTyXl7xWRp6hjFF2qxYw+NdhL/3uWhopRmIibohR fZSa5vQdIx5vouSfROlrz7zfPzXqdB5daFK9qfe7tCndwAZOBBBsxF8IoCh1ZQgYt6CZxd 9KJtxiLvnDgHe+oTyL2WHpzEKLMhRSut+9wMiQrpFa31c6QEYDtjrOp2JF1XGA== 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 4S0bWS3qmyz2dY; Wed, 4 Oct 2023 00:42:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3940gitb020548; Wed, 4 Oct 2023 00:42:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3940giQR020545; Wed, 4 Oct 2023 00:42:44 GMT (envelope-from git) Date: Wed, 4 Oct 2023 00:42:44 GMT Message-Id: <202310040042.3940giQR020545@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Piotr Kubaj Subject: git: 56a2b5d640f7 - stable/14 - ObsoleteFiles.inc: only leave ofwdump.8.gz when WITH_FDT is set List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: pkubaj X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 56a2b5d640f71ce1630f923e562b5878e1b6f945 Auto-Submitted: auto-generated The branch stable/14 has been updated by pkubaj: URL: https://cgit.FreeBSD.org/src/commit/?id=56a2b5d640f71ce1630f923e562b5878e1b6f945 commit 56a2b5d640f71ce1630f923e562b5878e1b6f945 Author: Piotr Kubaj AuthorDate: 2023-10-01 21:36:37 +0000 Commit: Piotr Kubaj CommitDate: 2023-10-04 00:42:32 +0000 ObsoleteFiles.inc: only leave ofwdump.8.gz when WITH_FDT is set Approved by: mhorne Differential Revision: https://reviews.freebsd.org/D41905 MFC after: 3 days (cherry picked from commit 4cf8075264c9db8f3e39a1f17def58cda8803853) --- ObsoleteFiles.inc | 5 ----- tools/build/mk/OptionalObsoleteFiles.inc | 4 ++++ 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index 589f6b968e9d..6f07b70494f8 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -17648,11 +17648,6 @@ OLD_FILES+=usr/share/man/man5/usbd.conf.5.gz .if ${TARGET_ARCH} != "i386" && ${TARGET_ARCH} != "amd64" OLD_FILES+=usr/share/man/man8/boot_i386.8.gz .endif -.if ${TARGET_ARCH} != "aarch64" && ${TARGET} != "arm" && \ - ${TARGET_ARCH} != "powerpc" && ${TARGET_ARCH} != "powerpc64" && \ - ${TARGET_ARCH} != "sparc64" && ${TARGET} != "mips" -OLD_FILES+=usr/share/man/man8/ofwdump.8.gz -.endif OLD_FILES+=usr/share/man/man8/mount_reiserfs.8.gz OLD_FILES+=usr/share/man/man9/VFS_START.9.gz OLD_FILES+=usr/share/man/man9/cpu_critical_exit.9.gz diff --git a/tools/build/mk/OptionalObsoleteFiles.inc b/tools/build/mk/OptionalObsoleteFiles.inc index 82ea542d7f55..b782f8d102b0 100644 --- a/tools/build/mk/OptionalObsoleteFiles.inc +++ b/tools/build/mk/OptionalObsoleteFiles.inc @@ -2015,6 +2015,10 @@ OLD_DIRS+=usr/share/examples/uefisign OLD_DIRS+=usr/share/examples/ypldap .endif +.if ${MK_FDT} == no +OLD_FILES+=usr/share/man/man8/ofwdump.8.gz +.endif + .if ${MK_FINGER} == no OLD_FILES+=usr/bin/finger OLD_FILES+=usr/share/man/man1/finger.1.gz From nobody Wed Oct 4 01:01:38 2023 X-Original-To: dev-commits-src-branches@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 4S0bxG5CYhz4wK1N; Wed, 4 Oct 2023 01:01: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0bxG52jtz4XJL; Wed, 4 Oct 2023 01:01:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381298; 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=MkvRv282KAXwkdesL+E1nvmMWiIzv9GhjVXwf1Y8vfI=; b=swS63W6XTD3a5v7GSKq4/YUnw5sg6UNhWBJban7zkNPH6Basn8cISzQqSlarl/GbXbk4mv jqK418Cz1Yv81IoyViCIpBJDoC7VsWMCKzEy2amb8uS8OU6UG6sL83i0ftsDQFE8fwRLSd EJovKqOaPgpCe6aseqyzuITXl4RSFinW4YTCRDXAe9LujZEsbVrmckbXTiyf71qKYI4wHf 03rhMzZPB8BJxeDOCcQOp/tp7J1Lm+qsaoiT07R7aGo5tG+iKdA+j8bGc+gFovBMSIQ4BB 7anpvCsgev3aRl9/nGR8amA/MpcB++UmapeHy8fvFzC0Pwu02Qc4q1HbhTpI6A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696381298; a=rsa-sha256; cv=none; b=ZVe7DvwNCh81xNr5d0aAi2/Jawapt6Dbq0cJwjbVfXeyJakETmv5oRp9NuV129ZcIzlvhX mcG2OuNS2gvrt7lT7C9I/okNsP/UAVD8eiIVT9IjNs3FvxvscCwUZR7xrYlNK29HsOgyWW xvxUBoIvJW8mhgB0ojPPpxBlN7i1q7xo/MBZcbE+45+G4gh6kRDcDkKY/pCzLPN0ICorkY EoTC64ypC32xefG31TEW8riZXkdO5D8XzAwJUyhb3IUvNOdoEtgFtShWnD79jwReDqViMC n+yirBcm3rMJGEHYVidjUnTVbWHSicjxWXuwpZ8VLDMAQYufkIx011amkgNwgw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381298; 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=MkvRv282KAXwkdesL+E1nvmMWiIzv9GhjVXwf1Y8vfI=; b=qPKHuQpR7JNEPj3OsjlvLe9errG/+cFkes2RhNdwR8LSRsNhok7PC/PXd1xifUUAjEUaSW xVH7q4fzX7vGLnC/h5DlI8kC5cxNeCwLW4zkEw2UJRj+tD0yXIm0Zs0oeUMmSJSMpcpxO7 wot4NoCM+gloz1x3CpAMbNzHwIPsuwMezn8MgoDXN5LjW9dFLK4r1agMNNkb+RDVq4d1/G QYY6ycjwFwUYqnPEKiVjldzRxXFEON+06AB5FH2aU8mEUskh0wL2DTKI5rNXU8Qryo/WQG /78tnXziHNECgQF0OdjpZXR81/VqDIi/ZbYiGCysR/yvZSHJuMz7mMIPNTfcjw== 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 4S0bxG4701z2m5; Wed, 4 Oct 2023 01:01:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39411cUD049047; Wed, 4 Oct 2023 01:01:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39411cIT049044; Wed, 4 Oct 2023 01:01:38 GMT (envelope-from git) Date: Wed, 4 Oct 2023 01:01:38 GMT Message-Id: <202310040101.39411cIT049044@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Cy Schubert Subject: git: 36eb0dc68ba1 - stable/14 - sqlite3: Vendor import of sqlite3 3.43.1 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 36eb0dc68ba1ab12444f7ceb297e083debf69335 Auto-Submitted: auto-generated The branch stable/14 has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=36eb0dc68ba1ab12444f7ceb297e083debf69335 commit 36eb0dc68ba1ab12444f7ceb297e083debf69335 Author: Cy Schubert AuthorDate: 2023-09-19 15:06:50 +0000 Commit: Cy Schubert CommitDate: 2023-10-04 01:01:06 +0000 sqlite3: Vendor import of sqlite3 3.43.1 Release notes at https://www.sqlite.org/releaselog/3_43_1.html. Obtained from: https://www.sqlite.org/2023/sqlite-autoconf-3430100.tar.gz Merge commit 'fa2bb1440e13602676feec708ac7a9a3bb5ce5c8' into main (cherry picked from commit ec994981447e8a974426660b5071bc405280af73) --- contrib/sqlite3/Makefile.am | 2 +- contrib/sqlite3/Makefile.in | 2 +- contrib/sqlite3/Makefile.msc | 27 + contrib/sqlite3/configure | 20 +- contrib/sqlite3/configure.ac | 2 +- contrib/sqlite3/shell.c | 1019 +++- contrib/sqlite3/sqlite3.1 | 161 +- contrib/sqlite3/sqlite3.c | 7881 +++++++++++++++++++++--------- contrib/sqlite3/sqlite3.h | 106 +- contrib/sqlite3/sqlite3ext.h | 4 + contrib/sqlite3/sqlite3rc.h | 2 +- contrib/sqlite3/tea/configure | 20 +- contrib/sqlite3/tea/configure.ac | 2 +- contrib/sqlite3/tea/generic/tclsqlite3.c | 33 +- 14 files changed, 6509 insertions(+), 2772 deletions(-) diff --git a/contrib/sqlite3/Makefile.am b/contrib/sqlite3/Makefile.am index 694419b27dfd..1eaa560ff884 100644 --- a/contrib/sqlite3/Makefile.am +++ b/contrib/sqlite3/Makefile.am @@ -9,7 +9,7 @@ sqlite3_SOURCES = shell.c sqlite3.h EXTRA_sqlite3_SOURCES = sqlite3.c sqlite3_LDADD = @EXTRA_SHELL_OBJ@ @READLINE_LIBS@ sqlite3_DEPENDENCIES = @EXTRA_SHELL_OBJ@ -sqlite3_CFLAGS = $(AM_CFLAGS) -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_ENABLE_STMTVTAB -DSQLITE_ENABLE_DBSTAT_VTAB $(SHELL_CFLAGS) +sqlite3_CFLAGS = $(AM_CFLAGS) -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_DQS=0 -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_ENABLE_STMTVTAB -DSQLITE_ENABLE_DBSTAT_VTAB $(SHELL_CFLAGS) include_HEADERS = sqlite3.h sqlite3ext.h diff --git a/contrib/sqlite3/Makefile.in b/contrib/sqlite3/Makefile.in index d45c6b8f4cde..fe708a0a9d84 100644 --- a/contrib/sqlite3/Makefile.in +++ b/contrib/sqlite3/Makefile.in @@ -371,7 +371,7 @@ sqlite3_SOURCES = shell.c sqlite3.h EXTRA_sqlite3_SOURCES = sqlite3.c sqlite3_LDADD = @EXTRA_SHELL_OBJ@ @READLINE_LIBS@ sqlite3_DEPENDENCIES = @EXTRA_SHELL_OBJ@ -sqlite3_CFLAGS = $(AM_CFLAGS) -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_ENABLE_STMTVTAB -DSQLITE_ENABLE_DBSTAT_VTAB $(SHELL_CFLAGS) +sqlite3_CFLAGS = $(AM_CFLAGS) -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_DQS=0 -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_ENABLE_STMTVTAB -DSQLITE_ENABLE_DBSTAT_VTAB $(SHELL_CFLAGS) include_HEADERS = sqlite3.h sqlite3ext.h EXTRA_DIST = sqlite3.1 tea Makefile.msc sqlite3.rc sqlite3rc.h README.txt Replace.cs Makefile.fallback pkgconfigdir = ${libdir}/pkgconfig diff --git a/contrib/sqlite3/Makefile.msc b/contrib/sqlite3/Makefile.msc index 09daa867eced..13663d877757 100644 --- a/contrib/sqlite3/Makefile.msc +++ b/contrib/sqlite3/Makefile.msc @@ -52,6 +52,13 @@ MINIMAL_AMALGAMATION = 0 USE_STDCALL = 0 !ENDIF +# Set this non-0 to use structured exception handling (SEH) for WAL mode +# in the core library. +# +!IFNDEF USE_SEH +USE_SEH = 1 +!ENDIF + # Set this non-0 to have the shell executable link against the core dynamic # link library. # @@ -180,6 +187,12 @@ WIN32HEAP = 0 OSTRACE = 0 !ENDIF +# enable address sanitizer using ASAN=1 on the command-line. +# +!IFNDEF ASAN +ASAN = 0 +!ENDIF + # Set this to one of the following values to enable various debugging # features. Each level includes the debugging options from the previous # levels. Currently, the recognized values for DEBUG are: @@ -311,6 +324,13 @@ OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_ENABLE_MATH_FUNCTIONS OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_ENABLE_RBU=1 !ENDIF +# Should structured exception handling (SEH) be enabled for WAL mode in +# the core library? +# +!IF $(USE_SEH)!=0 +OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_USE_SEH=1 +!ENDIF + # These are the "extended" SQLite compilation options used when compiling for # the Windows 10 platform. # @@ -718,6 +738,13 @@ RCC = $(RCC) -DSQLITE_WIN32_MALLOC_VALIDATE=1 !ENDIF +# Address sanitizer if ASAN=1 +# +!IF $(ASAN)>0 +TCC = $(TCC) /fsanitize=address +!ENDIF + + # Compiler options needed for programs that use the readline() library. # !IFNDEF READLINE_FLAGS diff --git a/contrib/sqlite3/configure b/contrib/sqlite3/configure index 1016e350c37f..39694c06793b 100755 --- a/contrib/sqlite3/configure +++ b/contrib/sqlite3/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.71 for sqlite 3.42.0. +# Generated by GNU Autoconf 2.71 for sqlite 3.43.1. # # Report bugs to . # @@ -621,8 +621,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='sqlite' PACKAGE_TARNAME='sqlite' -PACKAGE_VERSION='3.42.0' -PACKAGE_STRING='sqlite 3.42.0' +PACKAGE_VERSION='3.43.1' +PACKAGE_STRING='sqlite 3.43.1' PACKAGE_BUGREPORT='http://www.sqlite.org' PACKAGE_URL='' @@ -1367,7 +1367,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures sqlite 3.42.0 to adapt to many kinds of systems. +\`configure' configures sqlite 3.43.1 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1438,7 +1438,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of sqlite 3.42.0:";; + short | recursive ) echo "Configuration of sqlite 3.43.1:";; esac cat <<\_ACEOF @@ -1563,7 +1563,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -sqlite configure 3.42.0 +sqlite configure 3.43.1 generated by GNU Autoconf 2.71 Copyright (C) 2021 Free Software Foundation, Inc. @@ -1833,7 +1833,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by sqlite $as_me 3.42.0, which was +It was created by sqlite $as_me 3.43.1, which was generated by GNU Autoconf 2.71. Invocation command line was $ $0$ac_configure_args_raw @@ -3106,7 +3106,7 @@ fi # Define the identity of the package. PACKAGE='sqlite' - VERSION='3.42.0' + VERSION='3.43.1' printf "%s\n" "#define PACKAGE \"$PACKAGE\"" >>confdefs.h @@ -15314,7 +15314,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by sqlite $as_me 3.42.0, which was +This file was extended by sqlite $as_me 3.43.1, which was generated by GNU Autoconf 2.71. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -15373,7 +15373,7 @@ ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config='$ac_cs_config_escaped' ac_cs_version="\\ -sqlite config.status 3.42.0 +sqlite config.status 3.43.1 configured by $0, generated by GNU Autoconf 2.71, with options \\"\$ac_cs_config\\" diff --git a/contrib/sqlite3/configure.ac b/contrib/sqlite3/configure.ac index a706a4753049..3d7da8b984c3 100644 --- a/contrib/sqlite3/configure.ac +++ b/contrib/sqlite3/configure.ac @@ -10,7 +10,7 @@ # AC_PREREQ(2.61) -AC_INIT(sqlite, 3.42.0, http://www.sqlite.org) +AC_INIT(sqlite, 3.43.1, http://www.sqlite.org) AC_CONFIG_SRCDIR([sqlite3.c]) AC_CONFIG_AUX_DIR([.]) diff --git a/contrib/sqlite3/shell.c b/contrib/sqlite3/shell.c index 647a214226cc..6b2cdca83d6b 100644 --- a/contrib/sqlite3/shell.c +++ b/contrib/sqlite3/shell.c @@ -246,6 +246,7 @@ typedef unsigned char u8; #if SQLITE_OS_WINRT #include #endif +#undef WIN32_LEAN_AND_MEAN #define WIN32_LEAN_AND_MEAN #include @@ -1224,6 +1225,46 @@ static char *shellFakeSchema( return s.z; } +/* +** SQL function: strtod(X) +** +** Use the C-library strtod() function to convert string X into a double. +** Used for comparing the accuracy of SQLite's internal text-to-float conversion +** routines against the C-library. +*/ +static void shellStrtod( + sqlite3_context *pCtx, + int nVal, + sqlite3_value **apVal +){ + char *z = (char*)sqlite3_value_text(apVal[0]); + UNUSED_PARAMETER(nVal); + if( z==0 ) return; + sqlite3_result_double(pCtx, strtod(z,0)); +} + +/* +** SQL function: dtostr(X) +** +** Use the C-library printf() function to convert real value X into a string. +** Used for comparing the accuracy of SQLite's internal float-to-text conversion +** routines against the C-library. +*/ +static void shellDtostr( + sqlite3_context *pCtx, + int nVal, + sqlite3_value **apVal +){ + double r = sqlite3_value_double(apVal[0]); + int n = nVal>=2 ? sqlite3_value_int(apVal[1]) : 26; + char z[400]; + if( n<1 ) n = 1; + if( n>350 ) n = 350; + sprintf(z, "%#+.*e", n, r); + sqlite3_result_text(pCtx, z, -1, SQLITE_TRANSIENT); +} + + /* ** SQL function: shell_module_schema(X) ** @@ -1473,7 +1514,7 @@ struct DIR { #endif /* -** Provide the function prototype for the POSIX compatiable getenv() +** Provide the function prototype for the POSIX compatible getenv() ** function. This function is not thread-safe. */ @@ -1799,6 +1840,188 @@ int sqlite3MemTraceDeactivate(void){ } /************************* End ../ext/misc/memtrace.c ********************/ +/************************* Begin ../ext/misc/pcachetrace.c ******************/ +/* +** 2023-06-21 +** +** The author disclaims copyright to this source code. In place of +** a legal notice, here is a blessing: +** +** May you do good and not evil. +** May you find forgiveness for yourself and forgive others. +** May you share freely, never taking more than you give. +** +************************************************************************* +** +** This file implements an extension that uses the SQLITE_CONFIG_PCACHE2 +** mechanism to add a tracing layer on top of pluggable page cache of +** SQLite. If this extension is registered prior to sqlite3_initialize(), +** it will cause all page cache activities to be logged on standard output, +** or to some other FILE specified by the initializer. +** +** This file needs to be compiled into the application that uses it. +** +** This extension is used to implement the --pcachetrace option of the +** command-line shell. +*/ +#include +#include +#include + +/* The original page cache routines */ +static sqlite3_pcache_methods2 pcacheBase; +static FILE *pcachetraceOut; + +/* Methods that trace pcache activity */ +static int pcachetraceInit(void *pArg){ + int nRes; + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xInit(%p)\n", pArg); + } + nRes = pcacheBase.xInit(pArg); + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xInit(%p) -> %d\n", pArg, nRes); + } + return nRes; +} +static void pcachetraceShutdown(void *pArg){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xShutdown(%p)\n", pArg); + } + pcacheBase.xShutdown(pArg); +} +static sqlite3_pcache *pcachetraceCreate(int szPage, int szExtra, int bPurge){ + sqlite3_pcache *pRes; + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xCreate(%d,%d,%d)\n", + szPage, szExtra, bPurge); + } + pRes = pcacheBase.xCreate(szPage, szExtra, bPurge); + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xCreate(%d,%d,%d) -> %p\n", + szPage, szExtra, bPurge, pRes); + } + return pRes; +} +static void pcachetraceCachesize(sqlite3_pcache *p, int nCachesize){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xCachesize(%p, %d)\n", p, nCachesize); + } + pcacheBase.xCachesize(p, nCachesize); +} +static int pcachetracePagecount(sqlite3_pcache *p){ + int nRes; + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xPagecount(%p)\n", p); + } + nRes = pcacheBase.xPagecount(p); + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xPagecount(%p) -> %d\n", p, nRes); + } + return nRes; +} +static sqlite3_pcache_page *pcachetraceFetch( + sqlite3_pcache *p, + unsigned key, + int crFg +){ + sqlite3_pcache_page *pRes; + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xFetch(%p,%u,%d)\n", p, key, crFg); + } + pRes = pcacheBase.xFetch(p, key, crFg); + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xFetch(%p,%u,%d) -> %p\n", + p, key, crFg, pRes); + } + return pRes; +} +static void pcachetraceUnpin( + sqlite3_pcache *p, + sqlite3_pcache_page *pPg, + int bDiscard +){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xUnpin(%p, %p, %d)\n", + p, pPg, bDiscard); + } + pcacheBase.xUnpin(p, pPg, bDiscard); +} +static void pcachetraceRekey( + sqlite3_pcache *p, + sqlite3_pcache_page *pPg, + unsigned oldKey, + unsigned newKey +){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xRekey(%p, %p, %u, %u)\n", + p, pPg, oldKey, newKey); + } + pcacheBase.xRekey(p, pPg, oldKey, newKey); +} +static void pcachetraceTruncate(sqlite3_pcache *p, unsigned n){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xTruncate(%p, %u)\n", p, n); + } + pcacheBase.xTruncate(p, n); +} +static void pcachetraceDestroy(sqlite3_pcache *p){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xDestroy(%p)\n", p); + } + pcacheBase.xDestroy(p); +} +static void pcachetraceShrink(sqlite3_pcache *p){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xShrink(%p)\n", p); + } + pcacheBase.xShrink(p); +} + +/* The substitute pcache methods */ +static sqlite3_pcache_methods2 ersaztPcacheMethods = { + 0, + 0, + pcachetraceInit, + pcachetraceShutdown, + pcachetraceCreate, + pcachetraceCachesize, + pcachetracePagecount, + pcachetraceFetch, + pcachetraceUnpin, + pcachetraceRekey, + pcachetraceTruncate, + pcachetraceDestroy, + pcachetraceShrink +}; + +/* Begin tracing memory allocations to out. */ +int sqlite3PcacheTraceActivate(FILE *out){ + int rc = SQLITE_OK; + if( pcacheBase.xFetch==0 ){ + rc = sqlite3_config(SQLITE_CONFIG_GETPCACHE2, &pcacheBase); + if( rc==SQLITE_OK ){ + rc = sqlite3_config(SQLITE_CONFIG_PCACHE2, &ersaztPcacheMethods); + } + } + pcachetraceOut = out; + return rc; +} + +/* Deactivate memory tracing */ +int sqlite3PcacheTraceDeactivate(void){ + int rc = SQLITE_OK; + if( pcacheBase.xFetch!=0 ){ + rc = sqlite3_config(SQLITE_CONFIG_PCACHE2, &pcacheBase); + if( rc==SQLITE_OK ){ + memset(&pcacheBase, 0, sizeof(pcacheBase)); + } + } + pcachetraceOut = 0; + return rc; +} + +/************************* End ../ext/misc/pcachetrace.c ********************/ /************************* Begin ../ext/misc/shathree.c ******************/ /* ** 2017-03-08 @@ -2683,41 +2906,24 @@ static void decimal_free(Decimal *p){ } /* -** Allocate a new Decimal object. Initialize it to the number given -** by the input string. +** Allocate a new Decimal object initialized to the text in zIn[]. +** Return NULL if any kind of error occurs. */ -static Decimal *decimal_new( - sqlite3_context *pCtx, - sqlite3_value *pIn, - int nAlt, - const unsigned char *zAlt -){ - Decimal *p; - int n, i; - const unsigned char *zIn; +static Decimal *decimalNewFromText(const char *zIn, int n){ + Decimal *p = 0; + int i; int iExp = 0; + p = sqlite3_malloc( sizeof(*p) ); - if( p==0 ) goto new_no_mem; + if( p==0 ) goto new_from_text_failed; p->sign = 0; p->oom = 0; p->isInit = 1; p->isNull = 0; p->nDigit = 0; p->nFrac = 0; - if( zAlt ){ - n = nAlt, - zIn = zAlt; - }else{ - if( sqlite3_value_type(pIn)==SQLITE_NULL ){ - p->a = 0; - p->isNull = 1; - return p; - } - n = sqlite3_value_bytes(pIn); - zIn = sqlite3_value_text(pIn); - } p->a = sqlite3_malloc64( n+1 ); - if( p->a==0 ) goto new_no_mem; + if( p->a==0 ) goto new_from_text_failed; for(i=0; isspace(zIn[i]); i++){} if( zIn[i]=='-' ){ p->sign = 1; @@ -2768,7 +2974,7 @@ static Decimal *decimal_new( } if( iExp>0 ){ p->a = sqlite3_realloc64(p->a, p->nDigit + iExp + 1 ); - if( p->a==0 ) goto new_no_mem; + if( p->a==0 ) goto new_from_text_failed; memset(p->a+p->nDigit, 0, iExp); p->nDigit += iExp; } @@ -2787,7 +2993,7 @@ static Decimal *decimal_new( } if( iExp>0 ){ p->a = sqlite3_realloc64(p->a, p->nDigit + iExp + 1 ); - if( p->a==0 ) goto new_no_mem; + if( p->a==0 ) goto new_from_text_failed; memmove(p->a+iExp, p->a, p->nDigit); memset(p->a, 0, iExp); p->nDigit += iExp; @@ -2796,7 +3002,76 @@ static Decimal *decimal_new( } return p; -new_no_mem: +new_from_text_failed: + if( p ){ + if( p->a ) sqlite3_free(p->a); + sqlite3_free(p); + } + return 0; +} + +/* Forward reference */ +static Decimal *decimalFromDouble(double); + +/* +** Allocate a new Decimal object from an sqlite3_value. Return a pointer +** to the new object, or NULL if there is an error. If the pCtx argument +** is not NULL, then errors are reported on it as well. +** +** If the pIn argument is SQLITE_TEXT or SQLITE_INTEGER, it is converted +** directly into a Decimal. For SQLITE_FLOAT or for SQLITE_BLOB of length +** 8 bytes, the resulting double value is expanded into its decimal equivalent. +** If pIn is NULL or if it is a BLOB that is not exactly 8 bytes in length, +** then NULL is returned. +*/ +static Decimal *decimal_new( + sqlite3_context *pCtx, /* Report error here, if not null */ + sqlite3_value *pIn, /* Construct the decimal object from this */ + int bTextOnly /* Always interpret pIn as text if true */ +){ + Decimal *p = 0; + int eType = sqlite3_value_type(pIn); + if( bTextOnly && (eType==SQLITE_FLOAT || eType==SQLITE_BLOB) ){ + eType = SQLITE_TEXT; + } + switch( eType ){ + case SQLITE_TEXT: + case SQLITE_INTEGER: { + const char *zIn = (const char*)sqlite3_value_text(pIn); + int n = sqlite3_value_bytes(pIn); + p = decimalNewFromText(zIn, n); + if( p==0 ) goto new_failed; + break; + } + + case SQLITE_FLOAT: { + p = decimalFromDouble(sqlite3_value_double(pIn)); + break; + } + + case SQLITE_BLOB: { + const unsigned char *x; + unsigned int i; + sqlite3_uint64 v = 0; + double r; + + if( sqlite3_value_bytes(pIn)!=sizeof(r) ) break; + x = sqlite3_value_blob(pIn); + for(i=0; ioom ){ + sqlite3_result_error_nomem(pCtx); + return; + } + if( p->isNull ){ + sqlite3_result_null(pCtx); + return; + } + for(nDigit=p->nDigit; nDigit>0 && p->a[nDigit-1]==0; nDigit--){} + for(nZero=0; nZeroa[nZero]==0; nZero++){} + nFrac = p->nFrac + (nDigit - p->nDigit); + nDigit -= nZero; + z = sqlite3_malloc( nDigit+20 ); + if( z==0 ){ + sqlite3_result_error_nomem(pCtx); + return; + } + if( nDigit==0 ){ + zero = 0; + a = &zero; + nDigit = 1; + nFrac = 0; + }else{ + a = &p->a[nZero]; + } + if( p->sign && nDigit>0 ){ + z[0] = '-'; + }else{ + z[0] = '+'; + } + z[1] = a[0]+'0'; + z[2] = '.'; + if( nDigit==1 ){ + z[3] = '0'; + i = 4; + }else{ + for(i=1; iisNull ) goto cmp_done; - pB = decimal_new(context, argv[1], 0, 0); + pB = decimal_new(context, argv[1], 1); if( pB==0 || pB->isNull ) goto cmp_done; rc = decimal_cmp(pA, pB); if( rc<0 ) rc = -1; @@ -2963,7 +3283,7 @@ static void decimal_expand(Decimal *p, int nDigit, int nFrac){ } /* -** Add the value pB into pA. +** Add the value pB into pA. A := A + B. ** ** Both pA and pB might become denormalized by this routine. */ @@ -3032,6 +3352,172 @@ static void decimal_add(Decimal *pA, Decimal *pB){ } } +/* +** Multiply A by B. A := A * B +** +** All significant digits after the decimal point are retained. +** Trailing zeros after the decimal point are omitted as long as +** the number of digits after the decimal point is no less than +** either the number of digits in either input. +*/ +static void decimalMul(Decimal *pA, Decimal *pB){ + signed char *acc = 0; + int i, j, k; + int minFrac; + + if( pA==0 || pA->oom || pA->isNull + || pB==0 || pB->oom || pB->isNull + ){ + goto mul_end; + } + acc = sqlite3_malloc64( pA->nDigit + pB->nDigit + 2 ); + if( acc==0 ){ + pA->oom = 1; + goto mul_end; + } + memset(acc, 0, pA->nDigit + pB->nDigit + 2); + minFrac = pA->nFrac; + if( pB->nFracnFrac; + for(i=pA->nDigit-1; i>=0; i--){ + signed char f = pA->a[i]; + int carry = 0, x; + for(j=pB->nDigit-1, k=i+j+3; j>=0; j--, k--){ + x = acc[k] + f*pB->a[j] + carry; + acc[k] = x%10; + carry = x/10; + } + x = acc[k] + carry; + acc[k] = x%10; + acc[k-1] += x/10; + } + sqlite3_free(pA->a); + pA->a = acc; + acc = 0; + pA->nDigit += pB->nDigit + 2; + pA->nFrac += pB->nFrac; + pA->sign ^= pB->sign; + while( pA->nFrac>minFrac && pA->a[pA->nDigit-1]==0 ){ + pA->nFrac--; + pA->nDigit--; + } + +mul_end: + sqlite3_free(acc); +} + +/* +** Create a new Decimal object that contains an integer power of 2. +*/ +static Decimal *decimalPow2(int N){ + Decimal *pA = 0; /* The result to be returned */ + Decimal *pX = 0; /* Multiplier */ + if( N<-20000 || N>20000 ) goto pow2_fault; + pA = decimalNewFromText("1.0", 3); + if( pA==0 || pA->oom ) goto pow2_fault; + if( N==0 ) return pA; + if( N>0 ){ + pX = decimalNewFromText("2.0", 3); + }else{ + N = -N; + pX = decimalNewFromText("0.5", 3); + } + if( pX==0 || pX->oom ) goto pow2_fault; + while( 1 /* Exit by break */ ){ + if( N & 1 ){ + decimalMul(pA, pX); + if( pA->oom ) goto pow2_fault; + } + N >>= 1; + if( N==0 ) break; + decimalMul(pX, pX); + } + decimal_free(pX); + return pA; + +pow2_fault: + decimal_free(pA); + decimal_free(pX); + return 0; +} + +/* +** Use an IEEE754 binary64 ("double") to generate a new Decimal object. +*/ +static Decimal *decimalFromDouble(double r){ + sqlite3_int64 m, a; + int e; + int isNeg; + Decimal *pA; + Decimal *pX; + char zNum[100]; + if( r<0.0 ){ + isNeg = 1; + r = -r; + }else{ + isNeg = 0; + } + memcpy(&a,&r,sizeof(a)); + if( a==0 ){ + e = 0; + m = 0; + }else{ + e = a>>52; + m = a & ((((sqlite3_int64)1)<<52)-1); + if( e==0 ){ + m <<= 1; + }else{ + m |= ((sqlite3_int64)1)<<52; + } + while( e<1075 && m>0 && (m&1)==0 ){ + m >>= 1; + e++; + } + if( isNeg ) m = -m; + e = e - 1075; + if( e>971 ){ + return 0; /* A NaN or an Infinity */ + } + } + + /* At this point m is the integer significand and e is the exponent */ + sqlite3_snprintf(sizeof(zNum), zNum, "%lld", m); + pA = decimalNewFromText(zNum, (int)strlen(zNum)); + pX = decimalPow2(e); + decimalMul(pA, pX); + decimal_free(pX); + return pA; +} + +/* +** SQL Function: decimal(X) +** OR: decimal_exp(X) +** +** Convert input X into decimal and then back into text. +** +** If X is originally a float, then a full decimal expansion of that floating +** point value is done. Or if X is an 8-byte blob, it is interpreted +** as a float and similarly expanded. +** +** The decimal_exp(X) function returns the result in exponential notation. +** decimal(X) returns a complete decimal, without the e+NNN at the end. +*/ +static void decimalFunc( + sqlite3_context *context, + int argc, + sqlite3_value **argv +){ + Decimal *p = decimal_new(context, argv[0], 0); + UNUSED_PARAMETER(argc); + if( p ){ + if( sqlite3_user_data(context)!=0 ){ + decimal_result_sci(context, p); + }else{ + decimal_result(context, p); + } + decimal_free(p); + } +} + /* ** Compare text in decimal order. */ @@ -3042,8 +3528,8 @@ static int decimalCollFunc( ){ const unsigned char *zA = (const unsigned char*)pKey1; const unsigned char *zB = (const unsigned char*)pKey2; - Decimal *pA = decimal_new(0, 0, nKey1, zA); - Decimal *pB = decimal_new(0, 0, nKey2, zB); + Decimal *pA = decimalNewFromText((const char*)zA, nKey1); + Decimal *pB = decimalNewFromText((const char*)zB, nKey2); int rc; UNUSED_PARAMETER(notUsed); if( pA==0 || pB==0 ){ @@ -3068,8 +3554,8 @@ static void decimalAddFunc( int argc, sqlite3_value **argv ){ - Decimal *pA = decimal_new(context, argv[0], 0, 0); - Decimal *pB = decimal_new(context, argv[1], 0, 0); + Decimal *pA = decimal_new(context, argv[0], 1); + Decimal *pB = decimal_new(context, argv[1], 1); UNUSED_PARAMETER(argc); decimal_add(pA, pB); decimal_result(context, pA); @@ -3081,8 +3567,8 @@ static void decimalSubFunc( int argc, sqlite3_value **argv ){ - Decimal *pA = decimal_new(context, argv[0], 0, 0); - Decimal *pB = decimal_new(context, argv[1], 0, 0); + Decimal *pA = decimal_new(context, argv[0], 1); + Decimal *pB = decimal_new(context, argv[1], 1); UNUSED_PARAMETER(argc); if( pB ){ pB->sign = !pB->sign; @@ -3120,7 +3606,7 @@ static void decimalSumStep( p->nFrac = 0; } if( sqlite3_value_type(argv[0])==SQLITE_NULL ) return; - pArg = decimal_new(context, argv[0], 0, 0); + pArg = decimal_new(context, argv[0], 1); decimal_add(p, pArg); decimal_free(pArg); } @@ -3135,7 +3621,7 @@ static void decimalSumInverse( p = sqlite3_aggregate_context(context, sizeof(*p)); if( p==0 ) return; if( sqlite3_value_type(argv[0])==SQLITE_NULL ) return; - pArg = decimal_new(context, argv[0], 0, 0); + pArg = decimal_new(context, argv[0], 1); if( pArg ) pArg->sign = !pArg->sign; decimal_add(p, pArg); decimal_free(pArg); @@ -3156,66 +3642,49 @@ static void decimalSumFinalize(sqlite3_context *context){ ** SQL Function: decimal_mul(X, Y) ** ** Return the product of X and Y. -** -** All significant digits after the decimal point are retained. -** Trailing zeros after the decimal point are omitted as long as -** the number of digits after the decimal point is no less than -** either the number of digits in either input. */ static void decimalMulFunc( sqlite3_context *context, int argc, sqlite3_value **argv ){ - Decimal *pA = decimal_new(context, argv[0], 0, 0); - Decimal *pB = decimal_new(context, argv[1], 0, 0); - signed char *acc = 0; - int i, j, k; - int minFrac; + Decimal *pA = decimal_new(context, argv[0], 1); + Decimal *pB = decimal_new(context, argv[1], 1); UNUSED_PARAMETER(argc); if( pA==0 || pA->oom || pA->isNull || pB==0 || pB->oom || pB->isNull ){ goto mul_end; } - acc = sqlite3_malloc64( pA->nDigit + pB->nDigit + 2 ); - if( acc==0 ){ - sqlite3_result_error_nomem(context); + decimalMul(pA, pB); + if( pA->oom ){ goto mul_end; } - memset(acc, 0, pA->nDigit + pB->nDigit + 2); - minFrac = pA->nFrac; - if( pB->nFracnFrac; - for(i=pA->nDigit-1; i>=0; i--){ - signed char f = pA->a[i]; - int carry = 0, x; *** 15446 LINES SKIPPED *** From nobody Wed Oct 4 01:01:39 2023 X-Original-To: dev-commits-src-branches@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 4S0bxJ2VPDz4wK3P; Wed, 4 Oct 2023 01:01:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0bxJ1NV3z4X6D; Wed, 4 Oct 2023 01:01:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381300; 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=cfejPbYfMWVbmjd1XW0bzGrT4VmvHk7ZJn59nDOI8D8=; b=L+uedOVJQiSKsAiED5tTU27aync0jPxv4tUFm4OdD8XbcFIuQNhN+jwiGgeNVzU5eGShoi DDLevehDsyKTfQpEpA2crOZP83SO3rq6vlN9/FX2UKDQsPM43WoZ3xxEgMhmdFfWQgZy6p ADOT/je95ht5W3gzQ++T2wlNx6bvug9K3mrrUNr6g0d/4LyfFA14TyLb8susYg0yVtZx5k yuFwwwNN199M3wsTVIJrdEO5tp6Vsu0XHF7kJjcmOurmlkW99QqN9G4097VY9T4ysc64iA pXXGZZ0ardeHn34D7EQMsXOLF/Ggux7XLcFPXSdm/V9SEcb9W8bp+x/Yp62YXg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696381300; a=rsa-sha256; cv=none; b=RPntdzzCn/HN16eORKd3LbHoiDf+gxuDEd2Ye51bIaspgWDxDdOGYy1jG81r9gl1NGjhP4 79S4xmdBdNMt/Pdq2qiauEgMLyxFt4EeMxGEPTnZTXABZp5jnQfnx9Zp5YB3yNRlmb2Gmr fTyQlJwY0yhSHNjNi7u/66xrPfFjlq9+W0H2DgA3EvJBl5v96HONnqhsGT75+WsmY6L6Ex JumshDvcRediKjNb1vBV+7spcxkTecz7WlsfAoJ3WjCNMtt57064ML/JPloJ+5OwzUy3rb W3vAnzfsqGkq1CKoqKn+qUz5zqOeC7zuKJN/hXVjlOkK/NhjwKoWsES9Dnq4SA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381300; 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=cfejPbYfMWVbmjd1XW0bzGrT4VmvHk7ZJn59nDOI8D8=; b=RznkTAUWM+6/GP92omHZSseRdF07smPJH2ArATH0LHHbNXXXV6wrRJFzJ9DQ1K1sb7mRR8 BppjfhBzqWoIJhUChFYLM8J1jcjN7yKYetmVVA8DIvIvPqI37oKNWikLWPPL6gdh3kqtOw Rqc8gayS9oYZQCg3oREo/k5FAGWoQQPRo+bNegHJpKArJHzftHNH8K8fcsqlCnth1VHQiL RHmUHj6aBhu/N5YO9AyMtu6XD4blQe4iCxA+jtcfFl24SnWcxsr0eAVBA6glfPLLwnmFCB xQcyo8lazw5sVizP86phTk48eicMuVE8/hJIg6KkeX46BAUCb2VAe4pt8V2mBg== 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 4S0bxH6lgfz35G; Wed, 4 Oct 2023 01:01:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39411d9H049091; Wed, 4 Oct 2023 01:01:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39411d48049088; Wed, 4 Oct 2023 01:01:39 GMT (envelope-from git) Date: Wed, 4 Oct 2023 01:01:39 GMT Message-Id: <202310040101.39411d48049088@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Cy Schubert Subject: git: 1b5982339ced - stable/14 - unbound: Vendor import 1.18.0 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 1b5982339ced0f39ef588a07a3e960954e87c65e Auto-Submitted: auto-generated The branch stable/14 has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=1b5982339ced0f39ef588a07a3e960954e87c65e commit 1b5982339ced0f39ef588a07a3e960954e87c65e Author: Cy Schubert AuthorDate: 2023-09-19 04:17:09 +0000 Commit: Cy Schubert CommitDate: 2023-10-04 01:01:06 +0000 unbound: Vendor import 1.18.0 Release notes at https://www.nlnetlabs.nl/news/2023/Aug/30/unbound-1.18.0-released/ Merge commit '401770e05c71ecb5ae61a59d316069b4b78bf622' into main (cherry picked from commit 8f76bb7dad48538c6832c2fb466a433d2a3f8cd5) --- contrib/unbound/Makefile.in | 43 +- contrib/unbound/README.md | 2 +- contrib/unbound/acx_nlnetlabs.m4 | 36 +- contrib/unbound/acx_python.m4 | 61 +- contrib/unbound/cachedb/cachedb.c | 57 +- contrib/unbound/cachedb/redis.c | 28 +- contrib/unbound/compat/getentropy_solaris.c | 2 +- contrib/unbound/config.guess | 51 +- contrib/unbound/config.h.in | 25 +- contrib/unbound/config.h.in~ | 1456 ++++++++++++++++++++ contrib/unbound/config.sub | 72 +- contrib/unbound/configure | 170 ++- contrib/unbound/configure.ac | 99 +- contrib/unbound/contrib/Dockerfile.tests | 4 +- contrib/unbound/contrib/README | 3 + contrib/unbound/contrib/aaaa-filter-iterator.patch | 4 +- contrib/unbound/contrib/unbound.init_yocto | 139 ++ contrib/unbound/daemon/acl_list.c | 2 + contrib/unbound/daemon/acl_list.h | 8 +- contrib/unbound/daemon/cachedump.c | 28 +- contrib/unbound/daemon/remote.c | 236 ++-- contrib/unbound/daemon/remote.h | 2 +- contrib/unbound/daemon/stats.c | 53 +- contrib/unbound/daemon/stats.h | 7 + contrib/unbound/daemon/worker.c | 471 ++++--- contrib/unbound/dns64/dns64.c | 4 +- contrib/unbound/dnstap/dnstap.c | 7 +- contrib/unbound/dnstap/dnstap.h | 4 +- contrib/unbound/dnstap/unbound-dnstap-socket.c | 39 +- contrib/unbound/doc/Changelog | 323 +++++ contrib/unbound/doc/README | 2 +- contrib/unbound/doc/README.DNS64 | 20 + contrib/unbound/doc/example.conf.in | 32 +- contrib/unbound/doc/libunbound.3.in | 4 +- contrib/unbound/doc/unbound-anchor.8.in | 2 +- contrib/unbound/doc/unbound-checkconf.8.in | 2 +- contrib/unbound/doc/unbound-control.8.in | 58 +- contrib/unbound/doc/unbound-host.1.in | 2 +- contrib/unbound/doc/unbound.8.in | 4 +- contrib/unbound/doc/unbound.conf.5.in | 147 +- contrib/unbound/edns-subnet/subnetmod.c | 27 +- contrib/unbound/iterator/iter_delegpt.c | 39 + contrib/unbound/iterator/iter_delegpt.h | 25 + contrib/unbound/iterator/iter_resptype.c | 7 + contrib/unbound/iterator/iter_scrub.c | 43 +- contrib/unbound/iterator/iter_utils.c | 43 +- contrib/unbound/iterator/iter_utils.h | 7 +- contrib/unbound/iterator/iterator.c | 259 ++-- contrib/unbound/iterator/iterator.h | 23 +- contrib/unbound/libunbound/libworker.c | 16 +- contrib/unbound/libunbound/unbound-event.h | 6 +- contrib/unbound/libunbound/unbound.h | 116 +- contrib/unbound/services/authzone.c | 10 +- contrib/unbound/services/cache/dns.c | 50 +- contrib/unbound/services/cache/infra.c | 75 +- contrib/unbound/services/cache/infra.h | 5 +- contrib/unbound/services/listen_dnsport.c | 153 +- contrib/unbound/services/localzone.c | 20 +- contrib/unbound/services/localzone.h | 2 + contrib/unbound/services/mesh.c | 385 +++--- contrib/unbound/services/mesh.h | 14 +- contrib/unbound/services/modstack.c | 10 +- contrib/unbound/services/outside_network.c | 28 + contrib/unbound/services/rpz.c | 230 +++- contrib/unbound/services/rpz.h | 16 +- contrib/unbound/sldns/rrdef.c | 12 +- contrib/unbound/sldns/rrdef.h | 7 +- contrib/unbound/sldns/str2wire.c | 94 +- contrib/unbound/sldns/str2wire.h | 4 +- contrib/unbound/sldns/wire2str.c | 19 +- contrib/unbound/smallapp/unbound-anchor.c | 3 +- contrib/unbound/smallapp/unbound-checkconf.c | 2 +- contrib/unbound/smallapp/unbound-control.c | 54 +- contrib/unbound/smallapp/unbound-host.c | 5 +- contrib/unbound/testdata/00-lint.tdir/00-lint.pre | 14 + contrib/unbound/testdata/cachedb_cached_ede.crpl | 91 ++ .../unbound/testdata/edns_downstream_cookies.rpl | 235 ++++ .../testdata/ip_ratelimit.tdir/ip_ratelimit.conf | 28 + .../testdata/ip_ratelimit.tdir/ip_ratelimit.dsc | 16 + .../testdata/ip_ratelimit.tdir/ip_ratelimit.post | 13 + .../testdata/ip_ratelimit.tdir/ip_ratelimit.pre | 24 + .../testdata/ip_ratelimit.tdir/ip_ratelimit.test | 165 +++ .../testdata/ip_ratelimit.tdir/unbound_control.key | 39 + .../testdata/ip_ratelimit.tdir/unbound_control.pem | 22 + .../testdata/ip_ratelimit.tdir/unbound_server.key | 39 + .../testdata/ip_ratelimit.tdir/unbound_server.pem | 22 + .../unbound/testdata/iter_cname_minimise_nx.rpl | 246 ++++ contrib/unbound/testdata/iter_failreply.rpl | 132 ++ contrib/unbound/testdata/iter_ignore_empty.rpl | 198 +++ contrib/unbound/testdata/iter_nat64.rpl | 117 ++ contrib/unbound/testdata/iter_nat64_prefix.rpl | 119 ++ contrib/unbound/testdata/iter_nat64_prefix48.rpl | 118 ++ .../unbound/testdata/serve_expired_0ttl_nodata.rpl | 154 +++ .../testdata/serve_expired_0ttl_nxdomain.rpl | 154 +++ .../testdata/serve_expired_0ttl_servfail.rpl | 129 ++ .../serve_expired_cached_servfail_refresh.rpl | 145 ++ .../stat_values.tdir/stat_values_cachedb.conf | 36 + .../stat_values_downstream_cookies.conf | 32 + contrib/unbound/testdata/subnet_cached_ede.crpl | 114 ++ .../unbound/testdata/subnet_global_prefetch.crpl | 236 ++++ .../subnet_global_prefetch_always_forward.crpl | 167 +++ .../testdata/subnet_global_prefetch_expired.crpl | 241 ++++ contrib/unbound/testdata/val_any_negcache.rpl | 240 ++++ contrib/unbound/util/config_file.c | 153 +- contrib/unbound/util/config_file.h | 65 +- contrib/unbound/util/configlexer.lex | 15 +- contrib/unbound/util/configparser.y | 148 +- contrib/unbound/util/data/msgencode.c | 148 +- contrib/unbound/util/data/msgencode.h | 42 +- contrib/unbound/util/data/msgparse.c | 98 +- contrib/unbound/util/data/msgparse.h | 18 +- contrib/unbound/util/data/msgreply.c | 95 +- contrib/unbound/util/data/msgreply.h | 30 +- contrib/unbound/util/edns.c | 59 + contrib/unbound/util/edns.h | 59 + contrib/unbound/util/fptr_wlist.c | 8 + contrib/unbound/util/iana_ports.inc | 4 + contrib/unbound/util/module.c | 16 +- contrib/unbound/util/module.h | 14 +- contrib/unbound/util/net_help.c | 70 +- contrib/unbound/util/net_help.h | 23 + contrib/unbound/util/netevent.c | 229 +-- contrib/unbound/util/netevent.h | 70 +- contrib/unbound/util/regional.c | 2 +- contrib/unbound/util/rfc_1982.c | 74 + contrib/unbound/util/rfc_1982.h | 63 + contrib/unbound/util/siphash.c | 187 +++ contrib/unbound/util/siphash.h | 43 + contrib/unbound/util/storage/lruhash.c | 25 +- contrib/unbound/util/storage/lruhash.h | 5 +- contrib/unbound/util/storage/slabhash.c | 18 + contrib/unbound/util/storage/slabhash.h | 9 + contrib/unbound/util/timehist.c | 44 +- contrib/unbound/util/timeval_func.c | 113 ++ contrib/unbound/util/timeval_func.h | 53 + contrib/unbound/validator/autotrust.c | 2 + contrib/unbound/validator/val_kcache.c | 10 +- contrib/unbound/validator/val_kcache.h | 4 +- contrib/unbound/validator/val_kentry.c | 48 +- contrib/unbound/validator/val_kentry.h | 37 +- contrib/unbound/validator/val_neg.c | 7 +- contrib/unbound/validator/val_nsec.c | 19 +- contrib/unbound/validator/val_nsec.h | 5 +- contrib/unbound/validator/val_sigcrypt.c | 43 +- contrib/unbound/validator/val_utils.c | 19 +- contrib/unbound/validator/validator.c | 137 +- lib/libunbound/Makefile | 6 +- lib/libunbound/config.h | 6 +- 148 files changed, 9439 insertions(+), 1708 deletions(-) diff --git a/contrib/unbound/Makefile.in b/contrib/unbound/Makefile.in index bc021aa1eb00..0a2e7f9b6f08 100644 --- a/contrib/unbound/Makefile.in +++ b/contrib/unbound/Makefile.in @@ -122,15 +122,15 @@ iterator/iter_delegpt.c iterator/iter_donotq.c iterator/iter_fwd.c \ iterator/iter_hints.c iterator/iter_priv.c iterator/iter_resptype.c \ iterator/iter_scrub.c iterator/iter_utils.c services/listen_dnsport.c \ services/localzone.c services/mesh.c services/modstack.c services/view.c \ -services/rpz.c \ +services/rpz.c util/rfc_1982.c \ services/outbound_list.c services/outside_network.c util/alloc.c \ util/config_file.c util/configlexer.c util/configparser.c \ util/shm_side/shm_main.c services/authzone.c \ util/fptr_wlist.c util/locks.c util/log.c util/mini_event.c util/module.c \ util/netevent.c util/net_help.c util/random.c util/rbtree.c util/regional.c \ -util/rtt.c util/edns.c util/storage/dnstree.c util/storage/lookup3.c \ +util/rtt.c util/siphash.c util/edns.c util/storage/dnstree.c util/storage/lookup3.c \ util/storage/lruhash.c util/storage/slabhash.c util/tcp_conn_limit.c \ -util/timehist.c util/tube.c util/proxy_protocol.c \ +util/timehist.c util/tube.c util/proxy_protocol.c util/timeval_func.c \ util/ub_event.c util/ub_event_pluggable.c util/winsock_event.c \ validator/autotrust.c validator/val_anchor.c validator/validator.c \ validator/val_kcache.c validator/val_kentry.c validator/val_neg.c \ @@ -145,14 +145,14 @@ as112.lo msgparse.lo msgreply.lo packed_rrset.lo iterator.lo iter_delegpt.lo \ iter_donotq.lo iter_fwd.lo iter_hints.lo iter_priv.lo iter_resptype.lo \ iter_scrub.lo iter_utils.lo localzone.lo mesh.lo modstack.lo view.lo \ outbound_list.lo alloc.lo config_file.lo configlexer.lo configparser.lo \ -fptr_wlist.lo edns.lo locks.lo log.lo mini_event.lo module.lo net_help.lo \ +fptr_wlist.lo siphash.lo edns.lo locks.lo log.lo mini_event.lo module.lo net_help.lo \ random.lo rbtree.lo regional.lo rtt.lo dnstree.lo lookup3.lo lruhash.lo \ slabhash.lo tcp_conn_limit.lo timehist.lo tube.lo winsock_event.lo \ -autotrust.lo val_anchor.lo rpz.lo proxy_protocol.lo \ +autotrust.lo val_anchor.lo rpz.lo rfc_1982.lo proxy_protocol.lo \ validator.lo val_kcache.lo val_kentry.lo val_neg.lo val_nsec3.lo val_nsec.lo \ val_secalgo.lo val_sigcrypt.lo val_utils.lo dns64.lo $(CACHEDB_OBJ) authzone.lo \ $(SUBNET_OBJ) $(PYTHONMOD_OBJ) $(CHECKLOCK_OBJ) $(DNSTAP_OBJ) $(DNSCRYPT_OBJ) \ -$(IPSECMOD_OBJ) $(IPSET_OBJ) $(DYNLIBMOD_OBJ) respip.lo +$(IPSECMOD_OBJ) $(IPSET_OBJ) $(DYNLIBMOD_OBJ) respip.lo timeval_func.lo COMMON_OBJ_WITHOUT_UB_EVENT=$(COMMON_OBJ_WITHOUT_NETCALL) netevent.lo listen_dnsport.lo \ outside_network.lo COMMON_OBJ=$(COMMON_OBJ_WITHOUT_UB_EVENT) ub_event.lo @@ -198,7 +198,7 @@ CHECKCONF_OBJ=unbound-checkconf.lo worker_cb.lo CHECKCONF_OBJ_LINK=$(CHECKCONF_OBJ) $(COMMON_OBJ_ALL_SYMBOLS) $(SLDNS_OBJ) \ $(COMPAT_OBJ) @WIN_CHECKCONF_OBJ_LINK@ CONTROL_SRC=smallapp/unbound-control.c -CONTROL_OBJ=unbound-control.lo +CONTROL_OBJ=unbound-control.lo CONTROL_OBJ_LINK=$(CONTROL_OBJ) worker_cb.lo $(COMMON_OBJ_ALL_SYMBOLS) \ $(SLDNS_OBJ) $(COMPAT_OBJ) @WIN_CONTROL_OBJ_LINK@ HOST_SRC=smallapp/unbound-host.c @@ -455,6 +455,7 @@ unbound-dnstap-socket.lo unbound-dnstap-socket.o: $(srcdir)/dnstap/unbound-dnsta dynlibmod.lo dynlibdmod.o: $(srcdir)/dynlibmod/dynlibmod.c config.h $(srcdir)/dynlibmod/dynlibmod.h cachedb.lo cachedb.o: $(srcdir)/cachedb/cachedb.c config.h $(srcdir)/cachedb/cachedb.h redis.lo redis.o: $(srcdir)/cachedb/redis.c config.h $(srcdir)/cachedb/redis.h +timeval_func.lo timeval_func.o: $(srcdir)/util/timeval_func.c $(srcdir)/util/timeval_func.h # dnscrypt dnscrypt.lo dnscrypt.o: $(srcdir)/dnscrypt/dnscrypt.c config.h \ @@ -498,6 +499,7 @@ util/configlexer.c: $(srcdir)/util/configlexer.lex util/configparser.h echo "#include \"util/configyyrename.h\"" >> $@ ;\ $(LEX) -t $(srcdir)/util/configlexer.lex >> $@ ;\ fi + @if test ! -f $@; then echo "No $@ : need flex and bison to compile from source repository"; exit 1; fi util/configparser.c util/configparser.h: $(srcdir)/util/configparser.y @-if test ! -d util; then $(INSTALL) -d util; fi @@ -516,7 +518,7 @@ distclean: clean rm -f doc/example.conf doc/libunbound.3 doc/unbound-anchor.8 doc/unbound-checkconf.8 doc/unbound-control.8 doc/unbound.8 doc/unbound.conf.5 doc/unbound-host.1 rm -f smallapp/unbound-control-setup.sh dnstap/dnstap_config.h dnscrypt/dnscrypt_config.h contrib/libunbound.pc contrib/unbound.socket contrib/unbound.service rm -f $(TEST_BIN) - rm -f Makefile + rm -f Makefile maintainer-clean: distclean rm -f util/configlexer.c util/configparser.c util/configparser.h @@ -649,7 +651,7 @@ uninstall: $(PYTHONMOD_UNINSTALL) $(PYUNBOUND_UNINSTALL) $(UNBOUND_EVENT_UNINSTA iana_update: curl -o port-numbers.tmp https://www.iana.org/assignments/service-names-port-numbers/service-names-port-numbers.xml --compressed - if file port-numbers.tmp | grep 'gzip' >/dev/null; then zcat port-numbers.tmp; else cat port-numbers.tmp; fi | awk '// {p=0;} /udp/ {p=1;} /[^u]/ {p=0;} /Decomissioned|Decommissioned|Removed|De-registered|unassigned|Unassigned|Reserved/ {u=1;} // { if(u==1) {u=0;} else { if(p==1) { match($$0,/[0-9]+/); print substr($$0, RSTART, RLENGTH) ","}}}' | sort -nu > util/iana_ports.inc + if file port-numbers.tmp | grep 'gzip' >/dev/null; then zcat port-numbers.tmp; else cat port-numbers.tmp; fi | awk '// {p=0;} /udp/ {p=1;} /[^u]/ {p=0;} /Decomissioned|Decommissioned|Removed|De-registered|unassigned|Unassigned|Reserved/ {u=1;} // { if(u==1) {u=0;} else { if(p==1) { match($$0,/[0-9]+/); print substr($$0, RSTART, RLENGTH) ","}}}' | sort -nu > util/iana_ports.inc rm -f port-numbers.tmp # dependency generation @@ -877,7 +879,7 @@ rpz.lo rpz.o: $(srcdir)/services/rpz.c config.h $(srcdir)/services/rpz.h $(srcdi outbound_list.lo outbound_list.o: $(srcdir)/services/outbound_list.c config.h \ $(srcdir)/services/outbound_list.h $(srcdir)/services/outside_network.h $(srcdir)/util/rbtree.h \ $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ - + outside_network.lo outside_network.o: $(srcdir)/services/outside_network.c config.h \ $(srcdir)/services/outside_network.h $(srcdir)/util/rbtree.h $(srcdir)/util/netevent.h \ $(srcdir)/dnscrypt/dnscrypt.h \ @@ -915,7 +917,8 @@ config_file.lo config_file.o: $(srcdir)/util/config_file.c config.h $(srcdir)/ut configlexer.lo configlexer.o: util/configlexer.c config.h $(srcdir)/util/configyyrename.h \ $(srcdir)/util/config_file.h util/configparser.h configparser.lo configparser.o: util/configparser.c config.h $(srcdir)/util/configyyrename.h \ - $(srcdir)/util/config_file.h $(srcdir)/util/net_help.h $(srcdir)/util/log.h + $(srcdir)/util/config_file.h $(srcdir)/util/net_help.h $(srcdir)/util/log.h $(srcdir)/sldns/str2wire.h \ + $(srcdir)/sldns/rrdef.h shm_main.lo shm_main.o: $(srcdir)/util/shm_side/shm_main.c config.h $(srcdir)/util/shm_side/shm_main.h \ $(srcdir)/libunbound/unbound.h $(srcdir)/daemon/daemon.h $(srcdir)/util/locks.h $(srcdir)/util/log.h \ $(srcdir)/util/alloc.h $(srcdir)/services/modstack.h \ @@ -928,7 +931,7 @@ shm_main.lo shm_main.o: $(srcdir)/util/shm_side/shm_main.c config.h $(srcdir)/ut $(srcdir)/services/view.h $(srcdir)/util/config_file.h $(srcdir)/services/authzone.h $(srcdir)/respip/respip.h \ $(srcdir)/services/cache/rrset.h $(srcdir)/util/storage/slabhash.h $(srcdir)/services/cache/infra.h \ $(srcdir)/util/rtt.h $(srcdir)/validator/validator.h $(srcdir)/validator/val_utils.h $(srcdir)/util/fptr_wlist.h \ - $(srcdir)/util/tube.h + $(srcdir)/util/tube.h $(srcdir)/util/timeval_func.h authzone.lo authzone.o: $(srcdir)/services/authzone.c config.h $(srcdir)/services/authzone.h \ $(srcdir)/util/rbtree.h $(srcdir)/util/locks.h $(srcdir)/util/log.h $(srcdir)/services/mesh.h $(srcdir)/util/netevent.h \ $(srcdir)/dnscrypt/dnscrypt.h $(srcdir)/util/data/msgparse.h \ @@ -983,7 +986,7 @@ netevent.lo netevent.o: $(srcdir)/util/netevent.c config.h $(srcdir)/util/neteve $(srcdir)/services/modstack.h $(srcdir)/services/rpz.h $(srcdir)/services/localzone.h $(srcdir)/services/view.h \ $(srcdir)/sldns/sbuffer.h $(srcdir)/util/config_file.h $(srcdir)/services/authzone.h $(srcdir)/daemon/stats.h \ $(srcdir)/util/timehist.h $(srcdir)/libunbound/unbound.h $(srcdir)/respip/respip.h $(srcdir)/sldns/str2wire.h \ - $(srcdir)/dnstap/dnstap.h $(srcdir)/services/listen_dnsport.h + $(srcdir)/dnstap/dnstap.h $(srcdir)/services/listen_dnsport.h $(srcdir)/util/timeval_func.h proxy_protocol.lo proxy_protocol.o: $(srcdir)/util/proxy_protocol.c config.h \ $(srcdir)/util/proxy_protocol.h $(srcdir)/sldns/sbuffer.h net_help.lo net_help.o: $(srcdir)/util/net_help.c config.h $(srcdir)/util/net_help.h $(srcdir)/util/log.h \ @@ -1006,6 +1009,8 @@ rtt.lo rtt.o: $(srcdir)/util/rtt.c config.h $(srcdir)/util/rtt.h $(srcdir)/itera $(srcdir)/services/outbound_list.h $(srcdir)/util/data/msgreply.h $(srcdir)/util/storage/lruhash.h \ $(srcdir)/util/locks.h $(srcdir)/util/log.h $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/module.h \ $(srcdir)/util/data/msgparse.h $(srcdir)/sldns/pkthdr.h $(srcdir)/sldns/rrdef.h +siphash.lo siphash.o: $(srcdir)/util/siphash.c +rfc_1982.lo rfc_1982.o: $(srcdir)/util/rfc_1982.c edns.lo edns.o: $(srcdir)/util/edns.c config.h $(srcdir)/util/edns.h $(srcdir)/util/storage/dnstree.h \ $(srcdir)/util/rbtree.h $(srcdir)/util/config_file.h $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ $(srcdir)/util/net_help.h $(srcdir)/util/log.h $(srcdir)/util/regional.h \ @@ -1186,7 +1191,7 @@ unitmain.lo unitmain.o: $(srcdir)/testcode/unitmain.c config.h $(srcdir)/sldns/r $(srcdir)/util/storage/dnstree.h $(srcdir)/util/rbtree.h $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ $(srcdir)/util/random.h $(srcdir)/respip/respip.h \ $(srcdir)/services/localzone.h $(srcdir)/services/view.h $(srcdir)/sldns/sbuffer.h \ - $(srcdir)/services/outside_network.h + $(srcdir)/services/outside_network.h unitmsgparse.lo unitmsgparse.o: $(srcdir)/testcode/unitmsgparse.c config.h $(srcdir)/util/log.h \ $(srcdir)/testcode/unitmain.h $(srcdir)/util/data/msgparse.h $(srcdir)/util/storage/lruhash.h \ $(srcdir)/util/locks.h $(srcdir)/sldns/pkthdr.h $(srcdir)/sldns/rrdef.h $(srcdir)/util/data/msgreply.h \ @@ -1321,7 +1326,7 @@ unbound.lo unbound.o: $(srcdir)/daemon/unbound.c config.h $(srcdir)/util/log.h $ worker.lo worker.o: $(srcdir)/daemon/worker.c config.h $(srcdir)/util/log.h $(srcdir)/util/net_help.h \ $(srcdir)/util/random.h $(srcdir)/daemon/worker.h $(srcdir)/libunbound/worker.h $(srcdir)/sldns/sbuffer.h \ $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/storage/lruhash.h $(srcdir)/util/locks.h \ - $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ + $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h $(srcdir)/util/timeval_func.h \ $(srcdir)/util/alloc.h $(srcdir)/util/data/msgreply.h $(srcdir)/util/data/msgparse.h $(srcdir)/sldns/pkthdr.h \ $(srcdir)/sldns/rrdef.h $(srcdir)/daemon/stats.h $(srcdir)/util/timehist.h $(srcdir)/libunbound/unbound.h \ $(srcdir)/util/module.h $(srcdir)/dnstap/dnstap.h $(srcdir)/daemon/daemon.h \ @@ -1343,7 +1348,7 @@ testbound.lo testbound.o: $(srcdir)/testcode/testbound.c config.h $(srcdir)/test $(srcdir)/daemon/remote.h $(srcdir)/libunbound/worker.h $(srcdir)/sldns/sbuffer.h \ $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/storage/lruhash.h $(srcdir)/util/locks.h $(srcdir)/util/log.h \ $(srcdir)/util/config_file.h $(srcdir)/sldns/keyraw.h $(srcdir)/daemon/unbound.c $(srcdir)/daemon/daemon.h \ - $(srcdir)/util/alloc.h $(srcdir)/services/modstack.h \ + $(srcdir)/util/alloc.h $(srcdir)/util/timeval_func.h $(srcdir)/services/modstack.h \ $(srcdir)/util/storage/slabhash.h $(srcdir)/services/listen_dnsport.h $(srcdir)/services/cache/rrset.h \ $(srcdir)/services/cache/infra.h $(srcdir)/util/storage/dnstree.h $(srcdir)/util/rtt.h \ $(srcdir)/util/data/msgreply.h $(srcdir)/util/fptr_wlist.h $(srcdir)/util/module.h \ @@ -1357,7 +1362,7 @@ testpkts.lo testpkts.o: $(srcdir)/testcode/testpkts.c config.h $(srcdir)/testcod worker.lo worker.o: $(srcdir)/daemon/worker.c config.h $(srcdir)/util/log.h $(srcdir)/util/net_help.h \ $(srcdir)/util/random.h $(srcdir)/daemon/worker.h $(srcdir)/libunbound/worker.h $(srcdir)/sldns/sbuffer.h \ $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/storage/lruhash.h $(srcdir)/util/locks.h \ - $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ + $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h $(srcdir)/util/timeval_func.h \ $(srcdir)/util/alloc.h $(srcdir)/util/data/msgreply.h $(srcdir)/util/data/msgparse.h $(srcdir)/sldns/pkthdr.h \ $(srcdir)/sldns/rrdef.h $(srcdir)/daemon/stats.h $(srcdir)/util/timehist.h $(srcdir)/libunbound/unbound.h \ $(srcdir)/util/module.h $(srcdir)/dnstap/dnstap.h $(srcdir)/daemon/daemon.h \ @@ -1409,7 +1414,7 @@ stats.lo stats.o: $(srcdir)/daemon/stats.c config.h $(srcdir)/daemon/stats.h $(s $(srcdir)/validator/val_kcache.h $(srcdir)/validator/val_neg.h replay.lo replay.o: $(srcdir)/testcode/replay.c config.h $(srcdir)/util/log.h $(srcdir)/util/net_help.h \ $(srcdir)/util/config_file.h $(srcdir)/testcode/replay.h $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ - $(srcdir)/testcode/testpkts.h $(srcdir)/util/rbtree.h \ + $(srcdir)/testcode/testpkts.h $(srcdir)/util/rbtree.h $(srcdir)/util/timeval_func.h \ $(srcdir)/testcode/fake_event.h $(srcdir)/sldns/str2wire.h $(srcdir)/sldns/rrdef.h fake_event.lo fake_event.o: $(srcdir)/testcode/fake_event.c config.h $(srcdir)/testcode/fake_event.h \ $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ @@ -1417,7 +1422,7 @@ fake_event.lo fake_event.o: $(srcdir)/testcode/fake_event.c config.h $(srcdir)/t $(srcdir)/util/locks.h $(srcdir)/sldns/pkthdr.h $(srcdir)/sldns/rrdef.h $(srcdir)/util/data/msgreply.h \ $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/data/msgencode.h $(srcdir)/util/data/dname.h \ $(srcdir)/util/edns.h $(srcdir)/util/storage/dnstree.h $(srcdir)/util/rbtree.h $(srcdir)/util/config_file.h \ - $(srcdir)/services/listen_dnsport.h $(srcdir)/services/outside_network.h \ + $(srcdir)/services/listen_dnsport.h $(srcdir)/services/outside_network.h $(srcdir)/util/timeval_func.h \ $(srcdir)/services/cache/infra.h $(srcdir)/util/rtt.h \ $(srcdir)/testcode/replay.h $(srcdir)/testcode/testpkts.h $(srcdir)/util/fptr_wlist.h $(srcdir)/util/module.h \ $(srcdir)/util/tube.h $(srcdir)/services/mesh.h $(srcdir)/services/modstack.h $(srcdir)/services/rpz.h \ diff --git a/contrib/unbound/README.md b/contrib/unbound/README.md index c3d9bc2492ef..c220da030458 100644 --- a/contrib/unbound/README.md +++ b/contrib/unbound/README.md @@ -1,6 +1,6 @@ # Unbound -[![Travis Build Status](https://travis-ci.org/NLnetLabs/unbound.svg?branch=master)](https://travis-ci.org/NLnetLabs/unbound) +[![Github Build Status](https://github.com/NLnetLabs/unbound/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/NLnetLabs/unbound/actions) [![Packaging status](https://repology.org/badge/tiny-repos/unbound.svg)](https://repology.org/project/unbound/versions) [![Fuzzing Status](https://oss-fuzz-build-logs.storage.googleapis.com/badges/unbound.svg)](https://bugs.chromium.org/p/oss-fuzz/issues/list?sort=-opened&can=1&q=proj:unbound) [![Documentation Status](https://readthedocs.org/projects/unbound/badge/?version=latest)](https://unbound.readthedocs.io/en/latest/?badge=latest) diff --git a/contrib/unbound/acx_nlnetlabs.m4 b/contrib/unbound/acx_nlnetlabs.m4 index cf436ec54bb6..f27615bd8bce 100644 --- a/contrib/unbound/acx_nlnetlabs.m4 +++ b/contrib/unbound/acx_nlnetlabs.m4 @@ -2,7 +2,9 @@ # Copyright 2009, Wouter Wijngaards, NLnet Labs. # BSD licensed. # -# Version 44 +# Version 46 +# 2023-05-04 fix to remove unused whitespace. +# 2023-01-26 fix -Wstrict-prototypes. # 2022-09-01 fix checking if nonblocking sockets work on OpenBSD. # 2021-08-17 fix sed script in ssldir split handling. # 2021-08-17 fix for openssl to detect split version, with ssldir_include @@ -187,7 +189,7 @@ dnl cache=`echo $1 | sed 'y%.=/+- %___p__%'` AC_CACHE_VAL(cv_prog_cc_flag_needed_$cache, [ echo '$2' > conftest.c -echo 'void f(){}' >>conftest.c +echo 'void f(void){}' >>conftest.c if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then eval "cv_prog_cc_flag_needed_$cache=no" else @@ -233,7 +235,7 @@ dnl DEPFLAG: set to flag that generates dependencies. AC_DEFUN([ACX_DEPFLAG], [ AC_MSG_CHECKING([$CC dependency flag]) -echo 'void f(){}' >conftest.c +echo 'void f(void){}' >conftest.c if test "`$CC -MM conftest.c 2>&1`" = "conftest.o: conftest.c"; then DEPFLAG="-MM" else @@ -272,7 +274,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED($C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAUL #include #endif -int test() { +int test(void) { int a; char **opts = NULL; struct timeval tv; @@ -309,7 +311,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED($C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAUL #include #endif -int test() { +int test(void) { int a; char **opts = NULL; struct timeval tv; @@ -335,7 +337,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED($C99FLAG, [ #include #include -int test() { +int test(void) { int a = 0; return a; } @@ -345,7 +347,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D_BSD_SOURCE -D_DEFAULT_SOURCE, [ #include -int test() { +int test(void) { int a; a = isascii(32); return a; @@ -356,7 +358,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D_GNU_SOURCE, [ #include -int test() { +int test(void) { struct in6_pktinfo inf; int a = (int)sizeof(inf); return a; @@ -370,7 +372,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D_GNU_SOURCE -D_FRSRESGID, [ #include -int test() { +int test(void) { int a = setresgid(0,0,0); a = setresuid(0,0,0); return a; @@ -385,7 +387,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D_POSIX_C_SOURCE=200112, #endif #include -int test() { +int test(void) { int a = 0; char *t; time_t time = 0; @@ -413,7 +415,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D__EXTENSIONS__, #include #endif -int test() { +int test(void) { int a; char **opts = NULL; struct timeval tv; @@ -475,7 +477,7 @@ fi dnl Setup ATTR_FORMAT config.h parts. dnl make sure you call ACX_CHECK_FORMAT_ATTRIBUTE also. AC_DEFUN([AHX_CONFIG_FORMAT_ATTRIBUTE], -[ +[ #ifdef HAVE_ATTR_FORMAT # define ATTR_FORMAT(archetype, string_index, first_to_check) \ __attribute__ ((format (archetype, string_index, first_to_check))) @@ -834,7 +836,7 @@ dnl try to see if an additional _LARGEFILE_SOURCE 1 is needed to get fseeko ACX_CHECK_COMPILER_FLAG_NEEDED(-D_LARGEFILE_SOURCE=1, [ #include -int test() { +int test(void) { int a = fseeko(stdin, 0, 0); return a; } @@ -859,7 +861,7 @@ char* (*f) () = getaddrinfo; #ifdef __cplusplus } #endif -int main() { +int main(void) { ; return 0; } @@ -923,7 +925,7 @@ cache=`echo $1 | sed 'y%.=/+-%___p_%'` AC_CACHE_VAL(cv_cc_deprecated_$cache, [ echo '$3' >conftest.c -echo 'void f(){ $2 }' >>conftest.c +echo 'void f(void){ $2 }' >>conftest.c if test -z "`$CC $CPPFLAGS $CFLAGS -c conftest.c 2>&1 | grep -e deprecated -e unavailable`"; then eval "cv_cc_deprecated_$cache=no" else @@ -1317,7 +1319,7 @@ AC_DEFUN([AHX_CONFIG_W32_FD_SET_T], #ifdef HAVE_WINSOCK2_H #define FD_SET_T (u_int) #else -#define FD_SET_T +#define FD_SET_T #endif ]) @@ -1355,7 +1357,7 @@ dnl $3: define value, 1 AC_DEFUN([AHX_CONFIG_FLAG_OMITTED], [#if defined($1) && !defined($2) #define $2 $3 -[#]endif ]) +[#]endif]) dnl Wrapper for AHX_CONFIG_FLAG_OMITTED for -D style flags dnl $1: the -DNAME or -DNAME=value string. diff --git a/contrib/unbound/acx_python.m4 b/contrib/unbound/acx_python.m4 index 16c0c6fd943f..c945d6c8989e 100644 --- a/contrib/unbound/acx_python.m4 +++ b/contrib/unbound/acx_python.m4 @@ -17,33 +17,62 @@ AC_DEFUN([AC_PYTHON_DEVEL],[ PYTHON_VERSION=`$PYTHON -c "import sys; \ print(sys.version.split()[[0]])"` fi + # calculate the version number components. + [ + v="$PYTHON_VERSION" + PYTHON_VERSION_MAJOR=`echo $v | sed 's/[^0-9].*//'` + if test -z "$PYTHON_VERSION_MAJOR"; then PYTHON_VERSION_MAJOR="0"; fi + v=`echo $v | sed -e 's/^[0-9]*$//' -e 's/[0-9]*[^0-9]//'` + PYTHON_VERSION_MINOR=`echo $v | sed 's/[^0-9].*//'` + if test -z "$PYTHON_VERSION_MINOR"; then PYTHON_VERSION_MINOR="0"; fi + v=`echo $v | sed -e 's/^[0-9]*$//' -e 's/[0-9]*[^0-9]//'` + PYTHON_VERSION_PATCH=`echo $v | sed 's/[^0-9].*//'` + if test -z "$PYTHON_VERSION_PATCH"; then PYTHON_VERSION_PATCH="0"; fi + ] - # Check if you have sysconfig - AC_MSG_CHECKING([for the sysconfig Python module]) - if ac_sysconfig_result=`$PYTHON -c "import sysconfig" 2>&1`; then + # For some systems, sysconfig exists, but has the wrong paths, + # on Debian 10, for python 2.7 and 3.7. So, we check the version, + # and for older versions try distutils.sysconfig first. For newer + # versions>=3.10, where distutils.sysconfig is deprecated, use + # sysconfig first and then attempt the other one. + py_distutils_first="no" + if test $PYTHON_VERSION_MAJOR -lt 3; then + py_distutils_first="yes" + fi + if test $PYTHON_VERSION_MAJOR -eq 3 -a $PYTHON_VERSION_MINOR -lt 10; then + py_distutils_first="yes" + fi + + # Check if you have the first module + if test "$py_distutils_first" = "yes"; then m="distutils"; else m="sysconfig"; fi + sysconfig_module="" + AC_MSG_CHECKING([for the $m Python module]) + if ac_modulecheck_result1=`$PYTHON -c "import $m" 2>&1`; then AC_MSG_RESULT([yes]) - sysconfig_module="sysconfig" - # if yes, use sysconfig, because distutils is deprecated. + sysconfig_module="$m" else AC_MSG_RESULT([no]) - # if no, try to use distutils + fi - # - # Check if you have distutils, else fail - # - AC_MSG_CHECKING([for the distutils Python package]) - if ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`; then + # if not found, try the other one. + if test -z "$sysconfig_module"; then + if test "$py_distutils_first" = "yes"; then m2="sysconfig"; else m2="distutils"; fi + AC_MSG_CHECKING([for the $m2 Python module]) + if ac_modulecheck_result2=`$PYTHON -c "import $m2" 2>&1`; then AC_MSG_RESULT([yes]) + sysconfig_module="$m2" else AC_MSG_RESULT([no]) - AC_MSG_ERROR([cannot import Python module "distutils". - Please check your Python installation. The error was: - $ac_distutils_result]) + AC_MSG_ERROR([cannot import Python module "$m", or "$m2". + Please check your Python installation. The errors are: + $m + $ac_modulecheck_result1 + $m2 + $ac_modulecheck_result2]) PYTHON_VERSION="" fi - - sysconfig_module="distutils.sysconfig" fi + if test "$sysconfig_module" = "distutils"; then sysconfig_module="distutils.sysconfig"; fi # # Check for Python include path diff --git a/contrib/unbound/cachedb/cachedb.c b/contrib/unbound/cachedb/cachedb.c index 245daa986967..30645268ca23 100644 --- a/contrib/unbound/cachedb/cachedb.c +++ b/contrib/unbound/cachedb/cachedb.c @@ -102,7 +102,6 @@ static int testframe_init(struct module_env* env, struct cachedb_env* cachedb_env) { struct testframe_moddata* d; - (void)env; verbose(VERB_ALGO, "testframe_init"); d = (struct testframe_moddata*)calloc(1, sizeof(struct testframe_moddata)); @@ -111,6 +110,15 @@ testframe_init(struct module_env* env, struct cachedb_env* cachedb_env) log_err("out of memory"); return 0; } + /* Register an EDNS option (65534) to bypass the worker cache lookup + * for testing */ + if(!edns_register_option(LDNS_EDNS_UNBOUND_CACHEDB_TESTFRAME_TEST, + 1 /* bypass cache */, + 0 /* no aggregation */, env)) { + log_err("testframe_init, could not register test opcode"); + free(d); + return 0; + } lock_basic_init(&d->lock); lock_protect(&d->lock, d, sizeof(*d)); return 1; @@ -218,6 +226,8 @@ static int cachedb_apply_cfg(struct cachedb_env* cachedb_env, struct config_file* cfg) { const char* backend_str = cfg->cachedb_backend; + if(!backend_str || *backend_str==0) + return 1; cachedb_env->backend = cachedb_find_backend(backend_str); if(!cachedb_env->backend) { log_err("cachedb: cannot find backend name '%s'", backend_str); @@ -228,7 +238,7 @@ cachedb_apply_cfg(struct cachedb_env* cachedb_env, struct config_file* cfg) return 1; } -int +int cachedb_init(struct module_env* env, int id) { struct cachedb_env* cachedb_env = (struct cachedb_env*)calloc(1, @@ -267,19 +277,16 @@ cachedb_init(struct module_env* env, int id) return 1; } -void +void cachedb_deinit(struct module_env* env, int id) { struct cachedb_env* cachedb_env; if(!env || !env->modinfo[id]) return; cachedb_env = (struct cachedb_env*)env->modinfo[id]; - /* free contents */ - /* TODO */ if(cachedb_env->enabled) { (*cachedb_env->backend->deinit)(env, cachedb_env); } - free(cachedb_env); env->modinfo[id] = NULL; } @@ -406,6 +413,14 @@ prep_data(struct module_qstate* qstate, struct sldns_buffer* buf) if(qstate->return_msg->rep->ttl == 0 && !qstate->env->cfg->serve_expired) return 0; + + /* The EDE is added to the out-list so it is encoded in the cached message */ + if (qstate->env->cfg->ede && qstate->return_msg->rep->reason_bogus != LDNS_EDE_NONE) { + edns_opt_list_append_ede(&edns.opt_list_out, qstate->env->scratch, + qstate->return_msg->rep->reason_bogus, + qstate->return_msg->rep->reason_bogus_str); + } + if(verbosity >= VERB_ALGO) log_dns_msg("cachedb encoding", &qstate->return_msg->qinfo, qstate->return_msg->rep); @@ -502,6 +517,7 @@ parse_data(struct module_qstate* qstate, struct sldns_buffer* buf) { struct msg_parse* prs; struct edns_data edns; + struct edns_option* ede; uint64_t timestamp, expiry; time_t adjust; size_t lim = sldns_buffer_limit(buf); @@ -539,6 +555,24 @@ parse_data(struct module_qstate* qstate, struct sldns_buffer* buf) if(!qstate->return_msg) return 0; + /* We find the EDE in the in-list after parsing */ + if(qstate->env->cfg->ede && + (ede = edns_opt_list_find(edns.opt_list_in, LDNS_EDNS_EDE))) { + if(ede->opt_len >= 2) { + qstate->return_msg->rep->reason_bogus = + sldns_read_uint16(ede->opt_data); + } + /* allocate space and store the error string and it's size */ + if(ede->opt_len > 2) { + size_t ede_len = ede->opt_len - 2; + qstate->return_msg->rep->reason_bogus_str = regional_alloc( + qstate->region, sizeof(char) * (ede_len+1)); + memcpy(qstate->return_msg->rep->reason_bogus_str, + ede->opt_data+2, ede_len); + qstate->return_msg->rep->reason_bogus_str[ede_len] = 0; + } + } + qstate->return_rcode = LDNS_RCODE_NOERROR; /* see how much of the TTL expired, and remove it */ @@ -630,11 +664,15 @@ cachedb_extcache_store(struct module_qstate* qstate, struct cachedb_env* ie) * See if unbound's internal cache can answer the query */ static int -cachedb_intcache_lookup(struct module_qstate* qstate) +cachedb_intcache_lookup(struct module_qstate* qstate, struct cachedb_env* cde) { uint8_t* dpname=NULL; size_t dpnamelen=0; struct dns_msg* msg; + /* for testframe bypass this lookup */ + if(cde->backend == &testframe_backend) { + return 0; + } if(iter_stub_fwd_no_cache(qstate, &qstate->qinfo, &dpname, &dpnamelen)) return 0; /* no cache for these queries */ @@ -693,6 +731,7 @@ cachedb_handle_query(struct module_qstate* qstate, struct cachedb_qstate* ATTR_UNUSED(iq), struct cachedb_env* ie, int id) { + qstate->is_cachedb_answer = 0; /* check if we are enabled, and skip if so */ if(!ie->enabled) { /* pass request to next module */ @@ -709,7 +748,7 @@ cachedb_handle_query(struct module_qstate* qstate, /* lookup inside unbound's internal cache. * This does not look for expired entries. */ - if(cachedb_intcache_lookup(qstate)) { + if(cachedb_intcache_lookup(qstate, ie)) { if(verbosity >= VERB_ALGO) { if(qstate->return_msg->rep) log_dns_msg("cachedb internal cache lookup", @@ -746,6 +785,7 @@ cachedb_handle_query(struct module_qstate* qstate, qstate->ext_state[id] = module_wait_module; return; } + qstate->is_cachedb_answer = 1; /* we are done with the query */ qstate->ext_state[id] = module_finished; return; @@ -768,6 +808,7 @@ static void cachedb_handle_response(struct module_qstate* qstate, struct cachedb_qstate* ATTR_UNUSED(iq), struct cachedb_env* ie, int id) { + qstate->is_cachedb_answer = 0; /* check if we are not enabled or instructed to not cache, and skip */ if(!ie->enabled || qstate->no_cache_store) { /* we are done with the query */ diff --git a/contrib/unbound/cachedb/redis.c b/contrib/unbound/cachedb/redis.c index 16c3741f786b..93a575a4c6d2 100644 --- a/contrib/unbound/cachedb/redis.c +++ b/contrib/unbound/cachedb/redis.c @@ -56,6 +56,8 @@ struct redis_moddata { int numctxs; /* number of ctx entries */ const char* server_host; /* server's IP address or host name */ int server_port; /* server's TCP port */ + const char* server_path; /* server's unix path, or "", NULL if unused */ + const char* server_password; /* server's AUTH password, or "", NULL if unused */ struct timeval timeout; /* timeout for connection setup and commands */ }; @@ -67,8 +69,13 @@ redis_connect(const struct redis_moddata* moddata) { redisContext* ctx; - ctx = redisConnectWithTimeout(moddata->server_host, - moddata->server_port, moddata->timeout); + if(moddata->server_path && moddata->server_path[0]!=0) { + ctx = redisConnectUnixWithTimeout(moddata->server_path, + moddata->timeout); + } else { + ctx = redisConnectWithTimeout(moddata->server_host, + moddata->server_port, moddata->timeout); + } if(!ctx || ctx->err) { const char *errstr = "out of memory"; if(ctx) @@ -80,6 +87,17 @@ redis_connect(const struct redis_moddata* moddata) log_err("failed to set redis timeout"); goto fail; } + if(moddata->server_password && moddata->server_password[0]!=0) { + redisReply* rep; + rep = redisCommand(ctx, "AUTH %s", moddata->server_password); + if(!rep || rep->type == REDIS_REPLY_ERROR) { + log_err("failed to authenticate with password"); + freeReplyObject(rep); + goto fail; + } + freeReplyObject(rep); + } + verbose(VERB_OPS, "Connection to Redis established"); return ctx; fail: @@ -94,7 +112,7 @@ redis_init(struct module_env* env, struct cachedb_env* cachedb_env) int i; struct redis_moddata* moddata = NULL; - verbose(VERB_ALGO, "redis_init"); + verbose(VERB_OPS, "Redis initialization"); moddata = calloc(1, sizeof(struct redis_moddata)); if(!moddata) { @@ -112,6 +130,8 @@ redis_init(struct module_env* env, struct cachedb_env* cachedb_env) * we don't have to free it in this module. */ moddata->server_host = env->cfg->redis_server_host; moddata->server_port = env->cfg->redis_server_port; + moddata->server_path = env->cfg->redis_server_path; + moddata->server_password = env->cfg->redis_server_password; moddata->timeout.tv_sec = env->cfg->redis_timeout / 1000; moddata->timeout.tv_usec = (env->cfg->redis_timeout % 1000) * 1000; for(i = 0; i < moddata->numctxs; i++) @@ -154,7 +174,7 @@ redis_deinit(struct module_env* env, struct cachedb_env* cachedb_env) cachedb_env->backend_data; (void)env; - verbose(VERB_ALGO, "redis_deinit"); + verbose(VERB_OPS, "Redis deinitialization"); if(!moddata) return; diff --git a/contrib/unbound/compat/getentropy_solaris.c b/contrib/unbound/compat/getentropy_solaris.c index 5e3b1cbbbd30..1ff8162917b3 100644 --- a/contrib/unbound/compat/getentropy_solaris.c +++ b/contrib/unbound/compat/getentropy_solaris.c @@ -47,7 +47,7 @@ #define SHA512_Update SHA512Update #define SHA512_Final SHA512Final #else -#include "openssl/sha.h" +#include #endif #include diff --git a/contrib/unbound/config.guess b/contrib/unbound/config.guess index 980b02083815..b187213930f1 100755 --- a/contrib/unbound/config.guess +++ b/contrib/unbound/config.guess @@ -1,10 +1,10 @@ #! /bin/sh # Attempt to guess a canonical system name. -# Copyright 1992-2022 Free Software Foundation, Inc. +# Copyright 1992-2023 Free Software Foundation, Inc. # shellcheck disable=SC2006,SC2268 # see below for rationale -timestamp='2022-09-17' +timestamp='2023-07-20' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -47,7 +47,7 @@ me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] -Output the configuration name of the system \`$me' is run on. +Output the configuration name of the system '$me' is run on. Options: -h, --help print this help, then exit @@ -60,13 +60,13 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright 1992-2022 Free Software Foundation, Inc. +Copyright 1992-2023 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" -Try \`$me --help' for more information." +Try '$me --help' for more information." # Parse command line while test $# -gt 0 ; do @@ -102,8 +102,8 @@ GUESS= # temporary files to be created and, as you can see below, it is a # headache to deal with in a portable fashion. -# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still -# use `HOST_CC' if defined, but it is deprecated. +# Historically, 'CC_FOR_BUILD' used to be named 'HOST_CC'. We still +# use 'HOST_CC' if defined, but it is deprecated. # Portable tmp directory creation inspired by the Autoconf team. @@ -459,7 +459,7 @@ case $UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION in UNAME_RELEASE=`uname -v` ;; esac - # Japanese Language versions have a version number like `4.1.3-JL'. + # Japanese Language versions have a version number like '4.1.3-JL'. SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/'` GUESS=sparc-sun-sunos$SUN_REL ;; @@ -976,7 +976,27 @@ EOF GUESS=$UNAME_MACHINE-unknown-minix ;; aarch64:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + set_cc_for_build + CPU=$UNAME_MACHINE + LIBCABI=$LIBC + if test "$CC_FOR_BUILD" != no_compiler_found; then + ABI=64 + sed 's/^ //' << EOF > "$dummy.c" + #ifdef __ARM_EABI__ + #ifdef __ARM_PCS_VFP + ABI=eabihf + #else + ABI=eabi + #endif + #endif +EOF + cc_set_abi=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^ABI' | sed 's, ,,g'` + eval "$cc_set_abi" + case $ABI in + eabi | eabihf) CPU=armv8l; LIBCABI=$LIBC$ABI ;; + esac + fi + GUESS=$CPU-unknown-linux-$LIBCABI ;; aarch64_be:Linux:*:*) UNAME_MACHINE=aarch64_be @@ -1042,6 +1062,15 @@ EOF k1om:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; + kvx:Linux:*:*) + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; + kvx:cos:*:*) + GUESS=$UNAME_MACHINE-unknown-cos + ;; + kvx:mbr:*:*) + GUESS=$UNAME_MACHINE-unknown-mbr + ;; loongarch32:Linux:*:* | loongarch64:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; @@ -1197,7 +1226,7 @@ EOF GUESS=$UNAME_MACHINE-pc-sysv4.2uw$UNAME_VERSION ;; i*86:OS/2:*:*) - # If we were able to find `uname', then EMX Unix compatibility + # If we were able to find 'uname', then EMX Unix compatibility # is probably installed. GUESS=$UNAME_MACHINE-pc-os2-emx ;; @@ -1338,7 +1367,7 @@ EOF GUESS=ns32k-sni-sysv fi ;; - PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort + PENTIUM:*:4.0*:*) # Unisys 'ClearPath HMP IX 4000' SVR4/MP effort # says GUESS=i586-unisys-sysv4 ;; diff --git a/contrib/unbound/config.h.in b/contrib/unbound/config.h.in index 2caecf30d040..f31354d01408 100644 *** 18537 LINES SKIPPED *** From nobody Wed Oct 4 01:01:40 2023 X-Original-To: dev-commits-src-branches@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 4S0bxK2YK9z4wKHJ; Wed, 4 Oct 2023 01:01: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0bxK1S0Gz4XW3; Wed, 4 Oct 2023 01:01:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381301; 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=PgLbCTCV2ZdM23QuzfS8n047aArhqWbYnpXKCkuh/Es=; b=gnM985v40wX4xxmEmTUzBtoMjAD6UYGAGFfHgtm55VPjmGOngzrp4vSAUSuKoZ6AcFNaGT bKPpiC7z3J9x99LJG7AgLxrBfCePvDV4exaF0Q6Nmn1xA5TfdVDdXZjLpkw4HsB2KIyFBl ZNh6PHtK7jqw5PF/AsRK8AMQ8KNH0iNUNeKCoPs9E9dwx+k1EwEt4u+XITlJj8ZfhSxenw dj71fyvrc47iHXmHNGSzEfSzxhwuh00lUQxfgp3v12DgWQLt2Ed/DwCe/uBcPdU8fvDbEm 8mxiA49N9e5rDjWSvOeD4P23ezMtOgsa/e7+vZb6UzGnd+Tcj9mafCSj3UBxsg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696381301; a=rsa-sha256; cv=none; b=DfeQHpBPLtE4yGO2wkvTzLry/ww9Id7cs3NqQsmWLbGbUfcBDKTuBARiRrkrvNBKB7Ci+a WhY8uRrUgpqZn1oXKb8rlIlAPpMuKciTHPmDWDItkLLBRDkw+/OT41Cxm/bXCIOvTNXEsJ 2XSapA/nCoH6zrGxecHm1H1RbblpmDGnvjS4Kzkhy0VgybGj9MArPq+t0s3pO+tEhbogCI wWmbm4G76lTzMpDM3b3MOpZYZvDJfFozM4P/AdYvbscJMozVbTpA9nRPBf7AGcdluQHXmq trRZEQqbe1WG605rDSFZt5Tuls6ZlWnqo4DzSRuAik4gyy8Rz4b8ngR8yWO0fw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381301; 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=PgLbCTCV2ZdM23QuzfS8n047aArhqWbYnpXKCkuh/Es=; b=We1hoe1ublotsZ8xtJC50R6gx5V43KTqCDEeelCda7FP520USdLwa24000mCJR9wJCa4bo 9NRDXTM2luRP77y5nF+zn8b9+Xu/NWON5XQIaVMzCnz5tmCA/z/NaufQEKBupooysfR4gY YIWN7d43bQIU/CTn1E/6jkKfR2nk7GlsEfz0LcsWtqStCR5WCJlCQh0b1em4pqmAMuhpd+ RqEM6HJkEHDXK5BDVEYR4bpxonssE1OZRFo13tJlxQ0rEdrmktMO8z7WHKo7jBkCFtrIhY Ii8fo46mPe0rkWR47kZy1jT9npEdF3IjFDMdIyqjhkzv6mAmxAPpLZK+ANYnPQ== 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 4S0bxK0BZyz35H; Wed, 4 Oct 2023 01:01:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39411fx9049133; Wed, 4 Oct 2023 01:01:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39411ecJ049130; Wed, 4 Oct 2023 01:01:40 GMT (envelope-from git) Date: Wed, 4 Oct 2023 01:01:40 GMT Message-Id: <202310040101.39411ecJ049130@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Cy Schubert Subject: git: 9afc0c849e6e - stable/14 - local-unbound: remove stray config.h.in backup List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 9afc0c849e6e0436351fbdaf6157d1c822793d80 Auto-Submitted: auto-generated The branch stable/14 has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=9afc0c849e6e0436351fbdaf6157d1c822793d80 commit 9afc0c849e6e0436351fbdaf6157d1c822793d80 Author: Mina Galić AuthorDate: 2023-09-20 14:39:37 +0000 Commit: Cy Schubert CommitDate: 2023-10-04 01:01:06 +0000 local-unbound: remove stray config.h.in backup despite being ignored in our main .gitignore, such files can still be merged from vendor branches. Reviewed by: cy Fixes: 8f76bb7dad (unbound: Vendor import 1.18.0) MFC after: 2 weeks X-MFC with: 8f76bb7dad Differential Revision: https://reviews.freebsd.org/D41920 (cherry picked from commit 948e11aaf420cd7d493cc2e118cacc06d18653fe) --- contrib/unbound/config.h.in~ | 1456 ------------------------------------------ 1 file changed, 1456 deletions(-) diff --git a/contrib/unbound/config.h.in~ b/contrib/unbound/config.h.in~ deleted file mode 100644 index f31354d01408..000000000000 --- a/contrib/unbound/config.h.in~ +++ /dev/null @@ -1,1456 +0,0 @@ -/* config.h.in. Generated from configure.ac by autoheader. */ - -/* apply the noreturn attribute to a function that exits the program */ -#undef ATTR_NORETURN - -/* apply the weak attribute to a symbol */ -#undef ATTR_WEAK - -/* Directory to chroot to */ -#undef CHROOT_DIR - -/* Define this to enable client subnet option. */ -#undef CLIENT_SUBNET - -/* Do sha512 definitions in config.h */ -#undef COMPAT_SHA512 - -/* Command line arguments used with configure */ -#undef CONFCMDLINE - -/* Pathname to the Unbound configuration file */ -#undef CONFIGFILE - -/* Define this if on macOSX10.4-darwin8 and setreuid and setregid do not work - */ -#undef DARWIN_BROKEN_SETREUID - -/* Whether daemon is deprecated */ -#undef DEPRECATED_DAEMON - -/* Deprecate RSA 1024 bit length, makes that an unsupported key */ -#undef DEPRECATE_RSA_1024 - -/* Define this to enable kernel based UDP source port randomization. */ -#undef DISABLE_EXPLICIT_PORT_RANDOMISATION - -/* default dnstap socket path */ -#undef DNSTAP_SOCKET_PATH - -/* Define if you want to use debug lock checking (slow). */ -#undef ENABLE_LOCK_CHECKS - -/* Define this if you enabled-allsymbols from libunbound to link binaries to - it for smaller install size, but the libunbound export table is polluted by - internal symbols */ -#undef EXPORT_ALL_SYMBOLS - -/* Define to 1 if you have the `accept4' function. */ -#undef HAVE_ACCEPT4 - -/* Define to 1 if you have the `arc4random' function. */ -#undef HAVE_ARC4RANDOM - -/* Define to 1 if you have the `arc4random_uniform' function. */ -#undef HAVE_ARC4RANDOM_UNIFORM - -/* Define to 1 if you have the header file. */ -#undef HAVE_ARPA_INET_H - -/* Whether the C compiler accepts the "format" attribute */ -#undef HAVE_ATTR_FORMAT - -/* Whether the C compiler accepts the "noreturn" attribute */ -#undef HAVE_ATTR_NORETURN - -/* Whether the C compiler accepts the "unused" attribute */ -#undef HAVE_ATTR_UNUSED - -/* Whether the C compiler accepts the "weak" attribute */ -#undef HAVE_ATTR_WEAK - -/* If we have be64toh */ -#undef HAVE_BE64TOH - -/* Define to 1 if you have the `BIO_set_callback_ex' function. */ -#undef HAVE_BIO_SET_CALLBACK_EX - -/* Define to 1 if you have the header file. */ -#undef HAVE_BSD_STDLIB_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_BSD_STRING_H - -/* Define to 1 if you have the `chown' function. */ -#undef HAVE_CHOWN - -/* Define to 1 if you have the `chroot' function. */ -#undef HAVE_CHROOT - -/* Define to 1 if you have the `CRYPTO_cleanup_all_ex_data' function. */ -#undef HAVE_CRYPTO_CLEANUP_ALL_EX_DATA - -/* Define to 1 if you have the `CRYPTO_THREADID_set_callback' function. */ -#undef HAVE_CRYPTO_THREADID_SET_CALLBACK - -/* Define to 1 if you have the `ctime_r' function. */ -#undef HAVE_CTIME_R - -/* Define to 1 if you have the `daemon' function. */ -#undef HAVE_DAEMON - -/* Define to 1 if you have the declaration of `arc4random', and to 0 if you - don't. */ -#undef HAVE_DECL_ARC4RANDOM - -/* Define to 1 if you have the declaration of `arc4random_uniform', and to 0 - if you don't. */ -#undef HAVE_DECL_ARC4RANDOM_UNIFORM - -/* Define to 1 if you have the declaration of `evsignal_assign', and to 0 if - you don't. */ -#undef HAVE_DECL_EVSIGNAL_ASSIGN - -/* Define to 1 if you have the declaration of `inet_ntop', and to 0 if you - don't. */ -#undef HAVE_DECL_INET_NTOP - -/* Define to 1 if you have the declaration of `inet_pton', and to 0 if you - don't. */ -#undef HAVE_DECL_INET_PTON - -/* Define to 1 if you have the declaration of `nghttp2_session_server_new', - and to 0 if you don't. */ -#undef HAVE_DECL_NGHTTP2_SESSION_SERVER_NEW - -/* Define to 1 if you have the declaration of `NID_ED25519', and to 0 if you - don't. */ -#undef HAVE_DECL_NID_ED25519 - -/* Define to 1 if you have the declaration of `NID_ED448', and to 0 if you - don't. */ -#undef HAVE_DECL_NID_ED448 - -/* Define to 1 if you have the declaration of `NID_secp384r1', and to 0 if you - don't. */ -#undef HAVE_DECL_NID_SECP384R1 - -/* Define to 1 if you have the declaration of `NID_X9_62_prime256v1', and to 0 - if you don't. */ -#undef HAVE_DECL_NID_X9_62_PRIME256V1 - -/* Define to 1 if you have the declaration of `reallocarray', and to 0 if you - don't. */ -#undef HAVE_DECL_REALLOCARRAY - -/* Define to 1 if you have the declaration of `redisConnect', and to 0 if you - don't. */ -#undef HAVE_DECL_REDISCONNECT - -/* Define to 1 if you have the declaration of `sk_SSL_COMP_pop_free', and to 0 - if you don't. */ -#undef HAVE_DECL_SK_SSL_COMP_POP_FREE - -/* Define to 1 if you have the declaration of - `SSL_COMP_get_compression_methods', and to 0 if you don't. */ -#undef HAVE_DECL_SSL_COMP_GET_COMPRESSION_METHODS - -/* Define to 1 if you have the declaration of `SSL_CTX_set_ecdh_auto', and to - 0 if you don't. */ -#undef HAVE_DECL_SSL_CTX_SET_ECDH_AUTO - -/* Define to 1 if you have the declaration of `strlcat', and to 0 if you - don't. */ -#undef HAVE_DECL_STRLCAT - -/* Define to 1 if you have the declaration of `strlcpy', and to 0 if you - don't. */ -#undef HAVE_DECL_STRLCPY - -/* Define to 1 if you have the declaration of `XML_StopParser', and to 0 if - you don't. */ -#undef HAVE_DECL_XML_STOPPARSER - -/* Define to 1 if you have the header file. */ -#undef HAVE_DLFCN_H - -/* Define to 1 if you have the `DSA_SIG_set0' function. */ -#undef HAVE_DSA_SIG_SET0 - -/* Define to 1 if you have the header file. */ -#undef HAVE_ENDIAN_H - -/* Define to 1 if you have the `endprotoent' function. */ -#undef HAVE_ENDPROTOENT - -/* Define to 1 if you have the `endpwent' function. */ -#undef HAVE_ENDPWENT - -/* Define to 1 if you have the `endservent' function. */ -#undef HAVE_ENDSERVENT - -/* Define to 1 if you have the `ENGINE_cleanup' function. */ -#undef HAVE_ENGINE_CLEANUP - -/* Define to 1 if you have the `ERR_free_strings' function. */ -#undef HAVE_ERR_FREE_STRINGS - -/* Define to 1 if you have the `ERR_load_crypto_strings' function. */ -#undef HAVE_ERR_LOAD_CRYPTO_STRINGS - -/* Define to 1 if you have the `event_assign' function. */ -#undef HAVE_EVENT_ASSIGN - -/* Define to 1 if you have the `event_base_free' function. */ -#undef HAVE_EVENT_BASE_FREE - -/* Define to 1 if you have the `event_base_get_method' function. */ -#undef HAVE_EVENT_BASE_GET_METHOD - -/* Define to 1 if you have the `event_base_new' function. */ -#undef HAVE_EVENT_BASE_NEW - -/* Define to 1 if you have the `event_base_once' function. */ -#undef HAVE_EVENT_BASE_ONCE - -/* Define to 1 if you have the header file. */ -#undef HAVE_EVENT_H - -/* Define to 1 if you have the `EVP_aes_256_cbc' function. */ -#undef HAVE_EVP_AES_256_CBC - -/* Define to 1 if you have the `EVP_cleanup' function. */ -#undef HAVE_EVP_CLEANUP - -/* Define to 1 if you have the `EVP_default_properties_is_fips_enabled' - function. */ -#undef HAVE_EVP_DEFAULT_PROPERTIES_IS_FIPS_ENABLED - -/* Define to 1 if you have the `EVP_DigestVerify' function. */ -#undef HAVE_EVP_DIGESTVERIFY - -/* Define to 1 if you have the `EVP_dss1' function. */ -#undef HAVE_EVP_DSS1 - -/* Define to 1 if you have the `EVP_EncryptInit_ex' function. */ -#undef HAVE_EVP_ENCRYPTINIT_EX - -/* Define to 1 if you have the `EVP_MAC_CTX_set_params' function. */ -#undef HAVE_EVP_MAC_CTX_SET_PARAMS - -/* Define to 1 if you have the `EVP_MD_CTX_new' function. */ -#undef HAVE_EVP_MD_CTX_NEW - -/* Define to 1 if you have the `EVP_sha1' function. */ -#undef HAVE_EVP_SHA1 - -/* Define to 1 if you have the `EVP_sha256' function. */ -#undef HAVE_EVP_SHA256 - -/* Define to 1 if you have the `EVP_sha512' function. */ -#undef HAVE_EVP_SHA512 - -/* Define to 1 if you have the `ev_default_loop' function. */ -#undef HAVE_EV_DEFAULT_LOOP - -/* Define to 1 if you have the `ev_loop' function. */ -#undef HAVE_EV_LOOP - -/* Define to 1 if you have the header file. */ -#undef HAVE_EXPAT_H - -/* Define to 1 if you have the `explicit_bzero' function. */ -#undef HAVE_EXPLICIT_BZERO - -/* Define to 1 if you have the `fcntl' function. */ -#undef HAVE_FCNTL - -/* Define to 1 if you have the `FIPS_mode' function. */ -#undef HAVE_FIPS_MODE - -/* Define to 1 if you have the `fork' function. */ -#undef HAVE_FORK - -/* Define to 1 if fseeko (and presumably ftello) exists and is declared. */ -#undef HAVE_FSEEKO - -/* Define to 1 if you have the `fsync' function. */ -#undef HAVE_FSYNC - -/* Whether getaddrinfo is available */ -#undef HAVE_GETADDRINFO - -/* Define to 1 if you have the `getauxval' function. */ -#undef HAVE_GETAUXVAL - -/* Define to 1 if you have the `getentropy' function. */ -#undef HAVE_GETENTROPY - -/* Define to 1 if you have the `getifaddrs' function. */ -#undef HAVE_GETIFADDRS - -/* Define to 1 if you have the header file. */ -#undef HAVE_GETOPT_H - -/* Define to 1 if you have the `getpwnam' function. */ -#undef HAVE_GETPWNAM - -/* Define to 1 if you have the `getrlimit' function. */ -#undef HAVE_GETRLIMIT - -/* Define to 1 if you have the `gettid' function. */ -#undef HAVE_GETTID - -/* Define to 1 if you have the `glob' function. */ -#undef HAVE_GLOB - -/* Define to 1 if you have the header file. */ -#undef HAVE_GLOB_H - -/* Define to 1 if you have the `gmtime_r' function. */ -#undef HAVE_GMTIME_R - -/* Define to 1 if you have the header file. */ -#undef HAVE_GRP_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_HIREDIS_HIREDIS_H - -/* Define to 1 if you have the `HMAC_Init_ex' function. */ -#undef HAVE_HMAC_INIT_EX - -/* If we have htobe64 */ -#undef HAVE_HTOBE64 - -/* Define to 1 if you have the header file. */ -#undef HAVE_IFADDRS_H - -/* Define to 1 if you have the `if_nametoindex' function. */ -#undef HAVE_IF_NAMETOINDEX - -/* Define to 1 if you have the `inet_aton' function. */ -#undef HAVE_INET_ATON - -/* Define to 1 if you have the `inet_ntop' function. */ -#undef HAVE_INET_NTOP - -/* Define to 1 if you have the `inet_pton' function. */ -#undef HAVE_INET_PTON - -/* Define to 1 if you have the `initgroups' function. */ -#undef HAVE_INITGROUPS - -/* Define to 1 if you have the header file. */ -#undef HAVE_INTTYPES_H - -/* if the function 'ioctlsocket' is available */ -#undef HAVE_IOCTLSOCKET - -/* Define to 1 if you have the header file. */ -#undef HAVE_IPHLPAPI_H - -/* Define to 1 if you have the `isblank' function. */ -#undef HAVE_ISBLANK - -/* Define to 1 if you have the `kill' function. */ -#undef HAVE_KILL - -/* Use portable libbsd functions */ -#undef HAVE_LIBBSD - -/* Define to 1 if you have the header file. */ -#undef HAVE_LIBKERN_OSBYTEORDER_H - -/* Define if we have LibreSSL */ -#undef HAVE_LIBRESSL - -/* Define to 1 if you have the header file. */ -#undef HAVE_LINUX_NET_TSTAMP_H - -/* Define to 1 if you have the `localtime_r' function. */ -#undef HAVE_LOCALTIME_R - -/* Define to 1 if you have the header file. */ -#undef HAVE_LOGIN_CAP_H - -/* If have GNU libc compatible malloc */ -#undef HAVE_MALLOC - -/* Define to 1 if you have the `memmove' function. */ -#undef HAVE_MEMMOVE - -/* Define to 1 if you have the header file. */ -#undef HAVE_MEMORY_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETDB_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETINET_IN_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETINET_TCP_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETIOAPI_H - -/* Use libnettle for crypto */ -#undef HAVE_NETTLE - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETTLE_DSA_COMPAT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETTLE_EDDSA_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NET_IF_H - -/* Define this to use nghttp2 client. */ -#undef HAVE_NGHTTP2 - -/* Define to 1 if you have the header file. */ -#undef HAVE_NGHTTP2_NGHTTP2_H - -/* Use libnss for crypto */ -#undef HAVE_NSS - -/* Define to 1 if you have the `OpenSSL_add_all_digests' function. */ -#undef HAVE_OPENSSL_ADD_ALL_DIGESTS - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_BN_H - -/* Define to 1 if you have the `OPENSSL_config' function. */ -#undef HAVE_OPENSSL_CONFIG - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_CONF_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_CORE_NAMES_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_DH_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_DSA_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_ENGINE_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_ERR_H - -/* Define to 1 if you have the `OPENSSL_init_crypto' function. */ -#undef HAVE_OPENSSL_INIT_CRYPTO - -/* Define to 1 if you have the `OPENSSL_init_ssl' function. */ -#undef HAVE_OPENSSL_INIT_SSL - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_PARAM_BUILD_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_RAND_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_RSA_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_SSL_H - -/* Define to 1 if you have the `OSSL_PARAM_BLD_new' function. */ -#undef HAVE_OSSL_PARAM_BLD_NEW - -/* Define to 1 if you have the `poll' function. */ -#undef HAVE_POLL - -/* Define to 1 if you have the header file. */ -#undef HAVE_POLL_H - -/* Define if you have POSIX threads libraries and header files. */ -#undef HAVE_PTHREAD - -/* Have PTHREAD_PRIO_INHERIT. */ -#undef HAVE_PTHREAD_PRIO_INHERIT - -/* Define to 1 if the system has the type `pthread_rwlock_t'. */ -#undef HAVE_PTHREAD_RWLOCK_T - -/* Define to 1 if the system has the type `pthread_spinlock_t'. */ -#undef HAVE_PTHREAD_SPINLOCK_T - -/* Define to 1 if you have the header file. */ -#undef HAVE_PWD_H - -/* Define if you have Python libraries and header files. */ -#undef HAVE_PYTHON - -/* Define to 1 if you have the `random' function. */ -#undef HAVE_RANDOM - -/* Define to 1 if you have the `RAND_cleanup' function. */ -#undef HAVE_RAND_CLEANUP - -/* If we have reallocarray(3) */ -#undef HAVE_REALLOCARRAY - -/* Define to 1 if you have the `recvmsg' function. */ -#undef HAVE_RECVMSG - -/* Define to 1 if you have the `sendmsg' function. */ -#undef HAVE_SENDMSG - -/* Define to 1 if you have the `setregid' function. */ -#undef HAVE_SETREGID - -/* Define to 1 if you have the `setresgid' function. */ -#undef HAVE_SETRESGID - -/* Define to 1 if you have the `setresuid' function. */ -#undef HAVE_SETRESUID - -/* Define to 1 if you have the `setreuid' function. */ -#undef HAVE_SETREUID - -/* Define to 1 if you have the `setrlimit' function. */ -#undef HAVE_SETRLIMIT - -/* Define to 1 if you have the `setsid' function. */ -#undef HAVE_SETSID - -/* Define to 1 if you have the `setusercontext' function. */ -#undef HAVE_SETUSERCONTEXT - -/* Define to 1 if you have the `SHA512_Update' function. */ -#undef HAVE_SHA512_UPDATE - -/* Define to 1 if you have the `shmget' function. */ -#undef HAVE_SHMGET - -/* Define to 1 if you have the `sigprocmask' function. */ -#undef HAVE_SIGPROCMASK - -/* Define to 1 if you have the `sleep' function. */ -#undef HAVE_SLEEP - -/* Define to 1 if you have the `snprintf' function. */ -#undef HAVE_SNPRINTF - -/* Define to 1 if you have the `socketpair' function. */ -#undef HAVE_SOCKETPAIR - -/* Using Solaris threads */ -#undef HAVE_SOLARIS_THREADS - -/* Define to 1 if you have the `srandom' function. */ -#undef HAVE_SRANDOM - -/* Define if you have the SSL libraries installed. */ -#undef HAVE_SSL - -/* Define to 1 if you have the `SSL_CTX_set_alpn_protos' function. */ -#undef HAVE_SSL_CTX_SET_ALPN_PROTOS - -/* Define to 1 if you have the `SSL_CTX_set_alpn_select_cb' function. */ -#undef HAVE_SSL_CTX_SET_ALPN_SELECT_CB - -/* Define to 1 if you have the `SSL_CTX_set_ciphersuites' function. */ -#undef HAVE_SSL_CTX_SET_CIPHERSUITES - -/* Define to 1 if you have the `SSL_CTX_set_security_level' function. */ -#undef HAVE_SSL_CTX_SET_SECURITY_LEVEL - -/* Define to 1 if you have the `SSL_CTX_set_tlsext_ticket_key_evp_cb' - function. */ -#undef HAVE_SSL_CTX_SET_TLSEXT_TICKET_KEY_EVP_CB - -/* Define to 1 if you have the `SSL_get0_alpn_selected' function. */ -#undef HAVE_SSL_GET0_ALPN_SELECTED - -/* Define to 1 if you have the `SSL_get0_peername' function. */ -#undef HAVE_SSL_GET0_PEERNAME - -/* Define to 1 if you have the `SSL_get1_peer_certificate' function. */ -#undef HAVE_SSL_GET1_PEER_CERTIFICATE - -/* Define to 1 if you have the `SSL_set1_host' function. */ -#undef HAVE_SSL_SET1_HOST - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDARG_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDBOOL_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDINT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDLIB_H - -/* Define to 1 if you have the `strftime' function. */ -#undef HAVE_STRFTIME - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRINGS_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRING_H - -/* Define to 1 if you have the `strlcat' function. */ -#undef HAVE_STRLCAT - -/* Define to 1 if you have the `strlcpy' function. */ -#undef HAVE_STRLCPY - -/* Define to 1 if you have the `strptime' function. */ -#undef HAVE_STRPTIME - -/* Define to 1 if you have the `strsep' function. */ -#undef HAVE_STRSEP - -/* Define to 1 if `ipi_spec_dst' is a member of `struct in_pktinfo'. */ -#undef HAVE_STRUCT_IN_PKTINFO_IPI_SPEC_DST - -/* Define to 1 if `sun_len' is a member of `struct sockaddr_un'. */ -#undef HAVE_STRUCT_SOCKADDR_UN_SUN_LEN - -/* Define if you have Swig libraries and header files. */ -#undef HAVE_SWIG - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYSLOG_H - -/* Define to 1 if systemd should be used */ -#undef HAVE_SYSTEMD - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_ENDIAN_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_IPC_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_PARAM_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_RESOURCE_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SELECT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SHA2_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SHM_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SOCKET_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_STAT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SYSCTL_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_TYPES_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_UIO_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_UN_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_WAIT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_TARGETCONDITIONALS_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_TIME_H - -/* Define to 1 if you have the `tzset' function. */ -#undef HAVE_TZSET - -/* Define to 1 if you have the header file. */ -#undef HAVE_UNISTD_H - -/* Define to 1 if you have the `usleep' function. */ -#undef HAVE_USLEEP - -/* Define to 1 if you have the `vfork' function. */ -#undef HAVE_VFORK - -/* Define to 1 if you have the header file. */ -#undef HAVE_VFORK_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_WINDOWS_H - -/* Using Windows threads */ -#undef HAVE_WINDOWS_THREADS - -/* Define to 1 if you have the header file. */ -#undef HAVE_WINSOCK2_H - -/* Define to 1 if `fork' works. */ -#undef HAVE_WORKING_FORK - -/* Define to 1 if `vfork' works. */ -#undef HAVE_WORKING_VFORK - -/* Define to 1 if you have the `writev' function. */ -#undef HAVE_WRITEV - -/* Define to 1 if you have the header file. */ -#undef HAVE_WS2TCPIP_H - -/* Define to 1 if you have the `X509_VERIFY_PARAM_set1_host' function. */ -#undef HAVE_X509_VERIFY_PARAM_SET1_HOST - -/* Define to 1 if you have the `_beginthreadex' function. */ -#undef HAVE__BEGINTHREADEX - -/* If HMAC_Init_ex() returns void */ -#undef HMAC_INIT_EX_RETURNS_VOID - -/* if lex has yylex_destroy */ -#undef LEX_HAS_YYLEX_DESTROY - -/* Define to the sub-directory where libtool stores uninstalled libraries. */ -#undef LT_OBJDIR - -/* Define to the maximum message length to pass to syslog. */ -#undef MAXSYSLOGMSGLEN - -/* Define if memcmp() does not compare unsigned bytes */ -#undef MEMCMP_IS_BROKEN - -/* Define if mkdir has one argument. */ -#undef MKDIR_HAS_ONE_ARG - -/* Define if the network stack does not fully support nonblocking io (causes - lower performance). */ -#undef NONBLOCKING_IS_BROKEN - -/* Put -D_ALL_SOURCE define in config.h */ -#undef OMITTED__D_ALL_SOURCE - -/* Put -D_BSD_SOURCE define in config.h */ -#undef OMITTED__D_BSD_SOURCE - -/* Put -D_DEFAULT_SOURCE define in config.h */ -#undef OMITTED__D_DEFAULT_SOURCE - -/* Put -D_GNU_SOURCE define in config.h */ -#undef OMITTED__D_GNU_SOURCE - -/* Put -D_LARGEFILE_SOURCE=1 define in config.h */ -#undef OMITTED__D_LARGEFILE_SOURCE_1 - -/* Put -D_POSIX_C_SOURCE=200112 define in config.h */ -#undef OMITTED__D_POSIX_C_SOURCE_200112 - -/* Put -D_XOPEN_SOURCE=600 define in config.h */ -#undef OMITTED__D_XOPEN_SOURCE_600 - -/* Put -D_XOPEN_SOURCE_EXTENDED=1 define in config.h */ -#undef OMITTED__D_XOPEN_SOURCE_EXTENDED_1 - -/* Put -D__EXTENSIONS__ define in config.h */ -#undef OMITTED__D__EXTENSIONS__ - -/* Define to the address where bug reports for this package should be sent. */ -#undef PACKAGE_BUGREPORT - -/* Define to the full name of this package. */ -#undef PACKAGE_NAME - -/* Define to the full name and version of this package. */ -#undef PACKAGE_STRING - -/* Define to the one symbol short name of this package. */ -#undef PACKAGE_TARNAME - -/* Define to the home page for this package. */ -#undef PACKAGE_URL - -/* Define to the version of this package. */ -#undef PACKAGE_VERSION - -/* default pidfile location */ -#undef PIDFILE - -/* Define to necessary symbol if this constant uses a non-standard name on - your system. */ -#undef PTHREAD_CREATE_JOINABLE - -/* Return type of signal handlers, but autoconf 2.70 says 'your code may - safely assume C89 semantics that RETSIGTYPE is void.' */ -#undef RETSIGTYPE - -/* if REUSEPORT is enabled by default */ -#undef REUSEPORT_DEFAULT - -/* default rootkey location */ -#undef ROOT_ANCHOR_FILE - -/* default rootcert location */ -#undef ROOT_CERT_FILE - -/* version number for resource files */ -#undef RSRC_PACKAGE_VERSION - -/* Directory to chdir to */ -#undef RUN_DIR - -/* Shared data */ -#undef SHARE_DIR - -/* The size of `pthread_t', as computed by sizeof. */ -#undef SIZEOF_PTHREAD_T - -/* The size of `size_t', as computed by sizeof. */ -#undef SIZEOF_SIZE_T - -/* The size of `time_t', as computed by sizeof. */ -#undef SIZEOF_TIME_T - -/* The size of `unsigned long', as computed by sizeof. */ -#undef SIZEOF_UNSIGNED_LONG - -/* define if (v)snprintf does not return length needed, (but length used) */ -#undef SNPRINTF_RET_BROKEN - -/* Define to 1 if libsodium supports sodium_set_misuse_handler */ -#undef SODIUM_MISUSE_HANDLER - -/* Define to 1 if you have the ANSI C header files. */ -#undef STDC_HEADERS - -/* use default strptime. */ -#undef STRPTIME_WORKS - -/* Use win32 resources and API */ -#undef UB_ON_WINDOWS - -/* the SYSLOG_FACILITY to use, default LOG_DAEMON */ -#undef UB_SYSLOG_FACILITY - -/* default username */ -#undef UB_USERNAME - -/* use to enable lightweight alloc assertions, for debug use */ -#undef UNBOUND_ALLOC_LITE - -/* use malloc not regions, for debug use */ -#undef UNBOUND_ALLOC_NONREGIONAL - -/* use statistics for allocs and frees, for debug use */ -#undef UNBOUND_ALLOC_STATS - -/* define this to enable debug checks. */ -#undef UNBOUND_DEBUG - -/* Define to 1 to use cachedb support */ -#undef USE_CACHEDB - -/* Define to 1 to enable dnscrypt support */ -#undef USE_DNSCRYPT - -/* Define to 1 to enable dnscrypt with xchacha20 support */ -#undef USE_DNSCRYPT_XCHACHA20 - -/* Define to 1 to enable dnstap support */ -#undef USE_DNSTAP - -/* Define this to enable DSA support. */ -#undef USE_DSA - -/* Define this to enable ECDSA support. */ -#undef USE_ECDSA - -/* Define this to enable an EVP workaround for older openssl */ -#undef USE_ECDSA_EVP_WORKAROUND - -/* Define this to enable ED25519 support. */ -#undef USE_ED25519 - -/* Define this to enable ED448 support. */ -#undef USE_ED448 - -/* Define this to enable GOST support. */ -#undef USE_GOST - -/* Define to 1 to use ipsecmod support. */ -#undef USE_IPSECMOD - -/* Define to 1 to use ipset support */ -#undef USE_IPSET - -/* Define if you enable libevent */ -#undef USE_LIBEVENT - -/* Define this to enable use of /proc/sys/net/ipv4/ip_local_port_range as a - default outgoing port range. This is only for the libunbound on Linux and - does not affect unbound resolving daemon itself. This may severely limit - the number of available outgoing ports and thus decrease randomness. Define - this only when the target system restricts (e.g. some of SELinux enabled - distributions) the use of non-ephemeral ports. */ -#undef USE_LINUX_IP_LOCAL_PORT_RANGE - -/* Define if you want to use internal select based events */ -#undef USE_MINI_EVENT - -/* Define this to enable client TCP Fast Open. */ -#undef USE_MSG_FASTOPEN - -/* Define this to enable client TCP Fast Open. */ -#undef USE_OSX_MSG_FASTOPEN - -/* Define this to use hiredis client. */ -#undef USE_REDIS - -/* Define this to enable SHA1 support. */ -#undef USE_SHA1 - -/* Define this to enable SHA256 and SHA512 support. */ -#undef USE_SHA2 - -/* Enable extensions on AIX 3, Interix. */ -#ifndef _ALL_SOURCE -# undef _ALL_SOURCE -#endif -/* Enable GNU extensions on systems that have them. */ -#ifndef _GNU_SOURCE -# undef _GNU_SOURCE -#endif -/* Enable threading extensions on Solaris. */ -#ifndef _POSIX_PTHREAD_SEMANTICS -# undef _POSIX_PTHREAD_SEMANTICS -#endif -/* Enable extensions on HP NonStop. */ -#ifndef _TANDEM_SOURCE -# undef _TANDEM_SOURCE -#endif -/* Enable general extensions on Solaris. */ -#ifndef __EXTENSIONS__ -# undef __EXTENSIONS__ -#endif - - -/* Define this to enable server TCP Fast Open. */ -#undef USE_TCP_FASTOPEN - -/* Whether the windows socket API is used */ -#undef USE_WINSOCK - -/* the version of the windows API enabled */ -#undef WINVER *** 502 LINES SKIPPED *** From nobody Wed Oct 4 01:02:03 2023 X-Original-To: dev-commits-src-branches@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 4S0bxl6cgJz4wKKN; Wed, 4 Oct 2023 01:02: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0bxl6Rd3z4Xyj; Wed, 4 Oct 2023 01:02:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381323; 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=d5Leh95C3sVzv0SPErSdU4VCOvXlG88+m1OfFl9JTN0=; b=xUBpTUJJ1mgCIJ7+5xUQGYA7cPGJJkgLEfWBSUrxCbmgdAvEgQmc6ZAM2XPBkAglN68jtn 0QqtF0hkC5F/SnRf4OhQKpzWheq3Gm3fKNBUbHG1rwW25sjgTN8Z2GQAsAlnZV5l5GRTMm YFF4RTVSDFM0w7K8aer34Kya2bROda3VTtmpLxVleH/a8bikhFzNLcZVmn4eR2jbrV7H71 Zlr4xABu+lj42DL5GKoTkEEDKfY0BA2Ii6d+jehBUyxiswT2yF6VHZBlmyvgQN3MPwicGM oHCcKZVujv9UwGUGFJABjXh8AHajBQxfvLBYetM2RFuvOFVeEmfr1LDitUhGSw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696381323; a=rsa-sha256; cv=none; b=tP7O2Ppx0HD1R/zGUWGU5MkSZTI2K16Aa8G6hqmW09ccmgwBv/nkNAeTOTyNrmQx0Y/rxQ lkdbkpI6H+Uf0SqmEBZNjrX2xY3jV/xPKwoJcZ7nJDZYww49x1NUAhRUm51JfXCCpuOFwC kGlauPw0YJWkFarL00zVrpICRZsyGN8ADW6hvhvkGR6Jr/E86CvkUPWKJGnHeCTBFsbEHU YuQ3NLRtEmcU08xYymjqGGgXihSLojvs3F3hB3rRZcrF4hQsuGvR5U1FMJoZtwq/eiCgZn KkGwJ+kb0b0btqaUESZ8Dl4+B0jVW7sO8nX7eZ3aELcMuZeSxT8zhaiALp7ccA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381323; 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=d5Leh95C3sVzv0SPErSdU4VCOvXlG88+m1OfFl9JTN0=; b=eZh9/i+JKWUY9kG8toIrt3evn2j7dxvtO1uGACU7yBa/CDM0V4T+3EMD1P7ptEKUAKK1FB 5F2+WojKOLi+CpGizR0wSaNLZKD/y49Hh+DkJUmFIJBTaIqfVRD11z+GS4pQj1ykrBUkd0 XwrXCg4MDXaQjFIEvi3+ZEbQvtRLTHabrHcgo4fNXjAbe3QgNf/P8q66RJl96R5Lv6LFAT 1DoakfhIO7P1bMv1BDh0JKrn/nIqV8dMfADnPJZ8uEKfPyETZvgvJiwL8zl3nRUjuG4sWy NJ47/62whYmMkULeEZmQPeJ2FLYnRL7xk52hccDYvyZWriuG/Vy6z4vKDIdRJA== 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 4S0bxl5Bc4z33W; Wed, 4 Oct 2023 01:02:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394123kU050340; Wed, 4 Oct 2023 01:02:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394123ml050337; Wed, 4 Oct 2023 01:02:03 GMT (envelope-from git) Date: Wed, 4 Oct 2023 01:02:03 GMT Message-Id: <202310040102.394123ml050337@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Cy Schubert Subject: git: a931c02ae895 - stable/13 - sqlite3: Vendor import of sqlite3 3.43.1 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: a931c02ae895feb259cc84ec53e44e6f6481db25 Auto-Submitted: auto-generated The branch stable/13 has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=a931c02ae895feb259cc84ec53e44e6f6481db25 commit a931c02ae895feb259cc84ec53e44e6f6481db25 Author: Cy Schubert AuthorDate: 2023-09-19 15:06:50 +0000 Commit: Cy Schubert CommitDate: 2023-10-04 01:01:51 +0000 sqlite3: Vendor import of sqlite3 3.43.1 Release notes at https://www.sqlite.org/releaselog/3_43_1.html. Obtained from: https://www.sqlite.org/2023/sqlite-autoconf-3430100.tar.gz Merge commit 'fa2bb1440e13602676feec708ac7a9a3bb5ce5c8' into main (cherry picked from commit ec994981447e8a974426660b5071bc405280af73) --- contrib/sqlite3/Makefile.am | 2 +- contrib/sqlite3/Makefile.in | 2 +- contrib/sqlite3/Makefile.msc | 27 + contrib/sqlite3/configure | 20 +- contrib/sqlite3/configure.ac | 2 +- contrib/sqlite3/shell.c | 1019 +++- contrib/sqlite3/sqlite3.1 | 161 +- contrib/sqlite3/sqlite3.c | 7881 +++++++++++++++++++++--------- contrib/sqlite3/sqlite3.h | 106 +- contrib/sqlite3/sqlite3ext.h | 4 + contrib/sqlite3/sqlite3rc.h | 2 +- contrib/sqlite3/tea/configure | 20 +- contrib/sqlite3/tea/configure.ac | 2 +- contrib/sqlite3/tea/generic/tclsqlite3.c | 33 +- 14 files changed, 6509 insertions(+), 2772 deletions(-) diff --git a/contrib/sqlite3/Makefile.am b/contrib/sqlite3/Makefile.am index 694419b27dfd..1eaa560ff884 100644 --- a/contrib/sqlite3/Makefile.am +++ b/contrib/sqlite3/Makefile.am @@ -9,7 +9,7 @@ sqlite3_SOURCES = shell.c sqlite3.h EXTRA_sqlite3_SOURCES = sqlite3.c sqlite3_LDADD = @EXTRA_SHELL_OBJ@ @READLINE_LIBS@ sqlite3_DEPENDENCIES = @EXTRA_SHELL_OBJ@ -sqlite3_CFLAGS = $(AM_CFLAGS) -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_ENABLE_STMTVTAB -DSQLITE_ENABLE_DBSTAT_VTAB $(SHELL_CFLAGS) +sqlite3_CFLAGS = $(AM_CFLAGS) -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_DQS=0 -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_ENABLE_STMTVTAB -DSQLITE_ENABLE_DBSTAT_VTAB $(SHELL_CFLAGS) include_HEADERS = sqlite3.h sqlite3ext.h diff --git a/contrib/sqlite3/Makefile.in b/contrib/sqlite3/Makefile.in index d45c6b8f4cde..fe708a0a9d84 100644 --- a/contrib/sqlite3/Makefile.in +++ b/contrib/sqlite3/Makefile.in @@ -371,7 +371,7 @@ sqlite3_SOURCES = shell.c sqlite3.h EXTRA_sqlite3_SOURCES = sqlite3.c sqlite3_LDADD = @EXTRA_SHELL_OBJ@ @READLINE_LIBS@ sqlite3_DEPENDENCIES = @EXTRA_SHELL_OBJ@ -sqlite3_CFLAGS = $(AM_CFLAGS) -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_ENABLE_STMTVTAB -DSQLITE_ENABLE_DBSTAT_VTAB $(SHELL_CFLAGS) +sqlite3_CFLAGS = $(AM_CFLAGS) -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_DQS=0 -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_ENABLE_STMTVTAB -DSQLITE_ENABLE_DBSTAT_VTAB $(SHELL_CFLAGS) include_HEADERS = sqlite3.h sqlite3ext.h EXTRA_DIST = sqlite3.1 tea Makefile.msc sqlite3.rc sqlite3rc.h README.txt Replace.cs Makefile.fallback pkgconfigdir = ${libdir}/pkgconfig diff --git a/contrib/sqlite3/Makefile.msc b/contrib/sqlite3/Makefile.msc index 09daa867eced..13663d877757 100644 --- a/contrib/sqlite3/Makefile.msc +++ b/contrib/sqlite3/Makefile.msc @@ -52,6 +52,13 @@ MINIMAL_AMALGAMATION = 0 USE_STDCALL = 0 !ENDIF +# Set this non-0 to use structured exception handling (SEH) for WAL mode +# in the core library. +# +!IFNDEF USE_SEH +USE_SEH = 1 +!ENDIF + # Set this non-0 to have the shell executable link against the core dynamic # link library. # @@ -180,6 +187,12 @@ WIN32HEAP = 0 OSTRACE = 0 !ENDIF +# enable address sanitizer using ASAN=1 on the command-line. +# +!IFNDEF ASAN +ASAN = 0 +!ENDIF + # Set this to one of the following values to enable various debugging # features. Each level includes the debugging options from the previous # levels. Currently, the recognized values for DEBUG are: @@ -311,6 +324,13 @@ OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_ENABLE_MATH_FUNCTIONS OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_ENABLE_RBU=1 !ENDIF +# Should structured exception handling (SEH) be enabled for WAL mode in +# the core library? +# +!IF $(USE_SEH)!=0 +OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_USE_SEH=1 +!ENDIF + # These are the "extended" SQLite compilation options used when compiling for # the Windows 10 platform. # @@ -718,6 +738,13 @@ RCC = $(RCC) -DSQLITE_WIN32_MALLOC_VALIDATE=1 !ENDIF +# Address sanitizer if ASAN=1 +# +!IF $(ASAN)>0 +TCC = $(TCC) /fsanitize=address +!ENDIF + + # Compiler options needed for programs that use the readline() library. # !IFNDEF READLINE_FLAGS diff --git a/contrib/sqlite3/configure b/contrib/sqlite3/configure index 1016e350c37f..39694c06793b 100755 --- a/contrib/sqlite3/configure +++ b/contrib/sqlite3/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.71 for sqlite 3.42.0. +# Generated by GNU Autoconf 2.71 for sqlite 3.43.1. # # Report bugs to . # @@ -621,8 +621,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='sqlite' PACKAGE_TARNAME='sqlite' -PACKAGE_VERSION='3.42.0' -PACKAGE_STRING='sqlite 3.42.0' +PACKAGE_VERSION='3.43.1' +PACKAGE_STRING='sqlite 3.43.1' PACKAGE_BUGREPORT='http://www.sqlite.org' PACKAGE_URL='' @@ -1367,7 +1367,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures sqlite 3.42.0 to adapt to many kinds of systems. +\`configure' configures sqlite 3.43.1 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1438,7 +1438,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of sqlite 3.42.0:";; + short | recursive ) echo "Configuration of sqlite 3.43.1:";; esac cat <<\_ACEOF @@ -1563,7 +1563,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -sqlite configure 3.42.0 +sqlite configure 3.43.1 generated by GNU Autoconf 2.71 Copyright (C) 2021 Free Software Foundation, Inc. @@ -1833,7 +1833,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by sqlite $as_me 3.42.0, which was +It was created by sqlite $as_me 3.43.1, which was generated by GNU Autoconf 2.71. Invocation command line was $ $0$ac_configure_args_raw @@ -3106,7 +3106,7 @@ fi # Define the identity of the package. PACKAGE='sqlite' - VERSION='3.42.0' + VERSION='3.43.1' printf "%s\n" "#define PACKAGE \"$PACKAGE\"" >>confdefs.h @@ -15314,7 +15314,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by sqlite $as_me 3.42.0, which was +This file was extended by sqlite $as_me 3.43.1, which was generated by GNU Autoconf 2.71. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -15373,7 +15373,7 @@ ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config='$ac_cs_config_escaped' ac_cs_version="\\ -sqlite config.status 3.42.0 +sqlite config.status 3.43.1 configured by $0, generated by GNU Autoconf 2.71, with options \\"\$ac_cs_config\\" diff --git a/contrib/sqlite3/configure.ac b/contrib/sqlite3/configure.ac index a706a4753049..3d7da8b984c3 100644 --- a/contrib/sqlite3/configure.ac +++ b/contrib/sqlite3/configure.ac @@ -10,7 +10,7 @@ # AC_PREREQ(2.61) -AC_INIT(sqlite, 3.42.0, http://www.sqlite.org) +AC_INIT(sqlite, 3.43.1, http://www.sqlite.org) AC_CONFIG_SRCDIR([sqlite3.c]) AC_CONFIG_AUX_DIR([.]) diff --git a/contrib/sqlite3/shell.c b/contrib/sqlite3/shell.c index 647a214226cc..6b2cdca83d6b 100644 --- a/contrib/sqlite3/shell.c +++ b/contrib/sqlite3/shell.c @@ -246,6 +246,7 @@ typedef unsigned char u8; #if SQLITE_OS_WINRT #include #endif +#undef WIN32_LEAN_AND_MEAN #define WIN32_LEAN_AND_MEAN #include @@ -1224,6 +1225,46 @@ static char *shellFakeSchema( return s.z; } +/* +** SQL function: strtod(X) +** +** Use the C-library strtod() function to convert string X into a double. +** Used for comparing the accuracy of SQLite's internal text-to-float conversion +** routines against the C-library. +*/ +static void shellStrtod( + sqlite3_context *pCtx, + int nVal, + sqlite3_value **apVal +){ + char *z = (char*)sqlite3_value_text(apVal[0]); + UNUSED_PARAMETER(nVal); + if( z==0 ) return; + sqlite3_result_double(pCtx, strtod(z,0)); +} + +/* +** SQL function: dtostr(X) +** +** Use the C-library printf() function to convert real value X into a string. +** Used for comparing the accuracy of SQLite's internal float-to-text conversion +** routines against the C-library. +*/ +static void shellDtostr( + sqlite3_context *pCtx, + int nVal, + sqlite3_value **apVal +){ + double r = sqlite3_value_double(apVal[0]); + int n = nVal>=2 ? sqlite3_value_int(apVal[1]) : 26; + char z[400]; + if( n<1 ) n = 1; + if( n>350 ) n = 350; + sprintf(z, "%#+.*e", n, r); + sqlite3_result_text(pCtx, z, -1, SQLITE_TRANSIENT); +} + + /* ** SQL function: shell_module_schema(X) ** @@ -1473,7 +1514,7 @@ struct DIR { #endif /* -** Provide the function prototype for the POSIX compatiable getenv() +** Provide the function prototype for the POSIX compatible getenv() ** function. This function is not thread-safe. */ @@ -1799,6 +1840,188 @@ int sqlite3MemTraceDeactivate(void){ } /************************* End ../ext/misc/memtrace.c ********************/ +/************************* Begin ../ext/misc/pcachetrace.c ******************/ +/* +** 2023-06-21 +** +** The author disclaims copyright to this source code. In place of +** a legal notice, here is a blessing: +** +** May you do good and not evil. +** May you find forgiveness for yourself and forgive others. +** May you share freely, never taking more than you give. +** +************************************************************************* +** +** This file implements an extension that uses the SQLITE_CONFIG_PCACHE2 +** mechanism to add a tracing layer on top of pluggable page cache of +** SQLite. If this extension is registered prior to sqlite3_initialize(), +** it will cause all page cache activities to be logged on standard output, +** or to some other FILE specified by the initializer. +** +** This file needs to be compiled into the application that uses it. +** +** This extension is used to implement the --pcachetrace option of the +** command-line shell. +*/ +#include +#include +#include + +/* The original page cache routines */ +static sqlite3_pcache_methods2 pcacheBase; +static FILE *pcachetraceOut; + +/* Methods that trace pcache activity */ +static int pcachetraceInit(void *pArg){ + int nRes; + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xInit(%p)\n", pArg); + } + nRes = pcacheBase.xInit(pArg); + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xInit(%p) -> %d\n", pArg, nRes); + } + return nRes; +} +static void pcachetraceShutdown(void *pArg){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xShutdown(%p)\n", pArg); + } + pcacheBase.xShutdown(pArg); +} +static sqlite3_pcache *pcachetraceCreate(int szPage, int szExtra, int bPurge){ + sqlite3_pcache *pRes; + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xCreate(%d,%d,%d)\n", + szPage, szExtra, bPurge); + } + pRes = pcacheBase.xCreate(szPage, szExtra, bPurge); + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xCreate(%d,%d,%d) -> %p\n", + szPage, szExtra, bPurge, pRes); + } + return pRes; +} +static void pcachetraceCachesize(sqlite3_pcache *p, int nCachesize){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xCachesize(%p, %d)\n", p, nCachesize); + } + pcacheBase.xCachesize(p, nCachesize); +} +static int pcachetracePagecount(sqlite3_pcache *p){ + int nRes; + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xPagecount(%p)\n", p); + } + nRes = pcacheBase.xPagecount(p); + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xPagecount(%p) -> %d\n", p, nRes); + } + return nRes; +} +static sqlite3_pcache_page *pcachetraceFetch( + sqlite3_pcache *p, + unsigned key, + int crFg +){ + sqlite3_pcache_page *pRes; + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xFetch(%p,%u,%d)\n", p, key, crFg); + } + pRes = pcacheBase.xFetch(p, key, crFg); + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xFetch(%p,%u,%d) -> %p\n", + p, key, crFg, pRes); + } + return pRes; +} +static void pcachetraceUnpin( + sqlite3_pcache *p, + sqlite3_pcache_page *pPg, + int bDiscard +){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xUnpin(%p, %p, %d)\n", + p, pPg, bDiscard); + } + pcacheBase.xUnpin(p, pPg, bDiscard); +} +static void pcachetraceRekey( + sqlite3_pcache *p, + sqlite3_pcache_page *pPg, + unsigned oldKey, + unsigned newKey +){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xRekey(%p, %p, %u, %u)\n", + p, pPg, oldKey, newKey); + } + pcacheBase.xRekey(p, pPg, oldKey, newKey); +} +static void pcachetraceTruncate(sqlite3_pcache *p, unsigned n){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xTruncate(%p, %u)\n", p, n); + } + pcacheBase.xTruncate(p, n); +} +static void pcachetraceDestroy(sqlite3_pcache *p){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xDestroy(%p)\n", p); + } + pcacheBase.xDestroy(p); +} +static void pcachetraceShrink(sqlite3_pcache *p){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xShrink(%p)\n", p); + } + pcacheBase.xShrink(p); +} + +/* The substitute pcache methods */ +static sqlite3_pcache_methods2 ersaztPcacheMethods = { + 0, + 0, + pcachetraceInit, + pcachetraceShutdown, + pcachetraceCreate, + pcachetraceCachesize, + pcachetracePagecount, + pcachetraceFetch, + pcachetraceUnpin, + pcachetraceRekey, + pcachetraceTruncate, + pcachetraceDestroy, + pcachetraceShrink +}; + +/* Begin tracing memory allocations to out. */ +int sqlite3PcacheTraceActivate(FILE *out){ + int rc = SQLITE_OK; + if( pcacheBase.xFetch==0 ){ + rc = sqlite3_config(SQLITE_CONFIG_GETPCACHE2, &pcacheBase); + if( rc==SQLITE_OK ){ + rc = sqlite3_config(SQLITE_CONFIG_PCACHE2, &ersaztPcacheMethods); + } + } + pcachetraceOut = out; + return rc; +} + +/* Deactivate memory tracing */ +int sqlite3PcacheTraceDeactivate(void){ + int rc = SQLITE_OK; + if( pcacheBase.xFetch!=0 ){ + rc = sqlite3_config(SQLITE_CONFIG_PCACHE2, &pcacheBase); + if( rc==SQLITE_OK ){ + memset(&pcacheBase, 0, sizeof(pcacheBase)); + } + } + pcachetraceOut = 0; + return rc; +} + +/************************* End ../ext/misc/pcachetrace.c ********************/ /************************* Begin ../ext/misc/shathree.c ******************/ /* ** 2017-03-08 @@ -2683,41 +2906,24 @@ static void decimal_free(Decimal *p){ } /* -** Allocate a new Decimal object. Initialize it to the number given -** by the input string. +** Allocate a new Decimal object initialized to the text in zIn[]. +** Return NULL if any kind of error occurs. */ -static Decimal *decimal_new( - sqlite3_context *pCtx, - sqlite3_value *pIn, - int nAlt, - const unsigned char *zAlt -){ - Decimal *p; - int n, i; - const unsigned char *zIn; +static Decimal *decimalNewFromText(const char *zIn, int n){ + Decimal *p = 0; + int i; int iExp = 0; + p = sqlite3_malloc( sizeof(*p) ); - if( p==0 ) goto new_no_mem; + if( p==0 ) goto new_from_text_failed; p->sign = 0; p->oom = 0; p->isInit = 1; p->isNull = 0; p->nDigit = 0; p->nFrac = 0; - if( zAlt ){ - n = nAlt, - zIn = zAlt; - }else{ - if( sqlite3_value_type(pIn)==SQLITE_NULL ){ - p->a = 0; - p->isNull = 1; - return p; - } - n = sqlite3_value_bytes(pIn); - zIn = sqlite3_value_text(pIn); - } p->a = sqlite3_malloc64( n+1 ); - if( p->a==0 ) goto new_no_mem; + if( p->a==0 ) goto new_from_text_failed; for(i=0; isspace(zIn[i]); i++){} if( zIn[i]=='-' ){ p->sign = 1; @@ -2768,7 +2974,7 @@ static Decimal *decimal_new( } if( iExp>0 ){ p->a = sqlite3_realloc64(p->a, p->nDigit + iExp + 1 ); - if( p->a==0 ) goto new_no_mem; + if( p->a==0 ) goto new_from_text_failed; memset(p->a+p->nDigit, 0, iExp); p->nDigit += iExp; } @@ -2787,7 +2993,7 @@ static Decimal *decimal_new( } if( iExp>0 ){ p->a = sqlite3_realloc64(p->a, p->nDigit + iExp + 1 ); - if( p->a==0 ) goto new_no_mem; + if( p->a==0 ) goto new_from_text_failed; memmove(p->a+iExp, p->a, p->nDigit); memset(p->a, 0, iExp); p->nDigit += iExp; @@ -2796,7 +3002,76 @@ static Decimal *decimal_new( } return p; -new_no_mem: +new_from_text_failed: + if( p ){ + if( p->a ) sqlite3_free(p->a); + sqlite3_free(p); + } + return 0; +} + +/* Forward reference */ +static Decimal *decimalFromDouble(double); + +/* +** Allocate a new Decimal object from an sqlite3_value. Return a pointer +** to the new object, or NULL if there is an error. If the pCtx argument +** is not NULL, then errors are reported on it as well. +** +** If the pIn argument is SQLITE_TEXT or SQLITE_INTEGER, it is converted +** directly into a Decimal. For SQLITE_FLOAT or for SQLITE_BLOB of length +** 8 bytes, the resulting double value is expanded into its decimal equivalent. +** If pIn is NULL or if it is a BLOB that is not exactly 8 bytes in length, +** then NULL is returned. +*/ +static Decimal *decimal_new( + sqlite3_context *pCtx, /* Report error here, if not null */ + sqlite3_value *pIn, /* Construct the decimal object from this */ + int bTextOnly /* Always interpret pIn as text if true */ +){ + Decimal *p = 0; + int eType = sqlite3_value_type(pIn); + if( bTextOnly && (eType==SQLITE_FLOAT || eType==SQLITE_BLOB) ){ + eType = SQLITE_TEXT; + } + switch( eType ){ + case SQLITE_TEXT: + case SQLITE_INTEGER: { + const char *zIn = (const char*)sqlite3_value_text(pIn); + int n = sqlite3_value_bytes(pIn); + p = decimalNewFromText(zIn, n); + if( p==0 ) goto new_failed; + break; + } + + case SQLITE_FLOAT: { + p = decimalFromDouble(sqlite3_value_double(pIn)); + break; + } + + case SQLITE_BLOB: { + const unsigned char *x; + unsigned int i; + sqlite3_uint64 v = 0; + double r; + + if( sqlite3_value_bytes(pIn)!=sizeof(r) ) break; + x = sqlite3_value_blob(pIn); + for(i=0; ioom ){ + sqlite3_result_error_nomem(pCtx); + return; + } + if( p->isNull ){ + sqlite3_result_null(pCtx); + return; + } + for(nDigit=p->nDigit; nDigit>0 && p->a[nDigit-1]==0; nDigit--){} + for(nZero=0; nZeroa[nZero]==0; nZero++){} + nFrac = p->nFrac + (nDigit - p->nDigit); + nDigit -= nZero; + z = sqlite3_malloc( nDigit+20 ); + if( z==0 ){ + sqlite3_result_error_nomem(pCtx); + return; + } + if( nDigit==0 ){ + zero = 0; + a = &zero; + nDigit = 1; + nFrac = 0; + }else{ + a = &p->a[nZero]; + } + if( p->sign && nDigit>0 ){ + z[0] = '-'; + }else{ + z[0] = '+'; + } + z[1] = a[0]+'0'; + z[2] = '.'; + if( nDigit==1 ){ + z[3] = '0'; + i = 4; + }else{ + for(i=1; iisNull ) goto cmp_done; - pB = decimal_new(context, argv[1], 0, 0); + pB = decimal_new(context, argv[1], 1); if( pB==0 || pB->isNull ) goto cmp_done; rc = decimal_cmp(pA, pB); if( rc<0 ) rc = -1; @@ -2963,7 +3283,7 @@ static void decimal_expand(Decimal *p, int nDigit, int nFrac){ } /* -** Add the value pB into pA. +** Add the value pB into pA. A := A + B. ** ** Both pA and pB might become denormalized by this routine. */ @@ -3032,6 +3352,172 @@ static void decimal_add(Decimal *pA, Decimal *pB){ } } +/* +** Multiply A by B. A := A * B +** +** All significant digits after the decimal point are retained. +** Trailing zeros after the decimal point are omitted as long as +** the number of digits after the decimal point is no less than +** either the number of digits in either input. +*/ +static void decimalMul(Decimal *pA, Decimal *pB){ + signed char *acc = 0; + int i, j, k; + int minFrac; + + if( pA==0 || pA->oom || pA->isNull + || pB==0 || pB->oom || pB->isNull + ){ + goto mul_end; + } + acc = sqlite3_malloc64( pA->nDigit + pB->nDigit + 2 ); + if( acc==0 ){ + pA->oom = 1; + goto mul_end; + } + memset(acc, 0, pA->nDigit + pB->nDigit + 2); + minFrac = pA->nFrac; + if( pB->nFracnFrac; + for(i=pA->nDigit-1; i>=0; i--){ + signed char f = pA->a[i]; + int carry = 0, x; + for(j=pB->nDigit-1, k=i+j+3; j>=0; j--, k--){ + x = acc[k] + f*pB->a[j] + carry; + acc[k] = x%10; + carry = x/10; + } + x = acc[k] + carry; + acc[k] = x%10; + acc[k-1] += x/10; + } + sqlite3_free(pA->a); + pA->a = acc; + acc = 0; + pA->nDigit += pB->nDigit + 2; + pA->nFrac += pB->nFrac; + pA->sign ^= pB->sign; + while( pA->nFrac>minFrac && pA->a[pA->nDigit-1]==0 ){ + pA->nFrac--; + pA->nDigit--; + } + +mul_end: + sqlite3_free(acc); +} + +/* +** Create a new Decimal object that contains an integer power of 2. +*/ +static Decimal *decimalPow2(int N){ + Decimal *pA = 0; /* The result to be returned */ + Decimal *pX = 0; /* Multiplier */ + if( N<-20000 || N>20000 ) goto pow2_fault; + pA = decimalNewFromText("1.0", 3); + if( pA==0 || pA->oom ) goto pow2_fault; + if( N==0 ) return pA; + if( N>0 ){ + pX = decimalNewFromText("2.0", 3); + }else{ + N = -N; + pX = decimalNewFromText("0.5", 3); + } + if( pX==0 || pX->oom ) goto pow2_fault; + while( 1 /* Exit by break */ ){ + if( N & 1 ){ + decimalMul(pA, pX); + if( pA->oom ) goto pow2_fault; + } + N >>= 1; + if( N==0 ) break; + decimalMul(pX, pX); + } + decimal_free(pX); + return pA; + +pow2_fault: + decimal_free(pA); + decimal_free(pX); + return 0; +} + +/* +** Use an IEEE754 binary64 ("double") to generate a new Decimal object. +*/ +static Decimal *decimalFromDouble(double r){ + sqlite3_int64 m, a; + int e; + int isNeg; + Decimal *pA; + Decimal *pX; + char zNum[100]; + if( r<0.0 ){ + isNeg = 1; + r = -r; + }else{ + isNeg = 0; + } + memcpy(&a,&r,sizeof(a)); + if( a==0 ){ + e = 0; + m = 0; + }else{ + e = a>>52; + m = a & ((((sqlite3_int64)1)<<52)-1); + if( e==0 ){ + m <<= 1; + }else{ + m |= ((sqlite3_int64)1)<<52; + } + while( e<1075 && m>0 && (m&1)==0 ){ + m >>= 1; + e++; + } + if( isNeg ) m = -m; + e = e - 1075; + if( e>971 ){ + return 0; /* A NaN or an Infinity */ + } + } + + /* At this point m is the integer significand and e is the exponent */ + sqlite3_snprintf(sizeof(zNum), zNum, "%lld", m); + pA = decimalNewFromText(zNum, (int)strlen(zNum)); + pX = decimalPow2(e); + decimalMul(pA, pX); + decimal_free(pX); + return pA; +} + +/* +** SQL Function: decimal(X) +** OR: decimal_exp(X) +** +** Convert input X into decimal and then back into text. +** +** If X is originally a float, then a full decimal expansion of that floating +** point value is done. Or if X is an 8-byte blob, it is interpreted +** as a float and similarly expanded. +** +** The decimal_exp(X) function returns the result in exponential notation. +** decimal(X) returns a complete decimal, without the e+NNN at the end. +*/ +static void decimalFunc( + sqlite3_context *context, + int argc, + sqlite3_value **argv +){ + Decimal *p = decimal_new(context, argv[0], 0); + UNUSED_PARAMETER(argc); + if( p ){ + if( sqlite3_user_data(context)!=0 ){ + decimal_result_sci(context, p); + }else{ + decimal_result(context, p); + } + decimal_free(p); + } +} + /* ** Compare text in decimal order. */ @@ -3042,8 +3528,8 @@ static int decimalCollFunc( ){ const unsigned char *zA = (const unsigned char*)pKey1; const unsigned char *zB = (const unsigned char*)pKey2; - Decimal *pA = decimal_new(0, 0, nKey1, zA); - Decimal *pB = decimal_new(0, 0, nKey2, zB); + Decimal *pA = decimalNewFromText((const char*)zA, nKey1); + Decimal *pB = decimalNewFromText((const char*)zB, nKey2); int rc; UNUSED_PARAMETER(notUsed); if( pA==0 || pB==0 ){ @@ -3068,8 +3554,8 @@ static void decimalAddFunc( int argc, sqlite3_value **argv ){ - Decimal *pA = decimal_new(context, argv[0], 0, 0); - Decimal *pB = decimal_new(context, argv[1], 0, 0); + Decimal *pA = decimal_new(context, argv[0], 1); + Decimal *pB = decimal_new(context, argv[1], 1); UNUSED_PARAMETER(argc); decimal_add(pA, pB); decimal_result(context, pA); @@ -3081,8 +3567,8 @@ static void decimalSubFunc( int argc, sqlite3_value **argv ){ - Decimal *pA = decimal_new(context, argv[0], 0, 0); - Decimal *pB = decimal_new(context, argv[1], 0, 0); + Decimal *pA = decimal_new(context, argv[0], 1); + Decimal *pB = decimal_new(context, argv[1], 1); UNUSED_PARAMETER(argc); if( pB ){ pB->sign = !pB->sign; @@ -3120,7 +3606,7 @@ static void decimalSumStep( p->nFrac = 0; } if( sqlite3_value_type(argv[0])==SQLITE_NULL ) return; - pArg = decimal_new(context, argv[0], 0, 0); + pArg = decimal_new(context, argv[0], 1); decimal_add(p, pArg); decimal_free(pArg); } @@ -3135,7 +3621,7 @@ static void decimalSumInverse( p = sqlite3_aggregate_context(context, sizeof(*p)); if( p==0 ) return; if( sqlite3_value_type(argv[0])==SQLITE_NULL ) return; - pArg = decimal_new(context, argv[0], 0, 0); + pArg = decimal_new(context, argv[0], 1); if( pArg ) pArg->sign = !pArg->sign; decimal_add(p, pArg); decimal_free(pArg); @@ -3156,66 +3642,49 @@ static void decimalSumFinalize(sqlite3_context *context){ ** SQL Function: decimal_mul(X, Y) ** ** Return the product of X and Y. -** -** All significant digits after the decimal point are retained. -** Trailing zeros after the decimal point are omitted as long as -** the number of digits after the decimal point is no less than -** either the number of digits in either input. */ static void decimalMulFunc( sqlite3_context *context, int argc, sqlite3_value **argv ){ - Decimal *pA = decimal_new(context, argv[0], 0, 0); - Decimal *pB = decimal_new(context, argv[1], 0, 0); - signed char *acc = 0; - int i, j, k; - int minFrac; + Decimal *pA = decimal_new(context, argv[0], 1); + Decimal *pB = decimal_new(context, argv[1], 1); UNUSED_PARAMETER(argc); if( pA==0 || pA->oom || pA->isNull || pB==0 || pB->oom || pB->isNull ){ goto mul_end; } - acc = sqlite3_malloc64( pA->nDigit + pB->nDigit + 2 ); - if( acc==0 ){ - sqlite3_result_error_nomem(context); + decimalMul(pA, pB); + if( pA->oom ){ goto mul_end; } - memset(acc, 0, pA->nDigit + pB->nDigit + 2); - minFrac = pA->nFrac; - if( pB->nFracnFrac; - for(i=pA->nDigit-1; i>=0; i--){ - signed char f = pA->a[i]; - int carry = 0, x; *** 15446 LINES SKIPPED *** From nobody Wed Oct 4 01:02:04 2023 X-Original-To: dev-commits-src-branches@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 4S0bxn2vXnz4wJxt; Wed, 4 Oct 2023 01:02: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0bxn1BY8z4YFY; Wed, 4 Oct 2023 01:02:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381325; 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=AG7nIizqm5+QvXUrebJLcP/b/a3P+WOvVQn+zvEBy9c=; b=qCKrX8D9wAQLo1sJwR3vDRIEmyEB0ek7v2lsP1WO823ovKjNv2UnVTsMTijlvOMIF2SBTb JUwv57GcNaHFn/VBecl57IiDwUixQ4ecZYg+6rKy8XMIHku89K641lAYkwuzvkrGhxai8f fFXbzaUx0eBGRSt0AsQTCmIAit9SxOGWuNBH9i6jIgCcZegYkYOYQggl02uZn8xLes328N qxXHM2DdN4D31MQ5brCxkXC0Yic7d0DPClukv3uogGjGduJQ1OFcgxsCRMIT6X3thQd5gs drI3it1fS/11+Xyws16bi0CuSejgcLdvFfUPOHVKdlNwJruguDKOepAXEqCpQQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696381325; a=rsa-sha256; cv=none; b=Ci9vb4lOZMVONBUST2qZ7Csn8qI0fnjmJuO+29DvDOqLj71bdf4wt/nObZRTHbGwzIN7oC xFOiknxNmMRiDguNhZYVgvYSnjXxTnLTeiRg4aOdev0coiSKd0/7oiK/txT8eY84Wdf7zZ PqMRvqJbz9mDIRGJF70manxbj1SG17f3bXIY+Nh7d9KKymtg/HdvwSUQpYSU5nwubVeH9J 2dgqHdZX5ezwkoPBU70Fk8V4iMgoP1ReBqbjLdwleZ8euFQDE+ig7YSMedjWu1FRgtrLeI Av4613pzvdCJj8f7xgLF6wOZBGW4hQVjH65NEXQCdRdqj5OFYWDLJia6WZQGwA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381325; 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=AG7nIizqm5+QvXUrebJLcP/b/a3P+WOvVQn+zvEBy9c=; b=tLS0WTVuoCyxKVNHgJukmqn2uMe2K0j23ECAfpBSufVng8LLI934rxtyq2yaoBpP7oeQxn OUgrWYdOD7bJIyjuH8xFhzlYEMNsniDMiU2DnHnay5TTCkNnMgnldKv0CGSb6Q4pxlMAq0 gm/Q/OVK/YuD3RxGLPbYrHr54vLOiDy6MwhMSXx/uPfeZ4+el0xCS2mNGpeWqkCN3obKkx x12IyBTbxHjleS5iRGHPGmQOynQyiOkco02QniNd4C0c3HLA+vokaMe3+8OYW78euz/yHP 2thkoURCXwf1T7OEipydk01/PIhsnHhSI5DU+nx+CLeIPXg48+PLBGP/NDmbJg== 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 4S0bxn084Cz2TN; Wed, 4 Oct 2023 01:02:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394125ul050384; Wed, 4 Oct 2023 01:02:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394124Oa050379; Wed, 4 Oct 2023 01:02:04 GMT (envelope-from git) Date: Wed, 4 Oct 2023 01:02:04 GMT Message-Id: <202310040102.394124Oa050379@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Cy Schubert Subject: git: 4f4adb0576df - stable/13 - unbound: Vendor import 1.18.0 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4f4adb0576dfbcd0d956db0146c9de7e1bb71563 Auto-Submitted: auto-generated The branch stable/13 has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=4f4adb0576dfbcd0d956db0146c9de7e1bb71563 commit 4f4adb0576dfbcd0d956db0146c9de7e1bb71563 Author: Cy Schubert AuthorDate: 2023-09-19 04:17:09 +0000 Commit: Cy Schubert CommitDate: 2023-10-04 01:01:51 +0000 unbound: Vendor import 1.18.0 Release notes at https://www.nlnetlabs.nl/news/2023/Aug/30/unbound-1.18.0-released/ Merge commit '401770e05c71ecb5ae61a59d316069b4b78bf622' into main (cherry picked from commit 8f76bb7dad48538c6832c2fb466a433d2a3f8cd5) --- contrib/unbound/Makefile.in | 43 +- contrib/unbound/README.md | 2 +- contrib/unbound/acx_nlnetlabs.m4 | 36 +- contrib/unbound/acx_python.m4 | 61 +- contrib/unbound/cachedb/cachedb.c | 57 +- contrib/unbound/cachedb/redis.c | 28 +- contrib/unbound/compat/getentropy_solaris.c | 2 +- contrib/unbound/config.guess | 51 +- contrib/unbound/config.h.in | 25 +- contrib/unbound/config.h.in~ | 1456 ++++++++++++++++++++ contrib/unbound/config.sub | 72 +- contrib/unbound/configure | 170 ++- contrib/unbound/configure.ac | 99 +- contrib/unbound/contrib/Dockerfile.tests | 4 +- contrib/unbound/contrib/README | 3 + contrib/unbound/contrib/aaaa-filter-iterator.patch | 4 +- contrib/unbound/contrib/unbound.init_yocto | 139 ++ contrib/unbound/daemon/acl_list.c | 2 + contrib/unbound/daemon/acl_list.h | 8 +- contrib/unbound/daemon/cachedump.c | 28 +- contrib/unbound/daemon/remote.c | 236 ++-- contrib/unbound/daemon/remote.h | 2 +- contrib/unbound/daemon/stats.c | 53 +- contrib/unbound/daemon/stats.h | 7 + contrib/unbound/daemon/worker.c | 471 ++++--- contrib/unbound/dns64/dns64.c | 4 +- contrib/unbound/dnstap/dnstap.c | 7 +- contrib/unbound/dnstap/dnstap.h | 4 +- contrib/unbound/dnstap/unbound-dnstap-socket.c | 39 +- contrib/unbound/doc/Changelog | 323 +++++ contrib/unbound/doc/README | 2 +- contrib/unbound/doc/README.DNS64 | 20 + contrib/unbound/doc/example.conf.in | 32 +- contrib/unbound/doc/libunbound.3.in | 4 +- contrib/unbound/doc/unbound-anchor.8.in | 2 +- contrib/unbound/doc/unbound-checkconf.8.in | 2 +- contrib/unbound/doc/unbound-control.8.in | 58 +- contrib/unbound/doc/unbound-host.1.in | 2 +- contrib/unbound/doc/unbound.8.in | 4 +- contrib/unbound/doc/unbound.conf.5.in | 147 +- contrib/unbound/edns-subnet/subnetmod.c | 27 +- contrib/unbound/iterator/iter_delegpt.c | 39 + contrib/unbound/iterator/iter_delegpt.h | 25 + contrib/unbound/iterator/iter_resptype.c | 7 + contrib/unbound/iterator/iter_scrub.c | 43 +- contrib/unbound/iterator/iter_utils.c | 43 +- contrib/unbound/iterator/iter_utils.h | 7 +- contrib/unbound/iterator/iterator.c | 259 ++-- contrib/unbound/iterator/iterator.h | 23 +- contrib/unbound/libunbound/libworker.c | 16 +- contrib/unbound/libunbound/unbound-event.h | 6 +- contrib/unbound/libunbound/unbound.h | 116 +- contrib/unbound/services/authzone.c | 10 +- contrib/unbound/services/cache/dns.c | 50 +- contrib/unbound/services/cache/infra.c | 75 +- contrib/unbound/services/cache/infra.h | 5 +- contrib/unbound/services/listen_dnsport.c | 153 +- contrib/unbound/services/localzone.c | 20 +- contrib/unbound/services/localzone.h | 2 + contrib/unbound/services/mesh.c | 385 +++--- contrib/unbound/services/mesh.h | 14 +- contrib/unbound/services/modstack.c | 10 +- contrib/unbound/services/outside_network.c | 28 + contrib/unbound/services/rpz.c | 230 +++- contrib/unbound/services/rpz.h | 16 +- contrib/unbound/sldns/rrdef.c | 12 +- contrib/unbound/sldns/rrdef.h | 7 +- contrib/unbound/sldns/str2wire.c | 94 +- contrib/unbound/sldns/str2wire.h | 4 +- contrib/unbound/sldns/wire2str.c | 19 +- contrib/unbound/smallapp/unbound-anchor.c | 3 +- contrib/unbound/smallapp/unbound-checkconf.c | 2 +- contrib/unbound/smallapp/unbound-control.c | 54 +- contrib/unbound/smallapp/unbound-host.c | 5 +- contrib/unbound/testdata/00-lint.tdir/00-lint.pre | 14 + contrib/unbound/testdata/cachedb_cached_ede.crpl | 91 ++ .../unbound/testdata/edns_downstream_cookies.rpl | 235 ++++ .../testdata/ip_ratelimit.tdir/ip_ratelimit.conf | 28 + .../testdata/ip_ratelimit.tdir/ip_ratelimit.dsc | 16 + .../testdata/ip_ratelimit.tdir/ip_ratelimit.post | 13 + .../testdata/ip_ratelimit.tdir/ip_ratelimit.pre | 24 + .../testdata/ip_ratelimit.tdir/ip_ratelimit.test | 165 +++ .../testdata/ip_ratelimit.tdir/unbound_control.key | 39 + .../testdata/ip_ratelimit.tdir/unbound_control.pem | 22 + .../testdata/ip_ratelimit.tdir/unbound_server.key | 39 + .../testdata/ip_ratelimit.tdir/unbound_server.pem | 22 + .../unbound/testdata/iter_cname_minimise_nx.rpl | 246 ++++ contrib/unbound/testdata/iter_failreply.rpl | 132 ++ contrib/unbound/testdata/iter_ignore_empty.rpl | 198 +++ contrib/unbound/testdata/iter_nat64.rpl | 117 ++ contrib/unbound/testdata/iter_nat64_prefix.rpl | 119 ++ contrib/unbound/testdata/iter_nat64_prefix48.rpl | 118 ++ .../unbound/testdata/serve_expired_0ttl_nodata.rpl | 154 +++ .../testdata/serve_expired_0ttl_nxdomain.rpl | 154 +++ .../testdata/serve_expired_0ttl_servfail.rpl | 129 ++ .../serve_expired_cached_servfail_refresh.rpl | 145 ++ .../stat_values.tdir/stat_values_cachedb.conf | 36 + .../stat_values_downstream_cookies.conf | 32 + contrib/unbound/testdata/subnet_cached_ede.crpl | 114 ++ .../unbound/testdata/subnet_global_prefetch.crpl | 236 ++++ .../subnet_global_prefetch_always_forward.crpl | 167 +++ .../testdata/subnet_global_prefetch_expired.crpl | 241 ++++ contrib/unbound/testdata/val_any_negcache.rpl | 240 ++++ contrib/unbound/util/config_file.c | 153 +- contrib/unbound/util/config_file.h | 65 +- contrib/unbound/util/configlexer.lex | 15 +- contrib/unbound/util/configparser.y | 148 +- contrib/unbound/util/data/msgencode.c | 148 +- contrib/unbound/util/data/msgencode.h | 42 +- contrib/unbound/util/data/msgparse.c | 98 +- contrib/unbound/util/data/msgparse.h | 18 +- contrib/unbound/util/data/msgreply.c | 95 +- contrib/unbound/util/data/msgreply.h | 30 +- contrib/unbound/util/edns.c | 59 + contrib/unbound/util/edns.h | 59 + contrib/unbound/util/fptr_wlist.c | 8 + contrib/unbound/util/iana_ports.inc | 4 + contrib/unbound/util/module.c | 16 +- contrib/unbound/util/module.h | 14 +- contrib/unbound/util/net_help.c | 70 +- contrib/unbound/util/net_help.h | 23 + contrib/unbound/util/netevent.c | 229 +-- contrib/unbound/util/netevent.h | 70 +- contrib/unbound/util/regional.c | 2 +- contrib/unbound/util/rfc_1982.c | 74 + contrib/unbound/util/rfc_1982.h | 63 + contrib/unbound/util/siphash.c | 187 +++ contrib/unbound/util/siphash.h | 43 + contrib/unbound/util/storage/lruhash.c | 25 +- contrib/unbound/util/storage/lruhash.h | 5 +- contrib/unbound/util/storage/slabhash.c | 18 + contrib/unbound/util/storage/slabhash.h | 9 + contrib/unbound/util/timehist.c | 44 +- contrib/unbound/util/timeval_func.c | 113 ++ contrib/unbound/util/timeval_func.h | 53 + contrib/unbound/validator/autotrust.c | 2 + contrib/unbound/validator/val_kcache.c | 10 +- contrib/unbound/validator/val_kcache.h | 4 +- contrib/unbound/validator/val_kentry.c | 48 +- contrib/unbound/validator/val_kentry.h | 37 +- contrib/unbound/validator/val_neg.c | 7 +- contrib/unbound/validator/val_nsec.c | 19 +- contrib/unbound/validator/val_nsec.h | 5 +- contrib/unbound/validator/val_sigcrypt.c | 43 +- contrib/unbound/validator/val_utils.c | 19 +- contrib/unbound/validator/validator.c | 137 +- lib/libunbound/Makefile | 6 +- usr.sbin/unbound/config.h | 6 +- 148 files changed, 9439 insertions(+), 1708 deletions(-) diff --git a/contrib/unbound/Makefile.in b/contrib/unbound/Makefile.in index bc021aa1eb00..0a2e7f9b6f08 100644 --- a/contrib/unbound/Makefile.in +++ b/contrib/unbound/Makefile.in @@ -122,15 +122,15 @@ iterator/iter_delegpt.c iterator/iter_donotq.c iterator/iter_fwd.c \ iterator/iter_hints.c iterator/iter_priv.c iterator/iter_resptype.c \ iterator/iter_scrub.c iterator/iter_utils.c services/listen_dnsport.c \ services/localzone.c services/mesh.c services/modstack.c services/view.c \ -services/rpz.c \ +services/rpz.c util/rfc_1982.c \ services/outbound_list.c services/outside_network.c util/alloc.c \ util/config_file.c util/configlexer.c util/configparser.c \ util/shm_side/shm_main.c services/authzone.c \ util/fptr_wlist.c util/locks.c util/log.c util/mini_event.c util/module.c \ util/netevent.c util/net_help.c util/random.c util/rbtree.c util/regional.c \ -util/rtt.c util/edns.c util/storage/dnstree.c util/storage/lookup3.c \ +util/rtt.c util/siphash.c util/edns.c util/storage/dnstree.c util/storage/lookup3.c \ util/storage/lruhash.c util/storage/slabhash.c util/tcp_conn_limit.c \ -util/timehist.c util/tube.c util/proxy_protocol.c \ +util/timehist.c util/tube.c util/proxy_protocol.c util/timeval_func.c \ util/ub_event.c util/ub_event_pluggable.c util/winsock_event.c \ validator/autotrust.c validator/val_anchor.c validator/validator.c \ validator/val_kcache.c validator/val_kentry.c validator/val_neg.c \ @@ -145,14 +145,14 @@ as112.lo msgparse.lo msgreply.lo packed_rrset.lo iterator.lo iter_delegpt.lo \ iter_donotq.lo iter_fwd.lo iter_hints.lo iter_priv.lo iter_resptype.lo \ iter_scrub.lo iter_utils.lo localzone.lo mesh.lo modstack.lo view.lo \ outbound_list.lo alloc.lo config_file.lo configlexer.lo configparser.lo \ -fptr_wlist.lo edns.lo locks.lo log.lo mini_event.lo module.lo net_help.lo \ +fptr_wlist.lo siphash.lo edns.lo locks.lo log.lo mini_event.lo module.lo net_help.lo \ random.lo rbtree.lo regional.lo rtt.lo dnstree.lo lookup3.lo lruhash.lo \ slabhash.lo tcp_conn_limit.lo timehist.lo tube.lo winsock_event.lo \ -autotrust.lo val_anchor.lo rpz.lo proxy_protocol.lo \ +autotrust.lo val_anchor.lo rpz.lo rfc_1982.lo proxy_protocol.lo \ validator.lo val_kcache.lo val_kentry.lo val_neg.lo val_nsec3.lo val_nsec.lo \ val_secalgo.lo val_sigcrypt.lo val_utils.lo dns64.lo $(CACHEDB_OBJ) authzone.lo \ $(SUBNET_OBJ) $(PYTHONMOD_OBJ) $(CHECKLOCK_OBJ) $(DNSTAP_OBJ) $(DNSCRYPT_OBJ) \ -$(IPSECMOD_OBJ) $(IPSET_OBJ) $(DYNLIBMOD_OBJ) respip.lo +$(IPSECMOD_OBJ) $(IPSET_OBJ) $(DYNLIBMOD_OBJ) respip.lo timeval_func.lo COMMON_OBJ_WITHOUT_UB_EVENT=$(COMMON_OBJ_WITHOUT_NETCALL) netevent.lo listen_dnsport.lo \ outside_network.lo COMMON_OBJ=$(COMMON_OBJ_WITHOUT_UB_EVENT) ub_event.lo @@ -198,7 +198,7 @@ CHECKCONF_OBJ=unbound-checkconf.lo worker_cb.lo CHECKCONF_OBJ_LINK=$(CHECKCONF_OBJ) $(COMMON_OBJ_ALL_SYMBOLS) $(SLDNS_OBJ) \ $(COMPAT_OBJ) @WIN_CHECKCONF_OBJ_LINK@ CONTROL_SRC=smallapp/unbound-control.c -CONTROL_OBJ=unbound-control.lo +CONTROL_OBJ=unbound-control.lo CONTROL_OBJ_LINK=$(CONTROL_OBJ) worker_cb.lo $(COMMON_OBJ_ALL_SYMBOLS) \ $(SLDNS_OBJ) $(COMPAT_OBJ) @WIN_CONTROL_OBJ_LINK@ HOST_SRC=smallapp/unbound-host.c @@ -455,6 +455,7 @@ unbound-dnstap-socket.lo unbound-dnstap-socket.o: $(srcdir)/dnstap/unbound-dnsta dynlibmod.lo dynlibdmod.o: $(srcdir)/dynlibmod/dynlibmod.c config.h $(srcdir)/dynlibmod/dynlibmod.h cachedb.lo cachedb.o: $(srcdir)/cachedb/cachedb.c config.h $(srcdir)/cachedb/cachedb.h redis.lo redis.o: $(srcdir)/cachedb/redis.c config.h $(srcdir)/cachedb/redis.h +timeval_func.lo timeval_func.o: $(srcdir)/util/timeval_func.c $(srcdir)/util/timeval_func.h # dnscrypt dnscrypt.lo dnscrypt.o: $(srcdir)/dnscrypt/dnscrypt.c config.h \ @@ -498,6 +499,7 @@ util/configlexer.c: $(srcdir)/util/configlexer.lex util/configparser.h echo "#include \"util/configyyrename.h\"" >> $@ ;\ $(LEX) -t $(srcdir)/util/configlexer.lex >> $@ ;\ fi + @if test ! -f $@; then echo "No $@ : need flex and bison to compile from source repository"; exit 1; fi util/configparser.c util/configparser.h: $(srcdir)/util/configparser.y @-if test ! -d util; then $(INSTALL) -d util; fi @@ -516,7 +518,7 @@ distclean: clean rm -f doc/example.conf doc/libunbound.3 doc/unbound-anchor.8 doc/unbound-checkconf.8 doc/unbound-control.8 doc/unbound.8 doc/unbound.conf.5 doc/unbound-host.1 rm -f smallapp/unbound-control-setup.sh dnstap/dnstap_config.h dnscrypt/dnscrypt_config.h contrib/libunbound.pc contrib/unbound.socket contrib/unbound.service rm -f $(TEST_BIN) - rm -f Makefile + rm -f Makefile maintainer-clean: distclean rm -f util/configlexer.c util/configparser.c util/configparser.h @@ -649,7 +651,7 @@ uninstall: $(PYTHONMOD_UNINSTALL) $(PYUNBOUND_UNINSTALL) $(UNBOUND_EVENT_UNINSTA iana_update: curl -o port-numbers.tmp https://www.iana.org/assignments/service-names-port-numbers/service-names-port-numbers.xml --compressed - if file port-numbers.tmp | grep 'gzip' >/dev/null; then zcat port-numbers.tmp; else cat port-numbers.tmp; fi | awk '// {p=0;} /udp/ {p=1;} /[^u]/ {p=0;} /Decomissioned|Decommissioned|Removed|De-registered|unassigned|Unassigned|Reserved/ {u=1;} // { if(u==1) {u=0;} else { if(p==1) { match($$0,/[0-9]+/); print substr($$0, RSTART, RLENGTH) ","}}}' | sort -nu > util/iana_ports.inc + if file port-numbers.tmp | grep 'gzip' >/dev/null; then zcat port-numbers.tmp; else cat port-numbers.tmp; fi | awk '// {p=0;} /udp/ {p=1;} /[^u]/ {p=0;} /Decomissioned|Decommissioned|Removed|De-registered|unassigned|Unassigned|Reserved/ {u=1;} // { if(u==1) {u=0;} else { if(p==1) { match($$0,/[0-9]+/); print substr($$0, RSTART, RLENGTH) ","}}}' | sort -nu > util/iana_ports.inc rm -f port-numbers.tmp # dependency generation @@ -877,7 +879,7 @@ rpz.lo rpz.o: $(srcdir)/services/rpz.c config.h $(srcdir)/services/rpz.h $(srcdi outbound_list.lo outbound_list.o: $(srcdir)/services/outbound_list.c config.h \ $(srcdir)/services/outbound_list.h $(srcdir)/services/outside_network.h $(srcdir)/util/rbtree.h \ $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ - + outside_network.lo outside_network.o: $(srcdir)/services/outside_network.c config.h \ $(srcdir)/services/outside_network.h $(srcdir)/util/rbtree.h $(srcdir)/util/netevent.h \ $(srcdir)/dnscrypt/dnscrypt.h \ @@ -915,7 +917,8 @@ config_file.lo config_file.o: $(srcdir)/util/config_file.c config.h $(srcdir)/ut configlexer.lo configlexer.o: util/configlexer.c config.h $(srcdir)/util/configyyrename.h \ $(srcdir)/util/config_file.h util/configparser.h configparser.lo configparser.o: util/configparser.c config.h $(srcdir)/util/configyyrename.h \ - $(srcdir)/util/config_file.h $(srcdir)/util/net_help.h $(srcdir)/util/log.h + $(srcdir)/util/config_file.h $(srcdir)/util/net_help.h $(srcdir)/util/log.h $(srcdir)/sldns/str2wire.h \ + $(srcdir)/sldns/rrdef.h shm_main.lo shm_main.o: $(srcdir)/util/shm_side/shm_main.c config.h $(srcdir)/util/shm_side/shm_main.h \ $(srcdir)/libunbound/unbound.h $(srcdir)/daemon/daemon.h $(srcdir)/util/locks.h $(srcdir)/util/log.h \ $(srcdir)/util/alloc.h $(srcdir)/services/modstack.h \ @@ -928,7 +931,7 @@ shm_main.lo shm_main.o: $(srcdir)/util/shm_side/shm_main.c config.h $(srcdir)/ut $(srcdir)/services/view.h $(srcdir)/util/config_file.h $(srcdir)/services/authzone.h $(srcdir)/respip/respip.h \ $(srcdir)/services/cache/rrset.h $(srcdir)/util/storage/slabhash.h $(srcdir)/services/cache/infra.h \ $(srcdir)/util/rtt.h $(srcdir)/validator/validator.h $(srcdir)/validator/val_utils.h $(srcdir)/util/fptr_wlist.h \ - $(srcdir)/util/tube.h + $(srcdir)/util/tube.h $(srcdir)/util/timeval_func.h authzone.lo authzone.o: $(srcdir)/services/authzone.c config.h $(srcdir)/services/authzone.h \ $(srcdir)/util/rbtree.h $(srcdir)/util/locks.h $(srcdir)/util/log.h $(srcdir)/services/mesh.h $(srcdir)/util/netevent.h \ $(srcdir)/dnscrypt/dnscrypt.h $(srcdir)/util/data/msgparse.h \ @@ -983,7 +986,7 @@ netevent.lo netevent.o: $(srcdir)/util/netevent.c config.h $(srcdir)/util/neteve $(srcdir)/services/modstack.h $(srcdir)/services/rpz.h $(srcdir)/services/localzone.h $(srcdir)/services/view.h \ $(srcdir)/sldns/sbuffer.h $(srcdir)/util/config_file.h $(srcdir)/services/authzone.h $(srcdir)/daemon/stats.h \ $(srcdir)/util/timehist.h $(srcdir)/libunbound/unbound.h $(srcdir)/respip/respip.h $(srcdir)/sldns/str2wire.h \ - $(srcdir)/dnstap/dnstap.h $(srcdir)/services/listen_dnsport.h + $(srcdir)/dnstap/dnstap.h $(srcdir)/services/listen_dnsport.h $(srcdir)/util/timeval_func.h proxy_protocol.lo proxy_protocol.o: $(srcdir)/util/proxy_protocol.c config.h \ $(srcdir)/util/proxy_protocol.h $(srcdir)/sldns/sbuffer.h net_help.lo net_help.o: $(srcdir)/util/net_help.c config.h $(srcdir)/util/net_help.h $(srcdir)/util/log.h \ @@ -1006,6 +1009,8 @@ rtt.lo rtt.o: $(srcdir)/util/rtt.c config.h $(srcdir)/util/rtt.h $(srcdir)/itera $(srcdir)/services/outbound_list.h $(srcdir)/util/data/msgreply.h $(srcdir)/util/storage/lruhash.h \ $(srcdir)/util/locks.h $(srcdir)/util/log.h $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/module.h \ $(srcdir)/util/data/msgparse.h $(srcdir)/sldns/pkthdr.h $(srcdir)/sldns/rrdef.h +siphash.lo siphash.o: $(srcdir)/util/siphash.c +rfc_1982.lo rfc_1982.o: $(srcdir)/util/rfc_1982.c edns.lo edns.o: $(srcdir)/util/edns.c config.h $(srcdir)/util/edns.h $(srcdir)/util/storage/dnstree.h \ $(srcdir)/util/rbtree.h $(srcdir)/util/config_file.h $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ $(srcdir)/util/net_help.h $(srcdir)/util/log.h $(srcdir)/util/regional.h \ @@ -1186,7 +1191,7 @@ unitmain.lo unitmain.o: $(srcdir)/testcode/unitmain.c config.h $(srcdir)/sldns/r $(srcdir)/util/storage/dnstree.h $(srcdir)/util/rbtree.h $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ $(srcdir)/util/random.h $(srcdir)/respip/respip.h \ $(srcdir)/services/localzone.h $(srcdir)/services/view.h $(srcdir)/sldns/sbuffer.h \ - $(srcdir)/services/outside_network.h + $(srcdir)/services/outside_network.h unitmsgparse.lo unitmsgparse.o: $(srcdir)/testcode/unitmsgparse.c config.h $(srcdir)/util/log.h \ $(srcdir)/testcode/unitmain.h $(srcdir)/util/data/msgparse.h $(srcdir)/util/storage/lruhash.h \ $(srcdir)/util/locks.h $(srcdir)/sldns/pkthdr.h $(srcdir)/sldns/rrdef.h $(srcdir)/util/data/msgreply.h \ @@ -1321,7 +1326,7 @@ unbound.lo unbound.o: $(srcdir)/daemon/unbound.c config.h $(srcdir)/util/log.h $ worker.lo worker.o: $(srcdir)/daemon/worker.c config.h $(srcdir)/util/log.h $(srcdir)/util/net_help.h \ $(srcdir)/util/random.h $(srcdir)/daemon/worker.h $(srcdir)/libunbound/worker.h $(srcdir)/sldns/sbuffer.h \ $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/storage/lruhash.h $(srcdir)/util/locks.h \ - $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ + $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h $(srcdir)/util/timeval_func.h \ $(srcdir)/util/alloc.h $(srcdir)/util/data/msgreply.h $(srcdir)/util/data/msgparse.h $(srcdir)/sldns/pkthdr.h \ $(srcdir)/sldns/rrdef.h $(srcdir)/daemon/stats.h $(srcdir)/util/timehist.h $(srcdir)/libunbound/unbound.h \ $(srcdir)/util/module.h $(srcdir)/dnstap/dnstap.h $(srcdir)/daemon/daemon.h \ @@ -1343,7 +1348,7 @@ testbound.lo testbound.o: $(srcdir)/testcode/testbound.c config.h $(srcdir)/test $(srcdir)/daemon/remote.h $(srcdir)/libunbound/worker.h $(srcdir)/sldns/sbuffer.h \ $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/storage/lruhash.h $(srcdir)/util/locks.h $(srcdir)/util/log.h \ $(srcdir)/util/config_file.h $(srcdir)/sldns/keyraw.h $(srcdir)/daemon/unbound.c $(srcdir)/daemon/daemon.h \ - $(srcdir)/util/alloc.h $(srcdir)/services/modstack.h \ + $(srcdir)/util/alloc.h $(srcdir)/util/timeval_func.h $(srcdir)/services/modstack.h \ $(srcdir)/util/storage/slabhash.h $(srcdir)/services/listen_dnsport.h $(srcdir)/services/cache/rrset.h \ $(srcdir)/services/cache/infra.h $(srcdir)/util/storage/dnstree.h $(srcdir)/util/rtt.h \ $(srcdir)/util/data/msgreply.h $(srcdir)/util/fptr_wlist.h $(srcdir)/util/module.h \ @@ -1357,7 +1362,7 @@ testpkts.lo testpkts.o: $(srcdir)/testcode/testpkts.c config.h $(srcdir)/testcod worker.lo worker.o: $(srcdir)/daemon/worker.c config.h $(srcdir)/util/log.h $(srcdir)/util/net_help.h \ $(srcdir)/util/random.h $(srcdir)/daemon/worker.h $(srcdir)/libunbound/worker.h $(srcdir)/sldns/sbuffer.h \ $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/storage/lruhash.h $(srcdir)/util/locks.h \ - $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ + $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h $(srcdir)/util/timeval_func.h \ $(srcdir)/util/alloc.h $(srcdir)/util/data/msgreply.h $(srcdir)/util/data/msgparse.h $(srcdir)/sldns/pkthdr.h \ $(srcdir)/sldns/rrdef.h $(srcdir)/daemon/stats.h $(srcdir)/util/timehist.h $(srcdir)/libunbound/unbound.h \ $(srcdir)/util/module.h $(srcdir)/dnstap/dnstap.h $(srcdir)/daemon/daemon.h \ @@ -1409,7 +1414,7 @@ stats.lo stats.o: $(srcdir)/daemon/stats.c config.h $(srcdir)/daemon/stats.h $(s $(srcdir)/validator/val_kcache.h $(srcdir)/validator/val_neg.h replay.lo replay.o: $(srcdir)/testcode/replay.c config.h $(srcdir)/util/log.h $(srcdir)/util/net_help.h \ $(srcdir)/util/config_file.h $(srcdir)/testcode/replay.h $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ - $(srcdir)/testcode/testpkts.h $(srcdir)/util/rbtree.h \ + $(srcdir)/testcode/testpkts.h $(srcdir)/util/rbtree.h $(srcdir)/util/timeval_func.h \ $(srcdir)/testcode/fake_event.h $(srcdir)/sldns/str2wire.h $(srcdir)/sldns/rrdef.h fake_event.lo fake_event.o: $(srcdir)/testcode/fake_event.c config.h $(srcdir)/testcode/fake_event.h \ $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ @@ -1417,7 +1422,7 @@ fake_event.lo fake_event.o: $(srcdir)/testcode/fake_event.c config.h $(srcdir)/t $(srcdir)/util/locks.h $(srcdir)/sldns/pkthdr.h $(srcdir)/sldns/rrdef.h $(srcdir)/util/data/msgreply.h \ $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/data/msgencode.h $(srcdir)/util/data/dname.h \ $(srcdir)/util/edns.h $(srcdir)/util/storage/dnstree.h $(srcdir)/util/rbtree.h $(srcdir)/util/config_file.h \ - $(srcdir)/services/listen_dnsport.h $(srcdir)/services/outside_network.h \ + $(srcdir)/services/listen_dnsport.h $(srcdir)/services/outside_network.h $(srcdir)/util/timeval_func.h \ $(srcdir)/services/cache/infra.h $(srcdir)/util/rtt.h \ $(srcdir)/testcode/replay.h $(srcdir)/testcode/testpkts.h $(srcdir)/util/fptr_wlist.h $(srcdir)/util/module.h \ $(srcdir)/util/tube.h $(srcdir)/services/mesh.h $(srcdir)/services/modstack.h $(srcdir)/services/rpz.h \ diff --git a/contrib/unbound/README.md b/contrib/unbound/README.md index c3d9bc2492ef..c220da030458 100644 --- a/contrib/unbound/README.md +++ b/contrib/unbound/README.md @@ -1,6 +1,6 @@ # Unbound -[![Travis Build Status](https://travis-ci.org/NLnetLabs/unbound.svg?branch=master)](https://travis-ci.org/NLnetLabs/unbound) +[![Github Build Status](https://github.com/NLnetLabs/unbound/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/NLnetLabs/unbound/actions) [![Packaging status](https://repology.org/badge/tiny-repos/unbound.svg)](https://repology.org/project/unbound/versions) [![Fuzzing Status](https://oss-fuzz-build-logs.storage.googleapis.com/badges/unbound.svg)](https://bugs.chromium.org/p/oss-fuzz/issues/list?sort=-opened&can=1&q=proj:unbound) [![Documentation Status](https://readthedocs.org/projects/unbound/badge/?version=latest)](https://unbound.readthedocs.io/en/latest/?badge=latest) diff --git a/contrib/unbound/acx_nlnetlabs.m4 b/contrib/unbound/acx_nlnetlabs.m4 index cf436ec54bb6..f27615bd8bce 100644 --- a/contrib/unbound/acx_nlnetlabs.m4 +++ b/contrib/unbound/acx_nlnetlabs.m4 @@ -2,7 +2,9 @@ # Copyright 2009, Wouter Wijngaards, NLnet Labs. # BSD licensed. # -# Version 44 +# Version 46 +# 2023-05-04 fix to remove unused whitespace. +# 2023-01-26 fix -Wstrict-prototypes. # 2022-09-01 fix checking if nonblocking sockets work on OpenBSD. # 2021-08-17 fix sed script in ssldir split handling. # 2021-08-17 fix for openssl to detect split version, with ssldir_include @@ -187,7 +189,7 @@ dnl cache=`echo $1 | sed 'y%.=/+- %___p__%'` AC_CACHE_VAL(cv_prog_cc_flag_needed_$cache, [ echo '$2' > conftest.c -echo 'void f(){}' >>conftest.c +echo 'void f(void){}' >>conftest.c if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then eval "cv_prog_cc_flag_needed_$cache=no" else @@ -233,7 +235,7 @@ dnl DEPFLAG: set to flag that generates dependencies. AC_DEFUN([ACX_DEPFLAG], [ AC_MSG_CHECKING([$CC dependency flag]) -echo 'void f(){}' >conftest.c +echo 'void f(void){}' >conftest.c if test "`$CC -MM conftest.c 2>&1`" = "conftest.o: conftest.c"; then DEPFLAG="-MM" else @@ -272,7 +274,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED($C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAUL #include #endif -int test() { +int test(void) { int a; char **opts = NULL; struct timeval tv; @@ -309,7 +311,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED($C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAUL #include #endif -int test() { +int test(void) { int a; char **opts = NULL; struct timeval tv; @@ -335,7 +337,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED($C99FLAG, [ #include #include -int test() { +int test(void) { int a = 0; return a; } @@ -345,7 +347,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D_BSD_SOURCE -D_DEFAULT_SOURCE, [ #include -int test() { +int test(void) { int a; a = isascii(32); return a; @@ -356,7 +358,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D_GNU_SOURCE, [ #include -int test() { +int test(void) { struct in6_pktinfo inf; int a = (int)sizeof(inf); return a; @@ -370,7 +372,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D_GNU_SOURCE -D_FRSRESGID, [ #include -int test() { +int test(void) { int a = setresgid(0,0,0); a = setresuid(0,0,0); return a; @@ -385,7 +387,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D_POSIX_C_SOURCE=200112, #endif #include -int test() { +int test(void) { int a = 0; char *t; time_t time = 0; @@ -413,7 +415,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D__EXTENSIONS__, #include #endif -int test() { +int test(void) { int a; char **opts = NULL; struct timeval tv; @@ -475,7 +477,7 @@ fi dnl Setup ATTR_FORMAT config.h parts. dnl make sure you call ACX_CHECK_FORMAT_ATTRIBUTE also. AC_DEFUN([AHX_CONFIG_FORMAT_ATTRIBUTE], -[ +[ #ifdef HAVE_ATTR_FORMAT # define ATTR_FORMAT(archetype, string_index, first_to_check) \ __attribute__ ((format (archetype, string_index, first_to_check))) @@ -834,7 +836,7 @@ dnl try to see if an additional _LARGEFILE_SOURCE 1 is needed to get fseeko ACX_CHECK_COMPILER_FLAG_NEEDED(-D_LARGEFILE_SOURCE=1, [ #include -int test() { +int test(void) { int a = fseeko(stdin, 0, 0); return a; } @@ -859,7 +861,7 @@ char* (*f) () = getaddrinfo; #ifdef __cplusplus } #endif -int main() { +int main(void) { ; return 0; } @@ -923,7 +925,7 @@ cache=`echo $1 | sed 'y%.=/+-%___p_%'` AC_CACHE_VAL(cv_cc_deprecated_$cache, [ echo '$3' >conftest.c -echo 'void f(){ $2 }' >>conftest.c +echo 'void f(void){ $2 }' >>conftest.c if test -z "`$CC $CPPFLAGS $CFLAGS -c conftest.c 2>&1 | grep -e deprecated -e unavailable`"; then eval "cv_cc_deprecated_$cache=no" else @@ -1317,7 +1319,7 @@ AC_DEFUN([AHX_CONFIG_W32_FD_SET_T], #ifdef HAVE_WINSOCK2_H #define FD_SET_T (u_int) #else -#define FD_SET_T +#define FD_SET_T #endif ]) @@ -1355,7 +1357,7 @@ dnl $3: define value, 1 AC_DEFUN([AHX_CONFIG_FLAG_OMITTED], [#if defined($1) && !defined($2) #define $2 $3 -[#]endif ]) +[#]endif]) dnl Wrapper for AHX_CONFIG_FLAG_OMITTED for -D style flags dnl $1: the -DNAME or -DNAME=value string. diff --git a/contrib/unbound/acx_python.m4 b/contrib/unbound/acx_python.m4 index 16c0c6fd943f..c945d6c8989e 100644 --- a/contrib/unbound/acx_python.m4 +++ b/contrib/unbound/acx_python.m4 @@ -17,33 +17,62 @@ AC_DEFUN([AC_PYTHON_DEVEL],[ PYTHON_VERSION=`$PYTHON -c "import sys; \ print(sys.version.split()[[0]])"` fi + # calculate the version number components. + [ + v="$PYTHON_VERSION" + PYTHON_VERSION_MAJOR=`echo $v | sed 's/[^0-9].*//'` + if test -z "$PYTHON_VERSION_MAJOR"; then PYTHON_VERSION_MAJOR="0"; fi + v=`echo $v | sed -e 's/^[0-9]*$//' -e 's/[0-9]*[^0-9]//'` + PYTHON_VERSION_MINOR=`echo $v | sed 's/[^0-9].*//'` + if test -z "$PYTHON_VERSION_MINOR"; then PYTHON_VERSION_MINOR="0"; fi + v=`echo $v | sed -e 's/^[0-9]*$//' -e 's/[0-9]*[^0-9]//'` + PYTHON_VERSION_PATCH=`echo $v | sed 's/[^0-9].*//'` + if test -z "$PYTHON_VERSION_PATCH"; then PYTHON_VERSION_PATCH="0"; fi + ] - # Check if you have sysconfig - AC_MSG_CHECKING([for the sysconfig Python module]) - if ac_sysconfig_result=`$PYTHON -c "import sysconfig" 2>&1`; then + # For some systems, sysconfig exists, but has the wrong paths, + # on Debian 10, for python 2.7 and 3.7. So, we check the version, + # and for older versions try distutils.sysconfig first. For newer + # versions>=3.10, where distutils.sysconfig is deprecated, use + # sysconfig first and then attempt the other one. + py_distutils_first="no" + if test $PYTHON_VERSION_MAJOR -lt 3; then + py_distutils_first="yes" + fi + if test $PYTHON_VERSION_MAJOR -eq 3 -a $PYTHON_VERSION_MINOR -lt 10; then + py_distutils_first="yes" + fi + + # Check if you have the first module + if test "$py_distutils_first" = "yes"; then m="distutils"; else m="sysconfig"; fi + sysconfig_module="" + AC_MSG_CHECKING([for the $m Python module]) + if ac_modulecheck_result1=`$PYTHON -c "import $m" 2>&1`; then AC_MSG_RESULT([yes]) - sysconfig_module="sysconfig" - # if yes, use sysconfig, because distutils is deprecated. + sysconfig_module="$m" else AC_MSG_RESULT([no]) - # if no, try to use distutils + fi - # - # Check if you have distutils, else fail - # - AC_MSG_CHECKING([for the distutils Python package]) - if ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`; then + # if not found, try the other one. + if test -z "$sysconfig_module"; then + if test "$py_distutils_first" = "yes"; then m2="sysconfig"; else m2="distutils"; fi + AC_MSG_CHECKING([for the $m2 Python module]) + if ac_modulecheck_result2=`$PYTHON -c "import $m2" 2>&1`; then AC_MSG_RESULT([yes]) + sysconfig_module="$m2" else AC_MSG_RESULT([no]) - AC_MSG_ERROR([cannot import Python module "distutils". - Please check your Python installation. The error was: - $ac_distutils_result]) + AC_MSG_ERROR([cannot import Python module "$m", or "$m2". + Please check your Python installation. The errors are: + $m + $ac_modulecheck_result1 + $m2 + $ac_modulecheck_result2]) PYTHON_VERSION="" fi - - sysconfig_module="distutils.sysconfig" fi + if test "$sysconfig_module" = "distutils"; then sysconfig_module="distutils.sysconfig"; fi # # Check for Python include path diff --git a/contrib/unbound/cachedb/cachedb.c b/contrib/unbound/cachedb/cachedb.c index 245daa986967..30645268ca23 100644 --- a/contrib/unbound/cachedb/cachedb.c +++ b/contrib/unbound/cachedb/cachedb.c @@ -102,7 +102,6 @@ static int testframe_init(struct module_env* env, struct cachedb_env* cachedb_env) { struct testframe_moddata* d; - (void)env; verbose(VERB_ALGO, "testframe_init"); d = (struct testframe_moddata*)calloc(1, sizeof(struct testframe_moddata)); @@ -111,6 +110,15 @@ testframe_init(struct module_env* env, struct cachedb_env* cachedb_env) log_err("out of memory"); return 0; } + /* Register an EDNS option (65534) to bypass the worker cache lookup + * for testing */ + if(!edns_register_option(LDNS_EDNS_UNBOUND_CACHEDB_TESTFRAME_TEST, + 1 /* bypass cache */, + 0 /* no aggregation */, env)) { + log_err("testframe_init, could not register test opcode"); + free(d); + return 0; + } lock_basic_init(&d->lock); lock_protect(&d->lock, d, sizeof(*d)); return 1; @@ -218,6 +226,8 @@ static int cachedb_apply_cfg(struct cachedb_env* cachedb_env, struct config_file* cfg) { const char* backend_str = cfg->cachedb_backend; + if(!backend_str || *backend_str==0) + return 1; cachedb_env->backend = cachedb_find_backend(backend_str); if(!cachedb_env->backend) { log_err("cachedb: cannot find backend name '%s'", backend_str); @@ -228,7 +238,7 @@ cachedb_apply_cfg(struct cachedb_env* cachedb_env, struct config_file* cfg) return 1; } -int +int cachedb_init(struct module_env* env, int id) { struct cachedb_env* cachedb_env = (struct cachedb_env*)calloc(1, @@ -267,19 +277,16 @@ cachedb_init(struct module_env* env, int id) return 1; } -void +void cachedb_deinit(struct module_env* env, int id) { struct cachedb_env* cachedb_env; if(!env || !env->modinfo[id]) return; cachedb_env = (struct cachedb_env*)env->modinfo[id]; - /* free contents */ - /* TODO */ if(cachedb_env->enabled) { (*cachedb_env->backend->deinit)(env, cachedb_env); } - free(cachedb_env); env->modinfo[id] = NULL; } @@ -406,6 +413,14 @@ prep_data(struct module_qstate* qstate, struct sldns_buffer* buf) if(qstate->return_msg->rep->ttl == 0 && !qstate->env->cfg->serve_expired) return 0; + + /* The EDE is added to the out-list so it is encoded in the cached message */ + if (qstate->env->cfg->ede && qstate->return_msg->rep->reason_bogus != LDNS_EDE_NONE) { + edns_opt_list_append_ede(&edns.opt_list_out, qstate->env->scratch, + qstate->return_msg->rep->reason_bogus, + qstate->return_msg->rep->reason_bogus_str); + } + if(verbosity >= VERB_ALGO) log_dns_msg("cachedb encoding", &qstate->return_msg->qinfo, qstate->return_msg->rep); @@ -502,6 +517,7 @@ parse_data(struct module_qstate* qstate, struct sldns_buffer* buf) { struct msg_parse* prs; struct edns_data edns; + struct edns_option* ede; uint64_t timestamp, expiry; time_t adjust; size_t lim = sldns_buffer_limit(buf); @@ -539,6 +555,24 @@ parse_data(struct module_qstate* qstate, struct sldns_buffer* buf) if(!qstate->return_msg) return 0; + /* We find the EDE in the in-list after parsing */ + if(qstate->env->cfg->ede && + (ede = edns_opt_list_find(edns.opt_list_in, LDNS_EDNS_EDE))) { + if(ede->opt_len >= 2) { + qstate->return_msg->rep->reason_bogus = + sldns_read_uint16(ede->opt_data); + } + /* allocate space and store the error string and it's size */ + if(ede->opt_len > 2) { + size_t ede_len = ede->opt_len - 2; + qstate->return_msg->rep->reason_bogus_str = regional_alloc( + qstate->region, sizeof(char) * (ede_len+1)); + memcpy(qstate->return_msg->rep->reason_bogus_str, + ede->opt_data+2, ede_len); + qstate->return_msg->rep->reason_bogus_str[ede_len] = 0; + } + } + qstate->return_rcode = LDNS_RCODE_NOERROR; /* see how much of the TTL expired, and remove it */ @@ -630,11 +664,15 @@ cachedb_extcache_store(struct module_qstate* qstate, struct cachedb_env* ie) * See if unbound's internal cache can answer the query */ static int -cachedb_intcache_lookup(struct module_qstate* qstate) +cachedb_intcache_lookup(struct module_qstate* qstate, struct cachedb_env* cde) { uint8_t* dpname=NULL; size_t dpnamelen=0; struct dns_msg* msg; + /* for testframe bypass this lookup */ + if(cde->backend == &testframe_backend) { + return 0; + } if(iter_stub_fwd_no_cache(qstate, &qstate->qinfo, &dpname, &dpnamelen)) return 0; /* no cache for these queries */ @@ -693,6 +731,7 @@ cachedb_handle_query(struct module_qstate* qstate, struct cachedb_qstate* ATTR_UNUSED(iq), struct cachedb_env* ie, int id) { + qstate->is_cachedb_answer = 0; /* check if we are enabled, and skip if so */ if(!ie->enabled) { /* pass request to next module */ @@ -709,7 +748,7 @@ cachedb_handle_query(struct module_qstate* qstate, /* lookup inside unbound's internal cache. * This does not look for expired entries. */ - if(cachedb_intcache_lookup(qstate)) { + if(cachedb_intcache_lookup(qstate, ie)) { if(verbosity >= VERB_ALGO) { if(qstate->return_msg->rep) log_dns_msg("cachedb internal cache lookup", @@ -746,6 +785,7 @@ cachedb_handle_query(struct module_qstate* qstate, qstate->ext_state[id] = module_wait_module; return; } + qstate->is_cachedb_answer = 1; /* we are done with the query */ qstate->ext_state[id] = module_finished; return; @@ -768,6 +808,7 @@ static void cachedb_handle_response(struct module_qstate* qstate, struct cachedb_qstate* ATTR_UNUSED(iq), struct cachedb_env* ie, int id) { + qstate->is_cachedb_answer = 0; /* check if we are not enabled or instructed to not cache, and skip */ if(!ie->enabled || qstate->no_cache_store) { /* we are done with the query */ diff --git a/contrib/unbound/cachedb/redis.c b/contrib/unbound/cachedb/redis.c index 16c3741f786b..93a575a4c6d2 100644 --- a/contrib/unbound/cachedb/redis.c +++ b/contrib/unbound/cachedb/redis.c @@ -56,6 +56,8 @@ struct redis_moddata { int numctxs; /* number of ctx entries */ const char* server_host; /* server's IP address or host name */ int server_port; /* server's TCP port */ + const char* server_path; /* server's unix path, or "", NULL if unused */ + const char* server_password; /* server's AUTH password, or "", NULL if unused */ struct timeval timeout; /* timeout for connection setup and commands */ }; @@ -67,8 +69,13 @@ redis_connect(const struct redis_moddata* moddata) { redisContext* ctx; - ctx = redisConnectWithTimeout(moddata->server_host, - moddata->server_port, moddata->timeout); + if(moddata->server_path && moddata->server_path[0]!=0) { + ctx = redisConnectUnixWithTimeout(moddata->server_path, + moddata->timeout); + } else { + ctx = redisConnectWithTimeout(moddata->server_host, + moddata->server_port, moddata->timeout); + } if(!ctx || ctx->err) { const char *errstr = "out of memory"; if(ctx) @@ -80,6 +87,17 @@ redis_connect(const struct redis_moddata* moddata) log_err("failed to set redis timeout"); goto fail; } + if(moddata->server_password && moddata->server_password[0]!=0) { + redisReply* rep; + rep = redisCommand(ctx, "AUTH %s", moddata->server_password); + if(!rep || rep->type == REDIS_REPLY_ERROR) { + log_err("failed to authenticate with password"); + freeReplyObject(rep); + goto fail; + } + freeReplyObject(rep); + } + verbose(VERB_OPS, "Connection to Redis established"); return ctx; fail: @@ -94,7 +112,7 @@ redis_init(struct module_env* env, struct cachedb_env* cachedb_env) int i; struct redis_moddata* moddata = NULL; - verbose(VERB_ALGO, "redis_init"); + verbose(VERB_OPS, "Redis initialization"); moddata = calloc(1, sizeof(struct redis_moddata)); if(!moddata) { @@ -112,6 +130,8 @@ redis_init(struct module_env* env, struct cachedb_env* cachedb_env) * we don't have to free it in this module. */ moddata->server_host = env->cfg->redis_server_host; moddata->server_port = env->cfg->redis_server_port; + moddata->server_path = env->cfg->redis_server_path; + moddata->server_password = env->cfg->redis_server_password; moddata->timeout.tv_sec = env->cfg->redis_timeout / 1000; moddata->timeout.tv_usec = (env->cfg->redis_timeout % 1000) * 1000; for(i = 0; i < moddata->numctxs; i++) @@ -154,7 +174,7 @@ redis_deinit(struct module_env* env, struct cachedb_env* cachedb_env) cachedb_env->backend_data; (void)env; - verbose(VERB_ALGO, "redis_deinit"); + verbose(VERB_OPS, "Redis deinitialization"); if(!moddata) return; diff --git a/contrib/unbound/compat/getentropy_solaris.c b/contrib/unbound/compat/getentropy_solaris.c index 5e3b1cbbbd30..1ff8162917b3 100644 --- a/contrib/unbound/compat/getentropy_solaris.c +++ b/contrib/unbound/compat/getentropy_solaris.c @@ -47,7 +47,7 @@ #define SHA512_Update SHA512Update #define SHA512_Final SHA512Final #else -#include "openssl/sha.h" +#include #endif #include diff --git a/contrib/unbound/config.guess b/contrib/unbound/config.guess index 980b02083815..b187213930f1 100755 --- a/contrib/unbound/config.guess +++ b/contrib/unbound/config.guess @@ -1,10 +1,10 @@ #! /bin/sh # Attempt to guess a canonical system name. -# Copyright 1992-2022 Free Software Foundation, Inc. +# Copyright 1992-2023 Free Software Foundation, Inc. # shellcheck disable=SC2006,SC2268 # see below for rationale -timestamp='2022-09-17' +timestamp='2023-07-20' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -47,7 +47,7 @@ me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] -Output the configuration name of the system \`$me' is run on. +Output the configuration name of the system '$me' is run on. Options: -h, --help print this help, then exit @@ -60,13 +60,13 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright 1992-2022 Free Software Foundation, Inc. +Copyright 1992-2023 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" -Try \`$me --help' for more information." +Try '$me --help' for more information." # Parse command line while test $# -gt 0 ; do @@ -102,8 +102,8 @@ GUESS= # temporary files to be created and, as you can see below, it is a # headache to deal with in a portable fashion. -# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still -# use `HOST_CC' if defined, but it is deprecated. +# Historically, 'CC_FOR_BUILD' used to be named 'HOST_CC'. We still +# use 'HOST_CC' if defined, but it is deprecated. # Portable tmp directory creation inspired by the Autoconf team. @@ -459,7 +459,7 @@ case $UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION in UNAME_RELEASE=`uname -v` ;; esac - # Japanese Language versions have a version number like `4.1.3-JL'. + # Japanese Language versions have a version number like '4.1.3-JL'. SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/'` GUESS=sparc-sun-sunos$SUN_REL ;; @@ -976,7 +976,27 @@ EOF GUESS=$UNAME_MACHINE-unknown-minix ;; aarch64:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + set_cc_for_build + CPU=$UNAME_MACHINE + LIBCABI=$LIBC + if test "$CC_FOR_BUILD" != no_compiler_found; then + ABI=64 + sed 's/^ //' << EOF > "$dummy.c" + #ifdef __ARM_EABI__ + #ifdef __ARM_PCS_VFP + ABI=eabihf + #else + ABI=eabi + #endif + #endif +EOF + cc_set_abi=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^ABI' | sed 's, ,,g'` + eval "$cc_set_abi" + case $ABI in + eabi | eabihf) CPU=armv8l; LIBCABI=$LIBC$ABI ;; + esac + fi + GUESS=$CPU-unknown-linux-$LIBCABI ;; aarch64_be:Linux:*:*) UNAME_MACHINE=aarch64_be @@ -1042,6 +1062,15 @@ EOF k1om:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; + kvx:Linux:*:*) + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; + kvx:cos:*:*) + GUESS=$UNAME_MACHINE-unknown-cos + ;; + kvx:mbr:*:*) + GUESS=$UNAME_MACHINE-unknown-mbr + ;; loongarch32:Linux:*:* | loongarch64:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; @@ -1197,7 +1226,7 @@ EOF GUESS=$UNAME_MACHINE-pc-sysv4.2uw$UNAME_VERSION ;; i*86:OS/2:*:*) - # If we were able to find `uname', then EMX Unix compatibility + # If we were able to find 'uname', then EMX Unix compatibility # is probably installed. GUESS=$UNAME_MACHINE-pc-os2-emx ;; @@ -1338,7 +1367,7 @@ EOF GUESS=ns32k-sni-sysv fi ;; - PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort + PENTIUM:*:4.0*:*) # Unisys 'ClearPath HMP IX 4000' SVR4/MP effort # says GUESS=i586-unisys-sysv4 ;; diff --git a/contrib/unbound/config.h.in b/contrib/unbound/config.h.in index 2caecf30d040..f31354d01408 100644 *** 18537 LINES SKIPPED *** From nobody Wed Oct 4 01:02:06 2023 X-Original-To: dev-commits-src-branches@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 4S0bxp3QRhz4wK3W; Wed, 4 Oct 2023 01:02: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0bxp2ZC1z4Y9T; Wed, 4 Oct 2023 01:02:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381326; 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=rIOpaDcpOzbIlqZsoIiqC4b1u3eoZD7+hP1Hr2TJfks=; b=PnTmrblqGKHKGmT0M7RKLafyjpcwMehxY+7LK4++LoCM8bzQnKeZ9JRElxPtO0thYvx1WC gRByuLRnzA5yPnRVBzKL/Gjk162fxexyJTcJmbZBupe0tRWqmWtl99fUyWQScs9gzRsbzR Z+CB/BUGXpL3WlOmG+jqamAncxfVBKTbgfwxuZqgGzSzFLZ9/JT6Lq/tVZFafA+tQt9PkH vWsTBEUnuKKHD+irTKPR318aARrUokpUBYISG5cAEiBYC+q6uUothQVQZcMaJ9rPwCLoKw /QPROmwOa1O6mn1FbmMDS8bLnb0H/qoecvurC2nMFb4Xra9nsYjN6IVDli5J2g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696381326; a=rsa-sha256; cv=none; b=BQKVqtJGKrMG431GTuM7TdQ0oHXbsqYHliYA1tL8lV8XF4FbV7F7GHmffiUQKQUdH32wyW Scqzg4ywlY6OFKZX9A+4tYuUwzHCQCHlzx0hVjqesKKO/rj44/0mVsiMOwX1/5/JvLhj41 rPIjZGGkQpjx1Y5dUfPIfQhhrgc26LySDrShrhPoObYdHJG/dGOBwq8ZSKPo5rm+KWizg4 PFv2FaV+1fLsGgKmZc7ZCkV0k2iFY7DgivzW0W4LgF7B4Zoo0WlmLDveS4SzyTEi+SEGKU 0X/BCgBpqt2sDI4fWodLFfhPqXLLThVLH5F0uL97KtVlrAIqiAa0PTDNQDHj4A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381326; 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=rIOpaDcpOzbIlqZsoIiqC4b1u3eoZD7+hP1Hr2TJfks=; b=rBAclg+4CgxBlAEOGTlmRTAV4/bz6CNvNyn2NY0uCHkXS9EIirw1mcu+P9gO3+MsRAjpKy oURSuVDgkmJKeastw8AmwqlPhg6Mz5V6OG7432zzSisk4ic1IInYcz/cyvQTuECiYQ+WLT kNaqzq461DlwJBzreHinTJ9D7el46ppboS8efnfMP9m3D8fioYQtdbNqnnM0iA3nErCt6x KHJ3fP91Ny83NfrjhQtRibU7nrX//hI/2uWfofyowooqfTjKO67j7EI8Dp954h6vIBo0p8 /yfep10BQ/llvhqosWXKioHI0RRwXugD+GXb3AZplEJgbkRx3Hpht4nnHwzPbQ== 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 4S0bxp17VVz2TP; Wed, 4 Oct 2023 01:02:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394126NI050431; Wed, 4 Oct 2023 01:02:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3941268B050428; Wed, 4 Oct 2023 01:02:06 GMT (envelope-from git) Date: Wed, 4 Oct 2023 01:02:06 GMT Message-Id: <202310040102.3941268B050428@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Cy Schubert Subject: git: f5a091c1f6a0 - stable/13 - local-unbound: remove stray config.h.in backup List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f5a091c1f6a068cdc5c3bd23536830de9dfe7b84 Auto-Submitted: auto-generated The branch stable/13 has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=f5a091c1f6a068cdc5c3bd23536830de9dfe7b84 commit f5a091c1f6a068cdc5c3bd23536830de9dfe7b84 Author: Mina Galić AuthorDate: 2023-09-20 14:39:37 +0000 Commit: Cy Schubert CommitDate: 2023-10-04 01:01:52 +0000 local-unbound: remove stray config.h.in backup despite being ignored in our main .gitignore, such files can still be merged from vendor branches. Reviewed by: cy Fixes: 8f76bb7dad (unbound: Vendor import 1.18.0) MFC after: 2 weeks X-MFC with: 8f76bb7dad Differential Revision: https://reviews.freebsd.org/D41920 (cherry picked from commit 948e11aaf420cd7d493cc2e118cacc06d18653fe) --- contrib/unbound/config.h.in~ | 1456 ------------------------------------------ 1 file changed, 1456 deletions(-) diff --git a/contrib/unbound/config.h.in~ b/contrib/unbound/config.h.in~ deleted file mode 100644 index f31354d01408..000000000000 --- a/contrib/unbound/config.h.in~ +++ /dev/null @@ -1,1456 +0,0 @@ -/* config.h.in. Generated from configure.ac by autoheader. */ - -/* apply the noreturn attribute to a function that exits the program */ -#undef ATTR_NORETURN - -/* apply the weak attribute to a symbol */ -#undef ATTR_WEAK - -/* Directory to chroot to */ -#undef CHROOT_DIR - -/* Define this to enable client subnet option. */ -#undef CLIENT_SUBNET - -/* Do sha512 definitions in config.h */ -#undef COMPAT_SHA512 - -/* Command line arguments used with configure */ -#undef CONFCMDLINE - -/* Pathname to the Unbound configuration file */ -#undef CONFIGFILE - -/* Define this if on macOSX10.4-darwin8 and setreuid and setregid do not work - */ -#undef DARWIN_BROKEN_SETREUID - -/* Whether daemon is deprecated */ -#undef DEPRECATED_DAEMON - -/* Deprecate RSA 1024 bit length, makes that an unsupported key */ -#undef DEPRECATE_RSA_1024 - -/* Define this to enable kernel based UDP source port randomization. */ -#undef DISABLE_EXPLICIT_PORT_RANDOMISATION - -/* default dnstap socket path */ -#undef DNSTAP_SOCKET_PATH - -/* Define if you want to use debug lock checking (slow). */ -#undef ENABLE_LOCK_CHECKS - -/* Define this if you enabled-allsymbols from libunbound to link binaries to - it for smaller install size, but the libunbound export table is polluted by - internal symbols */ -#undef EXPORT_ALL_SYMBOLS - -/* Define to 1 if you have the `accept4' function. */ -#undef HAVE_ACCEPT4 - -/* Define to 1 if you have the `arc4random' function. */ -#undef HAVE_ARC4RANDOM - -/* Define to 1 if you have the `arc4random_uniform' function. */ -#undef HAVE_ARC4RANDOM_UNIFORM - -/* Define to 1 if you have the header file. */ -#undef HAVE_ARPA_INET_H - -/* Whether the C compiler accepts the "format" attribute */ -#undef HAVE_ATTR_FORMAT - -/* Whether the C compiler accepts the "noreturn" attribute */ -#undef HAVE_ATTR_NORETURN - -/* Whether the C compiler accepts the "unused" attribute */ -#undef HAVE_ATTR_UNUSED - -/* Whether the C compiler accepts the "weak" attribute */ -#undef HAVE_ATTR_WEAK - -/* If we have be64toh */ -#undef HAVE_BE64TOH - -/* Define to 1 if you have the `BIO_set_callback_ex' function. */ -#undef HAVE_BIO_SET_CALLBACK_EX - -/* Define to 1 if you have the header file. */ -#undef HAVE_BSD_STDLIB_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_BSD_STRING_H - -/* Define to 1 if you have the `chown' function. */ -#undef HAVE_CHOWN - -/* Define to 1 if you have the `chroot' function. */ -#undef HAVE_CHROOT - -/* Define to 1 if you have the `CRYPTO_cleanup_all_ex_data' function. */ -#undef HAVE_CRYPTO_CLEANUP_ALL_EX_DATA - -/* Define to 1 if you have the `CRYPTO_THREADID_set_callback' function. */ -#undef HAVE_CRYPTO_THREADID_SET_CALLBACK - -/* Define to 1 if you have the `ctime_r' function. */ -#undef HAVE_CTIME_R - -/* Define to 1 if you have the `daemon' function. */ -#undef HAVE_DAEMON - -/* Define to 1 if you have the declaration of `arc4random', and to 0 if you - don't. */ -#undef HAVE_DECL_ARC4RANDOM - -/* Define to 1 if you have the declaration of `arc4random_uniform', and to 0 - if you don't. */ -#undef HAVE_DECL_ARC4RANDOM_UNIFORM - -/* Define to 1 if you have the declaration of `evsignal_assign', and to 0 if - you don't. */ -#undef HAVE_DECL_EVSIGNAL_ASSIGN - -/* Define to 1 if you have the declaration of `inet_ntop', and to 0 if you - don't. */ -#undef HAVE_DECL_INET_NTOP - -/* Define to 1 if you have the declaration of `inet_pton', and to 0 if you - don't. */ -#undef HAVE_DECL_INET_PTON - -/* Define to 1 if you have the declaration of `nghttp2_session_server_new', - and to 0 if you don't. */ -#undef HAVE_DECL_NGHTTP2_SESSION_SERVER_NEW - -/* Define to 1 if you have the declaration of `NID_ED25519', and to 0 if you - don't. */ -#undef HAVE_DECL_NID_ED25519 - -/* Define to 1 if you have the declaration of `NID_ED448', and to 0 if you - don't. */ -#undef HAVE_DECL_NID_ED448 - -/* Define to 1 if you have the declaration of `NID_secp384r1', and to 0 if you - don't. */ -#undef HAVE_DECL_NID_SECP384R1 - -/* Define to 1 if you have the declaration of `NID_X9_62_prime256v1', and to 0 - if you don't. */ -#undef HAVE_DECL_NID_X9_62_PRIME256V1 - -/* Define to 1 if you have the declaration of `reallocarray', and to 0 if you - don't. */ -#undef HAVE_DECL_REALLOCARRAY - -/* Define to 1 if you have the declaration of `redisConnect', and to 0 if you - don't. */ -#undef HAVE_DECL_REDISCONNECT - -/* Define to 1 if you have the declaration of `sk_SSL_COMP_pop_free', and to 0 - if you don't. */ -#undef HAVE_DECL_SK_SSL_COMP_POP_FREE - -/* Define to 1 if you have the declaration of - `SSL_COMP_get_compression_methods', and to 0 if you don't. */ -#undef HAVE_DECL_SSL_COMP_GET_COMPRESSION_METHODS - -/* Define to 1 if you have the declaration of `SSL_CTX_set_ecdh_auto', and to - 0 if you don't. */ -#undef HAVE_DECL_SSL_CTX_SET_ECDH_AUTO - -/* Define to 1 if you have the declaration of `strlcat', and to 0 if you - don't. */ -#undef HAVE_DECL_STRLCAT - -/* Define to 1 if you have the declaration of `strlcpy', and to 0 if you - don't. */ -#undef HAVE_DECL_STRLCPY - -/* Define to 1 if you have the declaration of `XML_StopParser', and to 0 if - you don't. */ -#undef HAVE_DECL_XML_STOPPARSER - -/* Define to 1 if you have the header file. */ -#undef HAVE_DLFCN_H - -/* Define to 1 if you have the `DSA_SIG_set0' function. */ -#undef HAVE_DSA_SIG_SET0 - -/* Define to 1 if you have the header file. */ -#undef HAVE_ENDIAN_H - -/* Define to 1 if you have the `endprotoent' function. */ -#undef HAVE_ENDPROTOENT - -/* Define to 1 if you have the `endpwent' function. */ -#undef HAVE_ENDPWENT - -/* Define to 1 if you have the `endservent' function. */ -#undef HAVE_ENDSERVENT - -/* Define to 1 if you have the `ENGINE_cleanup' function. */ -#undef HAVE_ENGINE_CLEANUP - -/* Define to 1 if you have the `ERR_free_strings' function. */ -#undef HAVE_ERR_FREE_STRINGS - -/* Define to 1 if you have the `ERR_load_crypto_strings' function. */ -#undef HAVE_ERR_LOAD_CRYPTO_STRINGS - -/* Define to 1 if you have the `event_assign' function. */ -#undef HAVE_EVENT_ASSIGN - -/* Define to 1 if you have the `event_base_free' function. */ -#undef HAVE_EVENT_BASE_FREE - -/* Define to 1 if you have the `event_base_get_method' function. */ -#undef HAVE_EVENT_BASE_GET_METHOD - -/* Define to 1 if you have the `event_base_new' function. */ -#undef HAVE_EVENT_BASE_NEW - -/* Define to 1 if you have the `event_base_once' function. */ -#undef HAVE_EVENT_BASE_ONCE - -/* Define to 1 if you have the header file. */ -#undef HAVE_EVENT_H - -/* Define to 1 if you have the `EVP_aes_256_cbc' function. */ -#undef HAVE_EVP_AES_256_CBC - -/* Define to 1 if you have the `EVP_cleanup' function. */ -#undef HAVE_EVP_CLEANUP - -/* Define to 1 if you have the `EVP_default_properties_is_fips_enabled' - function. */ -#undef HAVE_EVP_DEFAULT_PROPERTIES_IS_FIPS_ENABLED - -/* Define to 1 if you have the `EVP_DigestVerify' function. */ -#undef HAVE_EVP_DIGESTVERIFY - -/* Define to 1 if you have the `EVP_dss1' function. */ -#undef HAVE_EVP_DSS1 - -/* Define to 1 if you have the `EVP_EncryptInit_ex' function. */ -#undef HAVE_EVP_ENCRYPTINIT_EX - -/* Define to 1 if you have the `EVP_MAC_CTX_set_params' function. */ -#undef HAVE_EVP_MAC_CTX_SET_PARAMS - -/* Define to 1 if you have the `EVP_MD_CTX_new' function. */ -#undef HAVE_EVP_MD_CTX_NEW - -/* Define to 1 if you have the `EVP_sha1' function. */ -#undef HAVE_EVP_SHA1 - -/* Define to 1 if you have the `EVP_sha256' function. */ -#undef HAVE_EVP_SHA256 - -/* Define to 1 if you have the `EVP_sha512' function. */ -#undef HAVE_EVP_SHA512 - -/* Define to 1 if you have the `ev_default_loop' function. */ -#undef HAVE_EV_DEFAULT_LOOP - -/* Define to 1 if you have the `ev_loop' function. */ -#undef HAVE_EV_LOOP - -/* Define to 1 if you have the header file. */ -#undef HAVE_EXPAT_H - -/* Define to 1 if you have the `explicit_bzero' function. */ -#undef HAVE_EXPLICIT_BZERO - -/* Define to 1 if you have the `fcntl' function. */ -#undef HAVE_FCNTL - -/* Define to 1 if you have the `FIPS_mode' function. */ -#undef HAVE_FIPS_MODE - -/* Define to 1 if you have the `fork' function. */ -#undef HAVE_FORK - -/* Define to 1 if fseeko (and presumably ftello) exists and is declared. */ -#undef HAVE_FSEEKO - -/* Define to 1 if you have the `fsync' function. */ -#undef HAVE_FSYNC - -/* Whether getaddrinfo is available */ -#undef HAVE_GETADDRINFO - -/* Define to 1 if you have the `getauxval' function. */ -#undef HAVE_GETAUXVAL - -/* Define to 1 if you have the `getentropy' function. */ -#undef HAVE_GETENTROPY - -/* Define to 1 if you have the `getifaddrs' function. */ -#undef HAVE_GETIFADDRS - -/* Define to 1 if you have the header file. */ -#undef HAVE_GETOPT_H - -/* Define to 1 if you have the `getpwnam' function. */ -#undef HAVE_GETPWNAM - -/* Define to 1 if you have the `getrlimit' function. */ -#undef HAVE_GETRLIMIT - -/* Define to 1 if you have the `gettid' function. */ -#undef HAVE_GETTID - -/* Define to 1 if you have the `glob' function. */ -#undef HAVE_GLOB - -/* Define to 1 if you have the header file. */ -#undef HAVE_GLOB_H - -/* Define to 1 if you have the `gmtime_r' function. */ -#undef HAVE_GMTIME_R - -/* Define to 1 if you have the header file. */ -#undef HAVE_GRP_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_HIREDIS_HIREDIS_H - -/* Define to 1 if you have the `HMAC_Init_ex' function. */ -#undef HAVE_HMAC_INIT_EX - -/* If we have htobe64 */ -#undef HAVE_HTOBE64 - -/* Define to 1 if you have the header file. */ -#undef HAVE_IFADDRS_H - -/* Define to 1 if you have the `if_nametoindex' function. */ -#undef HAVE_IF_NAMETOINDEX - -/* Define to 1 if you have the `inet_aton' function. */ -#undef HAVE_INET_ATON - -/* Define to 1 if you have the `inet_ntop' function. */ -#undef HAVE_INET_NTOP - -/* Define to 1 if you have the `inet_pton' function. */ -#undef HAVE_INET_PTON - -/* Define to 1 if you have the `initgroups' function. */ -#undef HAVE_INITGROUPS - -/* Define to 1 if you have the header file. */ -#undef HAVE_INTTYPES_H - -/* if the function 'ioctlsocket' is available */ -#undef HAVE_IOCTLSOCKET - -/* Define to 1 if you have the header file. */ -#undef HAVE_IPHLPAPI_H - -/* Define to 1 if you have the `isblank' function. */ -#undef HAVE_ISBLANK - -/* Define to 1 if you have the `kill' function. */ -#undef HAVE_KILL - -/* Use portable libbsd functions */ -#undef HAVE_LIBBSD - -/* Define to 1 if you have the header file. */ -#undef HAVE_LIBKERN_OSBYTEORDER_H - -/* Define if we have LibreSSL */ -#undef HAVE_LIBRESSL - -/* Define to 1 if you have the header file. */ -#undef HAVE_LINUX_NET_TSTAMP_H - -/* Define to 1 if you have the `localtime_r' function. */ -#undef HAVE_LOCALTIME_R - -/* Define to 1 if you have the header file. */ -#undef HAVE_LOGIN_CAP_H - -/* If have GNU libc compatible malloc */ -#undef HAVE_MALLOC - -/* Define to 1 if you have the `memmove' function. */ -#undef HAVE_MEMMOVE - -/* Define to 1 if you have the header file. */ -#undef HAVE_MEMORY_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETDB_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETINET_IN_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETINET_TCP_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETIOAPI_H - -/* Use libnettle for crypto */ -#undef HAVE_NETTLE - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETTLE_DSA_COMPAT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETTLE_EDDSA_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NET_IF_H - -/* Define this to use nghttp2 client. */ -#undef HAVE_NGHTTP2 - -/* Define to 1 if you have the header file. */ -#undef HAVE_NGHTTP2_NGHTTP2_H - -/* Use libnss for crypto */ -#undef HAVE_NSS - -/* Define to 1 if you have the `OpenSSL_add_all_digests' function. */ -#undef HAVE_OPENSSL_ADD_ALL_DIGESTS - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_BN_H - -/* Define to 1 if you have the `OPENSSL_config' function. */ -#undef HAVE_OPENSSL_CONFIG - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_CONF_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_CORE_NAMES_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_DH_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_DSA_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_ENGINE_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_ERR_H - -/* Define to 1 if you have the `OPENSSL_init_crypto' function. */ -#undef HAVE_OPENSSL_INIT_CRYPTO - -/* Define to 1 if you have the `OPENSSL_init_ssl' function. */ -#undef HAVE_OPENSSL_INIT_SSL - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_PARAM_BUILD_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_RAND_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_RSA_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_SSL_H - -/* Define to 1 if you have the `OSSL_PARAM_BLD_new' function. */ -#undef HAVE_OSSL_PARAM_BLD_NEW - -/* Define to 1 if you have the `poll' function. */ -#undef HAVE_POLL - -/* Define to 1 if you have the header file. */ -#undef HAVE_POLL_H - -/* Define if you have POSIX threads libraries and header files. */ -#undef HAVE_PTHREAD - -/* Have PTHREAD_PRIO_INHERIT. */ -#undef HAVE_PTHREAD_PRIO_INHERIT - -/* Define to 1 if the system has the type `pthread_rwlock_t'. */ -#undef HAVE_PTHREAD_RWLOCK_T - -/* Define to 1 if the system has the type `pthread_spinlock_t'. */ -#undef HAVE_PTHREAD_SPINLOCK_T - -/* Define to 1 if you have the header file. */ -#undef HAVE_PWD_H - -/* Define if you have Python libraries and header files. */ -#undef HAVE_PYTHON - -/* Define to 1 if you have the `random' function. */ -#undef HAVE_RANDOM - -/* Define to 1 if you have the `RAND_cleanup' function. */ -#undef HAVE_RAND_CLEANUP - -/* If we have reallocarray(3) */ -#undef HAVE_REALLOCARRAY - -/* Define to 1 if you have the `recvmsg' function. */ -#undef HAVE_RECVMSG - -/* Define to 1 if you have the `sendmsg' function. */ -#undef HAVE_SENDMSG - -/* Define to 1 if you have the `setregid' function. */ -#undef HAVE_SETREGID - -/* Define to 1 if you have the `setresgid' function. */ -#undef HAVE_SETRESGID - -/* Define to 1 if you have the `setresuid' function. */ -#undef HAVE_SETRESUID - -/* Define to 1 if you have the `setreuid' function. */ -#undef HAVE_SETREUID - -/* Define to 1 if you have the `setrlimit' function. */ -#undef HAVE_SETRLIMIT - -/* Define to 1 if you have the `setsid' function. */ -#undef HAVE_SETSID - -/* Define to 1 if you have the `setusercontext' function. */ -#undef HAVE_SETUSERCONTEXT - -/* Define to 1 if you have the `SHA512_Update' function. */ -#undef HAVE_SHA512_UPDATE - -/* Define to 1 if you have the `shmget' function. */ -#undef HAVE_SHMGET - -/* Define to 1 if you have the `sigprocmask' function. */ -#undef HAVE_SIGPROCMASK - -/* Define to 1 if you have the `sleep' function. */ -#undef HAVE_SLEEP - -/* Define to 1 if you have the `snprintf' function. */ -#undef HAVE_SNPRINTF - -/* Define to 1 if you have the `socketpair' function. */ -#undef HAVE_SOCKETPAIR - -/* Using Solaris threads */ -#undef HAVE_SOLARIS_THREADS - -/* Define to 1 if you have the `srandom' function. */ -#undef HAVE_SRANDOM - -/* Define if you have the SSL libraries installed. */ -#undef HAVE_SSL - -/* Define to 1 if you have the `SSL_CTX_set_alpn_protos' function. */ -#undef HAVE_SSL_CTX_SET_ALPN_PROTOS - -/* Define to 1 if you have the `SSL_CTX_set_alpn_select_cb' function. */ -#undef HAVE_SSL_CTX_SET_ALPN_SELECT_CB - -/* Define to 1 if you have the `SSL_CTX_set_ciphersuites' function. */ -#undef HAVE_SSL_CTX_SET_CIPHERSUITES - -/* Define to 1 if you have the `SSL_CTX_set_security_level' function. */ -#undef HAVE_SSL_CTX_SET_SECURITY_LEVEL - -/* Define to 1 if you have the `SSL_CTX_set_tlsext_ticket_key_evp_cb' - function. */ -#undef HAVE_SSL_CTX_SET_TLSEXT_TICKET_KEY_EVP_CB - -/* Define to 1 if you have the `SSL_get0_alpn_selected' function. */ -#undef HAVE_SSL_GET0_ALPN_SELECTED - -/* Define to 1 if you have the `SSL_get0_peername' function. */ -#undef HAVE_SSL_GET0_PEERNAME - -/* Define to 1 if you have the `SSL_get1_peer_certificate' function. */ -#undef HAVE_SSL_GET1_PEER_CERTIFICATE - -/* Define to 1 if you have the `SSL_set1_host' function. */ -#undef HAVE_SSL_SET1_HOST - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDARG_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDBOOL_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDINT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDLIB_H - -/* Define to 1 if you have the `strftime' function. */ -#undef HAVE_STRFTIME - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRINGS_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRING_H - -/* Define to 1 if you have the `strlcat' function. */ -#undef HAVE_STRLCAT - -/* Define to 1 if you have the `strlcpy' function. */ -#undef HAVE_STRLCPY - -/* Define to 1 if you have the `strptime' function. */ -#undef HAVE_STRPTIME - -/* Define to 1 if you have the `strsep' function. */ -#undef HAVE_STRSEP - -/* Define to 1 if `ipi_spec_dst' is a member of `struct in_pktinfo'. */ -#undef HAVE_STRUCT_IN_PKTINFO_IPI_SPEC_DST - -/* Define to 1 if `sun_len' is a member of `struct sockaddr_un'. */ -#undef HAVE_STRUCT_SOCKADDR_UN_SUN_LEN - -/* Define if you have Swig libraries and header files. */ -#undef HAVE_SWIG - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYSLOG_H - -/* Define to 1 if systemd should be used */ -#undef HAVE_SYSTEMD - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_ENDIAN_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_IPC_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_PARAM_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_RESOURCE_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SELECT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SHA2_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SHM_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SOCKET_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_STAT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SYSCTL_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_TYPES_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_UIO_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_UN_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_WAIT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_TARGETCONDITIONALS_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_TIME_H - -/* Define to 1 if you have the `tzset' function. */ -#undef HAVE_TZSET - -/* Define to 1 if you have the header file. */ -#undef HAVE_UNISTD_H - -/* Define to 1 if you have the `usleep' function. */ -#undef HAVE_USLEEP - -/* Define to 1 if you have the `vfork' function. */ -#undef HAVE_VFORK - -/* Define to 1 if you have the header file. */ -#undef HAVE_VFORK_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_WINDOWS_H - -/* Using Windows threads */ -#undef HAVE_WINDOWS_THREADS - -/* Define to 1 if you have the header file. */ -#undef HAVE_WINSOCK2_H - -/* Define to 1 if `fork' works. */ -#undef HAVE_WORKING_FORK - -/* Define to 1 if `vfork' works. */ -#undef HAVE_WORKING_VFORK - -/* Define to 1 if you have the `writev' function. */ -#undef HAVE_WRITEV - -/* Define to 1 if you have the header file. */ -#undef HAVE_WS2TCPIP_H - -/* Define to 1 if you have the `X509_VERIFY_PARAM_set1_host' function. */ -#undef HAVE_X509_VERIFY_PARAM_SET1_HOST - -/* Define to 1 if you have the `_beginthreadex' function. */ -#undef HAVE__BEGINTHREADEX - -/* If HMAC_Init_ex() returns void */ -#undef HMAC_INIT_EX_RETURNS_VOID - -/* if lex has yylex_destroy */ -#undef LEX_HAS_YYLEX_DESTROY - -/* Define to the sub-directory where libtool stores uninstalled libraries. */ -#undef LT_OBJDIR - -/* Define to the maximum message length to pass to syslog. */ -#undef MAXSYSLOGMSGLEN - -/* Define if memcmp() does not compare unsigned bytes */ -#undef MEMCMP_IS_BROKEN - -/* Define if mkdir has one argument. */ -#undef MKDIR_HAS_ONE_ARG - -/* Define if the network stack does not fully support nonblocking io (causes - lower performance). */ -#undef NONBLOCKING_IS_BROKEN - -/* Put -D_ALL_SOURCE define in config.h */ -#undef OMITTED__D_ALL_SOURCE - -/* Put -D_BSD_SOURCE define in config.h */ -#undef OMITTED__D_BSD_SOURCE - -/* Put -D_DEFAULT_SOURCE define in config.h */ -#undef OMITTED__D_DEFAULT_SOURCE - -/* Put -D_GNU_SOURCE define in config.h */ -#undef OMITTED__D_GNU_SOURCE - -/* Put -D_LARGEFILE_SOURCE=1 define in config.h */ -#undef OMITTED__D_LARGEFILE_SOURCE_1 - -/* Put -D_POSIX_C_SOURCE=200112 define in config.h */ -#undef OMITTED__D_POSIX_C_SOURCE_200112 - -/* Put -D_XOPEN_SOURCE=600 define in config.h */ -#undef OMITTED__D_XOPEN_SOURCE_600 - -/* Put -D_XOPEN_SOURCE_EXTENDED=1 define in config.h */ -#undef OMITTED__D_XOPEN_SOURCE_EXTENDED_1 - -/* Put -D__EXTENSIONS__ define in config.h */ -#undef OMITTED__D__EXTENSIONS__ - -/* Define to the address where bug reports for this package should be sent. */ -#undef PACKAGE_BUGREPORT - -/* Define to the full name of this package. */ -#undef PACKAGE_NAME - -/* Define to the full name and version of this package. */ -#undef PACKAGE_STRING - -/* Define to the one symbol short name of this package. */ -#undef PACKAGE_TARNAME - -/* Define to the home page for this package. */ -#undef PACKAGE_URL - -/* Define to the version of this package. */ -#undef PACKAGE_VERSION - -/* default pidfile location */ -#undef PIDFILE - -/* Define to necessary symbol if this constant uses a non-standard name on - your system. */ -#undef PTHREAD_CREATE_JOINABLE - -/* Return type of signal handlers, but autoconf 2.70 says 'your code may - safely assume C89 semantics that RETSIGTYPE is void.' */ -#undef RETSIGTYPE - -/* if REUSEPORT is enabled by default */ -#undef REUSEPORT_DEFAULT - -/* default rootkey location */ -#undef ROOT_ANCHOR_FILE - -/* default rootcert location */ -#undef ROOT_CERT_FILE - -/* version number for resource files */ -#undef RSRC_PACKAGE_VERSION - -/* Directory to chdir to */ -#undef RUN_DIR - -/* Shared data */ -#undef SHARE_DIR - -/* The size of `pthread_t', as computed by sizeof. */ -#undef SIZEOF_PTHREAD_T - -/* The size of `size_t', as computed by sizeof. */ -#undef SIZEOF_SIZE_T - -/* The size of `time_t', as computed by sizeof. */ -#undef SIZEOF_TIME_T - -/* The size of `unsigned long', as computed by sizeof. */ -#undef SIZEOF_UNSIGNED_LONG - -/* define if (v)snprintf does not return length needed, (but length used) */ -#undef SNPRINTF_RET_BROKEN - -/* Define to 1 if libsodium supports sodium_set_misuse_handler */ -#undef SODIUM_MISUSE_HANDLER - -/* Define to 1 if you have the ANSI C header files. */ -#undef STDC_HEADERS - -/* use default strptime. */ -#undef STRPTIME_WORKS - -/* Use win32 resources and API */ -#undef UB_ON_WINDOWS - -/* the SYSLOG_FACILITY to use, default LOG_DAEMON */ -#undef UB_SYSLOG_FACILITY - -/* default username */ -#undef UB_USERNAME - -/* use to enable lightweight alloc assertions, for debug use */ -#undef UNBOUND_ALLOC_LITE - -/* use malloc not regions, for debug use */ -#undef UNBOUND_ALLOC_NONREGIONAL - -/* use statistics for allocs and frees, for debug use */ -#undef UNBOUND_ALLOC_STATS - -/* define this to enable debug checks. */ -#undef UNBOUND_DEBUG - -/* Define to 1 to use cachedb support */ -#undef USE_CACHEDB - -/* Define to 1 to enable dnscrypt support */ -#undef USE_DNSCRYPT - -/* Define to 1 to enable dnscrypt with xchacha20 support */ -#undef USE_DNSCRYPT_XCHACHA20 - -/* Define to 1 to enable dnstap support */ -#undef USE_DNSTAP - -/* Define this to enable DSA support. */ -#undef USE_DSA - -/* Define this to enable ECDSA support. */ -#undef USE_ECDSA - -/* Define this to enable an EVP workaround for older openssl */ -#undef USE_ECDSA_EVP_WORKAROUND - -/* Define this to enable ED25519 support. */ -#undef USE_ED25519 - -/* Define this to enable ED448 support. */ -#undef USE_ED448 - -/* Define this to enable GOST support. */ -#undef USE_GOST - -/* Define to 1 to use ipsecmod support. */ -#undef USE_IPSECMOD - -/* Define to 1 to use ipset support */ -#undef USE_IPSET - -/* Define if you enable libevent */ -#undef USE_LIBEVENT - -/* Define this to enable use of /proc/sys/net/ipv4/ip_local_port_range as a - default outgoing port range. This is only for the libunbound on Linux and - does not affect unbound resolving daemon itself. This may severely limit - the number of available outgoing ports and thus decrease randomness. Define - this only when the target system restricts (e.g. some of SELinux enabled - distributions) the use of non-ephemeral ports. */ -#undef USE_LINUX_IP_LOCAL_PORT_RANGE - -/* Define if you want to use internal select based events */ -#undef USE_MINI_EVENT - -/* Define this to enable client TCP Fast Open. */ -#undef USE_MSG_FASTOPEN - -/* Define this to enable client TCP Fast Open. */ -#undef USE_OSX_MSG_FASTOPEN - -/* Define this to use hiredis client. */ -#undef USE_REDIS - -/* Define this to enable SHA1 support. */ -#undef USE_SHA1 - -/* Define this to enable SHA256 and SHA512 support. */ -#undef USE_SHA2 - -/* Enable extensions on AIX 3, Interix. */ -#ifndef _ALL_SOURCE -# undef _ALL_SOURCE -#endif -/* Enable GNU extensions on systems that have them. */ -#ifndef _GNU_SOURCE -# undef _GNU_SOURCE -#endif -/* Enable threading extensions on Solaris. */ -#ifndef _POSIX_PTHREAD_SEMANTICS -# undef _POSIX_PTHREAD_SEMANTICS -#endif -/* Enable extensions on HP NonStop. */ -#ifndef _TANDEM_SOURCE -# undef _TANDEM_SOURCE -#endif -/* Enable general extensions on Solaris. */ -#ifndef __EXTENSIONS__ -# undef __EXTENSIONS__ -#endif - - -/* Define this to enable server TCP Fast Open. */ -#undef USE_TCP_FASTOPEN - -/* Whether the windows socket API is used */ -#undef USE_WINSOCK - -/* the version of the windows API enabled */ -#undef WINVER *** 502 LINES SKIPPED *** From nobody Wed Oct 4 01:02:37 2023 X-Original-To: dev-commits-src-branches@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 4S0byP61rPz4wJxy; Wed, 4 Oct 2023 01:02: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0byP5dgFz4YmC; Wed, 4 Oct 2023 01:02:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381357; 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=ouKCfhbLiC41UUXb/nYznGBn1fMXO7f/d1hOTLDRyKs=; b=Yjq1EJgCfqGzR/xwT8AbLCanB+t73QThpwrLSMP1YV/tbtzuzGw4EIt3VgabFYAFOL90QU 0vKpxWjT1FnKGZaX9MjHlTloxrCViwI4iukU3UuS15IaBdiPoOD+RcEkQk3SPRUqD7JzPH cMfJLwfn5YthHeBbcm8HnPC6wKi2M6EUzXXWQAXKkk1FmoYUBuRGROX6OXKSIhXEtOhVwN HXfSnTbN35dF8lSS/Z8Wl6/JoVGwUIHXYbuX8VyPtCGfsvvAFcOtDBIzwkpur/f0iuf+th JDOBo82RVfzq7jFPMKTsgYWborW6lEjjclehogg1KvdnrcCGLdEY7iK9fQT5wQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696381357; a=rsa-sha256; cv=none; b=JmYzKgzNmp1S0tTBCqH8a9UyGCbyN/6/wdP4maxHWes2TPs2OzxE1yTvEFPHyur86ea5J5 yDQABrlCN4brqcpEaRdr0/m+wXQ2DTyilnWsTyHwbQ7BN2n84R8FaZNjclDPGUFCXFLJ30 8dggaR/vylMPfht/ScVZeeU2S+HskkoiWtuO6Hd+LCNyKhkExEk7ND8BznVN7H8bNEue+2 ESlJoS0jltl3IFp4dq34Ee8TFIqnogV5rVmRFzWGGqMIXS4wheG3qWALvwQ8kVyrBEjGOB Xop3Qwny2BGBNB3xqIA3nTG/u0i7HcX198vq8YTfOD176yoIjlXcVMTruAyvwA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381357; 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=ouKCfhbLiC41UUXb/nYznGBn1fMXO7f/d1hOTLDRyKs=; b=B+Q13x5sgScE5cYBzLlOVX1xiVOLsH0I6D92TPEW+EyvHIbDwKd9q7SN1Ai5YrwRUtdOGC DoY8LYRhhSrptbn9QdoYts1o2PPfnxnd1n5qXBcsQhltT8MyxiQqHSLKbooHOOU+XIUP7Y MXCQljU15oVwqGzcyH9YUX6IH4HGuV19zPGHVu3zdKmhH3JsAZFS89PyBwMqIauHug2Zah XUxn2SCN6xLpzP8+QerdP+MmexHSQCApgLLSCjOWl6lTu3BHXR3I5X3wIzO6VdAnEXzo6q yFzs9BaH28A5uP2974RdzOGuCeAZCAsqZAE4PXbnqIBnztVsXeKXJPmoltdXJg== 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 4S0byP4PgMz2Td; Wed, 4 Oct 2023 01:02:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39412blK054039; Wed, 4 Oct 2023 01:02:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39412bYe054036; Wed, 4 Oct 2023 01:02:37 GMT (envelope-from git) Date: Wed, 4 Oct 2023 01:02:37 GMT Message-Id: <202310040102.39412bYe054036@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Cy Schubert Subject: git: b607e17bca24 - stable/12 - sqlite3: Vendor import of sqlite3 3.43.1 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: b607e17bca2490bd6ab14ee3ee23e95032c21e24 Auto-Submitted: auto-generated The branch stable/12 has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=b607e17bca2490bd6ab14ee3ee23e95032c21e24 commit b607e17bca2490bd6ab14ee3ee23e95032c21e24 Author: Cy Schubert AuthorDate: 2023-09-19 15:06:50 +0000 Commit: Cy Schubert CommitDate: 2023-10-03 02:01:06 +0000 sqlite3: Vendor import of sqlite3 3.43.1 Release notes at https://www.sqlite.org/releaselog/3_43_1.html. Obtained from: https://www.sqlite.org/2023/sqlite-autoconf-3430100.tar.gz Merge commit 'fa2bb1440e13602676feec708ac7a9a3bb5ce5c8' into main (cherry picked from commit ec994981447e8a974426660b5071bc405280af73) --- contrib/sqlite3/Makefile.am | 2 +- contrib/sqlite3/Makefile.in | 2 +- contrib/sqlite3/Makefile.msc | 27 + contrib/sqlite3/configure | 20 +- contrib/sqlite3/configure.ac | 2 +- contrib/sqlite3/shell.c | 1019 +++- contrib/sqlite3/sqlite3.1 | 161 +- contrib/sqlite3/sqlite3.c | 7881 +++++++++++++++++++++--------- contrib/sqlite3/sqlite3.h | 106 +- contrib/sqlite3/sqlite3ext.h | 4 + contrib/sqlite3/sqlite3rc.h | 2 +- contrib/sqlite3/tea/configure | 20 +- contrib/sqlite3/tea/configure.ac | 2 +- contrib/sqlite3/tea/generic/tclsqlite3.c | 33 +- 14 files changed, 6509 insertions(+), 2772 deletions(-) diff --git a/contrib/sqlite3/Makefile.am b/contrib/sqlite3/Makefile.am index 694419b27dfd..1eaa560ff884 100644 --- a/contrib/sqlite3/Makefile.am +++ b/contrib/sqlite3/Makefile.am @@ -9,7 +9,7 @@ sqlite3_SOURCES = shell.c sqlite3.h EXTRA_sqlite3_SOURCES = sqlite3.c sqlite3_LDADD = @EXTRA_SHELL_OBJ@ @READLINE_LIBS@ sqlite3_DEPENDENCIES = @EXTRA_SHELL_OBJ@ -sqlite3_CFLAGS = $(AM_CFLAGS) -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_ENABLE_STMTVTAB -DSQLITE_ENABLE_DBSTAT_VTAB $(SHELL_CFLAGS) +sqlite3_CFLAGS = $(AM_CFLAGS) -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_DQS=0 -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_ENABLE_STMTVTAB -DSQLITE_ENABLE_DBSTAT_VTAB $(SHELL_CFLAGS) include_HEADERS = sqlite3.h sqlite3ext.h diff --git a/contrib/sqlite3/Makefile.in b/contrib/sqlite3/Makefile.in index d45c6b8f4cde..fe708a0a9d84 100644 --- a/contrib/sqlite3/Makefile.in +++ b/contrib/sqlite3/Makefile.in @@ -371,7 +371,7 @@ sqlite3_SOURCES = shell.c sqlite3.h EXTRA_sqlite3_SOURCES = sqlite3.c sqlite3_LDADD = @EXTRA_SHELL_OBJ@ @READLINE_LIBS@ sqlite3_DEPENDENCIES = @EXTRA_SHELL_OBJ@ -sqlite3_CFLAGS = $(AM_CFLAGS) -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_ENABLE_STMTVTAB -DSQLITE_ENABLE_DBSTAT_VTAB $(SHELL_CFLAGS) +sqlite3_CFLAGS = $(AM_CFLAGS) -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_DQS=0 -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_ENABLE_STMTVTAB -DSQLITE_ENABLE_DBSTAT_VTAB $(SHELL_CFLAGS) include_HEADERS = sqlite3.h sqlite3ext.h EXTRA_DIST = sqlite3.1 tea Makefile.msc sqlite3.rc sqlite3rc.h README.txt Replace.cs Makefile.fallback pkgconfigdir = ${libdir}/pkgconfig diff --git a/contrib/sqlite3/Makefile.msc b/contrib/sqlite3/Makefile.msc index 09daa867eced..13663d877757 100644 --- a/contrib/sqlite3/Makefile.msc +++ b/contrib/sqlite3/Makefile.msc @@ -52,6 +52,13 @@ MINIMAL_AMALGAMATION = 0 USE_STDCALL = 0 !ENDIF +# Set this non-0 to use structured exception handling (SEH) for WAL mode +# in the core library. +# +!IFNDEF USE_SEH +USE_SEH = 1 +!ENDIF + # Set this non-0 to have the shell executable link against the core dynamic # link library. # @@ -180,6 +187,12 @@ WIN32HEAP = 0 OSTRACE = 0 !ENDIF +# enable address sanitizer using ASAN=1 on the command-line. +# +!IFNDEF ASAN +ASAN = 0 +!ENDIF + # Set this to one of the following values to enable various debugging # features. Each level includes the debugging options from the previous # levels. Currently, the recognized values for DEBUG are: @@ -311,6 +324,13 @@ OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_ENABLE_MATH_FUNCTIONS OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_ENABLE_RBU=1 !ENDIF +# Should structured exception handling (SEH) be enabled for WAL mode in +# the core library? +# +!IF $(USE_SEH)!=0 +OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_USE_SEH=1 +!ENDIF + # These are the "extended" SQLite compilation options used when compiling for # the Windows 10 platform. # @@ -718,6 +738,13 @@ RCC = $(RCC) -DSQLITE_WIN32_MALLOC_VALIDATE=1 !ENDIF +# Address sanitizer if ASAN=1 +# +!IF $(ASAN)>0 +TCC = $(TCC) /fsanitize=address +!ENDIF + + # Compiler options needed for programs that use the readline() library. # !IFNDEF READLINE_FLAGS diff --git a/contrib/sqlite3/configure b/contrib/sqlite3/configure index 1016e350c37f..39694c06793b 100755 --- a/contrib/sqlite3/configure +++ b/contrib/sqlite3/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.71 for sqlite 3.42.0. +# Generated by GNU Autoconf 2.71 for sqlite 3.43.1. # # Report bugs to . # @@ -621,8 +621,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='sqlite' PACKAGE_TARNAME='sqlite' -PACKAGE_VERSION='3.42.0' -PACKAGE_STRING='sqlite 3.42.0' +PACKAGE_VERSION='3.43.1' +PACKAGE_STRING='sqlite 3.43.1' PACKAGE_BUGREPORT='http://www.sqlite.org' PACKAGE_URL='' @@ -1367,7 +1367,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures sqlite 3.42.0 to adapt to many kinds of systems. +\`configure' configures sqlite 3.43.1 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1438,7 +1438,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of sqlite 3.42.0:";; + short | recursive ) echo "Configuration of sqlite 3.43.1:";; esac cat <<\_ACEOF @@ -1563,7 +1563,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -sqlite configure 3.42.0 +sqlite configure 3.43.1 generated by GNU Autoconf 2.71 Copyright (C) 2021 Free Software Foundation, Inc. @@ -1833,7 +1833,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by sqlite $as_me 3.42.0, which was +It was created by sqlite $as_me 3.43.1, which was generated by GNU Autoconf 2.71. Invocation command line was $ $0$ac_configure_args_raw @@ -3106,7 +3106,7 @@ fi # Define the identity of the package. PACKAGE='sqlite' - VERSION='3.42.0' + VERSION='3.43.1' printf "%s\n" "#define PACKAGE \"$PACKAGE\"" >>confdefs.h @@ -15314,7 +15314,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by sqlite $as_me 3.42.0, which was +This file was extended by sqlite $as_me 3.43.1, which was generated by GNU Autoconf 2.71. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -15373,7 +15373,7 @@ ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config='$ac_cs_config_escaped' ac_cs_version="\\ -sqlite config.status 3.42.0 +sqlite config.status 3.43.1 configured by $0, generated by GNU Autoconf 2.71, with options \\"\$ac_cs_config\\" diff --git a/contrib/sqlite3/configure.ac b/contrib/sqlite3/configure.ac index a706a4753049..3d7da8b984c3 100644 --- a/contrib/sqlite3/configure.ac +++ b/contrib/sqlite3/configure.ac @@ -10,7 +10,7 @@ # AC_PREREQ(2.61) -AC_INIT(sqlite, 3.42.0, http://www.sqlite.org) +AC_INIT(sqlite, 3.43.1, http://www.sqlite.org) AC_CONFIG_SRCDIR([sqlite3.c]) AC_CONFIG_AUX_DIR([.]) diff --git a/contrib/sqlite3/shell.c b/contrib/sqlite3/shell.c index 647a214226cc..6b2cdca83d6b 100644 --- a/contrib/sqlite3/shell.c +++ b/contrib/sqlite3/shell.c @@ -246,6 +246,7 @@ typedef unsigned char u8; #if SQLITE_OS_WINRT #include #endif +#undef WIN32_LEAN_AND_MEAN #define WIN32_LEAN_AND_MEAN #include @@ -1224,6 +1225,46 @@ static char *shellFakeSchema( return s.z; } +/* +** SQL function: strtod(X) +** +** Use the C-library strtod() function to convert string X into a double. +** Used for comparing the accuracy of SQLite's internal text-to-float conversion +** routines against the C-library. +*/ +static void shellStrtod( + sqlite3_context *pCtx, + int nVal, + sqlite3_value **apVal +){ + char *z = (char*)sqlite3_value_text(apVal[0]); + UNUSED_PARAMETER(nVal); + if( z==0 ) return; + sqlite3_result_double(pCtx, strtod(z,0)); +} + +/* +** SQL function: dtostr(X) +** +** Use the C-library printf() function to convert real value X into a string. +** Used for comparing the accuracy of SQLite's internal float-to-text conversion +** routines against the C-library. +*/ +static void shellDtostr( + sqlite3_context *pCtx, + int nVal, + sqlite3_value **apVal +){ + double r = sqlite3_value_double(apVal[0]); + int n = nVal>=2 ? sqlite3_value_int(apVal[1]) : 26; + char z[400]; + if( n<1 ) n = 1; + if( n>350 ) n = 350; + sprintf(z, "%#+.*e", n, r); + sqlite3_result_text(pCtx, z, -1, SQLITE_TRANSIENT); +} + + /* ** SQL function: shell_module_schema(X) ** @@ -1473,7 +1514,7 @@ struct DIR { #endif /* -** Provide the function prototype for the POSIX compatiable getenv() +** Provide the function prototype for the POSIX compatible getenv() ** function. This function is not thread-safe. */ @@ -1799,6 +1840,188 @@ int sqlite3MemTraceDeactivate(void){ } /************************* End ../ext/misc/memtrace.c ********************/ +/************************* Begin ../ext/misc/pcachetrace.c ******************/ +/* +** 2023-06-21 +** +** The author disclaims copyright to this source code. In place of +** a legal notice, here is a blessing: +** +** May you do good and not evil. +** May you find forgiveness for yourself and forgive others. +** May you share freely, never taking more than you give. +** +************************************************************************* +** +** This file implements an extension that uses the SQLITE_CONFIG_PCACHE2 +** mechanism to add a tracing layer on top of pluggable page cache of +** SQLite. If this extension is registered prior to sqlite3_initialize(), +** it will cause all page cache activities to be logged on standard output, +** or to some other FILE specified by the initializer. +** +** This file needs to be compiled into the application that uses it. +** +** This extension is used to implement the --pcachetrace option of the +** command-line shell. +*/ +#include +#include +#include + +/* The original page cache routines */ +static sqlite3_pcache_methods2 pcacheBase; +static FILE *pcachetraceOut; + +/* Methods that trace pcache activity */ +static int pcachetraceInit(void *pArg){ + int nRes; + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xInit(%p)\n", pArg); + } + nRes = pcacheBase.xInit(pArg); + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xInit(%p) -> %d\n", pArg, nRes); + } + return nRes; +} +static void pcachetraceShutdown(void *pArg){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xShutdown(%p)\n", pArg); + } + pcacheBase.xShutdown(pArg); +} +static sqlite3_pcache *pcachetraceCreate(int szPage, int szExtra, int bPurge){ + sqlite3_pcache *pRes; + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xCreate(%d,%d,%d)\n", + szPage, szExtra, bPurge); + } + pRes = pcacheBase.xCreate(szPage, szExtra, bPurge); + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xCreate(%d,%d,%d) -> %p\n", + szPage, szExtra, bPurge, pRes); + } + return pRes; +} +static void pcachetraceCachesize(sqlite3_pcache *p, int nCachesize){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xCachesize(%p, %d)\n", p, nCachesize); + } + pcacheBase.xCachesize(p, nCachesize); +} +static int pcachetracePagecount(sqlite3_pcache *p){ + int nRes; + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xPagecount(%p)\n", p); + } + nRes = pcacheBase.xPagecount(p); + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xPagecount(%p) -> %d\n", p, nRes); + } + return nRes; +} +static sqlite3_pcache_page *pcachetraceFetch( + sqlite3_pcache *p, + unsigned key, + int crFg +){ + sqlite3_pcache_page *pRes; + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xFetch(%p,%u,%d)\n", p, key, crFg); + } + pRes = pcacheBase.xFetch(p, key, crFg); + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xFetch(%p,%u,%d) -> %p\n", + p, key, crFg, pRes); + } + return pRes; +} +static void pcachetraceUnpin( + sqlite3_pcache *p, + sqlite3_pcache_page *pPg, + int bDiscard +){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xUnpin(%p, %p, %d)\n", + p, pPg, bDiscard); + } + pcacheBase.xUnpin(p, pPg, bDiscard); +} +static void pcachetraceRekey( + sqlite3_pcache *p, + sqlite3_pcache_page *pPg, + unsigned oldKey, + unsigned newKey +){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xRekey(%p, %p, %u, %u)\n", + p, pPg, oldKey, newKey); + } + pcacheBase.xRekey(p, pPg, oldKey, newKey); +} +static void pcachetraceTruncate(sqlite3_pcache *p, unsigned n){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xTruncate(%p, %u)\n", p, n); + } + pcacheBase.xTruncate(p, n); +} +static void pcachetraceDestroy(sqlite3_pcache *p){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xDestroy(%p)\n", p); + } + pcacheBase.xDestroy(p); +} +static void pcachetraceShrink(sqlite3_pcache *p){ + if( pcachetraceOut ){ + fprintf(pcachetraceOut, "PCACHETRACE: xShrink(%p)\n", p); + } + pcacheBase.xShrink(p); +} + +/* The substitute pcache methods */ +static sqlite3_pcache_methods2 ersaztPcacheMethods = { + 0, + 0, + pcachetraceInit, + pcachetraceShutdown, + pcachetraceCreate, + pcachetraceCachesize, + pcachetracePagecount, + pcachetraceFetch, + pcachetraceUnpin, + pcachetraceRekey, + pcachetraceTruncate, + pcachetraceDestroy, + pcachetraceShrink +}; + +/* Begin tracing memory allocations to out. */ +int sqlite3PcacheTraceActivate(FILE *out){ + int rc = SQLITE_OK; + if( pcacheBase.xFetch==0 ){ + rc = sqlite3_config(SQLITE_CONFIG_GETPCACHE2, &pcacheBase); + if( rc==SQLITE_OK ){ + rc = sqlite3_config(SQLITE_CONFIG_PCACHE2, &ersaztPcacheMethods); + } + } + pcachetraceOut = out; + return rc; +} + +/* Deactivate memory tracing */ +int sqlite3PcacheTraceDeactivate(void){ + int rc = SQLITE_OK; + if( pcacheBase.xFetch!=0 ){ + rc = sqlite3_config(SQLITE_CONFIG_PCACHE2, &pcacheBase); + if( rc==SQLITE_OK ){ + memset(&pcacheBase, 0, sizeof(pcacheBase)); + } + } + pcachetraceOut = 0; + return rc; +} + +/************************* End ../ext/misc/pcachetrace.c ********************/ /************************* Begin ../ext/misc/shathree.c ******************/ /* ** 2017-03-08 @@ -2683,41 +2906,24 @@ static void decimal_free(Decimal *p){ } /* -** Allocate a new Decimal object. Initialize it to the number given -** by the input string. +** Allocate a new Decimal object initialized to the text in zIn[]. +** Return NULL if any kind of error occurs. */ -static Decimal *decimal_new( - sqlite3_context *pCtx, - sqlite3_value *pIn, - int nAlt, - const unsigned char *zAlt -){ - Decimal *p; - int n, i; - const unsigned char *zIn; +static Decimal *decimalNewFromText(const char *zIn, int n){ + Decimal *p = 0; + int i; int iExp = 0; + p = sqlite3_malloc( sizeof(*p) ); - if( p==0 ) goto new_no_mem; + if( p==0 ) goto new_from_text_failed; p->sign = 0; p->oom = 0; p->isInit = 1; p->isNull = 0; p->nDigit = 0; p->nFrac = 0; - if( zAlt ){ - n = nAlt, - zIn = zAlt; - }else{ - if( sqlite3_value_type(pIn)==SQLITE_NULL ){ - p->a = 0; - p->isNull = 1; - return p; - } - n = sqlite3_value_bytes(pIn); - zIn = sqlite3_value_text(pIn); - } p->a = sqlite3_malloc64( n+1 ); - if( p->a==0 ) goto new_no_mem; + if( p->a==0 ) goto new_from_text_failed; for(i=0; isspace(zIn[i]); i++){} if( zIn[i]=='-' ){ p->sign = 1; @@ -2768,7 +2974,7 @@ static Decimal *decimal_new( } if( iExp>0 ){ p->a = sqlite3_realloc64(p->a, p->nDigit + iExp + 1 ); - if( p->a==0 ) goto new_no_mem; + if( p->a==0 ) goto new_from_text_failed; memset(p->a+p->nDigit, 0, iExp); p->nDigit += iExp; } @@ -2787,7 +2993,7 @@ static Decimal *decimal_new( } if( iExp>0 ){ p->a = sqlite3_realloc64(p->a, p->nDigit + iExp + 1 ); - if( p->a==0 ) goto new_no_mem; + if( p->a==0 ) goto new_from_text_failed; memmove(p->a+iExp, p->a, p->nDigit); memset(p->a, 0, iExp); p->nDigit += iExp; @@ -2796,7 +3002,76 @@ static Decimal *decimal_new( } return p; -new_no_mem: +new_from_text_failed: + if( p ){ + if( p->a ) sqlite3_free(p->a); + sqlite3_free(p); + } + return 0; +} + +/* Forward reference */ +static Decimal *decimalFromDouble(double); + +/* +** Allocate a new Decimal object from an sqlite3_value. Return a pointer +** to the new object, or NULL if there is an error. If the pCtx argument +** is not NULL, then errors are reported on it as well. +** +** If the pIn argument is SQLITE_TEXT or SQLITE_INTEGER, it is converted +** directly into a Decimal. For SQLITE_FLOAT or for SQLITE_BLOB of length +** 8 bytes, the resulting double value is expanded into its decimal equivalent. +** If pIn is NULL or if it is a BLOB that is not exactly 8 bytes in length, +** then NULL is returned. +*/ +static Decimal *decimal_new( + sqlite3_context *pCtx, /* Report error here, if not null */ + sqlite3_value *pIn, /* Construct the decimal object from this */ + int bTextOnly /* Always interpret pIn as text if true */ +){ + Decimal *p = 0; + int eType = sqlite3_value_type(pIn); + if( bTextOnly && (eType==SQLITE_FLOAT || eType==SQLITE_BLOB) ){ + eType = SQLITE_TEXT; + } + switch( eType ){ + case SQLITE_TEXT: + case SQLITE_INTEGER: { + const char *zIn = (const char*)sqlite3_value_text(pIn); + int n = sqlite3_value_bytes(pIn); + p = decimalNewFromText(zIn, n); + if( p==0 ) goto new_failed; + break; + } + + case SQLITE_FLOAT: { + p = decimalFromDouble(sqlite3_value_double(pIn)); + break; + } + + case SQLITE_BLOB: { + const unsigned char *x; + unsigned int i; + sqlite3_uint64 v = 0; + double r; + + if( sqlite3_value_bytes(pIn)!=sizeof(r) ) break; + x = sqlite3_value_blob(pIn); + for(i=0; ioom ){ + sqlite3_result_error_nomem(pCtx); + return; + } + if( p->isNull ){ + sqlite3_result_null(pCtx); + return; + } + for(nDigit=p->nDigit; nDigit>0 && p->a[nDigit-1]==0; nDigit--){} + for(nZero=0; nZeroa[nZero]==0; nZero++){} + nFrac = p->nFrac + (nDigit - p->nDigit); + nDigit -= nZero; + z = sqlite3_malloc( nDigit+20 ); + if( z==0 ){ + sqlite3_result_error_nomem(pCtx); + return; + } + if( nDigit==0 ){ + zero = 0; + a = &zero; + nDigit = 1; + nFrac = 0; + }else{ + a = &p->a[nZero]; + } + if( p->sign && nDigit>0 ){ + z[0] = '-'; + }else{ + z[0] = '+'; + } + z[1] = a[0]+'0'; + z[2] = '.'; + if( nDigit==1 ){ + z[3] = '0'; + i = 4; + }else{ + for(i=1; iisNull ) goto cmp_done; - pB = decimal_new(context, argv[1], 0, 0); + pB = decimal_new(context, argv[1], 1); if( pB==0 || pB->isNull ) goto cmp_done; rc = decimal_cmp(pA, pB); if( rc<0 ) rc = -1; @@ -2963,7 +3283,7 @@ static void decimal_expand(Decimal *p, int nDigit, int nFrac){ } /* -** Add the value pB into pA. +** Add the value pB into pA. A := A + B. ** ** Both pA and pB might become denormalized by this routine. */ @@ -3032,6 +3352,172 @@ static void decimal_add(Decimal *pA, Decimal *pB){ } } +/* +** Multiply A by B. A := A * B +** +** All significant digits after the decimal point are retained. +** Trailing zeros after the decimal point are omitted as long as +** the number of digits after the decimal point is no less than +** either the number of digits in either input. +*/ +static void decimalMul(Decimal *pA, Decimal *pB){ + signed char *acc = 0; + int i, j, k; + int minFrac; + + if( pA==0 || pA->oom || pA->isNull + || pB==0 || pB->oom || pB->isNull + ){ + goto mul_end; + } + acc = sqlite3_malloc64( pA->nDigit + pB->nDigit + 2 ); + if( acc==0 ){ + pA->oom = 1; + goto mul_end; + } + memset(acc, 0, pA->nDigit + pB->nDigit + 2); + minFrac = pA->nFrac; + if( pB->nFracnFrac; + for(i=pA->nDigit-1; i>=0; i--){ + signed char f = pA->a[i]; + int carry = 0, x; + for(j=pB->nDigit-1, k=i+j+3; j>=0; j--, k--){ + x = acc[k] + f*pB->a[j] + carry; + acc[k] = x%10; + carry = x/10; + } + x = acc[k] + carry; + acc[k] = x%10; + acc[k-1] += x/10; + } + sqlite3_free(pA->a); + pA->a = acc; + acc = 0; + pA->nDigit += pB->nDigit + 2; + pA->nFrac += pB->nFrac; + pA->sign ^= pB->sign; + while( pA->nFrac>minFrac && pA->a[pA->nDigit-1]==0 ){ + pA->nFrac--; + pA->nDigit--; + } + +mul_end: + sqlite3_free(acc); +} + +/* +** Create a new Decimal object that contains an integer power of 2. +*/ +static Decimal *decimalPow2(int N){ + Decimal *pA = 0; /* The result to be returned */ + Decimal *pX = 0; /* Multiplier */ + if( N<-20000 || N>20000 ) goto pow2_fault; + pA = decimalNewFromText("1.0", 3); + if( pA==0 || pA->oom ) goto pow2_fault; + if( N==0 ) return pA; + if( N>0 ){ + pX = decimalNewFromText("2.0", 3); + }else{ + N = -N; + pX = decimalNewFromText("0.5", 3); + } + if( pX==0 || pX->oom ) goto pow2_fault; + while( 1 /* Exit by break */ ){ + if( N & 1 ){ + decimalMul(pA, pX); + if( pA->oom ) goto pow2_fault; + } + N >>= 1; + if( N==0 ) break; + decimalMul(pX, pX); + } + decimal_free(pX); + return pA; + +pow2_fault: + decimal_free(pA); + decimal_free(pX); + return 0; +} + +/* +** Use an IEEE754 binary64 ("double") to generate a new Decimal object. +*/ +static Decimal *decimalFromDouble(double r){ + sqlite3_int64 m, a; + int e; + int isNeg; + Decimal *pA; + Decimal *pX; + char zNum[100]; + if( r<0.0 ){ + isNeg = 1; + r = -r; + }else{ + isNeg = 0; + } + memcpy(&a,&r,sizeof(a)); + if( a==0 ){ + e = 0; + m = 0; + }else{ + e = a>>52; + m = a & ((((sqlite3_int64)1)<<52)-1); + if( e==0 ){ + m <<= 1; + }else{ + m |= ((sqlite3_int64)1)<<52; + } + while( e<1075 && m>0 && (m&1)==0 ){ + m >>= 1; + e++; + } + if( isNeg ) m = -m; + e = e - 1075; + if( e>971 ){ + return 0; /* A NaN or an Infinity */ + } + } + + /* At this point m is the integer significand and e is the exponent */ + sqlite3_snprintf(sizeof(zNum), zNum, "%lld", m); + pA = decimalNewFromText(zNum, (int)strlen(zNum)); + pX = decimalPow2(e); + decimalMul(pA, pX); + decimal_free(pX); + return pA; +} + +/* +** SQL Function: decimal(X) +** OR: decimal_exp(X) +** +** Convert input X into decimal and then back into text. +** +** If X is originally a float, then a full decimal expansion of that floating +** point value is done. Or if X is an 8-byte blob, it is interpreted +** as a float and similarly expanded. +** +** The decimal_exp(X) function returns the result in exponential notation. +** decimal(X) returns a complete decimal, without the e+NNN at the end. +*/ +static void decimalFunc( + sqlite3_context *context, + int argc, + sqlite3_value **argv +){ + Decimal *p = decimal_new(context, argv[0], 0); + UNUSED_PARAMETER(argc); + if( p ){ + if( sqlite3_user_data(context)!=0 ){ + decimal_result_sci(context, p); + }else{ + decimal_result(context, p); + } + decimal_free(p); + } +} + /* ** Compare text in decimal order. */ @@ -3042,8 +3528,8 @@ static int decimalCollFunc( ){ const unsigned char *zA = (const unsigned char*)pKey1; const unsigned char *zB = (const unsigned char*)pKey2; - Decimal *pA = decimal_new(0, 0, nKey1, zA); - Decimal *pB = decimal_new(0, 0, nKey2, zB); + Decimal *pA = decimalNewFromText((const char*)zA, nKey1); + Decimal *pB = decimalNewFromText((const char*)zB, nKey2); int rc; UNUSED_PARAMETER(notUsed); if( pA==0 || pB==0 ){ @@ -3068,8 +3554,8 @@ static void decimalAddFunc( int argc, sqlite3_value **argv ){ - Decimal *pA = decimal_new(context, argv[0], 0, 0); - Decimal *pB = decimal_new(context, argv[1], 0, 0); + Decimal *pA = decimal_new(context, argv[0], 1); + Decimal *pB = decimal_new(context, argv[1], 1); UNUSED_PARAMETER(argc); decimal_add(pA, pB); decimal_result(context, pA); @@ -3081,8 +3567,8 @@ static void decimalSubFunc( int argc, sqlite3_value **argv ){ - Decimal *pA = decimal_new(context, argv[0], 0, 0); - Decimal *pB = decimal_new(context, argv[1], 0, 0); + Decimal *pA = decimal_new(context, argv[0], 1); + Decimal *pB = decimal_new(context, argv[1], 1); UNUSED_PARAMETER(argc); if( pB ){ pB->sign = !pB->sign; @@ -3120,7 +3606,7 @@ static void decimalSumStep( p->nFrac = 0; } if( sqlite3_value_type(argv[0])==SQLITE_NULL ) return; - pArg = decimal_new(context, argv[0], 0, 0); + pArg = decimal_new(context, argv[0], 1); decimal_add(p, pArg); decimal_free(pArg); } @@ -3135,7 +3621,7 @@ static void decimalSumInverse( p = sqlite3_aggregate_context(context, sizeof(*p)); if( p==0 ) return; if( sqlite3_value_type(argv[0])==SQLITE_NULL ) return; - pArg = decimal_new(context, argv[0], 0, 0); + pArg = decimal_new(context, argv[0], 1); if( pArg ) pArg->sign = !pArg->sign; decimal_add(p, pArg); decimal_free(pArg); @@ -3156,66 +3642,49 @@ static void decimalSumFinalize(sqlite3_context *context){ ** SQL Function: decimal_mul(X, Y) ** ** Return the product of X and Y. -** -** All significant digits after the decimal point are retained. -** Trailing zeros after the decimal point are omitted as long as -** the number of digits after the decimal point is no less than -** either the number of digits in either input. */ static void decimalMulFunc( sqlite3_context *context, int argc, sqlite3_value **argv ){ - Decimal *pA = decimal_new(context, argv[0], 0, 0); - Decimal *pB = decimal_new(context, argv[1], 0, 0); - signed char *acc = 0; - int i, j, k; - int minFrac; + Decimal *pA = decimal_new(context, argv[0], 1); + Decimal *pB = decimal_new(context, argv[1], 1); UNUSED_PARAMETER(argc); if( pA==0 || pA->oom || pA->isNull || pB==0 || pB->oom || pB->isNull ){ goto mul_end; } - acc = sqlite3_malloc64( pA->nDigit + pB->nDigit + 2 ); - if( acc==0 ){ - sqlite3_result_error_nomem(context); + decimalMul(pA, pB); + if( pA->oom ){ goto mul_end; } - memset(acc, 0, pA->nDigit + pB->nDigit + 2); - minFrac = pA->nFrac; - if( pB->nFracnFrac; - for(i=pA->nDigit-1; i>=0; i--){ - signed char f = pA->a[i]; - int carry = 0, x; *** 15446 LINES SKIPPED *** From nobody Wed Oct 4 01:02:38 2023 X-Original-To: dev-commits-src-branches@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 4S0byR1jxvz4wK3h; Wed, 4 Oct 2023 01:02: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0byR0ldDz4YmX; Wed, 4 Oct 2023 01:02:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381359; 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=N97iUOcZ//5VQDAOHBPRcSqaW7qdmiTjhUzFaB8/f0o=; b=QqDrr1k/VEDuE1KVwmAB8u57gmFXBzp3XZDdhYojY10ztPNcSbJ3ZYpMiUdo5E17n3saWV Zw5wDECxUNtQL+r3l1WoKw+ZftFTuBqNgmzA3w1IOMUTRgw2+RaXFBhOh1g1wjV5rj+Vlh ihphztkrgTMZn5mnEw4bnFj+JsesRvsBs0AsO9lPtCXfXTFll98C7Go3rNO4NWGRske5KW y4A4bwZs1BdPc31PSn8QM6CIUIDxhRjqjqdkPGvY4p+8Ybv1rRUbSKPGPt6DoCVK+GlkZ6 6jDRUziXTKpiAuDpYlY0DNPqaI7PLoXSjJKYaPr+kL1AfD/5asmNzxyRsnixLA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696381359; a=rsa-sha256; cv=none; b=q83meDIHmrhd7RllfpK0ijdeNQtlhsHl1c5gcx38cjtzTZZfXvPMynrHyKbnQq07vbIiUs ohXU4QHJaxUnsvQ/9E2VwlNkP8WQu+JUb+Uql6ojonwWnxPe3Ay156U4TtqrIHxnm/HRV6 IE0s69uqt+EucZqrWltTr0JgmiE6WSDz4q72jOvi5ZqRSRJ8uVtvL8xPdF89dgU/ecZday ra/O18EN9T6rZNam+KYzmaru8qBLO4jZax2taCoDydkHMYdZuxqP8UnWQQtIHL4SeQtKL3 qPhRjW8ccSqSA99cmzDlJXk80ZEguZryBtQtb//+GUADxEABc1E6iSF8XobGiA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381359; 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=N97iUOcZ//5VQDAOHBPRcSqaW7qdmiTjhUzFaB8/f0o=; b=Zm49MP53jGe+Ff40zDL2unlT6hqvmywd85aiytFx5x3Q1VmJexy3/XmyuF0B8tmjs1Vhvr GIOy+W4EbdK4R5s5Sa9mBNeVmZcsvLeycGZaZWtTgpuVCCPVscqCsCxRdiVpaZ2WheOlVc csxFz6BSoGb5VX3hRzMqMJxpKVRfS3dc634Bwex/XAG+X375d6NApoBbuz/I+SRwDtNIbo vKOyB8Wa2BXVDmCHeK5jtPDm6nuJUi9L4lgR1+RJBp3Pv4jYLoHqS26cekjvX9OSfalr91 xplr9LxuMUhJ+JmJEtpB59WdLQLDu6++s+6TWM149gMOYR5BuOQ5zopd0wXVwg== 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 4S0byQ6sgdz2fT; Wed, 4 Oct 2023 01:02:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39412cfp054083; Wed, 4 Oct 2023 01:02:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39412clW054079; Wed, 4 Oct 2023 01:02:38 GMT (envelope-from git) Date: Wed, 4 Oct 2023 01:02:38 GMT Message-Id: <202310040102.39412clW054079@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Cy Schubert Subject: git: 8ac4404ce27b - stable/12 - unbound: Vendor import 1.18.0 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: 8ac4404ce27b180cca79e5e6e188616bbf30b2c5 Auto-Submitted: auto-generated The branch stable/12 has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=8ac4404ce27b180cca79e5e6e188616bbf30b2c5 commit 8ac4404ce27b180cca79e5e6e188616bbf30b2c5 Author: Cy Schubert AuthorDate: 2023-09-19 04:17:09 +0000 Commit: Cy Schubert CommitDate: 2023-10-03 02:01:07 +0000 unbound: Vendor import 1.18.0 Release notes at https://www.nlnetlabs.nl/news/2023/Aug/30/unbound-1.18.0-released/ Merge commit '401770e05c71ecb5ae61a59d316069b4b78bf622' into main (cherry picked from commit 8f76bb7dad48538c6832c2fb466a433d2a3f8cd5) --- contrib/unbound/Makefile.in | 43 +- contrib/unbound/README.md | 2 +- contrib/unbound/acx_nlnetlabs.m4 | 36 +- contrib/unbound/acx_python.m4 | 61 +- contrib/unbound/cachedb/cachedb.c | 57 +- contrib/unbound/cachedb/redis.c | 28 +- contrib/unbound/compat/getentropy_solaris.c | 2 +- contrib/unbound/config.guess | 51 +- contrib/unbound/config.h.in | 25 +- contrib/unbound/config.h.in~ | 1456 ++++++++++++++++++++ contrib/unbound/config.sub | 72 +- contrib/unbound/configure | 170 ++- contrib/unbound/configure.ac | 99 +- contrib/unbound/contrib/Dockerfile.tests | 4 +- contrib/unbound/contrib/README | 3 + contrib/unbound/contrib/aaaa-filter-iterator.patch | 4 +- contrib/unbound/contrib/unbound.init_yocto | 139 ++ contrib/unbound/daemon/acl_list.c | 2 + contrib/unbound/daemon/acl_list.h | 8 +- contrib/unbound/daemon/cachedump.c | 28 +- contrib/unbound/daemon/remote.c | 236 ++-- contrib/unbound/daemon/remote.h | 2 +- contrib/unbound/daemon/stats.c | 53 +- contrib/unbound/daemon/stats.h | 7 + contrib/unbound/daemon/worker.c | 471 ++++--- contrib/unbound/dns64/dns64.c | 4 +- contrib/unbound/dnstap/dnstap.c | 7 +- contrib/unbound/dnstap/dnstap.h | 4 +- contrib/unbound/dnstap/unbound-dnstap-socket.c | 39 +- contrib/unbound/doc/Changelog | 323 +++++ contrib/unbound/doc/README | 2 +- contrib/unbound/doc/README.DNS64 | 20 + contrib/unbound/doc/example.conf.in | 32 +- contrib/unbound/doc/libunbound.3.in | 4 +- contrib/unbound/doc/unbound-anchor.8.in | 2 +- contrib/unbound/doc/unbound-checkconf.8.in | 2 +- contrib/unbound/doc/unbound-control.8.in | 58 +- contrib/unbound/doc/unbound-host.1.in | 2 +- contrib/unbound/doc/unbound.8.in | 4 +- contrib/unbound/doc/unbound.conf.5.in | 147 +- contrib/unbound/edns-subnet/subnetmod.c | 27 +- contrib/unbound/iterator/iter_delegpt.c | 39 + contrib/unbound/iterator/iter_delegpt.h | 25 + contrib/unbound/iterator/iter_resptype.c | 7 + contrib/unbound/iterator/iter_scrub.c | 43 +- contrib/unbound/iterator/iter_utils.c | 43 +- contrib/unbound/iterator/iter_utils.h | 7 +- contrib/unbound/iterator/iterator.c | 259 ++-- contrib/unbound/iterator/iterator.h | 23 +- contrib/unbound/libunbound/libworker.c | 16 +- contrib/unbound/libunbound/unbound-event.h | 6 +- contrib/unbound/libunbound/unbound.h | 116 +- contrib/unbound/services/authzone.c | 10 +- contrib/unbound/services/cache/dns.c | 50 +- contrib/unbound/services/cache/infra.c | 75 +- contrib/unbound/services/cache/infra.h | 5 +- contrib/unbound/services/listen_dnsport.c | 153 +- contrib/unbound/services/localzone.c | 20 +- contrib/unbound/services/localzone.h | 2 + contrib/unbound/services/mesh.c | 385 +++--- contrib/unbound/services/mesh.h | 14 +- contrib/unbound/services/modstack.c | 10 +- contrib/unbound/services/outside_network.c | 28 + contrib/unbound/services/rpz.c | 230 +++- contrib/unbound/services/rpz.h | 16 +- contrib/unbound/sldns/rrdef.c | 12 +- contrib/unbound/sldns/rrdef.h | 7 +- contrib/unbound/sldns/str2wire.c | 94 +- contrib/unbound/sldns/str2wire.h | 4 +- contrib/unbound/sldns/wire2str.c | 19 +- contrib/unbound/smallapp/unbound-anchor.c | 3 +- contrib/unbound/smallapp/unbound-checkconf.c | 2 +- contrib/unbound/smallapp/unbound-control.c | 54 +- contrib/unbound/smallapp/unbound-host.c | 5 +- contrib/unbound/testdata/00-lint.tdir/00-lint.pre | 14 + contrib/unbound/testdata/cachedb_cached_ede.crpl | 91 ++ .../unbound/testdata/edns_downstream_cookies.rpl | 235 ++++ .../testdata/ip_ratelimit.tdir/ip_ratelimit.conf | 28 + .../testdata/ip_ratelimit.tdir/ip_ratelimit.dsc | 16 + .../testdata/ip_ratelimit.tdir/ip_ratelimit.post | 13 + .../testdata/ip_ratelimit.tdir/ip_ratelimit.pre | 24 + .../testdata/ip_ratelimit.tdir/ip_ratelimit.test | 165 +++ .../testdata/ip_ratelimit.tdir/unbound_control.key | 39 + .../testdata/ip_ratelimit.tdir/unbound_control.pem | 22 + .../testdata/ip_ratelimit.tdir/unbound_server.key | 39 + .../testdata/ip_ratelimit.tdir/unbound_server.pem | 22 + .../unbound/testdata/iter_cname_minimise_nx.rpl | 246 ++++ contrib/unbound/testdata/iter_failreply.rpl | 132 ++ contrib/unbound/testdata/iter_ignore_empty.rpl | 198 +++ contrib/unbound/testdata/iter_nat64.rpl | 117 ++ contrib/unbound/testdata/iter_nat64_prefix.rpl | 119 ++ contrib/unbound/testdata/iter_nat64_prefix48.rpl | 118 ++ .../unbound/testdata/serve_expired_0ttl_nodata.rpl | 154 +++ .../testdata/serve_expired_0ttl_nxdomain.rpl | 154 +++ .../testdata/serve_expired_0ttl_servfail.rpl | 129 ++ .../serve_expired_cached_servfail_refresh.rpl | 145 ++ .../stat_values.tdir/stat_values_cachedb.conf | 36 + .../stat_values_downstream_cookies.conf | 32 + contrib/unbound/testdata/subnet_cached_ede.crpl | 114 ++ .../unbound/testdata/subnet_global_prefetch.crpl | 236 ++++ .../subnet_global_prefetch_always_forward.crpl | 167 +++ .../testdata/subnet_global_prefetch_expired.crpl | 241 ++++ contrib/unbound/testdata/val_any_negcache.rpl | 240 ++++ contrib/unbound/util/config_file.c | 153 +- contrib/unbound/util/config_file.h | 65 +- contrib/unbound/util/configlexer.lex | 15 +- contrib/unbound/util/configparser.y | 148 +- contrib/unbound/util/data/msgencode.c | 148 +- contrib/unbound/util/data/msgencode.h | 42 +- contrib/unbound/util/data/msgparse.c | 98 +- contrib/unbound/util/data/msgparse.h | 18 +- contrib/unbound/util/data/msgreply.c | 95 +- contrib/unbound/util/data/msgreply.h | 30 +- contrib/unbound/util/edns.c | 59 + contrib/unbound/util/edns.h | 59 + contrib/unbound/util/fptr_wlist.c | 8 + contrib/unbound/util/iana_ports.inc | 4 + contrib/unbound/util/module.c | 16 +- contrib/unbound/util/module.h | 14 +- contrib/unbound/util/net_help.c | 70 +- contrib/unbound/util/net_help.h | 23 + contrib/unbound/util/netevent.c | 229 +-- contrib/unbound/util/netevent.h | 70 +- contrib/unbound/util/regional.c | 2 +- contrib/unbound/util/rfc_1982.c | 74 + contrib/unbound/util/rfc_1982.h | 63 + contrib/unbound/util/siphash.c | 187 +++ contrib/unbound/util/siphash.h | 43 + contrib/unbound/util/storage/lruhash.c | 25 +- contrib/unbound/util/storage/lruhash.h | 5 +- contrib/unbound/util/storage/slabhash.c | 18 + contrib/unbound/util/storage/slabhash.h | 9 + contrib/unbound/util/timehist.c | 44 +- contrib/unbound/util/timeval_func.c | 113 ++ contrib/unbound/util/timeval_func.h | 53 + contrib/unbound/validator/autotrust.c | 2 + contrib/unbound/validator/val_kcache.c | 10 +- contrib/unbound/validator/val_kcache.h | 4 +- contrib/unbound/validator/val_kentry.c | 48 +- contrib/unbound/validator/val_kentry.h | 37 +- contrib/unbound/validator/val_neg.c | 7 +- contrib/unbound/validator/val_nsec.c | 19 +- contrib/unbound/validator/val_nsec.h | 5 +- contrib/unbound/validator/val_sigcrypt.c | 43 +- contrib/unbound/validator/val_utils.c | 19 +- contrib/unbound/validator/validator.c | 137 +- lib/libunbound/Makefile | 6 +- usr.sbin/unbound/config.h | 6 +- 148 files changed, 9439 insertions(+), 1708 deletions(-) diff --git a/contrib/unbound/Makefile.in b/contrib/unbound/Makefile.in index bc021aa1eb00..0a2e7f9b6f08 100644 --- a/contrib/unbound/Makefile.in +++ b/contrib/unbound/Makefile.in @@ -122,15 +122,15 @@ iterator/iter_delegpt.c iterator/iter_donotq.c iterator/iter_fwd.c \ iterator/iter_hints.c iterator/iter_priv.c iterator/iter_resptype.c \ iterator/iter_scrub.c iterator/iter_utils.c services/listen_dnsport.c \ services/localzone.c services/mesh.c services/modstack.c services/view.c \ -services/rpz.c \ +services/rpz.c util/rfc_1982.c \ services/outbound_list.c services/outside_network.c util/alloc.c \ util/config_file.c util/configlexer.c util/configparser.c \ util/shm_side/shm_main.c services/authzone.c \ util/fptr_wlist.c util/locks.c util/log.c util/mini_event.c util/module.c \ util/netevent.c util/net_help.c util/random.c util/rbtree.c util/regional.c \ -util/rtt.c util/edns.c util/storage/dnstree.c util/storage/lookup3.c \ +util/rtt.c util/siphash.c util/edns.c util/storage/dnstree.c util/storage/lookup3.c \ util/storage/lruhash.c util/storage/slabhash.c util/tcp_conn_limit.c \ -util/timehist.c util/tube.c util/proxy_protocol.c \ +util/timehist.c util/tube.c util/proxy_protocol.c util/timeval_func.c \ util/ub_event.c util/ub_event_pluggable.c util/winsock_event.c \ validator/autotrust.c validator/val_anchor.c validator/validator.c \ validator/val_kcache.c validator/val_kentry.c validator/val_neg.c \ @@ -145,14 +145,14 @@ as112.lo msgparse.lo msgreply.lo packed_rrset.lo iterator.lo iter_delegpt.lo \ iter_donotq.lo iter_fwd.lo iter_hints.lo iter_priv.lo iter_resptype.lo \ iter_scrub.lo iter_utils.lo localzone.lo mesh.lo modstack.lo view.lo \ outbound_list.lo alloc.lo config_file.lo configlexer.lo configparser.lo \ -fptr_wlist.lo edns.lo locks.lo log.lo mini_event.lo module.lo net_help.lo \ +fptr_wlist.lo siphash.lo edns.lo locks.lo log.lo mini_event.lo module.lo net_help.lo \ random.lo rbtree.lo regional.lo rtt.lo dnstree.lo lookup3.lo lruhash.lo \ slabhash.lo tcp_conn_limit.lo timehist.lo tube.lo winsock_event.lo \ -autotrust.lo val_anchor.lo rpz.lo proxy_protocol.lo \ +autotrust.lo val_anchor.lo rpz.lo rfc_1982.lo proxy_protocol.lo \ validator.lo val_kcache.lo val_kentry.lo val_neg.lo val_nsec3.lo val_nsec.lo \ val_secalgo.lo val_sigcrypt.lo val_utils.lo dns64.lo $(CACHEDB_OBJ) authzone.lo \ $(SUBNET_OBJ) $(PYTHONMOD_OBJ) $(CHECKLOCK_OBJ) $(DNSTAP_OBJ) $(DNSCRYPT_OBJ) \ -$(IPSECMOD_OBJ) $(IPSET_OBJ) $(DYNLIBMOD_OBJ) respip.lo +$(IPSECMOD_OBJ) $(IPSET_OBJ) $(DYNLIBMOD_OBJ) respip.lo timeval_func.lo COMMON_OBJ_WITHOUT_UB_EVENT=$(COMMON_OBJ_WITHOUT_NETCALL) netevent.lo listen_dnsport.lo \ outside_network.lo COMMON_OBJ=$(COMMON_OBJ_WITHOUT_UB_EVENT) ub_event.lo @@ -198,7 +198,7 @@ CHECKCONF_OBJ=unbound-checkconf.lo worker_cb.lo CHECKCONF_OBJ_LINK=$(CHECKCONF_OBJ) $(COMMON_OBJ_ALL_SYMBOLS) $(SLDNS_OBJ) \ $(COMPAT_OBJ) @WIN_CHECKCONF_OBJ_LINK@ CONTROL_SRC=smallapp/unbound-control.c -CONTROL_OBJ=unbound-control.lo +CONTROL_OBJ=unbound-control.lo CONTROL_OBJ_LINK=$(CONTROL_OBJ) worker_cb.lo $(COMMON_OBJ_ALL_SYMBOLS) \ $(SLDNS_OBJ) $(COMPAT_OBJ) @WIN_CONTROL_OBJ_LINK@ HOST_SRC=smallapp/unbound-host.c @@ -455,6 +455,7 @@ unbound-dnstap-socket.lo unbound-dnstap-socket.o: $(srcdir)/dnstap/unbound-dnsta dynlibmod.lo dynlibdmod.o: $(srcdir)/dynlibmod/dynlibmod.c config.h $(srcdir)/dynlibmod/dynlibmod.h cachedb.lo cachedb.o: $(srcdir)/cachedb/cachedb.c config.h $(srcdir)/cachedb/cachedb.h redis.lo redis.o: $(srcdir)/cachedb/redis.c config.h $(srcdir)/cachedb/redis.h +timeval_func.lo timeval_func.o: $(srcdir)/util/timeval_func.c $(srcdir)/util/timeval_func.h # dnscrypt dnscrypt.lo dnscrypt.o: $(srcdir)/dnscrypt/dnscrypt.c config.h \ @@ -498,6 +499,7 @@ util/configlexer.c: $(srcdir)/util/configlexer.lex util/configparser.h echo "#include \"util/configyyrename.h\"" >> $@ ;\ $(LEX) -t $(srcdir)/util/configlexer.lex >> $@ ;\ fi + @if test ! -f $@; then echo "No $@ : need flex and bison to compile from source repository"; exit 1; fi util/configparser.c util/configparser.h: $(srcdir)/util/configparser.y @-if test ! -d util; then $(INSTALL) -d util; fi @@ -516,7 +518,7 @@ distclean: clean rm -f doc/example.conf doc/libunbound.3 doc/unbound-anchor.8 doc/unbound-checkconf.8 doc/unbound-control.8 doc/unbound.8 doc/unbound.conf.5 doc/unbound-host.1 rm -f smallapp/unbound-control-setup.sh dnstap/dnstap_config.h dnscrypt/dnscrypt_config.h contrib/libunbound.pc contrib/unbound.socket contrib/unbound.service rm -f $(TEST_BIN) - rm -f Makefile + rm -f Makefile maintainer-clean: distclean rm -f util/configlexer.c util/configparser.c util/configparser.h @@ -649,7 +651,7 @@ uninstall: $(PYTHONMOD_UNINSTALL) $(PYUNBOUND_UNINSTALL) $(UNBOUND_EVENT_UNINSTA iana_update: curl -o port-numbers.tmp https://www.iana.org/assignments/service-names-port-numbers/service-names-port-numbers.xml --compressed - if file port-numbers.tmp | grep 'gzip' >/dev/null; then zcat port-numbers.tmp; else cat port-numbers.tmp; fi | awk '// {p=0;} /udp/ {p=1;} /[^u]/ {p=0;} /Decomissioned|Decommissioned|Removed|De-registered|unassigned|Unassigned|Reserved/ {u=1;} // { if(u==1) {u=0;} else { if(p==1) { match($$0,/[0-9]+/); print substr($$0, RSTART, RLENGTH) ","}}}' | sort -nu > util/iana_ports.inc + if file port-numbers.tmp | grep 'gzip' >/dev/null; then zcat port-numbers.tmp; else cat port-numbers.tmp; fi | awk '// {p=0;} /udp/ {p=1;} /[^u]/ {p=0;} /Decomissioned|Decommissioned|Removed|De-registered|unassigned|Unassigned|Reserved/ {u=1;} // { if(u==1) {u=0;} else { if(p==1) { match($$0,/[0-9]+/); print substr($$0, RSTART, RLENGTH) ","}}}' | sort -nu > util/iana_ports.inc rm -f port-numbers.tmp # dependency generation @@ -877,7 +879,7 @@ rpz.lo rpz.o: $(srcdir)/services/rpz.c config.h $(srcdir)/services/rpz.h $(srcdi outbound_list.lo outbound_list.o: $(srcdir)/services/outbound_list.c config.h \ $(srcdir)/services/outbound_list.h $(srcdir)/services/outside_network.h $(srcdir)/util/rbtree.h \ $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ - + outside_network.lo outside_network.o: $(srcdir)/services/outside_network.c config.h \ $(srcdir)/services/outside_network.h $(srcdir)/util/rbtree.h $(srcdir)/util/netevent.h \ $(srcdir)/dnscrypt/dnscrypt.h \ @@ -915,7 +917,8 @@ config_file.lo config_file.o: $(srcdir)/util/config_file.c config.h $(srcdir)/ut configlexer.lo configlexer.o: util/configlexer.c config.h $(srcdir)/util/configyyrename.h \ $(srcdir)/util/config_file.h util/configparser.h configparser.lo configparser.o: util/configparser.c config.h $(srcdir)/util/configyyrename.h \ - $(srcdir)/util/config_file.h $(srcdir)/util/net_help.h $(srcdir)/util/log.h + $(srcdir)/util/config_file.h $(srcdir)/util/net_help.h $(srcdir)/util/log.h $(srcdir)/sldns/str2wire.h \ + $(srcdir)/sldns/rrdef.h shm_main.lo shm_main.o: $(srcdir)/util/shm_side/shm_main.c config.h $(srcdir)/util/shm_side/shm_main.h \ $(srcdir)/libunbound/unbound.h $(srcdir)/daemon/daemon.h $(srcdir)/util/locks.h $(srcdir)/util/log.h \ $(srcdir)/util/alloc.h $(srcdir)/services/modstack.h \ @@ -928,7 +931,7 @@ shm_main.lo shm_main.o: $(srcdir)/util/shm_side/shm_main.c config.h $(srcdir)/ut $(srcdir)/services/view.h $(srcdir)/util/config_file.h $(srcdir)/services/authzone.h $(srcdir)/respip/respip.h \ $(srcdir)/services/cache/rrset.h $(srcdir)/util/storage/slabhash.h $(srcdir)/services/cache/infra.h \ $(srcdir)/util/rtt.h $(srcdir)/validator/validator.h $(srcdir)/validator/val_utils.h $(srcdir)/util/fptr_wlist.h \ - $(srcdir)/util/tube.h + $(srcdir)/util/tube.h $(srcdir)/util/timeval_func.h authzone.lo authzone.o: $(srcdir)/services/authzone.c config.h $(srcdir)/services/authzone.h \ $(srcdir)/util/rbtree.h $(srcdir)/util/locks.h $(srcdir)/util/log.h $(srcdir)/services/mesh.h $(srcdir)/util/netevent.h \ $(srcdir)/dnscrypt/dnscrypt.h $(srcdir)/util/data/msgparse.h \ @@ -983,7 +986,7 @@ netevent.lo netevent.o: $(srcdir)/util/netevent.c config.h $(srcdir)/util/neteve $(srcdir)/services/modstack.h $(srcdir)/services/rpz.h $(srcdir)/services/localzone.h $(srcdir)/services/view.h \ $(srcdir)/sldns/sbuffer.h $(srcdir)/util/config_file.h $(srcdir)/services/authzone.h $(srcdir)/daemon/stats.h \ $(srcdir)/util/timehist.h $(srcdir)/libunbound/unbound.h $(srcdir)/respip/respip.h $(srcdir)/sldns/str2wire.h \ - $(srcdir)/dnstap/dnstap.h $(srcdir)/services/listen_dnsport.h + $(srcdir)/dnstap/dnstap.h $(srcdir)/services/listen_dnsport.h $(srcdir)/util/timeval_func.h proxy_protocol.lo proxy_protocol.o: $(srcdir)/util/proxy_protocol.c config.h \ $(srcdir)/util/proxy_protocol.h $(srcdir)/sldns/sbuffer.h net_help.lo net_help.o: $(srcdir)/util/net_help.c config.h $(srcdir)/util/net_help.h $(srcdir)/util/log.h \ @@ -1006,6 +1009,8 @@ rtt.lo rtt.o: $(srcdir)/util/rtt.c config.h $(srcdir)/util/rtt.h $(srcdir)/itera $(srcdir)/services/outbound_list.h $(srcdir)/util/data/msgreply.h $(srcdir)/util/storage/lruhash.h \ $(srcdir)/util/locks.h $(srcdir)/util/log.h $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/module.h \ $(srcdir)/util/data/msgparse.h $(srcdir)/sldns/pkthdr.h $(srcdir)/sldns/rrdef.h +siphash.lo siphash.o: $(srcdir)/util/siphash.c +rfc_1982.lo rfc_1982.o: $(srcdir)/util/rfc_1982.c edns.lo edns.o: $(srcdir)/util/edns.c config.h $(srcdir)/util/edns.h $(srcdir)/util/storage/dnstree.h \ $(srcdir)/util/rbtree.h $(srcdir)/util/config_file.h $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ $(srcdir)/util/net_help.h $(srcdir)/util/log.h $(srcdir)/util/regional.h \ @@ -1186,7 +1191,7 @@ unitmain.lo unitmain.o: $(srcdir)/testcode/unitmain.c config.h $(srcdir)/sldns/r $(srcdir)/util/storage/dnstree.h $(srcdir)/util/rbtree.h $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ $(srcdir)/util/random.h $(srcdir)/respip/respip.h \ $(srcdir)/services/localzone.h $(srcdir)/services/view.h $(srcdir)/sldns/sbuffer.h \ - $(srcdir)/services/outside_network.h + $(srcdir)/services/outside_network.h unitmsgparse.lo unitmsgparse.o: $(srcdir)/testcode/unitmsgparse.c config.h $(srcdir)/util/log.h \ $(srcdir)/testcode/unitmain.h $(srcdir)/util/data/msgparse.h $(srcdir)/util/storage/lruhash.h \ $(srcdir)/util/locks.h $(srcdir)/sldns/pkthdr.h $(srcdir)/sldns/rrdef.h $(srcdir)/util/data/msgreply.h \ @@ -1321,7 +1326,7 @@ unbound.lo unbound.o: $(srcdir)/daemon/unbound.c config.h $(srcdir)/util/log.h $ worker.lo worker.o: $(srcdir)/daemon/worker.c config.h $(srcdir)/util/log.h $(srcdir)/util/net_help.h \ $(srcdir)/util/random.h $(srcdir)/daemon/worker.h $(srcdir)/libunbound/worker.h $(srcdir)/sldns/sbuffer.h \ $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/storage/lruhash.h $(srcdir)/util/locks.h \ - $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ + $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h $(srcdir)/util/timeval_func.h \ $(srcdir)/util/alloc.h $(srcdir)/util/data/msgreply.h $(srcdir)/util/data/msgparse.h $(srcdir)/sldns/pkthdr.h \ $(srcdir)/sldns/rrdef.h $(srcdir)/daemon/stats.h $(srcdir)/util/timehist.h $(srcdir)/libunbound/unbound.h \ $(srcdir)/util/module.h $(srcdir)/dnstap/dnstap.h $(srcdir)/daemon/daemon.h \ @@ -1343,7 +1348,7 @@ testbound.lo testbound.o: $(srcdir)/testcode/testbound.c config.h $(srcdir)/test $(srcdir)/daemon/remote.h $(srcdir)/libunbound/worker.h $(srcdir)/sldns/sbuffer.h \ $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/storage/lruhash.h $(srcdir)/util/locks.h $(srcdir)/util/log.h \ $(srcdir)/util/config_file.h $(srcdir)/sldns/keyraw.h $(srcdir)/daemon/unbound.c $(srcdir)/daemon/daemon.h \ - $(srcdir)/util/alloc.h $(srcdir)/services/modstack.h \ + $(srcdir)/util/alloc.h $(srcdir)/util/timeval_func.h $(srcdir)/services/modstack.h \ $(srcdir)/util/storage/slabhash.h $(srcdir)/services/listen_dnsport.h $(srcdir)/services/cache/rrset.h \ $(srcdir)/services/cache/infra.h $(srcdir)/util/storage/dnstree.h $(srcdir)/util/rtt.h \ $(srcdir)/util/data/msgreply.h $(srcdir)/util/fptr_wlist.h $(srcdir)/util/module.h \ @@ -1357,7 +1362,7 @@ testpkts.lo testpkts.o: $(srcdir)/testcode/testpkts.c config.h $(srcdir)/testcod worker.lo worker.o: $(srcdir)/daemon/worker.c config.h $(srcdir)/util/log.h $(srcdir)/util/net_help.h \ $(srcdir)/util/random.h $(srcdir)/daemon/worker.h $(srcdir)/libunbound/worker.h $(srcdir)/sldns/sbuffer.h \ $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/storage/lruhash.h $(srcdir)/util/locks.h \ - $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ + $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h $(srcdir)/util/timeval_func.h \ $(srcdir)/util/alloc.h $(srcdir)/util/data/msgreply.h $(srcdir)/util/data/msgparse.h $(srcdir)/sldns/pkthdr.h \ $(srcdir)/sldns/rrdef.h $(srcdir)/daemon/stats.h $(srcdir)/util/timehist.h $(srcdir)/libunbound/unbound.h \ $(srcdir)/util/module.h $(srcdir)/dnstap/dnstap.h $(srcdir)/daemon/daemon.h \ @@ -1409,7 +1414,7 @@ stats.lo stats.o: $(srcdir)/daemon/stats.c config.h $(srcdir)/daemon/stats.h $(s $(srcdir)/validator/val_kcache.h $(srcdir)/validator/val_neg.h replay.lo replay.o: $(srcdir)/testcode/replay.c config.h $(srcdir)/util/log.h $(srcdir)/util/net_help.h \ $(srcdir)/util/config_file.h $(srcdir)/testcode/replay.h $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ - $(srcdir)/testcode/testpkts.h $(srcdir)/util/rbtree.h \ + $(srcdir)/testcode/testpkts.h $(srcdir)/util/rbtree.h $(srcdir)/util/timeval_func.h \ $(srcdir)/testcode/fake_event.h $(srcdir)/sldns/str2wire.h $(srcdir)/sldns/rrdef.h fake_event.lo fake_event.o: $(srcdir)/testcode/fake_event.c config.h $(srcdir)/testcode/fake_event.h \ $(srcdir)/util/netevent.h $(srcdir)/dnscrypt/dnscrypt.h \ @@ -1417,7 +1422,7 @@ fake_event.lo fake_event.o: $(srcdir)/testcode/fake_event.c config.h $(srcdir)/t $(srcdir)/util/locks.h $(srcdir)/sldns/pkthdr.h $(srcdir)/sldns/rrdef.h $(srcdir)/util/data/msgreply.h \ $(srcdir)/util/data/packed_rrset.h $(srcdir)/util/data/msgencode.h $(srcdir)/util/data/dname.h \ $(srcdir)/util/edns.h $(srcdir)/util/storage/dnstree.h $(srcdir)/util/rbtree.h $(srcdir)/util/config_file.h \ - $(srcdir)/services/listen_dnsport.h $(srcdir)/services/outside_network.h \ + $(srcdir)/services/listen_dnsport.h $(srcdir)/services/outside_network.h $(srcdir)/util/timeval_func.h \ $(srcdir)/services/cache/infra.h $(srcdir)/util/rtt.h \ $(srcdir)/testcode/replay.h $(srcdir)/testcode/testpkts.h $(srcdir)/util/fptr_wlist.h $(srcdir)/util/module.h \ $(srcdir)/util/tube.h $(srcdir)/services/mesh.h $(srcdir)/services/modstack.h $(srcdir)/services/rpz.h \ diff --git a/contrib/unbound/README.md b/contrib/unbound/README.md index c3d9bc2492ef..c220da030458 100644 --- a/contrib/unbound/README.md +++ b/contrib/unbound/README.md @@ -1,6 +1,6 @@ # Unbound -[![Travis Build Status](https://travis-ci.org/NLnetLabs/unbound.svg?branch=master)](https://travis-ci.org/NLnetLabs/unbound) +[![Github Build Status](https://github.com/NLnetLabs/unbound/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/NLnetLabs/unbound/actions) [![Packaging status](https://repology.org/badge/tiny-repos/unbound.svg)](https://repology.org/project/unbound/versions) [![Fuzzing Status](https://oss-fuzz-build-logs.storage.googleapis.com/badges/unbound.svg)](https://bugs.chromium.org/p/oss-fuzz/issues/list?sort=-opened&can=1&q=proj:unbound) [![Documentation Status](https://readthedocs.org/projects/unbound/badge/?version=latest)](https://unbound.readthedocs.io/en/latest/?badge=latest) diff --git a/contrib/unbound/acx_nlnetlabs.m4 b/contrib/unbound/acx_nlnetlabs.m4 index cf436ec54bb6..f27615bd8bce 100644 --- a/contrib/unbound/acx_nlnetlabs.m4 +++ b/contrib/unbound/acx_nlnetlabs.m4 @@ -2,7 +2,9 @@ # Copyright 2009, Wouter Wijngaards, NLnet Labs. # BSD licensed. # -# Version 44 +# Version 46 +# 2023-05-04 fix to remove unused whitespace. +# 2023-01-26 fix -Wstrict-prototypes. # 2022-09-01 fix checking if nonblocking sockets work on OpenBSD. # 2021-08-17 fix sed script in ssldir split handling. # 2021-08-17 fix for openssl to detect split version, with ssldir_include @@ -187,7 +189,7 @@ dnl cache=`echo $1 | sed 'y%.=/+- %___p__%'` AC_CACHE_VAL(cv_prog_cc_flag_needed_$cache, [ echo '$2' > conftest.c -echo 'void f(){}' >>conftest.c +echo 'void f(void){}' >>conftest.c if test -z "`$CC $CPPFLAGS $CFLAGS $ERRFLAG -c conftest.c 2>&1`"; then eval "cv_prog_cc_flag_needed_$cache=no" else @@ -233,7 +235,7 @@ dnl DEPFLAG: set to flag that generates dependencies. AC_DEFUN([ACX_DEPFLAG], [ AC_MSG_CHECKING([$CC dependency flag]) -echo 'void f(){}' >conftest.c +echo 'void f(void){}' >conftest.c if test "`$CC -MM conftest.c 2>&1`" = "conftest.o: conftest.c"; then DEPFLAG="-MM" else @@ -272,7 +274,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED($C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAUL #include #endif -int test() { +int test(void) { int a; char **opts = NULL; struct timeval tv; @@ -309,7 +311,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED($C99FLAG -D__EXTENSIONS__ -D_BSD_SOURCE -D_DEFAUL #include #endif -int test() { +int test(void) { int a; char **opts = NULL; struct timeval tv; @@ -335,7 +337,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED($C99FLAG, [ #include #include -int test() { +int test(void) { int a = 0; return a; } @@ -345,7 +347,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D_BSD_SOURCE -D_DEFAULT_SOURCE, [ #include -int test() { +int test(void) { int a; a = isascii(32); return a; @@ -356,7 +358,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D_GNU_SOURCE, [ #include -int test() { +int test(void) { struct in6_pktinfo inf; int a = (int)sizeof(inf); return a; @@ -370,7 +372,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D_GNU_SOURCE -D_FRSRESGID, [ #include -int test() { +int test(void) { int a = setresgid(0,0,0); a = setresuid(0,0,0); return a; @@ -385,7 +387,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D_POSIX_C_SOURCE=200112, #endif #include -int test() { +int test(void) { int a = 0; char *t; time_t time = 0; @@ -413,7 +415,7 @@ ACX_CHECK_COMPILER_FLAG_NEEDED(-D__EXTENSIONS__, #include #endif -int test() { +int test(void) { int a; char **opts = NULL; struct timeval tv; @@ -475,7 +477,7 @@ fi dnl Setup ATTR_FORMAT config.h parts. dnl make sure you call ACX_CHECK_FORMAT_ATTRIBUTE also. AC_DEFUN([AHX_CONFIG_FORMAT_ATTRIBUTE], -[ +[ #ifdef HAVE_ATTR_FORMAT # define ATTR_FORMAT(archetype, string_index, first_to_check) \ __attribute__ ((format (archetype, string_index, first_to_check))) @@ -834,7 +836,7 @@ dnl try to see if an additional _LARGEFILE_SOURCE 1 is needed to get fseeko ACX_CHECK_COMPILER_FLAG_NEEDED(-D_LARGEFILE_SOURCE=1, [ #include -int test() { +int test(void) { int a = fseeko(stdin, 0, 0); return a; } @@ -859,7 +861,7 @@ char* (*f) () = getaddrinfo; #ifdef __cplusplus } #endif -int main() { +int main(void) { ; return 0; } @@ -923,7 +925,7 @@ cache=`echo $1 | sed 'y%.=/+-%___p_%'` AC_CACHE_VAL(cv_cc_deprecated_$cache, [ echo '$3' >conftest.c -echo 'void f(){ $2 }' >>conftest.c +echo 'void f(void){ $2 }' >>conftest.c if test -z "`$CC $CPPFLAGS $CFLAGS -c conftest.c 2>&1 | grep -e deprecated -e unavailable`"; then eval "cv_cc_deprecated_$cache=no" else @@ -1317,7 +1319,7 @@ AC_DEFUN([AHX_CONFIG_W32_FD_SET_T], #ifdef HAVE_WINSOCK2_H #define FD_SET_T (u_int) #else -#define FD_SET_T +#define FD_SET_T #endif ]) @@ -1355,7 +1357,7 @@ dnl $3: define value, 1 AC_DEFUN([AHX_CONFIG_FLAG_OMITTED], [#if defined($1) && !defined($2) #define $2 $3 -[#]endif ]) +[#]endif]) dnl Wrapper for AHX_CONFIG_FLAG_OMITTED for -D style flags dnl $1: the -DNAME or -DNAME=value string. diff --git a/contrib/unbound/acx_python.m4 b/contrib/unbound/acx_python.m4 index 16c0c6fd943f..c945d6c8989e 100644 --- a/contrib/unbound/acx_python.m4 +++ b/contrib/unbound/acx_python.m4 @@ -17,33 +17,62 @@ AC_DEFUN([AC_PYTHON_DEVEL],[ PYTHON_VERSION=`$PYTHON -c "import sys; \ print(sys.version.split()[[0]])"` fi + # calculate the version number components. + [ + v="$PYTHON_VERSION" + PYTHON_VERSION_MAJOR=`echo $v | sed 's/[^0-9].*//'` + if test -z "$PYTHON_VERSION_MAJOR"; then PYTHON_VERSION_MAJOR="0"; fi + v=`echo $v | sed -e 's/^[0-9]*$//' -e 's/[0-9]*[^0-9]//'` + PYTHON_VERSION_MINOR=`echo $v | sed 's/[^0-9].*//'` + if test -z "$PYTHON_VERSION_MINOR"; then PYTHON_VERSION_MINOR="0"; fi + v=`echo $v | sed -e 's/^[0-9]*$//' -e 's/[0-9]*[^0-9]//'` + PYTHON_VERSION_PATCH=`echo $v | sed 's/[^0-9].*//'` + if test -z "$PYTHON_VERSION_PATCH"; then PYTHON_VERSION_PATCH="0"; fi + ] - # Check if you have sysconfig - AC_MSG_CHECKING([for the sysconfig Python module]) - if ac_sysconfig_result=`$PYTHON -c "import sysconfig" 2>&1`; then + # For some systems, sysconfig exists, but has the wrong paths, + # on Debian 10, for python 2.7 and 3.7. So, we check the version, + # and for older versions try distutils.sysconfig first. For newer + # versions>=3.10, where distutils.sysconfig is deprecated, use + # sysconfig first and then attempt the other one. + py_distutils_first="no" + if test $PYTHON_VERSION_MAJOR -lt 3; then + py_distutils_first="yes" + fi + if test $PYTHON_VERSION_MAJOR -eq 3 -a $PYTHON_VERSION_MINOR -lt 10; then + py_distutils_first="yes" + fi + + # Check if you have the first module + if test "$py_distutils_first" = "yes"; then m="distutils"; else m="sysconfig"; fi + sysconfig_module="" + AC_MSG_CHECKING([for the $m Python module]) + if ac_modulecheck_result1=`$PYTHON -c "import $m" 2>&1`; then AC_MSG_RESULT([yes]) - sysconfig_module="sysconfig" - # if yes, use sysconfig, because distutils is deprecated. + sysconfig_module="$m" else AC_MSG_RESULT([no]) - # if no, try to use distutils + fi - # - # Check if you have distutils, else fail - # - AC_MSG_CHECKING([for the distutils Python package]) - if ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`; then + # if not found, try the other one. + if test -z "$sysconfig_module"; then + if test "$py_distutils_first" = "yes"; then m2="sysconfig"; else m2="distutils"; fi + AC_MSG_CHECKING([for the $m2 Python module]) + if ac_modulecheck_result2=`$PYTHON -c "import $m2" 2>&1`; then AC_MSG_RESULT([yes]) + sysconfig_module="$m2" else AC_MSG_RESULT([no]) - AC_MSG_ERROR([cannot import Python module "distutils". - Please check your Python installation. The error was: - $ac_distutils_result]) + AC_MSG_ERROR([cannot import Python module "$m", or "$m2". + Please check your Python installation. The errors are: + $m + $ac_modulecheck_result1 + $m2 + $ac_modulecheck_result2]) PYTHON_VERSION="" fi - - sysconfig_module="distutils.sysconfig" fi + if test "$sysconfig_module" = "distutils"; then sysconfig_module="distutils.sysconfig"; fi # # Check for Python include path diff --git a/contrib/unbound/cachedb/cachedb.c b/contrib/unbound/cachedb/cachedb.c index 245daa986967..30645268ca23 100644 --- a/contrib/unbound/cachedb/cachedb.c +++ b/contrib/unbound/cachedb/cachedb.c @@ -102,7 +102,6 @@ static int testframe_init(struct module_env* env, struct cachedb_env* cachedb_env) { struct testframe_moddata* d; - (void)env; verbose(VERB_ALGO, "testframe_init"); d = (struct testframe_moddata*)calloc(1, sizeof(struct testframe_moddata)); @@ -111,6 +110,15 @@ testframe_init(struct module_env* env, struct cachedb_env* cachedb_env) log_err("out of memory"); return 0; } + /* Register an EDNS option (65534) to bypass the worker cache lookup + * for testing */ + if(!edns_register_option(LDNS_EDNS_UNBOUND_CACHEDB_TESTFRAME_TEST, + 1 /* bypass cache */, + 0 /* no aggregation */, env)) { + log_err("testframe_init, could not register test opcode"); + free(d); + return 0; + } lock_basic_init(&d->lock); lock_protect(&d->lock, d, sizeof(*d)); return 1; @@ -218,6 +226,8 @@ static int cachedb_apply_cfg(struct cachedb_env* cachedb_env, struct config_file* cfg) { const char* backend_str = cfg->cachedb_backend; + if(!backend_str || *backend_str==0) + return 1; cachedb_env->backend = cachedb_find_backend(backend_str); if(!cachedb_env->backend) { log_err("cachedb: cannot find backend name '%s'", backend_str); @@ -228,7 +238,7 @@ cachedb_apply_cfg(struct cachedb_env* cachedb_env, struct config_file* cfg) return 1; } -int +int cachedb_init(struct module_env* env, int id) { struct cachedb_env* cachedb_env = (struct cachedb_env*)calloc(1, @@ -267,19 +277,16 @@ cachedb_init(struct module_env* env, int id) return 1; } -void +void cachedb_deinit(struct module_env* env, int id) { struct cachedb_env* cachedb_env; if(!env || !env->modinfo[id]) return; cachedb_env = (struct cachedb_env*)env->modinfo[id]; - /* free contents */ - /* TODO */ if(cachedb_env->enabled) { (*cachedb_env->backend->deinit)(env, cachedb_env); } - free(cachedb_env); env->modinfo[id] = NULL; } @@ -406,6 +413,14 @@ prep_data(struct module_qstate* qstate, struct sldns_buffer* buf) if(qstate->return_msg->rep->ttl == 0 && !qstate->env->cfg->serve_expired) return 0; + + /* The EDE is added to the out-list so it is encoded in the cached message */ + if (qstate->env->cfg->ede && qstate->return_msg->rep->reason_bogus != LDNS_EDE_NONE) { + edns_opt_list_append_ede(&edns.opt_list_out, qstate->env->scratch, + qstate->return_msg->rep->reason_bogus, + qstate->return_msg->rep->reason_bogus_str); + } + if(verbosity >= VERB_ALGO) log_dns_msg("cachedb encoding", &qstate->return_msg->qinfo, qstate->return_msg->rep); @@ -502,6 +517,7 @@ parse_data(struct module_qstate* qstate, struct sldns_buffer* buf) { struct msg_parse* prs; struct edns_data edns; + struct edns_option* ede; uint64_t timestamp, expiry; time_t adjust; size_t lim = sldns_buffer_limit(buf); @@ -539,6 +555,24 @@ parse_data(struct module_qstate* qstate, struct sldns_buffer* buf) if(!qstate->return_msg) return 0; + /* We find the EDE in the in-list after parsing */ + if(qstate->env->cfg->ede && + (ede = edns_opt_list_find(edns.opt_list_in, LDNS_EDNS_EDE))) { + if(ede->opt_len >= 2) { + qstate->return_msg->rep->reason_bogus = + sldns_read_uint16(ede->opt_data); + } + /* allocate space and store the error string and it's size */ + if(ede->opt_len > 2) { + size_t ede_len = ede->opt_len - 2; + qstate->return_msg->rep->reason_bogus_str = regional_alloc( + qstate->region, sizeof(char) * (ede_len+1)); + memcpy(qstate->return_msg->rep->reason_bogus_str, + ede->opt_data+2, ede_len); + qstate->return_msg->rep->reason_bogus_str[ede_len] = 0; + } + } + qstate->return_rcode = LDNS_RCODE_NOERROR; /* see how much of the TTL expired, and remove it */ @@ -630,11 +664,15 @@ cachedb_extcache_store(struct module_qstate* qstate, struct cachedb_env* ie) * See if unbound's internal cache can answer the query */ static int -cachedb_intcache_lookup(struct module_qstate* qstate) +cachedb_intcache_lookup(struct module_qstate* qstate, struct cachedb_env* cde) { uint8_t* dpname=NULL; size_t dpnamelen=0; struct dns_msg* msg; + /* for testframe bypass this lookup */ + if(cde->backend == &testframe_backend) { + return 0; + } if(iter_stub_fwd_no_cache(qstate, &qstate->qinfo, &dpname, &dpnamelen)) return 0; /* no cache for these queries */ @@ -693,6 +731,7 @@ cachedb_handle_query(struct module_qstate* qstate, struct cachedb_qstate* ATTR_UNUSED(iq), struct cachedb_env* ie, int id) { + qstate->is_cachedb_answer = 0; /* check if we are enabled, and skip if so */ if(!ie->enabled) { /* pass request to next module */ @@ -709,7 +748,7 @@ cachedb_handle_query(struct module_qstate* qstate, /* lookup inside unbound's internal cache. * This does not look for expired entries. */ - if(cachedb_intcache_lookup(qstate)) { + if(cachedb_intcache_lookup(qstate, ie)) { if(verbosity >= VERB_ALGO) { if(qstate->return_msg->rep) log_dns_msg("cachedb internal cache lookup", @@ -746,6 +785,7 @@ cachedb_handle_query(struct module_qstate* qstate, qstate->ext_state[id] = module_wait_module; return; } + qstate->is_cachedb_answer = 1; /* we are done with the query */ qstate->ext_state[id] = module_finished; return; @@ -768,6 +808,7 @@ static void cachedb_handle_response(struct module_qstate* qstate, struct cachedb_qstate* ATTR_UNUSED(iq), struct cachedb_env* ie, int id) { + qstate->is_cachedb_answer = 0; /* check if we are not enabled or instructed to not cache, and skip */ if(!ie->enabled || qstate->no_cache_store) { /* we are done with the query */ diff --git a/contrib/unbound/cachedb/redis.c b/contrib/unbound/cachedb/redis.c index 16c3741f786b..93a575a4c6d2 100644 --- a/contrib/unbound/cachedb/redis.c +++ b/contrib/unbound/cachedb/redis.c @@ -56,6 +56,8 @@ struct redis_moddata { int numctxs; /* number of ctx entries */ const char* server_host; /* server's IP address or host name */ int server_port; /* server's TCP port */ + const char* server_path; /* server's unix path, or "", NULL if unused */ + const char* server_password; /* server's AUTH password, or "", NULL if unused */ struct timeval timeout; /* timeout for connection setup and commands */ }; @@ -67,8 +69,13 @@ redis_connect(const struct redis_moddata* moddata) { redisContext* ctx; - ctx = redisConnectWithTimeout(moddata->server_host, - moddata->server_port, moddata->timeout); + if(moddata->server_path && moddata->server_path[0]!=0) { + ctx = redisConnectUnixWithTimeout(moddata->server_path, + moddata->timeout); + } else { + ctx = redisConnectWithTimeout(moddata->server_host, + moddata->server_port, moddata->timeout); + } if(!ctx || ctx->err) { const char *errstr = "out of memory"; if(ctx) @@ -80,6 +87,17 @@ redis_connect(const struct redis_moddata* moddata) log_err("failed to set redis timeout"); goto fail; } + if(moddata->server_password && moddata->server_password[0]!=0) { + redisReply* rep; + rep = redisCommand(ctx, "AUTH %s", moddata->server_password); + if(!rep || rep->type == REDIS_REPLY_ERROR) { + log_err("failed to authenticate with password"); + freeReplyObject(rep); + goto fail; + } + freeReplyObject(rep); + } + verbose(VERB_OPS, "Connection to Redis established"); return ctx; fail: @@ -94,7 +112,7 @@ redis_init(struct module_env* env, struct cachedb_env* cachedb_env) int i; struct redis_moddata* moddata = NULL; - verbose(VERB_ALGO, "redis_init"); + verbose(VERB_OPS, "Redis initialization"); moddata = calloc(1, sizeof(struct redis_moddata)); if(!moddata) { @@ -112,6 +130,8 @@ redis_init(struct module_env* env, struct cachedb_env* cachedb_env) * we don't have to free it in this module. */ moddata->server_host = env->cfg->redis_server_host; moddata->server_port = env->cfg->redis_server_port; + moddata->server_path = env->cfg->redis_server_path; + moddata->server_password = env->cfg->redis_server_password; moddata->timeout.tv_sec = env->cfg->redis_timeout / 1000; moddata->timeout.tv_usec = (env->cfg->redis_timeout % 1000) * 1000; for(i = 0; i < moddata->numctxs; i++) @@ -154,7 +174,7 @@ redis_deinit(struct module_env* env, struct cachedb_env* cachedb_env) cachedb_env->backend_data; (void)env; - verbose(VERB_ALGO, "redis_deinit"); + verbose(VERB_OPS, "Redis deinitialization"); if(!moddata) return; diff --git a/contrib/unbound/compat/getentropy_solaris.c b/contrib/unbound/compat/getentropy_solaris.c index 5e3b1cbbbd30..1ff8162917b3 100644 --- a/contrib/unbound/compat/getentropy_solaris.c +++ b/contrib/unbound/compat/getentropy_solaris.c @@ -47,7 +47,7 @@ #define SHA512_Update SHA512Update #define SHA512_Final SHA512Final #else -#include "openssl/sha.h" +#include #endif #include diff --git a/contrib/unbound/config.guess b/contrib/unbound/config.guess index 980b02083815..b187213930f1 100755 --- a/contrib/unbound/config.guess +++ b/contrib/unbound/config.guess @@ -1,10 +1,10 @@ #! /bin/sh # Attempt to guess a canonical system name. -# Copyright 1992-2022 Free Software Foundation, Inc. +# Copyright 1992-2023 Free Software Foundation, Inc. # shellcheck disable=SC2006,SC2268 # see below for rationale -timestamp='2022-09-17' +timestamp='2023-07-20' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -47,7 +47,7 @@ me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] -Output the configuration name of the system \`$me' is run on. +Output the configuration name of the system '$me' is run on. Options: -h, --help print this help, then exit @@ -60,13 +60,13 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright 1992-2022 Free Software Foundation, Inc. +Copyright 1992-2023 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" -Try \`$me --help' for more information." +Try '$me --help' for more information." # Parse command line while test $# -gt 0 ; do @@ -102,8 +102,8 @@ GUESS= # temporary files to be created and, as you can see below, it is a # headache to deal with in a portable fashion. -# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still -# use `HOST_CC' if defined, but it is deprecated. +# Historically, 'CC_FOR_BUILD' used to be named 'HOST_CC'. We still +# use 'HOST_CC' if defined, but it is deprecated. # Portable tmp directory creation inspired by the Autoconf team. @@ -459,7 +459,7 @@ case $UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION in UNAME_RELEASE=`uname -v` ;; esac - # Japanese Language versions have a version number like `4.1.3-JL'. + # Japanese Language versions have a version number like '4.1.3-JL'. SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/'` GUESS=sparc-sun-sunos$SUN_REL ;; @@ -976,7 +976,27 @@ EOF GUESS=$UNAME_MACHINE-unknown-minix ;; aarch64:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + set_cc_for_build + CPU=$UNAME_MACHINE + LIBCABI=$LIBC + if test "$CC_FOR_BUILD" != no_compiler_found; then + ABI=64 + sed 's/^ //' << EOF > "$dummy.c" + #ifdef __ARM_EABI__ + #ifdef __ARM_PCS_VFP + ABI=eabihf + #else + ABI=eabi + #endif + #endif +EOF + cc_set_abi=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^ABI' | sed 's, ,,g'` + eval "$cc_set_abi" + case $ABI in + eabi | eabihf) CPU=armv8l; LIBCABI=$LIBC$ABI ;; + esac + fi + GUESS=$CPU-unknown-linux-$LIBCABI ;; aarch64_be:Linux:*:*) UNAME_MACHINE=aarch64_be @@ -1042,6 +1062,15 @@ EOF k1om:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; + kvx:Linux:*:*) + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; + kvx:cos:*:*) + GUESS=$UNAME_MACHINE-unknown-cos + ;; + kvx:mbr:*:*) + GUESS=$UNAME_MACHINE-unknown-mbr + ;; loongarch32:Linux:*:* | loongarch64:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; @@ -1197,7 +1226,7 @@ EOF GUESS=$UNAME_MACHINE-pc-sysv4.2uw$UNAME_VERSION ;; i*86:OS/2:*:*) - # If we were able to find `uname', then EMX Unix compatibility + # If we were able to find 'uname', then EMX Unix compatibility # is probably installed. GUESS=$UNAME_MACHINE-pc-os2-emx ;; @@ -1338,7 +1367,7 @@ EOF GUESS=ns32k-sni-sysv fi ;; - PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort + PENTIUM:*:4.0*:*) # Unisys 'ClearPath HMP IX 4000' SVR4/MP effort # says GUESS=i586-unisys-sysv4 ;; diff --git a/contrib/unbound/config.h.in b/contrib/unbound/config.h.in index 2caecf30d040..f31354d01408 100644 *** 18537 LINES SKIPPED *** From nobody Wed Oct 4 01:02:39 2023 X-Original-To: dev-commits-src-branches@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 4S0byS3yvPz4wKKq; Wed, 4 Oct 2023 01:02:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0byS1VXLz4YkP; Wed, 4 Oct 2023 01:02:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381360; 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=BZlLdOEcW7jgqrX96UtIlDWIpouh96ttHiYvP3uA6qA=; b=CJI8/39ON7ZOnkoDTOMKh9BjWkF+bDuq33aDxZsHjlIAOMVoO8+ZPumb72EiTbgffWpryW N25jG1sr1q7nyrghnqTJ/2E8S8KoqJs517UH8RnntHijkUxiLB/4vhctzs3LfZTMN1pu8A 7QcuvHlmFQja2BKNUbTmcKcWCPn/FFH0RlhXS48IolwlIgEh+V9tB1OHW8Q8S6zQde7xdj uujxL1Owm+JKGehEr2POyNJqZvp6LgSZP4aNcgTUMO7rOGeMeyx6sbzPyMJIxxiDhJ6MdB Y01CGAd1kOenjFiZV2ep6aIMQLuaTuaES4bLvvprCy5Clu+HSYrRn1Pp19Q0TA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696381360; a=rsa-sha256; cv=none; b=q2ABTXCz4bce2y2XgVCxjVbbys8NtYrhnhx9d7uS8Luz5VroePFwdPGCwuX1TaEoffgbrc UdqnhurTrlIZ80KbxCS50Zu0f6TTau3KfKFuFTLE9m+CD9YRJf2FFSYvfbqin+15BfSPFZ yVHzNJoDfvKe9mSv+IK+CSCjM6/698lcRnqXrfS8/XlxYchXWJFM/w68mvZdG/kdBYA/tX t9djA7wYOb0YSUPbopXwsF8m81A66zRsylrZ2q0KXQLjUKiwwsvHtxlp8dIEhI6RxtWscr Bt4KTmhA25x48wLzCuLLLwpiNjHz0+fw3EVMcJ8UpwIkGJ4nfYJ2OL2+I2G4NQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696381360; 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=BZlLdOEcW7jgqrX96UtIlDWIpouh96ttHiYvP3uA6qA=; b=s8OgWorrHV4hjUJkRJ9mFY2FPFgCt/hVoB+XeZPQNemb0qI5J8L0cu8p5ct1hzvzj98PsR I5JRUY8g82+/P45gPBDvy0F5I6uz59fOvMvKRFqxkNBrSGVcWiPuXCMPEuo5wugrIZHT7p H2VUPUqs4fcuKGQ5HdcAQEn9qvpVmvjPU/AgQFATq/MdwQNJxImSgMk66At7hoDHRwGMjk nmYBpeqC8S7IKPSAkepnucGrG3fvcz70Ef9t0uCpqhzeD/suY+D7QZWX82Z6O60T4j9u7e 8lIrbdt3V4PBsDtFKvO6u1RfL5tfCgk2N4rTRNFMheDuidzYpT5nwrtV7nxW0A== 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 4S0byS0Nmvz35W; Wed, 4 Oct 2023 01:02:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39412exg054130; Wed, 4 Oct 2023 01:02:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39412dCk054127; Wed, 4 Oct 2023 01:02:39 GMT (envelope-from git) Date: Wed, 4 Oct 2023 01:02:39 GMT Message-Id: <202310040102.39412dCk054127@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Cy Schubert Subject: git: 757524b3db9a - stable/12 - local-unbound: remove stray config.h.in backup List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: 757524b3db9a4cfcd7ad503f8791b7230e7b03a5 Auto-Submitted: auto-generated The branch stable/12 has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=757524b3db9a4cfcd7ad503f8791b7230e7b03a5 commit 757524b3db9a4cfcd7ad503f8791b7230e7b03a5 Author: Mina Galić AuthorDate: 2023-09-20 14:39:37 +0000 Commit: Cy Schubert CommitDate: 2023-10-04 01:00:54 +0000 local-unbound: remove stray config.h.in backup despite being ignored in our main .gitignore, such files can still be merged from vendor branches. Reviewed by: cy Fixes: 8f76bb7dad (unbound: Vendor import 1.18.0) MFC after: 2 weeks X-MFC with: 8f76bb7dad Differential Revision: https://reviews.freebsd.org/D41920 (cherry picked from commit 948e11aaf420cd7d493cc2e118cacc06d18653fe) --- contrib/unbound/config.h.in~ | 1456 ------------------------------------------ 1 file changed, 1456 deletions(-) diff --git a/contrib/unbound/config.h.in~ b/contrib/unbound/config.h.in~ deleted file mode 100644 index f31354d01408..000000000000 --- a/contrib/unbound/config.h.in~ +++ /dev/null @@ -1,1456 +0,0 @@ -/* config.h.in. Generated from configure.ac by autoheader. */ - -/* apply the noreturn attribute to a function that exits the program */ -#undef ATTR_NORETURN - -/* apply the weak attribute to a symbol */ -#undef ATTR_WEAK - -/* Directory to chroot to */ -#undef CHROOT_DIR - -/* Define this to enable client subnet option. */ -#undef CLIENT_SUBNET - -/* Do sha512 definitions in config.h */ -#undef COMPAT_SHA512 - -/* Command line arguments used with configure */ -#undef CONFCMDLINE - -/* Pathname to the Unbound configuration file */ -#undef CONFIGFILE - -/* Define this if on macOSX10.4-darwin8 and setreuid and setregid do not work - */ -#undef DARWIN_BROKEN_SETREUID - -/* Whether daemon is deprecated */ -#undef DEPRECATED_DAEMON - -/* Deprecate RSA 1024 bit length, makes that an unsupported key */ -#undef DEPRECATE_RSA_1024 - -/* Define this to enable kernel based UDP source port randomization. */ -#undef DISABLE_EXPLICIT_PORT_RANDOMISATION - -/* default dnstap socket path */ -#undef DNSTAP_SOCKET_PATH - -/* Define if you want to use debug lock checking (slow). */ -#undef ENABLE_LOCK_CHECKS - -/* Define this if you enabled-allsymbols from libunbound to link binaries to - it for smaller install size, but the libunbound export table is polluted by - internal symbols */ -#undef EXPORT_ALL_SYMBOLS - -/* Define to 1 if you have the `accept4' function. */ -#undef HAVE_ACCEPT4 - -/* Define to 1 if you have the `arc4random' function. */ -#undef HAVE_ARC4RANDOM - -/* Define to 1 if you have the `arc4random_uniform' function. */ -#undef HAVE_ARC4RANDOM_UNIFORM - -/* Define to 1 if you have the header file. */ -#undef HAVE_ARPA_INET_H - -/* Whether the C compiler accepts the "format" attribute */ -#undef HAVE_ATTR_FORMAT - -/* Whether the C compiler accepts the "noreturn" attribute */ -#undef HAVE_ATTR_NORETURN - -/* Whether the C compiler accepts the "unused" attribute */ -#undef HAVE_ATTR_UNUSED - -/* Whether the C compiler accepts the "weak" attribute */ -#undef HAVE_ATTR_WEAK - -/* If we have be64toh */ -#undef HAVE_BE64TOH - -/* Define to 1 if you have the `BIO_set_callback_ex' function. */ -#undef HAVE_BIO_SET_CALLBACK_EX - -/* Define to 1 if you have the header file. */ -#undef HAVE_BSD_STDLIB_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_BSD_STRING_H - -/* Define to 1 if you have the `chown' function. */ -#undef HAVE_CHOWN - -/* Define to 1 if you have the `chroot' function. */ -#undef HAVE_CHROOT - -/* Define to 1 if you have the `CRYPTO_cleanup_all_ex_data' function. */ -#undef HAVE_CRYPTO_CLEANUP_ALL_EX_DATA - -/* Define to 1 if you have the `CRYPTO_THREADID_set_callback' function. */ -#undef HAVE_CRYPTO_THREADID_SET_CALLBACK - -/* Define to 1 if you have the `ctime_r' function. */ -#undef HAVE_CTIME_R - -/* Define to 1 if you have the `daemon' function. */ -#undef HAVE_DAEMON - -/* Define to 1 if you have the declaration of `arc4random', and to 0 if you - don't. */ -#undef HAVE_DECL_ARC4RANDOM - -/* Define to 1 if you have the declaration of `arc4random_uniform', and to 0 - if you don't. */ -#undef HAVE_DECL_ARC4RANDOM_UNIFORM - -/* Define to 1 if you have the declaration of `evsignal_assign', and to 0 if - you don't. */ -#undef HAVE_DECL_EVSIGNAL_ASSIGN - -/* Define to 1 if you have the declaration of `inet_ntop', and to 0 if you - don't. */ -#undef HAVE_DECL_INET_NTOP - -/* Define to 1 if you have the declaration of `inet_pton', and to 0 if you - don't. */ -#undef HAVE_DECL_INET_PTON - -/* Define to 1 if you have the declaration of `nghttp2_session_server_new', - and to 0 if you don't. */ -#undef HAVE_DECL_NGHTTP2_SESSION_SERVER_NEW - -/* Define to 1 if you have the declaration of `NID_ED25519', and to 0 if you - don't. */ -#undef HAVE_DECL_NID_ED25519 - -/* Define to 1 if you have the declaration of `NID_ED448', and to 0 if you - don't. */ -#undef HAVE_DECL_NID_ED448 - -/* Define to 1 if you have the declaration of `NID_secp384r1', and to 0 if you - don't. */ -#undef HAVE_DECL_NID_SECP384R1 - -/* Define to 1 if you have the declaration of `NID_X9_62_prime256v1', and to 0 - if you don't. */ -#undef HAVE_DECL_NID_X9_62_PRIME256V1 - -/* Define to 1 if you have the declaration of `reallocarray', and to 0 if you - don't. */ -#undef HAVE_DECL_REALLOCARRAY - -/* Define to 1 if you have the declaration of `redisConnect', and to 0 if you - don't. */ -#undef HAVE_DECL_REDISCONNECT - -/* Define to 1 if you have the declaration of `sk_SSL_COMP_pop_free', and to 0 - if you don't. */ -#undef HAVE_DECL_SK_SSL_COMP_POP_FREE - -/* Define to 1 if you have the declaration of - `SSL_COMP_get_compression_methods', and to 0 if you don't. */ -#undef HAVE_DECL_SSL_COMP_GET_COMPRESSION_METHODS - -/* Define to 1 if you have the declaration of `SSL_CTX_set_ecdh_auto', and to - 0 if you don't. */ -#undef HAVE_DECL_SSL_CTX_SET_ECDH_AUTO - -/* Define to 1 if you have the declaration of `strlcat', and to 0 if you - don't. */ -#undef HAVE_DECL_STRLCAT - -/* Define to 1 if you have the declaration of `strlcpy', and to 0 if you - don't. */ -#undef HAVE_DECL_STRLCPY - -/* Define to 1 if you have the declaration of `XML_StopParser', and to 0 if - you don't. */ -#undef HAVE_DECL_XML_STOPPARSER - -/* Define to 1 if you have the header file. */ -#undef HAVE_DLFCN_H - -/* Define to 1 if you have the `DSA_SIG_set0' function. */ -#undef HAVE_DSA_SIG_SET0 - -/* Define to 1 if you have the header file. */ -#undef HAVE_ENDIAN_H - -/* Define to 1 if you have the `endprotoent' function. */ -#undef HAVE_ENDPROTOENT - -/* Define to 1 if you have the `endpwent' function. */ -#undef HAVE_ENDPWENT - -/* Define to 1 if you have the `endservent' function. */ -#undef HAVE_ENDSERVENT - -/* Define to 1 if you have the `ENGINE_cleanup' function. */ -#undef HAVE_ENGINE_CLEANUP - -/* Define to 1 if you have the `ERR_free_strings' function. */ -#undef HAVE_ERR_FREE_STRINGS - -/* Define to 1 if you have the `ERR_load_crypto_strings' function. */ -#undef HAVE_ERR_LOAD_CRYPTO_STRINGS - -/* Define to 1 if you have the `event_assign' function. */ -#undef HAVE_EVENT_ASSIGN - -/* Define to 1 if you have the `event_base_free' function. */ -#undef HAVE_EVENT_BASE_FREE - -/* Define to 1 if you have the `event_base_get_method' function. */ -#undef HAVE_EVENT_BASE_GET_METHOD - -/* Define to 1 if you have the `event_base_new' function. */ -#undef HAVE_EVENT_BASE_NEW - -/* Define to 1 if you have the `event_base_once' function. */ -#undef HAVE_EVENT_BASE_ONCE - -/* Define to 1 if you have the header file. */ -#undef HAVE_EVENT_H - -/* Define to 1 if you have the `EVP_aes_256_cbc' function. */ -#undef HAVE_EVP_AES_256_CBC - -/* Define to 1 if you have the `EVP_cleanup' function. */ -#undef HAVE_EVP_CLEANUP - -/* Define to 1 if you have the `EVP_default_properties_is_fips_enabled' - function. */ -#undef HAVE_EVP_DEFAULT_PROPERTIES_IS_FIPS_ENABLED - -/* Define to 1 if you have the `EVP_DigestVerify' function. */ -#undef HAVE_EVP_DIGESTVERIFY - -/* Define to 1 if you have the `EVP_dss1' function. */ -#undef HAVE_EVP_DSS1 - -/* Define to 1 if you have the `EVP_EncryptInit_ex' function. */ -#undef HAVE_EVP_ENCRYPTINIT_EX - -/* Define to 1 if you have the `EVP_MAC_CTX_set_params' function. */ -#undef HAVE_EVP_MAC_CTX_SET_PARAMS - -/* Define to 1 if you have the `EVP_MD_CTX_new' function. */ -#undef HAVE_EVP_MD_CTX_NEW - -/* Define to 1 if you have the `EVP_sha1' function. */ -#undef HAVE_EVP_SHA1 - -/* Define to 1 if you have the `EVP_sha256' function. */ -#undef HAVE_EVP_SHA256 - -/* Define to 1 if you have the `EVP_sha512' function. */ -#undef HAVE_EVP_SHA512 - -/* Define to 1 if you have the `ev_default_loop' function. */ -#undef HAVE_EV_DEFAULT_LOOP - -/* Define to 1 if you have the `ev_loop' function. */ -#undef HAVE_EV_LOOP - -/* Define to 1 if you have the header file. */ -#undef HAVE_EXPAT_H - -/* Define to 1 if you have the `explicit_bzero' function. */ -#undef HAVE_EXPLICIT_BZERO - -/* Define to 1 if you have the `fcntl' function. */ -#undef HAVE_FCNTL - -/* Define to 1 if you have the `FIPS_mode' function. */ -#undef HAVE_FIPS_MODE - -/* Define to 1 if you have the `fork' function. */ -#undef HAVE_FORK - -/* Define to 1 if fseeko (and presumably ftello) exists and is declared. */ -#undef HAVE_FSEEKO - -/* Define to 1 if you have the `fsync' function. */ -#undef HAVE_FSYNC - -/* Whether getaddrinfo is available */ -#undef HAVE_GETADDRINFO - -/* Define to 1 if you have the `getauxval' function. */ -#undef HAVE_GETAUXVAL - -/* Define to 1 if you have the `getentropy' function. */ -#undef HAVE_GETENTROPY - -/* Define to 1 if you have the `getifaddrs' function. */ -#undef HAVE_GETIFADDRS - -/* Define to 1 if you have the header file. */ -#undef HAVE_GETOPT_H - -/* Define to 1 if you have the `getpwnam' function. */ -#undef HAVE_GETPWNAM - -/* Define to 1 if you have the `getrlimit' function. */ -#undef HAVE_GETRLIMIT - -/* Define to 1 if you have the `gettid' function. */ -#undef HAVE_GETTID - -/* Define to 1 if you have the `glob' function. */ -#undef HAVE_GLOB - -/* Define to 1 if you have the header file. */ -#undef HAVE_GLOB_H - -/* Define to 1 if you have the `gmtime_r' function. */ -#undef HAVE_GMTIME_R - -/* Define to 1 if you have the header file. */ -#undef HAVE_GRP_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_HIREDIS_HIREDIS_H - -/* Define to 1 if you have the `HMAC_Init_ex' function. */ -#undef HAVE_HMAC_INIT_EX - -/* If we have htobe64 */ -#undef HAVE_HTOBE64 - -/* Define to 1 if you have the header file. */ -#undef HAVE_IFADDRS_H - -/* Define to 1 if you have the `if_nametoindex' function. */ -#undef HAVE_IF_NAMETOINDEX - -/* Define to 1 if you have the `inet_aton' function. */ -#undef HAVE_INET_ATON - -/* Define to 1 if you have the `inet_ntop' function. */ -#undef HAVE_INET_NTOP - -/* Define to 1 if you have the `inet_pton' function. */ -#undef HAVE_INET_PTON - -/* Define to 1 if you have the `initgroups' function. */ -#undef HAVE_INITGROUPS - -/* Define to 1 if you have the header file. */ -#undef HAVE_INTTYPES_H - -/* if the function 'ioctlsocket' is available */ -#undef HAVE_IOCTLSOCKET - -/* Define to 1 if you have the header file. */ -#undef HAVE_IPHLPAPI_H - -/* Define to 1 if you have the `isblank' function. */ -#undef HAVE_ISBLANK - -/* Define to 1 if you have the `kill' function. */ -#undef HAVE_KILL - -/* Use portable libbsd functions */ -#undef HAVE_LIBBSD - -/* Define to 1 if you have the header file. */ -#undef HAVE_LIBKERN_OSBYTEORDER_H - -/* Define if we have LibreSSL */ -#undef HAVE_LIBRESSL - -/* Define to 1 if you have the header file. */ -#undef HAVE_LINUX_NET_TSTAMP_H - -/* Define to 1 if you have the `localtime_r' function. */ -#undef HAVE_LOCALTIME_R - -/* Define to 1 if you have the header file. */ -#undef HAVE_LOGIN_CAP_H - -/* If have GNU libc compatible malloc */ -#undef HAVE_MALLOC - -/* Define to 1 if you have the `memmove' function. */ -#undef HAVE_MEMMOVE - -/* Define to 1 if you have the header file. */ -#undef HAVE_MEMORY_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETDB_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETINET_IN_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETINET_TCP_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETIOAPI_H - -/* Use libnettle for crypto */ -#undef HAVE_NETTLE - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETTLE_DSA_COMPAT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NETTLE_EDDSA_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_NET_IF_H - -/* Define this to use nghttp2 client. */ -#undef HAVE_NGHTTP2 - -/* Define to 1 if you have the header file. */ -#undef HAVE_NGHTTP2_NGHTTP2_H - -/* Use libnss for crypto */ -#undef HAVE_NSS - -/* Define to 1 if you have the `OpenSSL_add_all_digests' function. */ -#undef HAVE_OPENSSL_ADD_ALL_DIGESTS - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_BN_H - -/* Define to 1 if you have the `OPENSSL_config' function. */ -#undef HAVE_OPENSSL_CONFIG - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_CONF_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_CORE_NAMES_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_DH_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_DSA_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_ENGINE_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_ERR_H - -/* Define to 1 if you have the `OPENSSL_init_crypto' function. */ -#undef HAVE_OPENSSL_INIT_CRYPTO - -/* Define to 1 if you have the `OPENSSL_init_ssl' function. */ -#undef HAVE_OPENSSL_INIT_SSL - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_PARAM_BUILD_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_RAND_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_RSA_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_OPENSSL_SSL_H - -/* Define to 1 if you have the `OSSL_PARAM_BLD_new' function. */ -#undef HAVE_OSSL_PARAM_BLD_NEW - -/* Define to 1 if you have the `poll' function. */ -#undef HAVE_POLL - -/* Define to 1 if you have the header file. */ -#undef HAVE_POLL_H - -/* Define if you have POSIX threads libraries and header files. */ -#undef HAVE_PTHREAD - -/* Have PTHREAD_PRIO_INHERIT. */ -#undef HAVE_PTHREAD_PRIO_INHERIT - -/* Define to 1 if the system has the type `pthread_rwlock_t'. */ -#undef HAVE_PTHREAD_RWLOCK_T - -/* Define to 1 if the system has the type `pthread_spinlock_t'. */ -#undef HAVE_PTHREAD_SPINLOCK_T - -/* Define to 1 if you have the header file. */ -#undef HAVE_PWD_H - -/* Define if you have Python libraries and header files. */ -#undef HAVE_PYTHON - -/* Define to 1 if you have the `random' function. */ -#undef HAVE_RANDOM - -/* Define to 1 if you have the `RAND_cleanup' function. */ -#undef HAVE_RAND_CLEANUP - -/* If we have reallocarray(3) */ -#undef HAVE_REALLOCARRAY - -/* Define to 1 if you have the `recvmsg' function. */ -#undef HAVE_RECVMSG - -/* Define to 1 if you have the `sendmsg' function. */ -#undef HAVE_SENDMSG - -/* Define to 1 if you have the `setregid' function. */ -#undef HAVE_SETREGID - -/* Define to 1 if you have the `setresgid' function. */ -#undef HAVE_SETRESGID - -/* Define to 1 if you have the `setresuid' function. */ -#undef HAVE_SETRESUID - -/* Define to 1 if you have the `setreuid' function. */ -#undef HAVE_SETREUID - -/* Define to 1 if you have the `setrlimit' function. */ -#undef HAVE_SETRLIMIT - -/* Define to 1 if you have the `setsid' function. */ -#undef HAVE_SETSID - -/* Define to 1 if you have the `setusercontext' function. */ -#undef HAVE_SETUSERCONTEXT - -/* Define to 1 if you have the `SHA512_Update' function. */ -#undef HAVE_SHA512_UPDATE - -/* Define to 1 if you have the `shmget' function. */ -#undef HAVE_SHMGET - -/* Define to 1 if you have the `sigprocmask' function. */ -#undef HAVE_SIGPROCMASK - -/* Define to 1 if you have the `sleep' function. */ -#undef HAVE_SLEEP - -/* Define to 1 if you have the `snprintf' function. */ -#undef HAVE_SNPRINTF - -/* Define to 1 if you have the `socketpair' function. */ -#undef HAVE_SOCKETPAIR - -/* Using Solaris threads */ -#undef HAVE_SOLARIS_THREADS - -/* Define to 1 if you have the `srandom' function. */ -#undef HAVE_SRANDOM - -/* Define if you have the SSL libraries installed. */ -#undef HAVE_SSL - -/* Define to 1 if you have the `SSL_CTX_set_alpn_protos' function. */ -#undef HAVE_SSL_CTX_SET_ALPN_PROTOS - -/* Define to 1 if you have the `SSL_CTX_set_alpn_select_cb' function. */ -#undef HAVE_SSL_CTX_SET_ALPN_SELECT_CB - -/* Define to 1 if you have the `SSL_CTX_set_ciphersuites' function. */ -#undef HAVE_SSL_CTX_SET_CIPHERSUITES - -/* Define to 1 if you have the `SSL_CTX_set_security_level' function. */ -#undef HAVE_SSL_CTX_SET_SECURITY_LEVEL - -/* Define to 1 if you have the `SSL_CTX_set_tlsext_ticket_key_evp_cb' - function. */ -#undef HAVE_SSL_CTX_SET_TLSEXT_TICKET_KEY_EVP_CB - -/* Define to 1 if you have the `SSL_get0_alpn_selected' function. */ -#undef HAVE_SSL_GET0_ALPN_SELECTED - -/* Define to 1 if you have the `SSL_get0_peername' function. */ -#undef HAVE_SSL_GET0_PEERNAME - -/* Define to 1 if you have the `SSL_get1_peer_certificate' function. */ -#undef HAVE_SSL_GET1_PEER_CERTIFICATE - -/* Define to 1 if you have the `SSL_set1_host' function. */ -#undef HAVE_SSL_SET1_HOST - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDARG_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDBOOL_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDINT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDLIB_H - -/* Define to 1 if you have the `strftime' function. */ -#undef HAVE_STRFTIME - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRINGS_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRING_H - -/* Define to 1 if you have the `strlcat' function. */ -#undef HAVE_STRLCAT - -/* Define to 1 if you have the `strlcpy' function. */ -#undef HAVE_STRLCPY - -/* Define to 1 if you have the `strptime' function. */ -#undef HAVE_STRPTIME - -/* Define to 1 if you have the `strsep' function. */ -#undef HAVE_STRSEP - -/* Define to 1 if `ipi_spec_dst' is a member of `struct in_pktinfo'. */ -#undef HAVE_STRUCT_IN_PKTINFO_IPI_SPEC_DST - -/* Define to 1 if `sun_len' is a member of `struct sockaddr_un'. */ -#undef HAVE_STRUCT_SOCKADDR_UN_SUN_LEN - -/* Define if you have Swig libraries and header files. */ -#undef HAVE_SWIG - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYSLOG_H - -/* Define to 1 if systemd should be used */ -#undef HAVE_SYSTEMD - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_ENDIAN_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_IPC_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_PARAM_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_RESOURCE_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SELECT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SHA2_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SHM_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SOCKET_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_STAT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SYSCTL_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_TYPES_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_UIO_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_UN_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_WAIT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_TARGETCONDITIONALS_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_TIME_H - -/* Define to 1 if you have the `tzset' function. */ -#undef HAVE_TZSET - -/* Define to 1 if you have the header file. */ -#undef HAVE_UNISTD_H - -/* Define to 1 if you have the `usleep' function. */ -#undef HAVE_USLEEP - -/* Define to 1 if you have the `vfork' function. */ -#undef HAVE_VFORK - -/* Define to 1 if you have the header file. */ -#undef HAVE_VFORK_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_WINDOWS_H - -/* Using Windows threads */ -#undef HAVE_WINDOWS_THREADS - -/* Define to 1 if you have the header file. */ -#undef HAVE_WINSOCK2_H - -/* Define to 1 if `fork' works. */ -#undef HAVE_WORKING_FORK - -/* Define to 1 if `vfork' works. */ -#undef HAVE_WORKING_VFORK - -/* Define to 1 if you have the `writev' function. */ -#undef HAVE_WRITEV - -/* Define to 1 if you have the header file. */ -#undef HAVE_WS2TCPIP_H - -/* Define to 1 if you have the `X509_VERIFY_PARAM_set1_host' function. */ -#undef HAVE_X509_VERIFY_PARAM_SET1_HOST - -/* Define to 1 if you have the `_beginthreadex' function. */ -#undef HAVE__BEGINTHREADEX - -/* If HMAC_Init_ex() returns void */ -#undef HMAC_INIT_EX_RETURNS_VOID - -/* if lex has yylex_destroy */ -#undef LEX_HAS_YYLEX_DESTROY - -/* Define to the sub-directory where libtool stores uninstalled libraries. */ -#undef LT_OBJDIR - -/* Define to the maximum message length to pass to syslog. */ -#undef MAXSYSLOGMSGLEN - -/* Define if memcmp() does not compare unsigned bytes */ -#undef MEMCMP_IS_BROKEN - -/* Define if mkdir has one argument. */ -#undef MKDIR_HAS_ONE_ARG - -/* Define if the network stack does not fully support nonblocking io (causes - lower performance). */ -#undef NONBLOCKING_IS_BROKEN - -/* Put -D_ALL_SOURCE define in config.h */ -#undef OMITTED__D_ALL_SOURCE - -/* Put -D_BSD_SOURCE define in config.h */ -#undef OMITTED__D_BSD_SOURCE - -/* Put -D_DEFAULT_SOURCE define in config.h */ -#undef OMITTED__D_DEFAULT_SOURCE - -/* Put -D_GNU_SOURCE define in config.h */ -#undef OMITTED__D_GNU_SOURCE - -/* Put -D_LARGEFILE_SOURCE=1 define in config.h */ -#undef OMITTED__D_LARGEFILE_SOURCE_1 - -/* Put -D_POSIX_C_SOURCE=200112 define in config.h */ -#undef OMITTED__D_POSIX_C_SOURCE_200112 - -/* Put -D_XOPEN_SOURCE=600 define in config.h */ -#undef OMITTED__D_XOPEN_SOURCE_600 - -/* Put -D_XOPEN_SOURCE_EXTENDED=1 define in config.h */ -#undef OMITTED__D_XOPEN_SOURCE_EXTENDED_1 - -/* Put -D__EXTENSIONS__ define in config.h */ -#undef OMITTED__D__EXTENSIONS__ - -/* Define to the address where bug reports for this package should be sent. */ -#undef PACKAGE_BUGREPORT - -/* Define to the full name of this package. */ -#undef PACKAGE_NAME - -/* Define to the full name and version of this package. */ -#undef PACKAGE_STRING - -/* Define to the one symbol short name of this package. */ -#undef PACKAGE_TARNAME - -/* Define to the home page for this package. */ -#undef PACKAGE_URL - -/* Define to the version of this package. */ -#undef PACKAGE_VERSION - -/* default pidfile location */ -#undef PIDFILE - -/* Define to necessary symbol if this constant uses a non-standard name on - your system. */ -#undef PTHREAD_CREATE_JOINABLE - -/* Return type of signal handlers, but autoconf 2.70 says 'your code may - safely assume C89 semantics that RETSIGTYPE is void.' */ -#undef RETSIGTYPE - -/* if REUSEPORT is enabled by default */ -#undef REUSEPORT_DEFAULT - -/* default rootkey location */ -#undef ROOT_ANCHOR_FILE - -/* default rootcert location */ -#undef ROOT_CERT_FILE - -/* version number for resource files */ -#undef RSRC_PACKAGE_VERSION - -/* Directory to chdir to */ -#undef RUN_DIR - -/* Shared data */ -#undef SHARE_DIR - -/* The size of `pthread_t', as computed by sizeof. */ -#undef SIZEOF_PTHREAD_T - -/* The size of `size_t', as computed by sizeof. */ -#undef SIZEOF_SIZE_T - -/* The size of `time_t', as computed by sizeof. */ -#undef SIZEOF_TIME_T - -/* The size of `unsigned long', as computed by sizeof. */ -#undef SIZEOF_UNSIGNED_LONG - -/* define if (v)snprintf does not return length needed, (but length used) */ -#undef SNPRINTF_RET_BROKEN - -/* Define to 1 if libsodium supports sodium_set_misuse_handler */ -#undef SODIUM_MISUSE_HANDLER - -/* Define to 1 if you have the ANSI C header files. */ -#undef STDC_HEADERS - -/* use default strptime. */ -#undef STRPTIME_WORKS - -/* Use win32 resources and API */ -#undef UB_ON_WINDOWS - -/* the SYSLOG_FACILITY to use, default LOG_DAEMON */ -#undef UB_SYSLOG_FACILITY - -/* default username */ -#undef UB_USERNAME - -/* use to enable lightweight alloc assertions, for debug use */ -#undef UNBOUND_ALLOC_LITE - -/* use malloc not regions, for debug use */ -#undef UNBOUND_ALLOC_NONREGIONAL - -/* use statistics for allocs and frees, for debug use */ -#undef UNBOUND_ALLOC_STATS - -/* define this to enable debug checks. */ -#undef UNBOUND_DEBUG - -/* Define to 1 to use cachedb support */ -#undef USE_CACHEDB - -/* Define to 1 to enable dnscrypt support */ -#undef USE_DNSCRYPT - -/* Define to 1 to enable dnscrypt with xchacha20 support */ -#undef USE_DNSCRYPT_XCHACHA20 - -/* Define to 1 to enable dnstap support */ -#undef USE_DNSTAP - -/* Define this to enable DSA support. */ -#undef USE_DSA - -/* Define this to enable ECDSA support. */ -#undef USE_ECDSA - -/* Define this to enable an EVP workaround for older openssl */ -#undef USE_ECDSA_EVP_WORKAROUND - -/* Define this to enable ED25519 support. */ -#undef USE_ED25519 - -/* Define this to enable ED448 support. */ -#undef USE_ED448 - -/* Define this to enable GOST support. */ -#undef USE_GOST - -/* Define to 1 to use ipsecmod support. */ -#undef USE_IPSECMOD - -/* Define to 1 to use ipset support */ -#undef USE_IPSET - -/* Define if you enable libevent */ -#undef USE_LIBEVENT - -/* Define this to enable use of /proc/sys/net/ipv4/ip_local_port_range as a - default outgoing port range. This is only for the libunbound on Linux and - does not affect unbound resolving daemon itself. This may severely limit - the number of available outgoing ports and thus decrease randomness. Define - this only when the target system restricts (e.g. some of SELinux enabled - distributions) the use of non-ephemeral ports. */ -#undef USE_LINUX_IP_LOCAL_PORT_RANGE - -/* Define if you want to use internal select based events */ -#undef USE_MINI_EVENT - -/* Define this to enable client TCP Fast Open. */ -#undef USE_MSG_FASTOPEN - -/* Define this to enable client TCP Fast Open. */ -#undef USE_OSX_MSG_FASTOPEN - -/* Define this to use hiredis client. */ -#undef USE_REDIS - -/* Define this to enable SHA1 support. */ -#undef USE_SHA1 - -/* Define this to enable SHA256 and SHA512 support. */ -#undef USE_SHA2 - -/* Enable extensions on AIX 3, Interix. */ -#ifndef _ALL_SOURCE -# undef _ALL_SOURCE -#endif -/* Enable GNU extensions on systems that have them. */ -#ifndef _GNU_SOURCE -# undef _GNU_SOURCE -#endif -/* Enable threading extensions on Solaris. */ -#ifndef _POSIX_PTHREAD_SEMANTICS -# undef _POSIX_PTHREAD_SEMANTICS -#endif -/* Enable extensions on HP NonStop. */ -#ifndef _TANDEM_SOURCE -# undef _TANDEM_SOURCE -#endif -/* Enable general extensions on Solaris. */ -#ifndef __EXTENSIONS__ -# undef __EXTENSIONS__ -#endif - - -/* Define this to enable server TCP Fast Open. */ -#undef USE_TCP_FASTOPEN - -/* Whether the windows socket API is used */ -#undef USE_WINSOCK - -/* the version of the windows API enabled */ -#undef WINVER *** 502 LINES SKIPPED *** From nobody Wed Oct 4 01:44:16 2023 X-Original-To: dev-commits-src-branches@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 4S0ctS3B0kz4wMw8; Wed, 4 Oct 2023 01:44: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0ctS2MTTz4cqW; Wed, 4 Oct 2023 01:44:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696383856; 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=8AevzWiONsOLrj+rkJtTnkOUWNw5rJ2WTAJh/ZW3FxU=; b=EdXWXuCcb3H+9GHfI3ufBDv7QGL+QToVeDzbnG7Jyhe6b98OgmvrE0qCLJFZDUUytP66TV SFebOEOv6cHHbTyBsmrrwHfiNYSdzRhiEWiNE9tzEWZicMR6agNownHStKEuDngX5T1i6g K50sHFaEphA+Og71rm0bdPxJk8LLGTgvqbYRVAq9tmekT67Gbd2iPJxelkoq7DaW6KFL+h V37uqYXnnWmD2NqG3Ow7zahCL/HJcEJttEpm6gC9HZ8vosX33y1VaNziaP22K/nU3Ny7FK x4FwBjYmprOs0vs8InscXhabq5WKWZUIE9+mODHgsaEPg+lwdFofcG7YEhUwbw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696383856; a=rsa-sha256; cv=none; b=ZpuyNIZ+MD0hX+ShrFmwCxmHdZXKpgCLML8XBlXjtLxA+gNqRiBcEpGaLbzAhOD4wk3IgH tBwtC9dm8QoqF96MachHMhSoeIk3kKx8LJDX1mIOXvM+KzIXArk+b7xQUceYXfeeO7gwd9 ZtALbUChUJhzTt7uNo76onJ+5jt7Kbo4xqVormuSv+7iCQ6m7gH+fBb8dJZasWwEo1jTyx 4/r6juWqqL1+IP8ad364GBqwROqT/2XwAP/pd8Gc39z4Pixw925Viw6QSUctLTwHtXUZdt XqtNLfV4z0nZ4vUhO1nD54vnhVe5aFkPfXwg2FJ/PuOm31F/kg0O4G7N9kjrvA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696383856; 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=8AevzWiONsOLrj+rkJtTnkOUWNw5rJ2WTAJh/ZW3FxU=; b=ON9Zo8f2PT/bo+MUkmgOf7F+TL2hefgZrIPOwW2CC+mzSN4JbFQA8P8QEl/C55KOeZkhe/ B/JPCbN+epKuuPEsBDKAQl6xfYbGWkYpfWEaqpgbOFJ4UcU7hj1dsfkFcFNCNNhb7s8xQC E+sXdPlyaoGdYM5a8gym2QD29F7rF9A2Lbxv/xfMZTTKpEASX4o0InAyyBQY+8AoFY8MGS d1aoYe2UwOeUhZdJC/AIKkniPgO/iDUZX8MdKd3ZGdzC745cGrVe6F9qnaOl+z0p00jMKA Mfy/UTq4UTJbQd12uQJORth6UTlJV4KHr/0cZY08TeetFdQZkfLFltTtJnKFfg== 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 4S0ctS1R1Pz40s; Wed, 4 Oct 2023 01:44:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3941iGSo020570; Wed, 4 Oct 2023 01:44:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3941iGcU020567; Wed, 4 Oct 2023 01:44:16 GMT (envelope-from git) Date: Wed, 4 Oct 2023 01:44:16 GMT Message-Id: <202310040144.3941iGcU020567@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: 05a0e28167d5 - stable/13 - xhci: Add support for 64-bit DMA in generic XHCI controller driver List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: 05a0e28167d5ab68762ad0a56d6dc9af4ed48d55 Auto-Submitted: auto-generated The branch stable/13 has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=05a0e28167d5ab68762ad0a56d6dc9af4ed48d55 commit 05a0e28167d5ab68762ad0a56d6dc9af4ed48d55 Author: Stephen J. Kiernan AuthorDate: 2023-08-11 16:06:02 +0000 Commit: Kyle Evans CommitDate: 2023-10-04 01:42:34 +0000 xhci: Add support for 64-bit DMA in generic XHCI controller driver The XHCI controller on 64-bit SoCs need to use 64-bit DMA. Add a quirk to tell the generic XHCI driver that 32-bit DMA needs to be used, if there are any that may need to use 32-bit DMA only. PR: 274237 Reviewed by: andrew Obtained from: Juniper Networks, Inc. (cherry picked from commit 332af8c25dfc9857e997817281d7b7fa406783ef) --- sys/dev/usb/controller/generic_xhci.c | 9 ++++++++- sys/dev/usb/controller/generic_xhci_fdt.c | 20 +++++++++++++++----- sys/dev/usb/controller/xhci.h | 1 + 3 files changed, 24 insertions(+), 6 deletions(-) diff --git a/sys/dev/usb/controller/generic_xhci.c b/sys/dev/usb/controller/generic_xhci.c index e0caf8f42af5..e89d1bc84497 100644 --- a/sys/dev/usb/controller/generic_xhci.c +++ b/sys/dev/usb/controller/generic_xhci.c @@ -61,7 +61,13 @@ #include "generic_xhci.h" +#if __SIZEOF_LONG__ == 8 +#define IS_DMA_32B 0 +#elif __SIZEOF_LONG__ == 4 #define IS_DMA_32B 1 +#else +#error unsupported long size +#endif int generic_xhci_attach(device_t dev) @@ -114,7 +120,8 @@ generic_xhci_attach(device_t dev) return (err); } - err = xhci_init(sc, dev, IS_DMA_32B); + err = xhci_init(sc, dev, + (sc->sc_quirks & XHCI_QUIRK_DMA_32B) == 0 ? IS_DMA_32B : 1); if (err != 0) { device_printf(dev, "Failed to init XHCI, with error %d\n", err); generic_xhci_detach(dev); diff --git a/sys/dev/usb/controller/generic_xhci_fdt.c b/sys/dev/usb/controller/generic_xhci_fdt.c index 8af9591a86b4..c850d2fb1314 100644 --- a/sys/dev/usb/controller/generic_xhci_fdt.c +++ b/sys/dev/usb/controller/generic_xhci_fdt.c @@ -55,12 +55,16 @@ #include "generic_xhci.h" +/* Flags for the OFW compat data table */ +#define XHCI_FDT_MATCH 0x01 +#define XHCI_FDT_32BIT_DMA 0x02 /* Controller needs 32-bit DMA */ + static struct ofw_compat_data compat_data[] = { - {"marvell,armada-380-xhci", true}, - {"marvell,armada3700-xhci", true}, - {"marvell,armada-8k-xhci", true}, - {"generic-xhci", true}, - {NULL, false} + {"marvell,armada-380-xhci", XHCI_FDT_MATCH}, + {"marvell,armada3700-xhci", XHCI_FDT_MATCH}, + {"marvell,armada-8k-xhci", XHCI_FDT_MATCH}, + {"generic-xhci", XHCI_FDT_MATCH}, + {NULL, 0} }; static int @@ -81,14 +85,20 @@ generic_xhci_fdt_probe(device_t dev) static int generic_xhci_fdt_attach(device_t dev) { + struct xhci_softc *sc = device_get_softc(dev); phandle_t node; phy_t phy; + int flags; node = ofw_bus_get_node(dev); if (phy_get_by_ofw_property(dev, node, "usb-phy", &phy) == 0) if (phy_enable(phy) != 0) device_printf(dev, "Cannot enable phy\n"); + flags = ofw_bus_search_compatible(dev, compat_data)->ocd_data; + if ((flags & XHCI_FDT_32BIT_DMA) != 0) + sc->sc_quirks |= XHCI_QUIRK_DMA_32B; + return (generic_xhci_attach(dev)); } diff --git a/sys/dev/usb/controller/xhci.h b/sys/dev/usb/controller/xhci.h index 0be0d185a869..3758815238ad 100644 --- a/sys/dev/usb/controller/xhci.h +++ b/sys/dev/usb/controller/xhci.h @@ -488,6 +488,7 @@ typedef int (xhci_port_route_t)(device_t, uint32_t, uint32_t); enum xhci_quirks { XHCI_QUIRK_DISABLE_PORT_PED = 0x00000001, + XHCI_QUIRK_DMA_32B = 0x00000002, }; struct xhci_softc { From nobody Wed Oct 4 03:38:48 2023 X-Original-To: dev-commits-src-branches@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 4S0gQd1gb9z4wXl4; Wed, 4 Oct 2023 03:38: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0gQd18ljz3K1N; Wed, 4 Oct 2023 03:38:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696390729; 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=yF+8AURP7+ygXK1zMYN6F3YATjvj7aKfucCghI1UWFE=; b=UBcTiGYpMZyViPTTum2JkYNajbhuoqsiGOhckKzgOgYlVzFO7PRgryIl6CnHNBpkSvpPbW BEuiQ7Jz5e8Yxz9LuliCXXdXvUAu4MFtSWTCWIMjFTBwbSO7eYaA2kZLzAnRkmRghe8KxB nMj1dH9h9G6o5x7l695bygNjNuJIJigZ5rXq98sx8LBqLc/339LrqhTIASAtZckrGJRYo4 vNA8SiIpn+w7ZV/pqHcmznvrvXnvubFZKyA0d9N7dDvyS0lnKXeSwuqr2Nu9levYTtexUj RvZzAtiuHIOwtOYqQpo5jfZRHFLs6YQ424XScy4EFFhdsYTiHoZbGZaCr2nwaQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696390729; a=rsa-sha256; cv=none; b=aIGIQ03wRKGEL16nucFz3ZOnVa4zMNviEKZWK2453VRGDIj+yfq0+qfIrr5Q32qpJFhH0m 3bW/dcXged+fyHy+rdk7L+B/hoDDV54+G6wmJ2nkTwm454q7xQqbRqDnpH6Fbs9ovwZPAV wUlNDfO8YlhJRrFldCtnQZ5P1xLwdt1RdPHSVh9w8dus2SAjRo8MufbOE5o5pWXmD2Myop CjIltf+20M1TrOvLMWeTeVA+ACzrriZJgZohInVeEBKo9CWUcS5VvcdN6fs51kyTFsXrZ9 9R3JLUeOVsVUR27M3IqtGcgGozQJ9BlNP2+F9ZcWF6tGgsbS/wsro9R0fiDQWQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696390729; 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=yF+8AURP7+ygXK1zMYN6F3YATjvj7aKfucCghI1UWFE=; b=R6GuI1jbk73oaEDWxKxlR2y32wVSK+8FGRR+UPdlT6iK0Ae9P5hyXAIG2IuuWajE766v6d ykH14ouTDy0dy+cGF/LdfRydhV+Mak3BFq6fAPG1oAykz+sAnyuHO1G0tJ8k9s36sjH5Qh b21665iguhbLLPTIUoLjMtObnNRTY771mZqIRwOsTXNoZtxfX0eNlExXO71X95R6LfzbCn M4I+tRzpXXtW5vqix8rmaR35r5p1vgBW9jph4C9BSzQgWYn+0OAx0kI7fwGdH7j9GrPVAo jF593+8quxiiZBVDCIwYckiforkTpeQj5b1KRkKeLK2lkB3PHy1mKNrV5snpbw== 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 4S0gQc6v1zz74Q; Wed, 4 Oct 2023 03:38:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3943cmZO005729; Wed, 4 Oct 2023 03:38:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3943cmZ8005726; Wed, 4 Oct 2023 03:38:48 GMT (envelope-from git) Date: Wed, 4 Oct 2023 03:38:48 GMT Message-Id: <202310040338.3943cmZ8005726@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Xin LI Subject: git: a2c359c0f771 - stable/13 - gve: Make LRO work for jumbo packets List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: a2c359c0f7715507f6a49a911becbd50a8521b9a Auto-Submitted: auto-generated The branch stable/13 has been updated by delphij: URL: https://cgit.FreeBSD.org/src/commit/?id=a2c359c0f7715507f6a49a911becbd50a8521b9a commit a2c359c0f7715507f6a49a911becbd50a8521b9a Author: Shailend Chand AuthorDate: 2023-09-07 13:28:26 +0000 Commit: Xin LI CommitDate: 2023-10-04 03:38:44 +0000 gve: Make LRO work for jumbo packets Each Rx descriptor points to a packet buffer of size 2K, which means that MTUs greater than 2K see multi-descriptor packets. The TCP-hood of such packets was being incorrectly determined by looking for a flag on the last descriptor instead of the first descriptor. Also fixed and progressed the version number. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D41754 (cherry picked from commit 5f62584a9adb7887bae33af617cfa4f43017abf8) --- sys/dev/gve/gve.h | 1 + sys/dev/gve/gve_main.c | 8 ++++---- sys/dev/gve/gve_rx.c | 3 ++- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/sys/dev/gve/gve.h b/sys/dev/gve/gve.h index 61781cddee94..c446199dff2d 100644 --- a/sys/dev/gve/gve.h +++ b/sys/dev/gve/gve.h @@ -164,6 +164,7 @@ struct gve_rx_ctx { struct mbuf *mbuf_tail; uint32_t total_size; uint8_t frag_cnt; + bool is_tcp; bool drop_pkt; }; diff --git a/sys/dev/gve/gve_main.c b/sys/dev/gve/gve_main.c index c3ee6d5c3433..cd7849778bce 100644 --- a/sys/dev/gve/gve_main.c +++ b/sys/dev/gve/gve_main.c @@ -31,10 +31,10 @@ #include "gve.h" #include "gve_adminq.h" -#define GVE_DRIVER_VERSION "GVE-FBSD-1.0.0\n" -#define GVE_VERSION_MAJOR 0 -#define GVE_VERSION_MINOR 9 -#define GVE_VERSION_SUB 0 +#define GVE_DRIVER_VERSION "GVE-FBSD-1.0.1\n" +#define GVE_VERSION_MAJOR 1 +#define GVE_VERSION_MINOR 0 +#define GVE_VERSION_SUB 1 #define GVE_DEFAULT_RX_COPYBREAK 256 diff --git a/sys/dev/gve/gve_rx.c b/sys/dev/gve/gve_rx.c index f5d8fd7a7b75..9be96cf1ee3a 100644 --- a/sys/dev/gve/gve_rx.c +++ b/sys/dev/gve/gve_rx.c @@ -546,6 +546,7 @@ gve_rx(struct gve_priv *priv, struct gve_rx_ring *rx, struct gve_rx_desc *desc, if (is_first_frag) { mbuf->m_pkthdr.rcvif = priv->ifp; + ctx->is_tcp = desc->flags_seq & GVE_RXF_TCP; if (gve_needs_rss(desc->flags_seq)) { gve_set_rss_type(desc->flags_seq, mbuf); @@ -567,7 +568,7 @@ gve_rx(struct gve_priv *priv, struct gve_rx_ring *rx, struct gve_rx_desc *desc, do_if_input = true; if (((if_getcapenable(priv->ifp) & IFCAP_LRO) != 0) && /* LRO is enabled */ - (desc->flags_seq & GVE_RXF_TCP) && /* pkt is a TCP pkt */ + (ctx->is_tcp) && /* pkt is a TCP pkt */ ((mbuf->m_pkthdr.csum_flags & CSUM_DATA_VALID) != 0) && /* NIC verified csum */ (rx->lro.lro_cnt != 0) && /* LRO resources exist */ (tcp_lro_rx(&rx->lro, mbuf, 0) == 0)) From nobody Wed Oct 4 11:23:38 2023 X-Original-To: dev-commits-src-branches@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 4S0skz1L2qz4vkYt; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0skz0qPXz4bFc; Wed, 4 Oct 2023 11:23:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418619; 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=pi3+aoL3T2v0wd4sSDFFsUsuC/PWaRha+bJPNepM7zY=; b=PDzth4hGHRSuIEbgbarDnZaQKysMt/mrExgPZFvKlyhbd10TeFvxFLLC4yx/yTCC83XzgP F7XDzcddbhp+IqcQ5bVL8RNMUcQMvy3qI2AOQ/XUElvwPEpWPAhIHpV1lDqEPnl/GLv5BZ 9b1x0iVoaMsPacY11MzQADIVd2lVpE1HV+dkfOCdDEypgLoCw2GDGYxfoC6hDuAjB2SvoI aD47pKars3uNljekQVG5uu/AZudq9o/V41Fk08p5fMUufMb6Iuu/RVwOqr7h/aXvfzvZTe HNKtPCKzx4aRwgVfioV4Qwhh4EFXztpA87ey8GnmxSSaSMpFZAs2RJpt9ypgww== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418619; a=rsa-sha256; cv=none; b=EtGMCKTgAsmSyLu1L6P7UI6+MDNSylCcuUyBRSt5AxojaWV7lLroARg0NEzTF4vXAJmgU1 ORxYO/U7Ghdw23AUA1BQpvhJc4JDjif/Eq3ORVorjwUV+gGZs4bR+tAN+S41kNwlmHKZ4E tqEfkHWNLeQqPpXnZ/8ChS5G6W7FPsTomGVHjwuxXo0LroT4rgaQU2Z56FNJl7mEkT/aSw NPhwkR1vC8opsOZ9JhH8vCO+tfPxGVfBe6pdmga/0QMkQu2RxCoJt9GEh+QCuLHmQtcxDf v7wozrjlYCykkHhhGyZ47MbrQ428md09x0SNAoI2RnHlYdXc5hXq3I7YLo4SeQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418619; 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=pi3+aoL3T2v0wd4sSDFFsUsuC/PWaRha+bJPNepM7zY=; b=ygjTUGAUjnbvdRIlSFSI/YSplqMAcO0a7pq13lXZ6892q6WWv2ccaMMLg2zZlbEgwKplf1 98NqUvQ830gApI0Trd0XPl4M9g1RxFoj/yl6CoxVr0gMjcIITvk+2aplQY+uMib1Jh9jyg xBVxporMoCwWftOpG3teBqXvEMg6ycr5CFD9GpaBEZuPqh7TUO35oAYxZV7zLQhOwjLuej wfi9EoxHOZKYn3X4k8lh9oH7pH7GTMdOoKNeuBJob77/DyfG1ncTnOH3g43rlVIKZHouzW mFUFfPYuVvaTIS4OzZU3NKQi2wJJOO4SAJC3QJpjF7mdSs1ZfOR5bmWUYr9srQ== 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 4S0sky6zXxzbK5; Wed, 4 Oct 2023 11:23:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNcRO084464; Wed, 4 Oct 2023 11:23:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNcW7084461; Wed, 4 Oct 2023 11:23:38 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:38 GMT Message-Id: <202310041123.394BNcW7084461@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: b0e0774daccc - stable/13 - dtrace_proc.4: Fix the description of pr_sname List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: b0e0774dacccf52992a862c78fee09f2f30bbe29 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=b0e0774dacccf52992a862c78fee09f2f30bbe29 commit b0e0774dacccf52992a862c78fee09f2f30bbe29 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2023-03-03 10:14:41 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 10:48:20 +0000 dtrace_proc.4: Fix the description of pr_sname MFC after: 2 weeks Sponsored by: Klara Inc. Sponsored by: ELW – Entsorgungsbetriebe der Landeshauptstadt Wiesbaden (cherry picked from commit 0ea0a371d2e0f821e4bd7e1c90c772781d80975e) --- share/man/man4/dtrace_proc.4 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/share/man/man4/dtrace_proc.4 b/share/man/man4/dtrace_proc.4 index 355ba63af1bd..5e217eb0e205 100644 --- a/share/man/man4/dtrace_proc.4 +++ b/share/man/man4/dtrace_proc.4 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd April 17, 2016 +.Dd March 3, 2023 .Dt DTRACE_PROC 4 .Os .Sh NAME @@ -186,7 +186,7 @@ Real scheduling priority of the thread. Currently always 0. .It Vt char pr_sname Currently always -.Ql ? . +.Ql \&? . .It Vt short pr_syscall Currently always 0. .It Vt uintptr_t pr_addr From nobody Wed Oct 4 11:23:40 2023 X-Original-To: dev-commits-src-branches@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 4S0sl02YNNz4vkhP; Wed, 4 Oct 2023 11:23:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0sl01rGBz4bJJ; Wed, 4 Oct 2023 11:23:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418620; 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=shuaA6w/RJmKnp+b3Ve6tvxqs+MR6N4wiMVrYPiLJWw=; b=YssHH7l63mn2dSHk3M5rbocCWQhdfJelgYMp8oPbWZfL89DiJ/FdOdpIEpCj1M6UQo3Eez FKJMSHXUaHr3LdzlISGn3G55mvftdH5JBAL7+8lyEoG868q2cMmjF6vdc6MugyXNqDcxLS 2hUX9UWXKWX4sibVXmPwUulCYOrgfTO1R0Cwwo/FFRruQcZc4uQxcjLJ8Q8yQkxf/Uiobc JCcE5cnarCI3YjU4SbjZQuIBRML0QN/UL1k7kt2fgGdfsvNKI3U7WAfL0TxkMxmeAOcATP 9KtLBciJvqWxGCbbET1ZkUxez7SH3OEDcFflbfseLVtUG0wxcq7Au8HcLBKIXw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418620; a=rsa-sha256; cv=none; b=N1KWbKM5vJqlfOEI83AguQxAgOysqwk1qiDrlAZoT9cv/w34Vz4BCbphZoTkxwaQhW7V4d uH0UCJLufVXKYpcX7COWWnU9t5ChjGVljRN3eRc1bcyywvaSg+K6mvppy3GPgAkw1YpsJ8 MtzkGGb2o4yqRX+2W8vDUbYnDKDpSDmOa4hGIn/fk4wlU4btSx7uxzrEe7o3zdACSFh4Ql nTZmah9RQqvaAcOQHz62LLWhNWt4cFFoBIZv4n0Y1cT4AVVrBMX0hxCHAe+XlNcLqeFwDq NkR01iUpQIR4TD1heeTCQ0AVF2OQbnf75gKRO7+PbvoKY0VaMqfLmI4MAif8YA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418620; 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=shuaA6w/RJmKnp+b3Ve6tvxqs+MR6N4wiMVrYPiLJWw=; b=K79eL1C6IL95UUPsmT+C1viqFnWZgdLj66uyDcNLFyfrbHx/rVUixSJaQU87WYBD/ODBPp i/46nEggNWQGgNnTPsHEhA5Y3B1c+2NbOOM5rDR8f/5tL9sA9oabdVwUaqJ2O2xoR86JpG dQCvp0le1eOgQuEHEa310NFO7buG7C08Rxsl5l9Bf4Su1Zr+zdoyiCVcx4I5vP6jX1Mf0s GyBG8ZS6ZucWmJGIY9DU5e2hk5GZwBKVAMbpgAREp0mMrs/rDsS7vqxbnHbLju5WvbWWWA W/UN3c/ajyq6hR+Y0JkKeM56CXBd2sffYN1Nnby8szwLwmNAfbiE5xouIYjm8A== 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 4S0sl00vTJzbdW; Wed, 4 Oct 2023 11:23:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNe7K084525; Wed, 4 Oct 2023 11:23:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNePj084522; Wed, 4 Oct 2023 11:23:40 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:40 GMT Message-Id: <202310041123.394BNePj084522@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 65b22ee09319 - stable/13 - date.1: Examples: Use syntax that is also compatible with csh List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 65b22ee0931970896f1189e9f620d9895f9d4070 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=65b22ee0931970896f1189e9f620d9895f9d4070 commit 65b22ee0931970896f1189e9f620d9895f9d4070 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2023-02-27 16:34:00 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 10:51:32 +0000 date.1: Examples: Use syntax that is also compatible with csh MFC after: 1 month Sponsored by: Klara Inc. (cherry picked from commit de7a6b6fd04ee686364883a817a4b707e3567d27) --- bin/date/date.1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/date/date.1 b/bin/date/date.1 index 850e37bba0ac..39a314214da6 100644 --- a/bin/date/date.1 +++ b/bin/date/date.1 @@ -31,7 +31,7 @@ .\" .\" @(#)date.1 8.3 (Berkeley) 4/28/95 .\" -.Dd May 31, 2022 +.Dd February 27, 2023 .Dt DATE 1 .Os .Sh NAME @@ -453,7 +453,7 @@ will display .Pp Finally the command: .Pp -.Dl "date -j -f ""%a %b %d %T %Z %Y"" ""`LC_ALL=C date`"" ""+%s""" +.Dl "date -j -f ""%a %b %d %T %Z %Y"" ""`env LC_ALL=C date`"" ""+%s""" .Pp can be used to parse the output from .Nm From nobody Wed Oct 4 11:23:41 2023 X-Original-To: dev-commits-src-branches@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 4S0sl14tbRz4vkfC; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0sl13JcPz4bc3; Wed, 4 Oct 2023 11:23:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418621; 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=5ERQJrJfWPkVRBnNtanC6bccir6xO5cmKgclZoDscFA=; b=XSMb5rmTPhSEXGuDX+0JAv4wbnA1drxPtPy9DKuTwmaU/+4o7FRNrpVfEUV83yOrGQGSGa GKnGYE05DqRuDNKteVctaOCohfDsG3gLVx3OV6EIY4CjnVqtVhuVo067G9h54QvWAJ0g2M U9TMHjmiaxbh7dVFfze3ReXOfRbLyFAFUN9V2nuh/ENm0JQWe+FCHFQ5jgtjIcZa/XrsmN jeKMk16/EFpQR/aKq086Sk7WkJMYobJ3mgrMNAWcLNtzKECzGpMjKQ18f3ik0//6abZ44v 0ANUpqF6Pg/TC0rD+IgydQtad50wZxuhisF5Cdh2ghstmKVgCdiICqfoSgngdA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418621; a=rsa-sha256; cv=none; b=tnAcQWiXkdaXaLPwl8XE9ITm8GRxnDksZvOp3X6d8X0CP3xR1TjG9eaAq5FZwZXJUpLC+Z y+YzeEityDdQnGWjJlLMk+nMxKl6/ikRg39N7ec+THDF9Oex2w+vMKFxl46PMdN+RLnz39 9mXv/WKs9vOSMQNfC/wxX/c9thofNxdtlEeWRLNly3Un5Kp8BuElG65+U+UBLeSF7SJZiG tjpoWAro4zu5/f7gvGBMEroSPTkn9bA+0JMdn+d2/Yk1LwKTAN7eO5qHWmPqKNaUkjrgUk FhDGxd5sctIAZDSTQ5M5Zuu8WI1ius3CsYD0DzKD5xpIoMUvYpAVPmQBEBb5DA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418621; 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=5ERQJrJfWPkVRBnNtanC6bccir6xO5cmKgclZoDscFA=; b=c255+uxLHRBrnhifP5gIATpJoxo8HPtvoCkAs7rqH6aUu8QnDT6dnyMH+NRSAHv7xg2t49 3xG7ZdiGEnwJFjt6/ecz8mTgCEXTbL+P9guvJwC99tvPEFKoS0nP0RCz6ATZagZF7W0zxL 4M6AszCbLQvgrRYZ5JXyPz3V4JhkXEQ7M+ioK530eHdoH1wyphxn8j5dOTb/RokoEfPSac 8Ce8IL1v6uEA87fTJnOHjEn2f0xKQRe7fgpFWsHjbJ0tNrjth7Pi4X/UfMpIJGRenjNQW0 4ao5OsaOTNjBJHy4ENHP9shn+AANWrALQYZKOxiXv5paN2SQMsG6/Ne0dU8Rxg== 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 4S0sl11mBszbkb; Wed, 4 Oct 2023 11:23:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNfAB084582; Wed, 4 Oct 2023 11:23:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNfKF084579; Wed, 4 Oct 2023 11:23:41 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:41 GMT Message-Id: <202310041123.394BNfKF084579@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: f15d8ede5166 - stable/13 - powerd.8: Provide a whole path to power_profile for clarity List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f15d8ede5166e361c6e881f031b2aaa9f9042d8c Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=f15d8ede5166e361c6e881f031b2aaa9f9042d8c commit f15d8ede5166e361c6e881f031b2aaa9f9042d8c Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2023-02-25 16:28:49 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:10:42 +0000 powerd.8: Provide a whole path to power_profile for clarity MFC after: 3 weeks (cherry picked from commit 28111ddf9ee6d14eea6941a66168f2aeb361746d) --- usr.sbin/powerd/powerd.8 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.sbin/powerd/powerd.8 b/usr.sbin/powerd/powerd.8 index e9beef44e63a..43442a38b97f 100644 --- a/usr.sbin/powerd/powerd.8 +++ b/usr.sbin/powerd/powerd.8 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd November 6, 2021 +.Dd February 25, 2023 .Dt POWERD 8 .Os .Sh NAME @@ -168,7 +168,7 @@ utility should also power down idle disks and other components besides the CPU. If .Nm is used with -.Pa power_profile , +.Pa /etc/rc.d/power_profile , they may override each other. .Pp The From nobody Wed Oct 4 11:23:42 2023 X-Original-To: dev-commits-src-branches@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 4S0sl23znwz4vkVB; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0sl23VtKz4blx; Wed, 4 Oct 2023 11:23:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418622; 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=4K6juzbhnQrMr+cNGyPBRrMWKr50d6RuMzVJoPoFKgs=; b=WToZwS+aGG1Z6+Oy8gZrDT3oFchJhf/cz5ipQRLMZ+h9RMm9AuQxtsS9yvD4ISQNmcad+2 3zp0Vvn6NtR8AcQhPZuOuKyzDF3K8s5j3lnOWKH/HUWLPVcbaybO6OtGn/RB7TU0OFNene s1inuxqSXb7stKK6PC3PI3jzuBXFTXBd+QmdF3C1FlLQr3FF5oS1oyvbOAiGRoQIcmfUw8 MTE2vCiip9tW2Z+xfnFfPIXnx2hLOd9cDvqNYwJ56YNloiXavM8hrVwWKCZXh/dtwdbEXG IpMYwkpflU0YwVHOrP+5/Hv2uVXLlRHmIrkUAo054Hh7AUZsBP2mVLwG2Hz0Xg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418622; a=rsa-sha256; cv=none; b=cvJp/VF64qbUTeg40Gckf+fUQm1EWMCNnXpjy7f1i/Yg4f6+0gnOvQtDd5qfLkc11dASaH YTMXJQxTCwpLYf+EluCbd5WxbbGVAtA0uLTu6VjFwFiaLSm3wSWLo4/5E8R2BYvQOWxpWy CPMJoIu06JoCoyGOHW2O8wsWQZsi/eJVWKt7OYFDYaEJt/wdbSNeIWlbRR9favSZZZKgpF 9MAyS2qxatT9nOspImzAf5waQJ9455WI+Zh+a0G1YJQ9MrZj1rqjn7nIWExR+Vj2D3+ao9 rr0NJOYJW5TfRjitZ9hSpkE3lM7FNye2zYHsJUCC0qryTmHXcBaLmuKanQcR+g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418622; 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=4K6juzbhnQrMr+cNGyPBRrMWKr50d6RuMzVJoPoFKgs=; b=NLDIJZFE7O1YeLFrY5Z9QTcKKCZXh+3/ZmdUtpN5egZTpD0QnzCFWATo5y+V9L8P4i5fBL FMCz+/xUEcVdvmQT8WtXnwnWe8fAtOP0RTon2RJTNNqEpYXZ1+UjWQslc2t9fTv3EF9vZw 3g7kKZ97FIwCBXZAK4rhHMWJPa3LfAz/HcDkKaQXDfCcx/AHORvx91oeNseTIHT8WpzkTF UWTUaq0YO40IJCxV9WsrocYQjeb0c7gjdqPiQlEqcjD6p8NOCntEjQBE07kuK/TuUx1Do0 Le8plDox15fl3aQLTDVyepuhDDxgeQ0fDf5vvFkWGZa75LZsYfNk5SrcOoQYog== 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 4S0sl22X81zbjg; Wed, 4 Oct 2023 11:23:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNgt1084627; Wed, 4 Oct 2023 11:23:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNgKi084624; Wed, 4 Oct 2023 11:23:42 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:42 GMT Message-Id: <202310041123.394BNgKi084624@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: b10a23df1cc2 - stable/13 - ifconfig.8: Improve readability of vlanproto's description List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: b10a23df1cc231aa8ae2ae345b12823afa658979 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=b10a23df1cc231aa8ae2ae345b12823afa658979 commit b10a23df1cc231aa8ae2ae345b12823afa658979 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-08-19 16:17:44 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:11:05 +0000 ifconfig.8: Improve readability of vlanproto's description Sponsored by: Klara Inc. MFC after: 1 week (cherry picked from commit 197947e0a3b27b0eb455fdcd29def867efe582e6) --- sbin/ifconfig/ifconfig.8 | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) diff --git a/sbin/ifconfig/ifconfig.8 b/sbin/ifconfig/ifconfig.8 index f4d49be0abb9..f280a263cb51 100644 --- a/sbin/ifconfig/ifconfig.8 +++ b/sbin/ifconfig/ifconfig.8 @@ -27,7 +27,7 @@ .\" .\" From: @(#)ifconfig.8 8.3 (Berkeley) 1/5/94 .\" -.Dd June 20, 2023 +.Dd February 1, 2023 .Dt IFCONFIG 8 .Os .Sh NAME @@ -2887,17 +2887,15 @@ must both be set at the same time. .It Cm vlanproto Ar vlan_proto Set the VLAN encapsulation protocol to .Ar vlan_proto . -Supported encapsulation protocols are currently -.Dq 802.1Q -and -.Dq 802.1ad . -The default encapsulation protocol is -.Dq 802.1Q . -The -.Dq 802.1ad -protocol is also commonly known as -.Dq QinQ ; -either name can be used. +Supported encapsulation protocols are currently: +.Bl -tag +.It Cm 802.1Q +Default. +.It Cm 802.1ad +.It Cm QinQ +Same as +.Cm 802.1ad . +.El .It Cm vlanpcp Ar priority_code_point Priority code point .Pq Dv PCP From nobody Wed Oct 4 11:23:43 2023 X-Original-To: dev-commits-src-branches@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 4S0sl35KPwz4vk64; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0sl34kDzz4bXc; Wed, 4 Oct 2023 11:23:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418623; 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=3HMoOXocNzDDY3Ku4v4lgq/ebkjA2S7xt0RxT4Xfw+k=; b=WOPPsQNr6riau0fZgo02ZhsMJWQHHHbzq6umbJXb4Rk8OSrDNfaawdpn6lzMt8KrCQKUpX KMlAU4aBlbDAUrGEYa5CiPXBVp4BSb8KdD47B9t0yNPjFRArEqr+qJaTDHrHp5grKWlN4C NY/zrBJpwtk6zaU+TLzvJLCpXKWUcMglroBC+sPceMP9LgQjYabMaEojEKZHdIb6xwNTT4 M6QhRMvVVdSjKDGoZWMLSlT5Iwj7roi9ucndfBDanJdZoubtgAZo0v7MKrKqVkmqE4ce4O X40PVLSw1IiWAHBYKkvOCq8XkZ5nZ/o/xJb96I3Wv1LFQua+IYQ2+rdgV9k1kg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418623; a=rsa-sha256; cv=none; b=W3foDNtpuNqle52+TkfKEye+3Fxy/x9YmDlenAX2Z/ri6iix4mwB5qdxLUCgYS6smUoVjl LUnujmN1UO2JYI7i9nOb2CVAFSgihM0WAF56TyN8bZPhmDLQH6HCh5TwcjxVbwkYhUytMU tJ+6qNPVXn3fd1I6/hhFir8UzlRstSBzDyZObIAIIePFVU56FYJPwLN4YVVAGBHJzxDFiD Lcg/FRCkCyn+NamYKHyAccjMSv5v50RAV4uTym1DNPJvUZ41gFMbEMJZEkFrmJdDSDNIH6 QXsZE8KCohBawNTw6ZU7cL1cHUb/egVdtHz5nYJNBkqDj8U2mDL/903JwUy5Wg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418623; 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=3HMoOXocNzDDY3Ku4v4lgq/ebkjA2S7xt0RxT4Xfw+k=; b=eLHbIVTRqeFTJa8NSHdk6M1RGsMqZueRNc9G4mrCOrtunZp+T+p5OeQ2ly/vLzBsuSVCKM BAb3n3FPrPXdEGvOytOow2gBY3islV8KTuIuGfd2HVmDJsvMb6M8swEOpNAYuN9j0FwP0G 6/czaQSDzYuWXVnmydyjmwy2e1zfP9LIFvmqnghMU5j48dhBtIe/O8NoNeE6sKsZJz9A7J hcTbhV2NGdZ154VbTkQVJe7vTQ1fvsLsXL8KVmyBFG5+btAetWDEdZ5T3koSoI9AftGeGo wIffB8nMxGDkdAmaJzU4fEzjsPue5UibGf6auZ3j40dNZmjNDFYrI9duWDCqwA== 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 4S0sl33n4Yzbjh; Wed, 4 Oct 2023 11:23:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNhhi084674; Wed, 4 Oct 2023 11:23:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNhSH084671; Wed, 4 Oct 2023 11:23:43 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:43 GMT Message-Id: <202310041123.394BNhSH084671@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 6d5f98380ecf - stable/13 - exports.5: Clean up EXAMPLES and STANDARDS List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 6d5f98380ecf7544c50a156928219c684ac73205 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=6d5f98380ecf7544c50a156928219c684ac73205 commit 6d5f98380ecf7544c50a156928219c684ac73205 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-08-16 13:03:20 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:11:13 +0000 exports.5: Clean up EXAMPLES and STANDARDS There was a missing sentence in the description of the second mount entry in the example. Fix that and some other bits in the EXAMPLES section. Also, make the STANDARDS section a bit more readable. MFC after: 1 week Sponsored by: Klara Inc. (cherry picked from commit f9572577cf5f28d8e7592b4f1fb24c54e8e79783) --- usr.sbin/mountd/exports.5 | 48 ++++++++++++++++++++++++++++------------------- 1 file changed, 29 insertions(+), 19 deletions(-) diff --git a/usr.sbin/mountd/exports.5 b/usr.sbin/mountd/exports.5 index 714e5e72b884..56facef29a12 100644 --- a/usr.sbin/mountd/exports.5 +++ b/usr.sbin/mountd/exports.5 @@ -27,7 +27,7 @@ .\" .\" @(#)exports.5 8.3 (Berkeley) 3/29/95 .\" -.Dd November 9, 2021 +.Dd August 16, 2022 .Dt EXPORTS 5 .Os .Sh NAME @@ -411,6 +411,13 @@ file. the default remote mount-point file .El .Sh EXAMPLES +Given that +.Pa /usr , /u , /a +and +.Pa /u2 +are +local file system mount points, let's consider the following example: +.Pp .Bd -literal -offset indent /usr /usr/local -maproot=0:10 friends /usr -maproot=daemon grumpy.cis.uoguelph.ca 131.104.48.16 @@ -427,27 +434,21 @@ V4: / -sec=krb5:krb5i:krb5p -network 131.104.48 -mask 255.255.255.0 V4: / -sec=sys:krb5:krb5i:krb5p grumpy.cis.uoguelph.ca .Ed .Pp -Given that -.Pa /usr , /u , /a -and -.Pa /u2 -are -local file system mount points, the above example specifies the following: -.Pp -The file system rooted at +The file systems rooted at .Pa /usr -is exported to hosts -.Em friends -where friends is specified in the netgroup file +and +.Pa /usr/local +are exported to hosts within the +.Dq friends +network group with users mapped to their remote credentials and root mapped to UID 0 and group 10. -It is exported read-write and the hosts in -.Dq friends -can mount either +They are exported read-write and the hosts in +.Dq friends . +.Pp +The file system rooted at .Pa /usr -or -.Pa /usr/local . -It is exported to +is exported to .Em 131.104.48.16 and .Em grumpy.cis.uoguelph.ca @@ -590,12 +591,21 @@ afterwards, whereas NFSv3 rejects the mount request. .Xr rpc.tlsservd 8 , .Xr showmount 8 .Sh STANDARDS -The implementation is based on the specification in +The implementation is based on the following documents: +.Bl -dash +.It .Rs .%T "Network File System Protocol Specification, Appendix A, RFC 1094" +.Re +.It +.Rs .%T "NFS: Network File System Version 3, Appendix I, RFC 1813" +.Re +.It +.Rs .%T "Towards Remote Procedure Call Encryption By Default, RFC nnnn" .Re +.El .Sh BUGS The export options are tied to the local mount points in the kernel and must be non-contradictory for any exported subdirectory of the local From nobody Wed Oct 4 11:23:44 2023 X-Original-To: dev-commits-src-branches@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 4S0sl45xzWz4vkZ2; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0sl45NjBz4brj; Wed, 4 Oct 2023 11:23:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418624; 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=w9nAsIKFRdNinjquat/Bm6akci/B2WBNEMlKQBI7w/c=; b=YnPdnE1sB+rmClIm/IaFOWqy/DJoFTIxtmoEpWVb/B+S2s09XEg+S0OKHySqm7cw0oqSif 62ZBzajgrLobJsCXlw+ZDORUH9Ek5cUtr+6c1J3i2u3ow0VQB7PSIlldV9xyg2cZrnIqAh lTjZ2kO9D4eiWPHvutwceDFpDGEwXQhx3TQOqye+JXiuXmHlx0Rtv8pcxhIkv8Csu9NBCS hjsmt4Io4XXhjl4tkjSUi7xNFgVY14zqIvzWpayfBKFIKiJ3aKIbxgC2ugJXlfxRt1e2OG FLuU6TyYUxqYbR+OC3Lp2BfNKWke2wx2dT72bxv95g2Kf+Dw8ansT3Vltmuidg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418624; a=rsa-sha256; cv=none; b=UCPNl/pfsfMmMXtBIpJDfnpmsALra+nKMMcI0KGhj1sxEeE9V2PPEUb2dZLzvwvYUYFyvm zZ+MUy35scZrNxemEiOWEEzMSt5I7hldIP5Y6yRwwIuc2ECGmf9rdUhdAXLP+JmQipzCjq PMneLy9C1XbSaBYyA5x0RkZ3kw6ulV3ZK01l794Lnte+L5HxcayFLX0+C9jVkX3ia+YVo0 qJU8ycYMXqtEYWXsTE0mMKheRPJjxdDdc29goPoPTH+TS9q2x3bxL8Oa1NIa/oWPFy0nhZ /90G2MBCL4d+Oq+WsADAAg2rTr1+Nr1jb9c47t1otV6iV0wX56CMMptEtW6pBQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418624; 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=w9nAsIKFRdNinjquat/Bm6akci/B2WBNEMlKQBI7w/c=; b=WFNBhfNxQAfFd4L3eLoxkT6Pg0m7HZoxmzcFG6kYhdvUztvgu66N2k9YyeWXoCj5ODCbbS 7o4i97Sji4NWul9BhAqvu8CVSQSHk9CIBJImzo4Qsjx4tY1fiM2q9uCBf7jgGOFYGVyvmE ysSC0THC2K3u3NUArUPTsGav8pZQrGPpxaAvrUS4mU5bkIUKZxVWYMhXreFZViareUojkj 8h+5mOUxCwViPE536ziHGkABp2MQ932LYGOFoY8DjwxxlT6BDG7SuGnZ9fq1HtlC+Pd7qb QFnVqUDfXhiSwIoyvCZ0MeK+2TDKghY+9vUzG5M4/5gHOfmrclbByM16C1fvOQ== 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 4S0sl44VRPzbdX; Wed, 4 Oct 2023 11:23:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNicg084737; Wed, 4 Oct 2023 11:23:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNiRV084734; Wed, 4 Oct 2023 11:23:44 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:44 GMT Message-Id: <202310041123.394BNiRV084734@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 220af70281c5 - stable/13 - rc: Start testing the rc(8) framework (beginning with *_oomprotect) List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 220af70281c5c04610f6bf4ce904e269d1532992 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=220af70281c5c04610f6bf4ce904e269d1532992 commit 220af70281c5c04610f6bf4ce904e269d1532992 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-07 18:24:27 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:11:18 +0000 rc: Start testing the rc(8) framework (beginning with *_oomprotect) This change adds 2 tests to make sure that the *_oomprotect variable sets the protection against OOM killer properly within rc(8) scripts. This is also adding the first tests for the rc(8) framework. More tests will be added as we go. PR: 256148 Approved by: des MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D35745 (cherry picked from commit e7437ae907c89bf85a99c5cbb7ddd194a1ff1354) --- etc/mtree/BSD.tests.dist | 2 + libexec/rc/Makefile | 3 ++ libexec/rc/tests/Makefile | 3 ++ libexec/rc/tests/rc_subr_test.sh | 103 +++++++++++++++++++++++++++++++++++++++ 4 files changed, 111 insertions(+) diff --git a/etc/mtree/BSD.tests.dist b/etc/mtree/BSD.tests.dist index 39d1e7801619..46a305aec62d 100644 --- a/etc/mtree/BSD.tests.dist +++ b/etc/mtree/BSD.tests.dist @@ -429,6 +429,8 @@ atf-sh .. .. + rc + .. rtld-elf .. tftpd diff --git a/libexec/rc/Makefile b/libexec/rc/Makefile index 9383ab124839..4f9d374c8f15 100644 --- a/libexec/rc/Makefile +++ b/libexec/rc/Makefile @@ -23,4 +23,7 @@ CONFETCDEFAULTSPACKAGE= rc SUBDIR+= rc.d +HAS_TESTS= +SUBDIR.${MK_TESTS}+= tests + .include diff --git a/libexec/rc/tests/Makefile b/libexec/rc/tests/Makefile new file mode 100644 index 000000000000..c44c6db90b77 --- /dev/null +++ b/libexec/rc/tests/Makefile @@ -0,0 +1,3 @@ +ATF_TESTS_SH+= rc_subr_test + +.include diff --git a/libexec/rc/tests/rc_subr_test.sh b/libexec/rc/tests/rc_subr_test.sh new file mode 100644 index 000000000000..0ca790e39a14 --- /dev/null +++ b/libexec/rc/tests/rc_subr_test.sh @@ -0,0 +1,103 @@ +# +# Copyright 2022 Mateusz Piotrowski <0mp@FreeBSD.org> +# +# SPDX-License-Identifier: BSD-2-Clause-FreeBSD +# +# 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. +# + +atf_test_case oomprotect_all +oomprotect_all_head() +{ + atf_set "descr" "Verify that \${name}_oomprotect=all protects " \ + "the command and all its current and future children" + atf_set "require.user" "root" # For protect(1). +} + +oomprotect_all_body() +{ + __name="$(atf_get ident)" + __pidfile="$(mktemp -t "${__name}.pid")" + __childpidfile="$(mktemp -t "${__name}.childpid")" + __script=$(mktemp -t "${__name}.script") + + cat >> "$__script" <<-'LITERAL' + . /etc/rc.subr + name="$1" + pidfile="$2" + _childpidfile="$3" + _rc_arg="$4" + setvar "${name}_oomprotect" all + command="/usr/sbin/daemon" + command_args="-P $pidfile -p $_childpidfile -- /bin/sleep 5" + run_rc_command "$_rc_arg" + LITERAL + + atf_check -s exit:0 -o inline:"Starting ${__name}.\n" -e empty \ + /bin/sh "$__script" "$__name" "$__pidfile" "$__childpidfile" onestart + atf_check -s exit:0 -o match:'^..1..... .......1$' -e empty \ + ps -p "$(cat "$__pidfile")" -ax -o flags,flags2 + atf_check -s exit:0 -o match:'^..1..... .......1$' -e empty \ + ps -p "$(cat "$__childpidfile")" -ax -o flags,flags2 + atf_check -s exit:0 -o ignore -e empty \ + /bin/sh "$__script" "$__name" "$__pidfile" "$__childpidfile" onestop +} + +atf_test_case oomprotect_yes +oomprotect_yes_head() +{ + atf_set "descr" "Verify that \${name}_oomprotect=yes protects " \ + "the command but not its children" + atf_set "require.user" "root" # For protect(1). +} + +oomprotect_yes_body() +{ + __name="$(atf_get ident)" + __pidfile="$(mktemp -t "${__name}.pid")" + __script=$(mktemp -t "${__name}.script") + + cat >> "$__script" <<-'LITERAL' + . /etc/rc.subr + name="$1" + pidfile="$2" + _rc_arg="$3" + setvar "${name}_oomprotect" yes + procname="/bin/sleep" + command="/usr/sbin/daemon" + command_args="-p $pidfile -- $procname 5" + run_rc_command "$_rc_arg" + LITERAL + + atf_check -s exit:0 -o inline:"Starting ${__name}.\n" -e empty \ + /bin/sh "$__script" "$__name" "$__pidfile" onestart + atf_check -s exit:0 -o match:'^..1..... .......0$' -e empty \ + ps -p "$(cat "$__pidfile")" -ax -o flags,flags2 + atf_check -s exit:0 -o ignore -e empty \ + /bin/sh "$__script" "$__name" "$__pidfile" onestop +} + +atf_init_test_cases() +{ + atf_add_test_case oomprotect_all + atf_add_test_case oomprotect_yes +} From nobody Wed Oct 4 11:23:45 2023 X-Original-To: dev-commits-src-branches@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 4S0sl60N1sz4vkZ4; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0sl56j51z4bvf; Wed, 4 Oct 2023 11:23:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418625; 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=Haaok4PZuxstGosXfTr0GsJD3okoIUryjRe0Y7Bft04=; b=xvD3f15oCSUDOzqgLmgQ9gr/tPK9dyqUY4eAfyOiaQ3rH648ajIbMZruOT3FcVo6tvsj1s LrQDI2WozEoToGH3UtijKps47TFVaekxnJ4TpJZrsE/THXm6mOWqNf5p/bM4+9JND3TV30 UTMoJaJoz1EzvQPSZjW4PDlFUIuI4oiPUDjQvcNTO586h3UxsCcGB+lEPPhaJMcS1L/BRH wkrVX+A/4PUvHrTOz46wfOmynoWNRIZvo6J3VJQe/ULbQzt7C6qt13hjZP8xYB9FoLIIEI usyztuuveUAe3uhWJqn1GMpYEud2Ae4F6JvS9Ya7hbHLY46Z/4ltma8e6MWKNg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418625; a=rsa-sha256; cv=none; b=AUQgEype5x5MULW+epxCuGpFmwhoP3HUE1Sy1coXDO30+tJhmlMVhyESkRAKPLLoHB//AV W5EwxVCtsUQKBBn97yFvNfsDIMBY7AmNiMsW2lqy4wxkpGhkUDWh7qHnIt0IjFXhoaqBeD oiqZdXZuWE6kwYnSXmslJx75SZEy0IteHT8grkZ/vETKdXAn5bz9xp2lBJx8gyK0Gp8aR6 hxrrM9fnUnKb3pGcoCg6ybBs7PRCBP44/rS2cXvX1brCXrE4HzJX7Oq00t3xO0dshZyy74 ELeOs3ur8aryy43Rf1s9/r2qDIBPwXCbyMrCXijaXAl9GFVPEasFUAm/hjtS2A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418625; 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=Haaok4PZuxstGosXfTr0GsJD3okoIUryjRe0Y7Bft04=; b=P+yOKVZiu+WMHgr33bp4boHac0HSqze350+K6FaIDObaAL7Ip8bRF/HWhyCogHp1WxXkkh jhfMWjzFBHDVujU/vwLjOuR5993Q+sZZLYWt7PbsGU/Hvg0V38Bx0jk8vAbkMEcCIlxu32 mg3A76nWvp5CtKj8oP67FAJYL2HMKaWuS1xuoOL5Qvc5kxVaGPZ+iIVfpWeqHNkMRE4b4z 3irujBNp5IChFBBnZLFkqalPRNByKggg9XqaLgdB5K6jiwNgKI8cOney9z23CRELGOutgN 8+b5Eg4LvJ1LJA6RFeRSxIj2rRDY1xI5TmoVx3z6h5uoqMIbF7AsRCDG20mcOA== 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 4S0sl55Vd9zbK6; Wed, 4 Oct 2023 11:23:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNjAO084777; Wed, 4 Oct 2023 11:23:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNjJP084775; Wed, 4 Oct 2023 11:23:45 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:45 GMT Message-Id: <202310041123.394BNjJP084775@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: a22d61c6918c - stable/13 - gmirror.8: Remove references rc.early List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: a22d61c6918c0f76ac7af2c82bc2a87a780f70b9 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=a22d61c6918c0f76ac7af2c82bc2a87a780f70b9 commit a22d61c6918c0f76ac7af2c82bc2a87a780f70b9 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-21 19:43:14 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:11:41 +0000 gmirror.8: Remove references rc.early The manual page of gmirror describes how gmirror providers can be used for kernel dumps. Unfortunately, the instruction references /etc/rc.early, which is no longer a part of rc(8). Remove references to rc.early and suggest creating an rc(8) service script instead. Future work: In the Problem Report on Bugzilla, Lawrence Chen suggested adding example rc(8) scripts to the gmirror. However, those examples need to be tested before they become official reference examples in the base. Also, those scripts should probably land directly to /etc/rc.d, /usr/share/examples/rc.d, or /usr/share/examples/gmirror instead of the gmirror manual page. PR: 178818 Reported by: Lawrence Chen Fixes: dd2b024a336f Removal of early.sh MFC after: 1 week (cherry picked from commit a848315f68047ae46a5d96cbc7a890e645ce646f) --- lib/geom/mirror/gmirror.8 | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/lib/geom/mirror/gmirror.8 b/lib/geom/mirror/gmirror.8 index 22639646a4b5..af9ad87f22d0 100644 --- a/lib/geom/mirror/gmirror.8 +++ b/lib/geom/mirror/gmirror.8 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd November 30, 2017 +.Dd July 21, 2022 .Dt GMIRROR 8 .Os .Sh NAME @@ -386,21 +386,26 @@ Reading a dump from the mirror on boot will only work if the balance algorithm is used (that way .Nm will read only from the component with the highest priority). -If you use a different balance algorithm, you should add: +If you use a different balance algorithm, you should create an +.Xr rc 8 +script that sets the balance algorithm to +.Cm prefer , +for example with the following command: .Bd -literal -offset indent gmirror configure -b prefer data .Ed .Pp -to the -.Pa /etc/rc.early -script and: +Make sure that +.Xr rcorder 8 +schedules the new script before +.Xr savecore 8 . +The desired balance algorithm can be restored later on +by placing the following command in +.Xr rc.local 8 : .Bd -literal -offset indent gmirror configure -b round-robin data .Ed .Pp -to the -.Pa /etc/rc.local -script. The decision which component to choose for dumping is made when .Xr dumpon 8 is called. From nobody Wed Oct 4 11:23:46 2023 X-Original-To: dev-commits-src-branches@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 4S0sl7231Tz4vkVJ; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0sl70Pc7z4bxd; Wed, 4 Oct 2023 11:23:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418627; 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=yG6bAA1hkA0ojLltVMQ6/9fArmWzZQKq5AjyNqOLTNE=; b=gD0UgitDAsKFoI7ZbNYim7f+ycgYs0ng0MFmvZyHi/3/hppfCAUFqFCX3KD/VOyAmo9rza J748KnWZZRtSdy3BYog5EQJS4epVWAJdxfMB2c6Y9+5Ev3LAU8mJrLgpZKr3zJtdG/3Mvm lzwdN3EDck8OcMpANloFW+8UfkMA5m0UuQ9XR/YDVoKMgpqfk7ztmZsOC+CFr2Iof6IQ1E QqR2ooKVAIrX2aYNluKNOts5xrfF8mWxBfSoWDqEXyZWTDCcjGX/HLQMJlzSqFFRr+nwci Dk/iZFxv4vX9CkGrjixNn665OZvC1RSTH4tpVxdTFMDTof6MALVzxDfifP/wMg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418627; a=rsa-sha256; cv=none; b=PYhvLNw3pG8nN5fMF9kgmOlCXAkV9q8rOKC7MO6wmk0rsDuvjLTsQp6kkfaX9+MEzGfXwi Uyi5U52VwwE/mvxupU539I9S0oxYIYVgkp/4p0t94lYlJOsyO037hT9aIJnl5X40PFBDFp jfVG5KhDM+oQgk9Y5o9YBUroha8v+M3RhJDLflpwZEv3R/qAq0eLTd+5ZAvU6flrN5L1Ym x9KPfYsmM16KrRvHYegzrXLK7WJ+mKn8r21/Q+mDyIuqDBDAT2/PReCu+06GqjewpUh8Zs LY5jm6IlAUZlzXzBEn8faNAPdYYQ/EdUg3dege70Nh9iRd8x7CGI5jKzxthBPA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418627; 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=yG6bAA1hkA0ojLltVMQ6/9fArmWzZQKq5AjyNqOLTNE=; b=J51jxJAR5ceavoz7mS665JdFgCg70I/997/YyrvzGk3qaAU8JTP/EnSHS2fTsmKSUBzOWu H9ZXG7eeXaILsJwfjbahrCKLqOnFop4JzpShIqNsioAAqOn22McGMldd/Xt2MOb8toI/k6 G0+fVsGLnxTBHhpdjaNEIQ57DI9Vb4yTItecLpHlNb+1qtB3NCxtlzRnUeXiphXpX67Hk0 83WnEAeasaBMb1Nv+lSfSS8xTc49UePm9iJI62Z2txbA03OO8ACF+ZZnJYl9LX80UGRmLX 8MwdYQ+7Qd8RrMHPreSKPzWoF3T5RQ9MU58p61zqencj2N0egwmgOyHNBcei/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 4S0sl66csGzbc4; Wed, 4 Oct 2023 11:23:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNkLD084824; Wed, 4 Oct 2023 11:23:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNk8e084821; Wed, 4 Oct 2023 11:23:46 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:46 GMT Message-Id: <202310041123.394BNk8e084821@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 8ed7602b4e0b - stable/13 - development.7: Remove CVS and SVN cross-references List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 8ed7602b4e0b33e5fd397fad17bea71d14234a85 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=8ed7602b4e0b33e5fd397fad17bea71d14234a85 commit 8ed7602b4e0b33e5fd397fad17bea71d14234a85 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-21 18:33:47 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:12:07 +0000 development.7: Remove CVS and SVN cross-references Instead, point to the homepages of the projects. MFC after: 1 week (cherry picked from commit abfa92dee642a3687aaef107203e69722a16ef8c) --- share/man/man7/development.7 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/share/man/man7/development.7 b/share/man/man7/development.7 index f4d0fd300c40..3c8442e36e2f 100644 --- a/share/man/man7/development.7 +++ b/share/man/man7/development.7 @@ -194,9 +194,9 @@ December 2002. It was since extensively modified by .An Eitan Adler Aq Mt eadler@FreeBSD.org to reflect the repository conversion from -.Xr cvs 1 +.Lk https://www.nongnu.org/cvs/ CVS to -.Xr svn 1 . +.Lk https://subversion.apache.org/ Subversion . It was rewritten from scratch by .An Edward Tomasz Napierala Aq Mt trasz@FreeBSD.org for From nobody Wed Oct 4 11:23:47 2023 X-Original-To: dev-commits-src-branches@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 4S0sl82DRJz4vkZC; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0sl81Hg4z4bhk; Wed, 4 Oct 2023 11:23:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418628; 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=5jltlKwlQCxQeL0DZ/tS4CBnwrzGYdtqGpOThO+1pVo=; b=lw+/XteVWUPLPG+scLJT6Ig0FtpYZ0waX9mSCdoynXK5cqpPx/MClEM17tp4Xggu29/1Qm Z79+58M1ChX6i2HmafCPnfLp3o7874kpr7LIQS8Ii4dELOH3bMNVNSv0YCQznYhC0T25VO NEwJbVep1FYDPVELBgB/iCFYM5oWGR6r9vxlRmmQSPhi/0qUcYun5GWJH1Ntru2hfItXHi TOks06LirIL3GPtx2hJk4a+2ph2BNQcLLVqQ0GpuTne7cmo16Av7B1BcldFOca0+hiNOF8 uC35qHG4h2g7NStdRqXPnw9IX4lb0y/6iCzCVxIL9Q1f7Cnolf+W6xMYtHq5jQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418628; a=rsa-sha256; cv=none; b=Erx+suzl4naB9z9wcB/TMGu8VJooHMxmKw/yleq1ytNy/cMCnqNhUAFmj4lD9MrT3vWWgz 6FQFukPwBY4Aia4Z/lltkgAQdB3EC43s33E0r4xz9ZXKKeNRgOTnrUfY55ATRUP3LUIrgy rPvn7tTpQbKL8sEGSG1WWI3eajslp8ertR7jcO9ZjEYtbyyqtjtI316x2Zq/LE1gZf71WV hCW3U/EFhwFIWhNFtiE2rfe2BiHAftrNtGg7gSRNBjkiUs605TxRV23V2Jt5cmmQZT6p+5 4wjA2N9t2duzcWJnafRQlh3kdU2ohEYz+nkBUm49DoIP8l8UYm6EdCnZr/Qs9w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418628; 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=5jltlKwlQCxQeL0DZ/tS4CBnwrzGYdtqGpOThO+1pVo=; b=FBByWyZw3C5bpepaxbNDkVWi265ckqG+LNsSVR0zNwXoOSYon0641Tc0euxnfPRmUGTJxV B3N+DppufCE7uF1c3y3saPC2AnaRMFTf4JtFSgIDtryehqNSgwQs0ld61ASMnhpWLwnzpa h9+BHviXI58aXyXRTDKwt90AHi3C8Vrkif8jeTZbBDu347XzCXUCKJw8TTOkjXQmN64MBj 5qHak2NFvD8idkQF2BWgdd5jkuhKU1O7XSBFJDG0X90lkAsvI6y2MVs8ACBNtXmmVHMYF9 t9rI2h/NxTCAv/TDsPYGZBepifWYAW90oJLyQHmN6pEauLwNEC4lMjgHUu2DCQ== 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 4S0sl80Hn3zbV0; Wed, 4 Oct 2023 11:23:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNlLo084863; Wed, 4 Oct 2023 11:23:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNl0i084860; Wed, 4 Oct 2023 11:23:47 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:47 GMT Message-Id: <202310041123.394BNl0i084860@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 2575844bf968 - stable/13 - release.7: Update EMDEDDEDPORTS documentation List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 2575844bf968c633562e0cdd1a25cc7d52ad0b81 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=2575844bf968c633562e0cdd1a25cc7d52ad0b81 commit 2575844bf968c633562e0cdd1a25cc7d52ad0b81 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-21 18:21:44 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:12:56 +0000 release.7: Update EMDEDDEDPORTS documentation EMDEDDEDPORTS does not contain devel/subversion anymore. Fixes: a03128832c6c In extra_chroot_setup(), use 'uname -U' to determine OSVERSION. MFC after: 1 week (cherry picked from commit 6542fd4b959fa2919b39690ea3ea83e55848e091) --- share/man/man7/release.7 | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/share/man/man7/release.7 b/share/man/man7/release.7 index c183ac2a2d92..b68e0b65f24b 100644 --- a/share/man/man7/release.7 +++ b/share/man/man7/release.7 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd March 4, 2021 +.Dd July 21, 2022 .Dt RELEASE 7 .Os .Sh NAME @@ -332,9 +332,6 @@ directory in Set to the list of any ports that are required for the target device in the format of .Fa category/port . -The -.Fa devel/subversion -port is built by default. .It Va EMBEDDED_TARGET When set, its value is passed to .Xr make 1 From nobody Wed Oct 4 11:23:49 2023 X-Original-To: dev-commits-src-branches@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 4S0sl92KDFz4vk6F; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0sl91rvBz4c4b; Wed, 4 Oct 2023 11:23:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418629; 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=rurIMIbIzAQy3EV7G0yjWD21DPOf0uMys0onaIlhoMQ=; b=Ti2jHGGShQYG1vdTlH/BMaww0Mgi00DzQEQ33ihzQwIVFFzH8ZttWiECa9gM/pjt3tMLe3 WTbLTMuVHu74GHE/3D4FOK5ck59RAFwi3RLSiPqEAZDA4f/ZojiT0vvfpqcmFfYYiNyyqQ vR/wL3HNhNeAyj2WTraxq9PpBvw0XGEAGRigQyN7EfVa1zd9UEXZjgV/i4zHx2TmhDqEOk 3yQqc56y4FfSiQ3hOft9ZZ5gFK3VnPnFAo8FfwyrQBPQ8JnMpA6oV0l/cDbgq6/4FNc9LI wNNDdPB1R4bwQRk6jNxQtaGXFNFLJ7vad3R3dZpx6oATvMLdQy587GjRylMsqg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418629; a=rsa-sha256; cv=none; b=Tse/C50oTVJcBhzTa8iaNYquLZQ95JZkNssmSt4wXx6rhZ2+fJvhUOUOSoOPGLKNwdd3BE gVOUK5NC8yQwl4p+JGh1ZE7/R+9HMS12pgmtFZVK5Ka+sj7Mn5SBTc74D71vCpsdH+yzLL pMFSZp7n/mgVkGpgvwLMGYww1Lj3lBRL3hBxuvEKTWBOukUjvIzdtSeJM22Z9UVfUqMs7A OgziVR8uiygJ1MHz64X23+r7HHsOYquILlraYPtEeEGLkKazuBLnF7b25DbPQE0u8Aj6F9 w+Bc1Zqeb/K3iaFSNhky4qKj5EShU1s591V9D2iRa6jr69zu1qZYcejXuJS3Tg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418629; 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=rurIMIbIzAQy3EV7G0yjWD21DPOf0uMys0onaIlhoMQ=; b=C2WFUEQs7DNpewHtdPxyirc/Mg3oDwDGg6KxOZlJk+z+vM9CWP7iDIgIjFjBSg8SyX78kC vE6O92nPuW08RTLOVmfkzUR2EU0YGPwB+EmJZrqifn2Z5JbFMoNddQQo7ArJEGM9lQFtwC Uqjo+Dscyv/N5pn7JmjlW6cIGsiqQWx8CvGQOUgDltbMPtqDkKKztPnuyG2gY+mFf7qARf hnA9KFheK2Hgg/Gx2V41Yno2V2r5KiI4r0qHdcf7PhcgPTk195qqPXKUvsADy0rj2hr9DQ 7M54Ph+PJWe1mBGCJ06itMXXwTTTkYJyes1DJ84TF4ZCfh83ae9pWIlj6HBO8A== 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 4S0sl90v1nzbTF; Wed, 4 Oct 2023 11:23:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNnSP084902; Wed, 4 Oct 2023 11:23:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNnVE084899; Wed, 4 Oct 2023 11:23:49 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:49 GMT Message-Id: <202310041123.394BNnVE084899@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 9131b0a7f485 - stable/13 - release.7: Remove Subversion references List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 9131b0a7f48539b4d32b407652cae6083ab11d47 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=9131b0a7f48539b4d32b407652cae6083ab11d47 commit 9131b0a7f48539b4d32b407652cae6083ab11d47 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-21 18:25:58 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:13:00 +0000 release.7: Remove Subversion references MFC after: 1 week (cherry picked from commit d3d60927950be441b05ec9317a23c4cbdd91f3c1) --- share/man/man7/release.7 | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/share/man/man7/release.7 b/share/man/man7/release.7 index b68e0b65f24b..548ba540f6c0 100644 --- a/share/man/man7/release.7 +++ b/share/man/man7/release.7 @@ -674,12 +674,7 @@ cd /usr/src/release sh release.sh .Ed .Pp -Optionally, a configuration file can be used customize the release build, -such as the subversion revision to use, the branch of the subversion tree for -.Li src/ , -.Li ports/ , -and -.Li doc/ . +Optionally, a configuration file can be used to customize the release build: .Bd -literal -offset indent cd /usr/src/release sh release.sh -c $HOME/release.conf From nobody Wed Oct 4 11:23:50 2023 X-Original-To: dev-commits-src-branches@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 4S0slB3zxxz4vkbm; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0slB33dPz4cJD; Wed, 4 Oct 2023 11:23:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418630; 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=vKd8BWXux8+0OjHKEzGtm71YxeB3qDMmD9G+onHcf48=; b=V3XvmHviUzzRkpQTBoK2e9pKxXGyj2m3IhNv8+6nmPLb9tfZv59Whvb/NHF8jaMXKpG7BO i46ilxAwFrrVZ1zg5i3rg6rsAoOKXSLtvtxZ2JjFVL5JAMh7svKaKmc9qBdItQCOGfCmsB Pod8HcbIwH0Zz6p3Q6FwOCXX1pA+DOCfma9QsJNWwLtb7QHtPPTtx38mnNZsBrV20bDHfg +j31ZHsxEACvmLzW/u9TgiGac+QVdnepJQFooVbdWMk424hZIMVYey0mg2eX+pVtsjBC3v bNvQeCe6TILwYDNgFcdGHAAWOJ0RuMB583FTl4NzZ2zHYGkn0c+I1kutsneWRA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418630; a=rsa-sha256; cv=none; b=EJo/6pg75BhDctu4IuRvsMUHkMsZTRlluD3yZKl+FtQ/B6sINg0QcRMbje44/eRGB8UMLO Xm9L5Mt0oJwaSfYZCESQmGiXxerHcF0h7TUvTOqf87UWi1ASYvx3ALrAxCGMHpwW7nYblx 4RV1hnTVKuBNy5aNWEHIskT+ijUhVXQq5kD0+A4QOAobmxAVNDkWERA0bdKRD3NbiWmOAX Q80b8fd5OXGo/7Tf2Wa+C7TDlRSpJYSE80ZT0edl7HviVMhrb49VQoZHrFfG4hWV2I6zNP V9VYNxp9MjLaCL6dgbCA8Rbveug/YdtotavgTWEKeWDy7sss6s4EvFWu1B+eeQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418630; 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=vKd8BWXux8+0OjHKEzGtm71YxeB3qDMmD9G+onHcf48=; b=Ger2h1BsFmEhpkrZZouBIxxSO7ECmm+rxlaIrOyBwuzLrsHFRpuvWVdoovf60EvDH5Ladf EsURYIxm9b9VVOn6xGsm+6NFCPvyz7aPLF7ZCHA4Kh55yISQO/bn5xhC2pmOJjm7f9uyC5 KSyzwPNPk5su762+iGtjmYUTLQhhdmS0FUUqdWFPYoAVivjJ5XaEsTWKTqI7UOpcczjA2S vFuxVpyLkAoPsDH5HM+/ZcVx+qS4keMKz4NW5sRBCPTZJDGSlq2AkiF3Ezy1h7gw21VMt/ uv1LdU9vv7p3FYGj/JYO2bRr+WaRdBGrRdlE+1W/+TGMaM6p3/usBqw9SHXtDA== 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 4S0slB26ngzbK7; Wed, 4 Oct 2023 11:23:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNoNX084947; Wed, 4 Oct 2023 11:23:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNoRt084944; Wed, 4 Oct 2023 11:23:50 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:50 GMT Message-Id: <202310041123.394BNoRt084944@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 4f9dbf7d5d09 - stable/13 - pw.8: Refernece to openssl-passwd(1) and crypt(3) List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4f9dbf7d5d0904a9292e403107f1ffe9bf2494b6 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=4f9dbf7d5d0904a9292e403107f1ffe9bf2494b6 commit 4f9dbf7d5d0904a9292e403107f1ffe9bf2494b6 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-21 17:59:19 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:13:24 +0000 pw.8: Refernece to openssl-passwd(1) and crypt(3) It may be unclear how to generate an encrypted password hash for -H, so point users to openssl-passwd(1) and crypt(3). MFC after: 2 weeks (cherry picked from commit adf9cd56fa8421ffbf2d9c74ada547bdbfa8b143) --- usr.sbin/pw/pw.8 | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/usr.sbin/pw/pw.8 b/usr.sbin/pw/pw.8 index 871880b54f37..5d461fc6464e 100644 --- a/usr.sbin/pw/pw.8 +++ b/usr.sbin/pw/pw.8 @@ -539,6 +539,11 @@ This is like .Fl h , but the password should be supplied already encrypted in a form suitable for writing directly to the password database. +See +.Xr openssl-passwd 1 +and +.Xr crypt 3 +for more details about generating an encrypted password hash. .El .Pp It is possible to use From nobody Wed Oct 4 11:23:51 2023 X-Original-To: dev-commits-src-branches@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 4S0slC6ySwz4vkHq; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0slC46RYz4cP6; Wed, 4 Oct 2023 11:23:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418631; 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=PAonIyeDXBBYyxq3mHdy6CSNxjZdIrp/sHtEVW5K8CQ=; b=TcwSG4Jp8mVl6LlB5rI4Ggdt8EiEu0LbnwlJNOIwCz0jhwgmpJWlvgX3eSjOV1S/+/AHnM O8LsZzxj6LxQBtdN5qKfU/H25hh8T4m5IriIu+QAOb7NNklCDgC1qe6s0irykZf0qVqRF1 +EDuJaTP+YGVInvLE85kjW41SYZuOwTKBRN9U6L9tGWd5nGeRZT0S/4Q2UigVNU3QyJ5lN WyBTtbHrSZ0BW0ryUJF2Z+4JNbQCdXcKLyEWl9UvPXCvjjSk68RCnkLyoNHOOsz/0r0mtE KcMebIrCdM23jWANV9O5xPC4s+sysqXvyO/moSumpLWGH3NaDH4A4Iv8pP2vkQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418631; a=rsa-sha256; cv=none; b=P6vsfrbGiZ1rPQnwg+Q+uZBCC51/F8gqxW7sOZcZJldboz1GPHmvRPONpsBeAiu/j8p7vC LnkUI8a81TES55SDQDY5cPSYbQdXLM3BSQcy0nX3scxCHbhqd4Hg5Jreq3nl5LfAo5F/hh wr+Iw16URthEgjI3H4kTEEGa/8GWeUEMYW89rdf8i8kCXRgojARj5TzWJ7TICK630GXjED nC6y4UT0B40T64+ViAHq8h+ZJPSVezfGf8IBPoMX/hr7QRvmOVed+a5wDx+k1JseFfFr78 3QAx92Mj0Dfa5cYfTE1PETL0eTCp3VTf1QQs+FfdIeMllH2Vqnd2Equh04pE/Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418631; 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=PAonIyeDXBBYyxq3mHdy6CSNxjZdIrp/sHtEVW5K8CQ=; b=gBu8bCWmORTlsiyeiLqFUhX2Pxyf2pk2EvTyYQ0d260vZ5+HlScmUYQCyTIRiWbiDwMTLE wdwsnqlfx5gjBfj1gGrpdsnTIJ9WP9q09ynP0WclBnn0Nb/TaLlGLpT5JNzvfeEQNlyRXf ex9vyUi/8/sZ09LlA4W04P1+4if5yd1ie8a2CWV+O/tEwIB2lxylMcDdiT0MEFzeLDPud6 r1wiFo+eJEe3lFyMNoqwqbvdt4NpbMt2qhJRGvyeyZso/RX51guhOdWJxLeprmoAHZxMiQ c37SFGlcjyX+cQMU1WIyaghTF765pwWgQrdj5hfx0FM4BhCV46RHN7cPKoaumA== 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 4S0slC2wzfzbY4; Wed, 4 Oct 2023 11:23:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNpUA084992; Wed, 4 Oct 2023 11:23:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNpHt084989; Wed, 4 Oct 2023 11:23:51 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:51 GMT Message-Id: <202310041123.394BNpHt084989@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 24319ec19e1c - stable/13 - vtfontcvt.8: Improve synopsis and -f documentation List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 24319ec19e1c44637d836f757b79aac5a29e4298 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=24319ec19e1c44637d836f757b79aac5a29e4298 commit 24319ec19e1c44637d836f757b79aac5a29e4298 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-19 14:28:22 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:14:05 +0000 vtfontcvt.8: Improve synopsis and -f documentation MFC after: 2 weeks (cherry picked from commit b38e3722f5df6260a4ec70c9c3cbc00ecf169129) --- usr.bin/vtfontcvt/vtfontcvt.8 | 41 +++++++++++++++++++++++++++-------------- 1 file changed, 27 insertions(+), 14 deletions(-) diff --git a/usr.bin/vtfontcvt/vtfontcvt.8 b/usr.bin/vtfontcvt/vtfontcvt.8 index 1c007d344650..427afb0645d3 100644 --- a/usr.bin/vtfontcvt/vtfontcvt.8 +++ b/usr.bin/vtfontcvt/vtfontcvt.8 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 2, 2020 +.Dd July 19, 2022 .Dt VTFONTCVT 8 .Os .Sh NAME @@ -31,7 +31,7 @@ .Sh SYNOPSIS .Nm .Op Fl n -.Op Fl f Ar font Ns | Ns Ar source Ns | Ns Ar compressed-source +.Op Fl f Ar format .Op Fl h Ar height .Fl o Ar output_file .Op Fl v @@ -42,22 +42,35 @@ The .Nm utility reads source font files in either BDF or Unifont HEX format and -outputs a binary font file, C source, or C source with font data compressed -by using LZ4 compression method. -The output in C source is intended to be used to embed the font into program -binary. -The binary font file is for use by -.Xr vt 4 . -HEX format files must have the file extension +outputs a file in one of the available output formats. +.Pp +HEX format files +.Po Ar normal_font +and +.Ar bold_font Pc +must have the file extension .Pa .hex . .Pp The following options are available: -.Bl -tag -width "12345678" -.It Fl f Ar font Ns | Ns Ar source Ns | Ns Ar compressed-source +.Bl -tag -width "-o output_file" +.It Fl f Ar format Specify the output format. -The default is binary -.Ar font -file. +Available formats are: +.Bl -tag -width "compressed-source" +.It Cm compressed-source +C source with font data compressed by using LZ4 compression method. +.It Cm font +A binary font file +.Pq default . +.It Cm source +C source. +.El +.Pp +The output in C source is intended to be used to embed the font into program +binary. +.Pp +The binary font file is for use by +.Xr vt 4 . .It Fl h Ar height Set font height. The default is 16. From nobody Wed Oct 4 11:23:52 2023 X-Original-To: dev-commits-src-branches@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 4S0slF3659z4vkZM; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0slD4vGcz4cRg; Wed, 4 Oct 2023 11:23:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418632; 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=NQDYMZlkos/zKhkLAL2V4CjnyjNFpOvxu0NYeGjqSp4=; b=aI+MvBcHmRMpYEE/97qT3f0gTyBuHEsCE7J++OPsMBNLI4/BvXU6uG5n965a6SYU4U0aq8 5gm85GZKXRoi+UGDMAIE83Vcj7hGFiCxFI1KmSlq7sWZjTgtueUhW1y5Cm0UHKoL2wGKJp KzYeDt8KlM5YdPqUYPosLQDDkiRfPCLFR5Q6oYI2EQXE5/CPGHTy/PS80lB14FwmwZ4SEe 8rr24274G8FrjE5mx+ApzP+JEsgOZvmvhISWOjGd/FYc9rB0b4KInswgvuNgzZa9eVkWVh iADjfIxye1L3OJF8yaWekXJT+42SySUreWN3dzBqo1JD/O61I+NnGBQFsVU4Qg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418632; a=rsa-sha256; cv=none; b=tTpf1FGSZHdhu4mXNkA1MUNo4X6LRLsGEpn3DR0YtLVNWqp0yO5JhCeztV2npW2SF3mgjq rR/do52jajLY7MteTwX9Ky3cwH3x2jnVV1W2ZG8zcs/xiojuEauWy95CXpHHZo95ncfJb0 pNPxHQlNupYxE3uo3nuK/Dc1Xlg3eszlerZxVf6lqalmsj04OK+Wv2bwRR0YP7gGVMJ48e azgxjSIok+12MvtXPVoxWKP4Guj8iL778Cfk1xrkOBdq7BUhKbOw03Y5a5JQg/JoXp/2nT KgEkKQIv5S8g/T7T7tF1C1RfD/ZzUQz0Ow/e5oqvdicXEFLE0wYJmoKxZNENIQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418632; 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=NQDYMZlkos/zKhkLAL2V4CjnyjNFpOvxu0NYeGjqSp4=; b=A4N8h6u5S9z98WPh36bizlHxnAN000c4VwmFBPnGgiin2woV+SZBq53n0A51XTRZdpO8Oi UnAzCn9wc4jqDvWeIwCUNY3+bdizTBLQHecDwL4l6Cb1NCwWL8CqRr4IYt/GMyP/mlNlgA zp/pmu+5cRR1RflSTplp0FgmLQs/PMAZHKP+S4/VRe0OJo8H/nDdTw6FmRLgV+ja4i0BfV lPW137RqUL3ShkQGbvc5SebBtH2uU2sUqk12VJvkfTDVQITb6pMJ84zHwLrisLZCNoeRDQ oC1UTofipyWGuFW7bSpfKhcxQiGVq9svsZlelF0zOeMPHdi2DOGV/Exm7txqRA== 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 4S0slD3zYszbc5; Wed, 4 Oct 2023 11:23:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNqog085028; Wed, 4 Oct 2023 11:23:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNqku085025; Wed, 4 Oct 2023 11:23:52 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:52 GMT Message-Id: <202310041123.394BNqku085025@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: c0141df5f433 - stable/13 - vtfontcvt.8: Sort synopsis List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: c0141df5f43310e031b96891efb856f0ce42d020 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=c0141df5f43310e031b96891efb856f0ce42d020 commit c0141df5f43310e031b96891efb856f0ce42d020 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-19 14:32:26 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:14:10 +0000 vtfontcvt.8: Sort synopsis MFC after: 2 weeks (cherry picked from commit e0bd2ab2eb4a379e73ebd5ca0fd80c3d6ceee5ee) --- usr.bin/vtfontcvt/vtfontcvt.8 | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/usr.bin/vtfontcvt/vtfontcvt.8 b/usr.bin/vtfontcvt/vtfontcvt.8 index 427afb0645d3..7ca0564481d1 100644 --- a/usr.bin/vtfontcvt/vtfontcvt.8 +++ b/usr.bin/vtfontcvt/vtfontcvt.8 @@ -30,12 +30,11 @@ .Nd "convert font files for use by the video console" .Sh SYNOPSIS .Nm -.Op Fl n +.Op Fl nv .Op Fl f Ar format .Op Fl h Ar height -.Fl o Ar output_file -.Op Fl v .Op Fl w Ar width +.Fl o Ar output_file .Ar normal_font .Op Ar bold_font .Sh DESCRIPTION From nobody Wed Oct 4 11:23:53 2023 X-Original-To: dev-commits-src-branches@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 4S0slG0YZ0z4vkfW; Wed, 4 Oct 2023 11:23:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0slF6BlPz4cF1; Wed, 4 Oct 2023 11:23:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418633; 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=JliU+yi+iXxezi2TAoDQzVPczRvEJZrH/Ccn9UpV9DA=; b=v/z6thpqofmdkEcYmYFQjRHrWs/2cbMuAGsSnI0q8IUzu3/i/zsWbsCTpE99TsWG6exWgC pmWlKyYBG1srD3I+5oTUOvYD4UVR9povnfy0WB9YfckrR/j8PegPC0C0zZ/LFNHi7V4u1a m7mjPAocckrqNPk7vPUmnHc5Hc3LeaBpPOacPmAsODGYI4Kcbnyykx0igrkKWVWs28kJ6Z m7ZyoJKyLY8eWmofhQQlNVG31m+BxwBAzwSxafkV7LNv+564aTTU/4tYto1KmdEHdrdkbc TyuffyzULETYhLA5qfSpq7xzK3YvCx8x1SU2n7/Gy7DI/dWHJkEvXrZRtRIOPw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418633; a=rsa-sha256; cv=none; b=X1jWp85cFUgQr29Fqd6jjBkz3Pn4qUK8FUhjwF7j8fzmzz7BhJnGSMd9n7jb/gsG0/D2sl gNR4nSnlsuEqAIfzsMArPF8E+GEF+noiWo8cdIojfG31zzg2PrjosHRbXhQ3HuPTkxXwsd aRoBrEqOdpVqBxCksieea9dRUP4n+6bqe2u0tdLFFMFlfdzuRFpTH2I11PwCQWQq+RV+kM PSJCCRJJ0IS3Cq5H1N1i17jb39a2NRiD43bzoE/LI30w9oGQ04EJyLuHkxQH8xMskL4qcn XIhhpcVuvGG/qO1dJn/OS1kbF0nkfHDNXiRBvf1X7mKHy5YzmxPyn+E/Khq7MQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418633; 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=JliU+yi+iXxezi2TAoDQzVPczRvEJZrH/Ccn9UpV9DA=; b=xq1mFek557N//Jg5ijdItGjAKBdi+OsCEqhjMTUqYNMMZui0XGugHIuw6CuFecDUqrAxeu QLT23KYQCukBOoPzspi26nGruODJpFacK7GUqJMW7fKkfWtUHNKSyNLraOFVoTRONscKzH gTdQ4f4WuxzydRQAFvMs/V28oRj/li6UNH58+/KYZHqb10UP3RUejLkKl6IZNlEH7ishyT pJ3hEPtoIpJKBg0SdDPneYS7++ICRf5rZF/6OIk8+2w9IDCnjDGGL93ETb3nP0im46qvYr QtWNZWKJtl0wj9jLH5vE3rZbEY24wv1gdAzRDL1G0/5HyoNFgofyK9d5wcnyXw== 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 4S0slF5Gpdzbc6; Wed, 4 Oct 2023 11:23:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNrfN085079; Wed, 4 Oct 2023 11:23:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNrrl085076; Wed, 4 Oct 2023 11:23:53 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:53 GMT Message-Id: <202310041123.394BNrrl085076@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: f787c870f6f6 - stable/13 - vtfontcvt.8: Use D1 instead of Ql for readability List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f787c870f6f67a8b8640e856085b8bfdccca72ac Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=f787c870f6f67a8b8640e856085b8bfdccca72ac commit f787c870f6f67a8b8640e856085b8bfdccca72ac Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-19 14:32:41 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:14:14 +0000 vtfontcvt.8: Use D1 instead of Ql for readability MFC after: 2 weeks (cherry picked from commit cad64622ca704145f7fe108b3a3f3c52d1796e25) --- usr.bin/vtfontcvt/vtfontcvt.8 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.bin/vtfontcvt/vtfontcvt.8 b/usr.bin/vtfontcvt/vtfontcvt.8 index 7ca0564481d1..1e643f175668 100644 --- a/usr.bin/vtfontcvt/vtfontcvt.8 +++ b/usr.bin/vtfontcvt/vtfontcvt.8 @@ -74,7 +74,7 @@ The binary font file is for use by Set font height. The default is 16. Font height is set automatically for BDF files and for HEX files that have a -.Ql # Height: Ar height +.D1 # Height: Ar height comment before any font data. .It Fl n Do not apply output filtering with C source output. @@ -86,7 +86,7 @@ Display verbose statistics about the converted font. Set font width. The default is 8. Font width is set automatically for BDF files and for HEX files that have a -.Ql # Width: Ar width +.D1 # Width: Ar width comment before any font data. .El .Sh SEE ALSO From nobody Wed Oct 4 11:23:54 2023 X-Original-To: dev-commits-src-branches@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 4S0slH0jgtz4vkhx; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0slH07kfz4cHs; Wed, 4 Oct 2023 11:23:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418635; 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=dQQa6BePPfcbxqZMmrPC5cNtCwQFjRD4M36NAi9axDo=; b=RYNbALKnMeU/NhnsIMJMc9QlS5thOVnE7BhfaGgmpq8Y6bT/lA9yGLf2bVdoSUcSE5AXWn OADYYMUArXPyfgdhEYshRlSDDX3ihCp+A6n22kGskkT/BWU0qunNoEXBp/GMn1hAGXoDZ1 D7jnksvL65uHem2flxddOEuDfoeKwwJ6tg8Ql2SvAotDc2jVV9vbOTCVQbraO0nf/SH4rg 3hyn924vBJdtiJcvQeRZNnGbZ0sAduJuaJQwMHL68ldAxyZA/eqoTDrg4zVZlw+OmrKqlA V00YrKxF+249lsGORjgt3LEWJHXucJBbQzhpycPha2+XEH7VjWQhLmcgsall6A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418635; a=rsa-sha256; cv=none; b=hmmJmRS11BdaXTjE0CMOHUXcv66QPHrb6vmTNiFd+a4bTGqr+l+Q6etsipHelW5EHVjxoZ 6hXHcm+z/Du7PL7UYymllYSKQ9reywdQqS6Fj2STVKtGLiIV+GGYTkWo8K20E23ftsSVOw AW5XP4Zi7VhGJkEYASreFA+jN9i/RPzhTJac++Vo7XnJvQiS81DkePVoND23+GzVbQxaxA mQrhpEXDnXJNE/q92s24fSZd1PyhuGeeR6zGCWThqUcwDRAS/mW9gZJfZEPtYy7KQ4WRWd qtWbzhCDO4Tjspz9cAKkzIWxYuzh4k9oSVOMS2qE2ZyuLOxIWugPOg8s7OKPDQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418635; 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=dQQa6BePPfcbxqZMmrPC5cNtCwQFjRD4M36NAi9axDo=; b=cfJeJHhynByIjoqqcH59hn0ZFRzMa7SgR5QlAzEq/4T1H5jhpbr5ZHYPdRy1xLQnUNDdxA P7XUzv3XtWCSJWAcAR4KR7QVgxqHb4KwTIM16siD/oyLkXXZSdOXpvslXesGwfNpysxd5T vAALPsgjCkNXZOwzrPSn6iHJ4yeVfO+wqdGsNuW2hytny/cKwlhF/gJsMOA/Vsc7SqNfsm CySCKtPTjDgFLTZi/xWcsHfKWsqVj2MoAfAjdtdVelwgVNWxZ+C1pl2s9f51GlNd53L2KD MhUy/hvdGyIbneHCIqychTkN86fsPUPFES0frN3VlVnr5MSO/Xu5ZRPcMMjFeg== 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 4S0slG6L9WzbY5; Wed, 4 Oct 2023 11:23:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNs4C085130; Wed, 4 Oct 2023 11:23:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNsis085127; Wed, 4 Oct 2023 11:23:54 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:54 GMT Message-Id: <202310041123.394BNsis085127@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 237ce4092c23 - stable/13 - vtfontcvt(8): Update usage() to match vtfontcvt.8 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 237ce4092c23b9c9e66316ecfa88c355ee3d9c8b Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=237ce4092c23b9c9e66316ecfa88c355ee3d9c8b commit 237ce4092c23b9c9e66316ecfa88c355ee3d9c8b Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-19 14:34:29 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:14:18 +0000 vtfontcvt(8): Update usage() to match vtfontcvt.8 MFC after: 2 weeks (cherry picked from commit ef2d0816dd0b28560309612b75b301e7f179db8f) --- usr.bin/vtfontcvt/vtfontcvt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.bin/vtfontcvt/vtfontcvt.c b/usr.bin/vtfontcvt/vtfontcvt.c index 54635f54ae7a..d68516dda360 100644 --- a/usr.bin/vtfontcvt/vtfontcvt.c +++ b/usr.bin/vtfontcvt/vtfontcvt.c @@ -178,8 +178,8 @@ usage(void) { (void)fprintf(stderr, "usage: vtfontcvt " - "[-n] [-f font|source|compressed-source] [-w width] [-h height]\n" - "\t[-v] -o output_file normal.bdf [bold.bdf]\n"); + "[-nv] [-f format] [-h height] [-w width]\n" + "\t-o output_file normal_font [bold_font]\n"); exit(1); } From nobody Wed Oct 4 11:23:55 2023 X-Original-To: dev-commits-src-branches@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 4S0slJ2K0Kz4vkfc; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0slJ0v19z4cNQ; Wed, 4 Oct 2023 11:23:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418636; 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=vtrS0kePUUWkoveHpXYzS06D9UvQlYikvORt9PYGosU=; b=YiQmfaL35O3YpfUAwoyMC3MWtaTA9uFDULmb6oLBi8lKKqTRdGdOAB5PhLjXYx5QSYGLtC CpapAu8tWqqor2ISKcu4Imx+0iMQt1yUGctYIKl5Nu4+0fLZM4Rm5C3woBQGIuOvoHeKjb iDuEv3wIhwNh+zUHdVpktKH7XQFc8I1K/MZ5ve8GZ5/RZtO0uYff/tZybp8x6r3l+8iAfl vA9vnoSXTJm4TFzBXDBBGz7WMiqznmsgpVXKsxfW14x0/wpRElXypoPX3vrkNlvK+yneQ9 ybu5+sbY/Rd3dXUQJ23VPPF9/k/F9ev7u9eSo1p137zkuq/280tFcCMWRd2r2Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418636; a=rsa-sha256; cv=none; b=jnYkLjS3d3/I5fY0B+cGbBZwKX9GX6HybNm1bgVNQ4gtvI+k95sBoXq1ai7+PcuzXy8HTn iibt9K53uPyOgXDEqZbyP5gUjxQRgygTETw2nMC9WRCagZVe+iTdaBpmMiZ7PipB4Wxko5 xB7uai6ZpwdpWpvtD2yFIGkK0VstZH2e9cGGVikPq1rtzCebjGQZsGBfZYnPSlGC+uIOvM T7aralW9VGIa1fPm1LegYEIagA80mYHvNye/mh1P9XQopQ/eo+ejUP5yZcdkZhXc+fIgQa tGx2W/PAIOGMyA60GnGtSHlq3RqU/UrRyV/VBgqjtTqL+xc3/NdO6pLhbD+PRw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418636; 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=vtrS0kePUUWkoveHpXYzS06D9UvQlYikvORt9PYGosU=; b=XGB4OJq0j/hJ871Er2JvsQ6wRe94fJLM6QCQD3qU+sefSkyD5SpYqv/IZewZr4tGL3Ylfk /wD1UNNlvcg2okDHerxksHHvreKrRaQiAj80AB9fVPvapx/LFjXEi8IxxobL3Wn30NyfLU jQofAaVDPmbqMxtk4IeI3ZrQbrmI6I0a7ZSmnthmWHz9vxxeYYRlkhJ7pWg/TAywaCgvd+ SfudtlJmP+cBxJFFEV/ZmTlxymSs8WkTt/cgVYQkgvtKDDmItH50qGimzJgLF/S9WRrd8O Qye1nKb0cEfqUeDsJCCFhtVFxP8I4wH2GPLlAqhGuEHkUnUT07MJRMCEHuiNlA== 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 4S0slH70TYzbjj; Wed, 4 Oct 2023 11:23:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNt1j085183; Wed, 4 Oct 2023 11:23:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNtAn085180; Wed, 4 Oct 2023 11:23:55 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:55 GMT Message-Id: <202310041123.394BNtAn085180@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 4ae02ef76df4 - stable/13 - clock_gettime.2: Add cross references and fix linter warnings List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4ae02ef76df4ad151ba927480351b9c8298fafa9 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=4ae02ef76df4ad151ba927480351b9c8298fafa9 commit 4ae02ef76df4ad151ba927480351b9c8298fafa9 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-08 19:51:03 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:14:43 +0000 clock_gettime.2: Add cross references and fix linter warnings MFC after: 3 days (cherry picked from commit 13a9da7d5550392a754fcc72d8ec74c0ddbec26f) --- lib/libc/sys/clock_gettime.2 | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/lib/libc/sys/clock_gettime.2 b/lib/libc/sys/clock_gettime.2 index 49b6bab13762..7b325a2bb394 100644 --- a/lib/libc/sys/clock_gettime.2 +++ b/lib/libc/sys/clock_gettime.2 @@ -27,7 +27,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd July 30, 2021 +.Dd July 8, 2022 .Dt CLOCK_GETTIME 2 .Os .Sh NAME @@ -130,7 +130,9 @@ struct timespec { .Pp Only the super-user may set the time of day, using only .Fa CLOCK_REALTIME . -If the system securelevel is greater than 1 (see +If the system +.Xr securelevel 7 +is greater than 1 (see .Xr init 8 ) , the time may only be advanced. This limitation is imposed to prevent a malicious super-user @@ -183,7 +185,9 @@ The clock IDs .Fa CLOCK_UPTIME_FAST , .Fa CLOCK_UPTIME_PRECISE , .Fa CLOCK_SECOND -are FreeBSD extensions to the POSIX interface. +are +.Fx +extensions to the POSIX interface. .Sh HISTORY The .Fn clock_gettime , From nobody Wed Oct 4 11:23:57 2023 X-Original-To: dev-commits-src-branches@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 4S0slK5T8Nz4vkby; Wed, 4 Oct 2023 11:23:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0slK27KMz4cNm; Wed, 4 Oct 2023 11:23:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418637; 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=VyqZl+C2zDUuTgT6HExGxJR8mQtfqa/E34aUxCAM2Ns=; b=gjCCgqt1plHJGoI98H50xIurJoyIvlsRO/0ptkHIuN/sCrsXejb/gCxdVZDVnF9dSFEepO uSj0FEoSnYG7QntsXcRHTIOF3a2DJEVlZJxs8tJlxylyIklJm7lqc0liWsYY/HrGJweFYI X8CcTgHwh0qcprmXiejSROnORTlQuxJSieJnwCgt6IY/h2fI7Fk8Kg3rGEekklG8hsKQE6 QUsn6d+Y4XIkK3HAQ7JKb+K8br42DPpK79UkRXJcP3BP2xFnSWoaazMqL3HZiMgqQnHxEE D4Xpptz8DFXJpwPTdgnCOzfr98fKZe581sZlmFz/VrIjDDAgQxul2qe4pJz6hA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418637; a=rsa-sha256; cv=none; b=VOqc0i7OfxTHzH8RV3AOyAZCPpL9WuFXTXTB1SHgOQ7KQOy3bEVuwglfwrUm2p+3VPYKOJ X7euHS8wyprw3/gv/IfNg+O8t+dN4e1NQiVwKqvem2+oyhfP9KQh6UXYGAFIgu1pUqj2ve TvgVOPK2EJrs+2opV8WvY+pUHt7OY4u1pQdlaU6PqcIrNCLIzdkfUKmE5cM/kkJj1Fa++O WpOexZ/z/qgBW2aoU5tyrNXxwHm4TXKcJwN74hcu+h5luFMJIPuQse9dd9xK5YMtwyiO+J BnhFYCVff2EAAJKmMVnEfQjVIZJk8axFUt+fJZXLCZLLFoOULJ4K5KgDXx4gEg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418637; 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=VyqZl+C2zDUuTgT6HExGxJR8mQtfqa/E34aUxCAM2Ns=; b=dgcVJE0gHP9rKWVvEylLnqI7FwioEPdvIOmyOJakbQkBOppGOULsDlJl/nzym/MBUA5Hw1 tkq+tfAs7Pbugr936gNwmycNj5GQntIQlkEw3UuxRInzP5AQ4dISxvDEdwRveyJY/TNlHw 58xmk+I2eCGU0s5uXwXOzKJz9fUeoiP3fXmUWr6ia6RTmVLGg9jD6PHgb0Af7s8S87vDhI k5I0TwJflo17+5JOJ4Fa2HePSysveVZd/LOKFyPbv7laC/mP1GkXF8UUXT6A4d7GmHYS5f bTCmxGuEdEZu+jRArEyTIlE47VdP4VN2SBDsadMu7DJZDWMsq4SEihsSE5i0QA== 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 4S0slK1D65zbY6; Wed, 4 Oct 2023 11:23:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNvrp085222; Wed, 4 Oct 2023 11:23:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNvh9085219; Wed, 4 Oct 2023 11:23:57 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:57 GMT Message-Id: <202310041123.394BNvh9085219@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 755710da7177 - stable/13 - rc.subr: Fix a typo List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 755710da7177487d7af95aa640fb43f19ae197a2 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=755710da7177487d7af95aa640fb43f19ae197a2 commit 755710da7177487d7af95aa640fb43f19ae197a2 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-08 19:34:34 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:14:52 +0000 rc.subr: Fix a typo MFC after: 3 days (cherry picked from commit 7f6754d9659183a0c56fe76044d7826ca849675f) --- libexec/rc/rc.subr | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libexec/rc/rc.subr b/libexec/rc/rc.subr index 37a614e122a4..032d7b261bc2 100644 --- a/libexec/rc/rc.subr +++ b/libexec/rc/rc.subr @@ -863,7 +863,7 @@ startmsg() # ($sig_stop defaults to TERM.) # # reload Similar to stop, except use $sig_reload instead, -# and doesn't wait_for_pids. +# and don't wait_for_pids. # $sig_reload defaults to HUP. # Note that `reload' isn't provided by default, # it should be enabled via $extra_commands. From nobody Wed Oct 4 11:23:58 2023 X-Original-To: dev-commits-src-branches@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 4S0slL3pnWz4vkfd; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0slL36pcz4cVx; Wed, 4 Oct 2023 11:23:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418638; 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=avZo3lhRdTrwNiCETgv8I0pq3FTZE+/207jE7G6XugY=; b=KTDmXmo7nb0udSCm+0JuTqRvDRag5roWIAhiFhRRpr7YmBuujf1PHwKyDq7uYkI63uQJtY leJZ9S9rmK4dJNBxjNfQTluOwpufL9RLpKnNn8zNZm5OQ0034l9Y0ZUPCIcYSGeolg9N2t bHRx+RqHHpsGbSAHv5aPN6c/IldOtQMlUqT8exTISFzA32bMsS11FbKR9qUzqjmnx0Q7Yp VV2CZsvsF7hbaYnThZ0DkiAMi4VC6i5zSgi/uXkUpBLtTCMvzDh+c2dRgbSHf7lKRHmq0a w/QiapWMTJDUAHOr9TmCTTAkrtCXxSZQ+wFvHl/8mYWYYU6sgFWP/+OPCaTasw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418638; a=rsa-sha256; cv=none; b=eOnddFRb1ivVw9ZJ5/N0Ekue2UCBer8om4KkN7JugxR4zAd4WC0A3XNeGkL61tFyDxuHIX jMwLtX1C7xOaiLdTceOQPW5QpMnqXWcN/qg/SV8ygqiTnYKQ3Bduhj0XD0s1rO9K9A1z64 vygTierR8vdpcGStiJJtbd7xXWLVtB/gW4EHFAxqJDm4NG/AD11edJbdb7PZOviRL0abtC P+wqozqbF0BG/PbKHtEnPSN6Q+LcwqHkJEPbbOqL8zfBU31yPo7X7u6n1rVEcgYIxJbkGq SAO/jre3iqOw1YRSufbA5EzYdtNKw4u/o5K1ZyE1pBIipoZ0pJJell0vS8e+iQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418638; 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=avZo3lhRdTrwNiCETgv8I0pq3FTZE+/207jE7G6XugY=; b=jECFqpklBn6ksZjUPke4ZHmpxdDHBhWNQQa9w1UJiyHFc8SByghllVT9tvgjrPKvKhaLp5 SYwaFIldz6DI1Leeg6v43sz6KxWu9iB+zwOTTTkT4/ZhF8fSTiTK/fTCFWA3liF7PUUjrj 1HCI4NwxpGoykw+KBBAdOvVD+7yMwlbGGPnQHn1I2MclUg3k5qyk5+1HeFQNU201hjiS2m i4yNvGqyFjtenKt9o/x48vOhUBQ/STNL18bDm/Nj4Ht54lJlGiqhvG1g9mYi/VJEHNriyt fMyA/2CtllQesG6eQQCf+Z5b0JGyZlFikm1eszHBr943OGo6Tsf7IMNmg/LTyA== 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 4S0slL2Cw6zbc7; Wed, 4 Oct 2023 11:23:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNwEC085271; Wed, 4 Oct 2023 11:23:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNwtQ085268; Wed, 4 Oct 2023 11:23:58 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:58 GMT Message-Id: <202310041123.394BNwtQ085268@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 873117aefd2a - stable/13 - swapinfo.8: Mention BLOCKSIZE in the ENVIRONMENT section List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 873117aefd2a3b796cc82942a885f066b1d6bf5d Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=873117aefd2a3b796cc82942a885f066b1d6bf5d commit 873117aefd2a3b796cc82942a885f066b1d6bf5d Author: Felix Johnson AuthorDate: 2022-07-08 19:33:02 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:14:57 +0000 swapinfo.8: Mention BLOCKSIZE in the ENVIRONMENT section Copy the ENVIRONMENT section from df(1) to swapinfo(8), except that the --si option is removed for swapinfo. PR: 235225 Reported by: 0mp MFC after: 3 days (cherry picked from commit 39ad6e289f062fc8da239c0372f49b21f0911060) --- usr.sbin/pstat/pstat.8 | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/usr.sbin/pstat/pstat.8 b/usr.sbin/pstat/pstat.8 index 9cf0e7ef340b..2075718626a3 100644 --- a/usr.sbin/pstat/pstat.8 +++ b/usr.sbin/pstat/pstat.8 @@ -34,7 +34,7 @@ .\" .\" @(#)pstat.8 8.5 (Berkeley) 5/13/94 .\" -.Dd October 11, 2014 +.Dd July 8, 2022 .Dt PSTAT 8 .Os .Sh NAME @@ -228,6 +228,26 @@ is also specified, extract the name list from the specified system instead of the default, which is the kernel image the system has booted from. .El +.Sh ENVIRONMENT +.Bl -tag -width BLOCKSIZE +.It Ev BLOCKSIZE +If the environment variable +.Ev BLOCKSIZE +is set, and the +.Fl h , k , +or +.Fl m +options are not specified, the block counts will be displayed in units of +that block size. +If +.Ev BLOCKSIZE +is not set, and the +.Fl h , k , +or +.Fl m +options are not specified, the block counts will be displayed in 512-byte +blocks. +.El .Sh SEE ALSO .Xr ps 1 , .Xr systat 1 , From nobody Wed Oct 4 11:23:59 2023 X-Original-To: dev-commits-src-branches@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 4S0slM5T42z4vkrH; Wed, 4 Oct 2023 11:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0slM40z2z4cRS; Wed, 4 Oct 2023 11:23:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418639; 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=cywZZExTN/1uceJIhr7HH6n4Y/pv6yakq0uH6McNj9s=; b=BLi8Ew9sdRB2hJ8iWPiXimBk7LRsql0XfmdC1DilLc5Wv1vb1yGubHRybgZ6VkETVp4kN0 u5TIZ8OqbrxUFaar/GUvYs2loM8FeRHNXgtlw2xavqxUTGWelWjYcxyqFbsnrosDb+Oioj 6xAdvHP/tyBdjLPM1R00a2o4LFt6Wiluq8K+/eAE0p7i0eJGJZSG5FQ4WJRmBE2f3E25y3 fLqc/HZ3FGI17mQm7ymW7pfo1KyvBTrL2YOJC+lg1JvJl7aTyAlv7cNyvTKqpw5zSPpYE1 f425VwoKjbyQ7cb7riTH1puicgzvSPZiNJ8BKf5UJijw7fUNjf2iVDQ2G9kseQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418639; a=rsa-sha256; cv=none; b=CsRIbpwUfCCXTmPk4jdc7iptso0/UrqUz16jTZIjyw78PjK+nd3G+NQnsplrM+v4ioNBSY Lhg1PMOS5UykVbSG+R6r2o0uqTbSaGnuJUWlBNHYKSJxRDmj8/9Q4K2Dg8GkKE6vpk2ptS kHPiHXDLMHvr9daa/VPnVi9JqrtMfCMRIO8sX9tl8y+uY4h9Nd1Ec2AH05nc7H6hdju1K1 lqtKFRrieDTaXSa4aZZOqkOiwE+lspaJQ2UwcRPPzPmQXs7d2EIx1WLCg+YuuK5b0sdP1l zkvn6iiarqedEqWut7D3yoISMrdQ1nKabGbKCa0ZvdjsEMZQoCjDKnBEp1nbyg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418639; 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=cywZZExTN/1uceJIhr7HH6n4Y/pv6yakq0uH6McNj9s=; b=Co8Cl5WtHmY80nxZuL1CClGuZLWd3lm7dpXhb3TyXslTiuRuCvAWWt2Dwtksa+wpX1gIHK Z2N4EneHr+duNswlneecLeht0je8kEDBQGbT73mt/M5eZB6CKu51Yn4ZA8C0SoAHNyVpL4 bZfEzzreDPvxBDK7nbTTxkZKtKsVzb/V0KC3U9DWrau9ab26U0n+PqgEeQfXDeIl2t4yIW YQ36dNcEko1cTXbKSPJExGDRpF1qPTyZSJINRzjz5/yvzE1Qbwq2u6tg6/rQ5E9bedzvvq zpB06W8xQ8tw/R188E28iB7M4+YaeJ8lsfJDW7quaSouUMuTkV9BtpgmibZB9g== 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 4S0slM33f6zbdY; Wed, 4 Oct 2023 11:23:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BNxsV085322; Wed, 4 Oct 2023 11:23:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BNxUe085319; Wed, 4 Oct 2023 11:23:59 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:23:59 GMT Message-Id: <202310041123.394BNxUe085319@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: aafabde86ea6 - stable/13 - jail.conf.5: List configuration and example files List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: aafabde86ea6c43cf9c2da26109e9799665ebcef Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=aafabde86ea6c43cf9c2da26109e9799665ebcef commit aafabde86ea6c43cf9c2da26109e9799665ebcef Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-08 08:43:37 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:15:18 +0000 jail.conf.5: List configuration and example files MFC after: 3 days (cherry picked from commit ccee95df52c2477d5580024758ab57ee9775da6a) --- usr.sbin/jail/jail.conf.5 | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/usr.sbin/jail/jail.conf.5 b/usr.sbin/jail/jail.conf.5 index f08ba569b3cf..824ae66d3061 100644 --- a/usr.sbin/jail/jail.conf.5 +++ b/usr.sbin/jail/jail.conf.5 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 6, 2019 +.Dd July 8, 2022 .Dt JAIL.CONF 5 .Os .Sh NAME @@ -175,6 +175,13 @@ shell formats: .Pp Comments are legal wherever whitespace is allowed, i.e. anywhere except in the middle of a string or a token. +.Sh FILES +.Bl -tag -width "indent" -compact +.It Pa /etc/jail.conf +.It Pa /etc/jail.*.conf +.It Pa /etc/jail.conf.d/*.conf +.It Pa /usr/share/examples/jails/ +.El .Sh EXAMPLES .Bd -literal # Typical static defaults: From nobody Wed Oct 4 11:24:00 2023 X-Original-To: dev-commits-src-branches@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 4S0slN666Rz4vkrL; Wed, 4 Oct 2023 11:24: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0slN58JRz4cV0; Wed, 4 Oct 2023 11:24:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418640; 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=2rA0rCNUNzUcDkgOv8991jUpQe62B46MQQHBYy6rwWQ=; b=HCv0OSLBTnf+xXu3rdNVJBfhSqaFIt5dmmCnD1QGcyscaco2+cCZnH0vi1xHHO43jFgj/E FaX/7YkQVy4KRT/GLaFxPBjbVfm+i//NcOqVZbU34EQnRJsXOcjiooA5xz1DT9YTJuTtCK LgaBOJnns5/wm0NKc9J9atJTQy6mWwZeJ/udjsixfqe18xvLI04qU828aCc53evlyaCuXR GcnPziqRMRt3eFgfOoqBR6ELAIWIjdH33hJQ007h07rLziQqLPG9RFxN4az0mh2WjLuNKz sWiyWF1xGBGVLlhMGLAOKBDhAbDLqnx82vEiZCZYHrz/7BmYh36YJEGtD8O6aQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418640; a=rsa-sha256; cv=none; b=UCerZS/EEHQsiaD3M9WACVmtRseEj53R4h8Bls09D4dvmUyzI/pTC2Jv1b2F375rVi8jXy fcZIbkvjSuEjoqpHgpM+SM5mo/r52+ATVu0Y7O89L+b5XZoWWvoKDY6qBVK9BW3a8cm+GR Fmjx/tWyIH9nbCR6PCHyYxThm28jRyDGFwWxYVlC8Lw5gO8ePj4hYLfsu3ruEHbipSkyj4 NYa7hOpvymMpyaPZvXtHuL4wInks6KO+5Qcew3s6zqD1bCGDd0FkPWQuG+/8ti3qe7QFIE rcG8Z36LmK3o0iEJKCmGWCG8nR9MaSrv6c1sogK0RLredmd+iHEwg8074ZfOdQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418640; 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=2rA0rCNUNzUcDkgOv8991jUpQe62B46MQQHBYy6rwWQ=; b=KI+2FPndSbjmxQqA48Nic4iNgTnu4uLnGtLh4KtMyiCXjI3cnsp703ZL0TzlvBhxQrnQvZ vBCBL+oBxw8TWO2senJLaEwCsGwPBXAu4vVO7K0IGJQOOGiejtTcpZCKhUXC1uwAozqXul /BrlLqDSulVoEw6GLZNzrMAraFu5/Pb4JbyGCU9tWW/M3sqdkjS2Vkt8FvcBweAeXUkblb 40Tgp0mSJEyVXz08pxewChwOHzGSmcEusK8bfRR0WUGOqrLMyCi4z68wkpAAE5bOnlWUTS +l+E5vEqQUL68nEhl192he4Go6trIjGrTb7zHXRkxlH0XEAuB6bRyY9nu5HF9g== 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 4S0slN4FC6zbV1; Wed, 4 Oct 2023 11:24:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BO0Ru085377; Wed, 4 Oct 2023 11:24:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BO0jC085374; Wed, 4 Oct 2023 11:24:00 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:24:00 GMT Message-Id: <202310041124.394BO0jC085374@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: afc5d2b0d0ec - stable/13 - rc.conf.5: Add /etc/rc.conf.d/ to FILES List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: afc5d2b0d0ecda6fce00a56ec08d6cb1ee7a472d Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=afc5d2b0d0ecda6fce00a56ec08d6cb1ee7a472d commit afc5d2b0d0ecda6fce00a56ec08d6cb1ee7a472d Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-07-07 18:07:43 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:15:21 +0000 rc.conf.5: Add /etc/rc.conf.d/ to FILES While here, fix the -width argument. MFC after: 3 days (cherry picked from commit a6e734d779b3b5f5679588c1e6f66d0d1533fcbf) --- share/man/man5/rc.conf.5 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/share/man/man5/rc.conf.5 b/share/man/man5/rc.conf.5 index 035cd20631b5..666ccbbc6b6e 100644 --- a/share/man/man5/rc.conf.5 +++ b/share/man/man5/rc.conf.5 @@ -4715,11 +4715,12 @@ to unlock an encrypted dataset. The default is 10. .El .Sh FILES -.Bl -tag -width ".Pa /etc/defaults/rc.conf" -compact +.Bl -tag -width "/etc/defaults/rc.conf" -compact .It Pa /etc/defaults/rc.conf .It Pa /etc/defaults/vendor.conf .It Pa /etc/rc.conf .It Pa /etc/rc.conf.local +.It Pa /etc/rc.conf.d/ .El .Sh SEE ALSO .Xr chmod 1 , From nobody Wed Oct 4 11:24:01 2023 X-Original-To: dev-commits-src-branches@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 4S0slQ1M59z4vknj; Wed, 4 Oct 2023 11:24: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0slP6DL9z4cZN; Wed, 4 Oct 2023 11:24:01 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418641; 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=gj14O2ehaRViQw5H4kYzfd/gw0F39UUJ4JqlRqqdEBk=; b=M+PnTw30/dMcPa5SdrD1++/mYLm7O+ALy7npUUel+k9bsQcKBx7LPeJBJnkkggKyay0wGJ JGU1zJ2b2vyFyKdD1CEwkqdl2z2HEscyl45RnWFv91sm0cS6n+w4MHrTcT6k0iLgTXD8zv bb79zhyXVfb0TLWLgyj4snrxEXqV5nwSKCKvAVuCVCWV029ibSqDcVLTyam34ScGOOco4m QFbdsmyU7cZDcYPtpOTF8NV1kRxD2JaAm5opuJqweR4oPBHL8wnaAzImbxNvUedmaTCXPW U8GfnYNSnIsEmEOsBJQNGIlMYbGZUBbhxnHmSGPe/9fMQ0sa3mrqTEFAIep3vg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418641; a=rsa-sha256; cv=none; b=fD6Wo148P79/KRGws3w8f9Sat08Qfg650wdgVtArSfM37yQmD1vXIkxxUOHGnIGLy5dGeo V2czbxnEQaJnIJCLx58HZgC0HDx9tFq+dY/F4S7ED10gOO+bNJEK02nx7YGLUy5Zl1qDj1 2iW6k/rnYDEArv29WWxqwluxinltSTd+2ZYke2iIHNQlMRSxJC9m4SjMWhzNK4mInUukar 0ZsGfosxi3EuJLrUZouLT9vOOQFvwJrYmqjvvukhN2H/I9+2Ft3sg6aZNW7yINH6LK4Xk4 nVzDeoIDCayzSuhc2DoTz3QXAisp0xL1tZpyM+ljgU2Y69TnXtbnmL/ldv5rHQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418641; 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=gj14O2ehaRViQw5H4kYzfd/gw0F39UUJ4JqlRqqdEBk=; b=wchUKFWDiSS3p277EMf0aO75aCm6QicaYeDP9tUB/ywB2BCr4FM7d/y+8HDLYVPL6bc1qH tYGhgAfxMLlUey8WFCOMOc5jw+VRpyDAtv/PTZ8vZZ4nD6kQX1jnm8Wu2oeS1igHPJn7o+ HuKfLrRe/gv2LgHJuFa3kIuQMyYau+Hj++0zOqhyOrD1h3aHoZ9u2favt5rZr/3MVjwnJx VDnkZBh1NwantgsWf9DeU2MviqWAvP3ORBogBW7E0OL0fibsaJ2uxuAIcNRude+/6GR/nM +bcNGh7ziPh7S0Kx/MXEHUbYRmMNGFNZAQiOmpx8rzkio1pF4ZnNOUMBZEEjeQ== 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 4S0slP5L9Bzbc8; Wed, 4 Oct 2023 11:24:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BO1pP085413; Wed, 4 Oct 2023 11:24:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BO17i085410; Wed, 4 Oct 2023 11:24:01 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:24:01 GMT Message-Id: <202310041124.394BO17i085410@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 41d03ea794c5 - stable/13 - banner: Correct history. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 41d03ea794c569c4a2f6ea386ea96e62c0967cce Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=41d03ea794c569c4a2f6ea386ea96e62c0967cce commit 41d03ea794c569c4a2f6ea386ea96e62c0967cce Author: Warner Losh AuthorDate: 2021-06-21 14:16:10 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:17:44 +0000 banner: Correct history. Banner appeared in the 6th edition of AT&T Research unit. It was subsequently on all the Berkeley tapes, as well as PWB, System III and System V. The PWB/AT&T and BSD banner programs were different, and the current FreeBSD banner program shares many elements of the 3BSD one, though the font has changed. Sponsored by: Netflix (cherry picked from commit b77e235dd52a682c11ddd93256b3848cdc6f1d72) --- usr.bin/banner/banner.6 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.bin/banner/banner.6 b/usr.bin/banner/banner.6 index 2a5cbe599c9d..a1a8e9f0b379 100644 --- a/usr.bin/banner/banner.6 +++ b/usr.bin/banner/banner.6 @@ -27,7 +27,7 @@ .\" .\" From: @(#)banner.6 8.2 (Berkeley) 4/29/95 .\" -.Dd May 26, 2020 +.Dd June 21, 2021 .Dt BANNER 6 .Os .Sh NAME @@ -63,7 +63,7 @@ suitable for a narrow terminal. The .Nm utility first appeared in -.Bx 4.4 . +.At 6 . .Sh AUTHORS .An Mark Horton .Sh BUGS From nobody Wed Oct 4 11:24:02 2023 X-Original-To: dev-commits-src-branches@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 4S0slR2jq8z4vkZm; Wed, 4 Oct 2023 11:24: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0slR0CW7z4cmW; Wed, 4 Oct 2023 11:24:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418643; 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=IOUluiEStHWQrdj1RRQ3pcxsfofHg/KUbbmWwS9J2Gk=; b=arYuBKra0UKCCsmGZI7LiKXBPVJacM0ogLRn4VfYAkSzoWWi1KO/Eza1n/PSKwKlOcnxR4 ozuNh0fhWAGqeL2mQ6R1OeDejU1FguCnutRtFAmlRCgFxuE+LhcQlxnAqqUPZER2ARfbi3 sUd3vNf7Kx5U/dNomXknM2xKCvOnWDnLweiAsn6/I2LIwTg39PRMy0Vyft1VsuS52tKlcl s5PWUeNATOzNj6oyAKWUmq3JOjts1KZYaAC5R0jiZuoT+vUHOrmey/oLqf5RAL3hyLVy8L Ng5ce/JREtZQ5nBscv2ACpSJg4/JNCIp1+/SzOwEFoMu3jmLhBUrtoIQikSoHQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418643; a=rsa-sha256; cv=none; b=lwNSSb1eHeD49D1Y5mYYI//G8ZaJfpDn6eqYa652eVKoBWxyREelkQHuq/FPpAE/a8HvHc uS8aiHFSnLOYQ5r+Hy2gT6ZttbKSn/mmo8u4F4o4bKoIc9BG0NgeaTi7ntodwaaQdjBI4X T0j0sNuVJH2BwmLR9wA6cl7ZwzVSwl8lA/vur8IuZMOBaXj2IQ/t3jw4Mnc8U7wuJCMmdZ mSFgm+ES8mWhvk4MBbtW/uFNhxq2dX/kz7MEhyn2UaRyXKAUTwvRaJ7IFa0CUEbLu2np4O lZWLK8FP/be8EVQVcWJQ8jTNm5GYcRb8I3I5pYHQbdk/6zkd5WA/MVCO8kSZbA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418643; 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=IOUluiEStHWQrdj1RRQ3pcxsfofHg/KUbbmWwS9J2Gk=; b=L9XEqfkM6mc8kiY+4DnGiAO4dEW+DhMURnfn4S61PQy5918Y2viDmzapCqCDg3cK4oZ0Kq K+P7Qu8zC+MHgLyxerLkr60Oofj4qZ3goXwFEF8OEdTYc17qlO8LtwSX0roITMnw0bDT4o MnFUSvv1hNVUtjLFugBo2VTYFZKQjCAQ0ixrK/WeN6SjFdx2R5s4PRpYd9YimE6Wh6YNwm Q9yAPKlPMI/L0+N8oXER5q6SqI/nSefT5fqNEFvI1RGXnkToIiF68HkQlWsmTc1bfh7f9O 0I5xm7TO7nydVbyr4mEWV4hLTWx99lKsxz8yBpUOPsnqWUCHNwjCtCEHAw6jhw== 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 4S0slQ6R5szbkc; Wed, 4 Oct 2023 11:24:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BO2nO085449; Wed, 4 Oct 2023 11:24:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BO25m085446; Wed, 4 Oct 2023 11:24:02 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:24:02 GMT Message-Id: <202310041124.394BO25m085446@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 5d26c78b507b - stable/13 - basename: fix history List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 5d26c78b507bf76353b339a78623851801842e94 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=5d26c78b507bf76353b339a78623851801842e94 commit 5d26c78b507bf76353b339a78623851801842e94 Author: Warner Losh AuthorDate: 2021-06-21 14:23:34 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:18:39 +0000 basename: fix history Basename(1) first appeared in the 7th edition. It was not in the 6th edition, or PWB releases. It's on all the subsequent descendants. Dirname(1) first appeared in System III, and was later picked up in 4.3-Reno and 8th edition research unix (though was not in 4.1BSD where the bulk of 8th edition came from). In System III and V8 it was a shell script, though the BSD version is in C. Sponsored by: Netflix (cherry picked from commit f394c73666ba375cbd6114950b1b1ea5943185a8) --- usr.bin/basename/basename.1 | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/usr.bin/basename/basename.1 b/usr.bin/basename/basename.1 index 9d459abee4fc..d15de2c19edf 100644 --- a/usr.bin/basename/basename.1 +++ b/usr.bin/basename/basename.1 @@ -30,7 +30,7 @@ .\" .\" @(#)basename.1 8.2 (Berkeley) 4/18/94 .\" -.Dd May 26, 2020 +.Dd June 21, 2021 .Dt BASENAME 1 .Os .Sh NAME @@ -113,7 +113,9 @@ compatible. .Sh HISTORY The .Nm -and +utility first appeared in +.At 7 . +The .Nm dirname -utilities first appeared in -.Bx 4.4 . +utility first appeared in +.At III . From nobody Wed Oct 4 11:24:03 2023 X-Original-To: dev-commits-src-branches@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 4S0slS2GvJz4vkJ1; Wed, 4 Oct 2023 11:24: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0slS149lz4crS; Wed, 4 Oct 2023 11:24:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418644; 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=3+A03gZZLZ/gwroZqkPDuEZkWxQtNwnxXZ0HHxgbpxk=; b=Y7qFF04pYftr0v/CpeJ/QFlIyYwIvzDNkbqRky6bVadiSbwKN/0jUN+nQYVUQSPhixe7+S chXpzbQ0G2fo38gqcI5WrnxFifSFaHebb1BYchbt3bd3sD8icJ0P4msZ9Y57Fcf0h3on0L f+ozeLxQDfSu/tGznAvM12OupCShEUct7pZEjS0/ua4/XVojBngG5VD3c/X+uTOn4cePTk N9lZNUqssUqJ40afGr+NVhPgjj4fgibgQgK+Up/Gv0NzQGoZ1qQX1X9XXuSfrpPAqunyDE ICmT5P0pcz06FShBgawkqnYXMttu9bpKYg/zIDdFT9CelVvSu9qt2ZEP3SP1Lg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696418644; a=rsa-sha256; cv=none; b=A6QMHLOMY8jrABgP97MY9DocBO/tQw+o07XfPubI2hZj4VF3XbuiWpg/58oML+u4l7KYvh jc21gUlVVjy0qEjuoRO59OYX0yKDRy7HKANCssUEYyggjDV3JBq97J7lAjuTo2awbghliS pkC6lfQKQI+BCW6AW9dhf75WeVn51ypw4tqDr/kw3QzwNr38t8HeTfIqPkJanfciusJABy cbfLk+k34m3leEkct1bWWdBs1Y6DchPCemMFD8GDNlgYj/dsge9rbK3vcBBpEfmUjvB1Fm SdjLEKn9P7x/dyA0H740BQz/RGRJi6Kk7YEV0RhL3JTODNRh2hteQphVqUThtw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696418644; 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=3+A03gZZLZ/gwroZqkPDuEZkWxQtNwnxXZ0HHxgbpxk=; b=Otu9Gl5TcCOXmaPDrr3yY+TPF4dC5KHLNgGsUOGX7DJKDZZIqKddfYg5Ec2OJCprfeM9dW kjrtIyGdA9SEt86m+3NHWBUZNUGwtlbBql/uDHEIp90bzJOqmWFfWZ7WhQJ0LHXaNPJP9B 5ax0i3sD5cwcdiS2+WDpeEXZCdmxjcV7JTEBDRPXZ1UFlPaTN/wS2NVqtr5FNNso+GeY+I MRVDsK+tRSHOgrjYg7FDp4l3zDWvrkgc4rDFZ39r50fBkHPM/gl1vle50G9pM6mLYzixfH Mq94LOi+8cF9yX4vEYAgMxT4FYhmTum7OZHkfPM1QPKKQcWjayAeJ2dOAqs8PA== 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 4S0slS09kczbc9; Wed, 4 Oct 2023 11:24:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394BO3JS085494; Wed, 4 Oct 2023 11:24:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394BO3rM085491; Wed, 4 Oct 2023 11:24:03 GMT (envelope-from git) Date: Wed, 4 Oct 2023 11:24:03 GMT Message-Id: <202310041124.394BO3rM085491@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: db91ad364211 - stable/13 - manpages: Fix use of At macro List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: db91ad364211e68e44661c0e0018bab14c824698 Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=db91ad364211e68e44661c0e0018bab14c824698 commit db91ad364211e68e44661c0e0018bab14c824698 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2022-03-03 23:03:44 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-04 11:18:49 +0000 manpages: Fix use of At macro The versions for the At macro from 1 to 7 must be prefixed with "v". MFC after: 3 days (cherry picked from commit 8b73b57c1b4bae9c9862d7655f86d1610f32f083) --- usr.bin/banner/banner.6 | 2 +- usr.bin/basename/basename.1 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.bin/banner/banner.6 b/usr.bin/banner/banner.6 index a1a8e9f0b379..8c3ad5e29bc3 100644 --- a/usr.bin/banner/banner.6 +++ b/usr.bin/banner/banner.6 @@ -63,7 +63,7 @@ suitable for a narrow terminal. The .Nm utility first appeared in -.At 6 . +.At v6 . .Sh AUTHORS .An Mark Horton .Sh BUGS diff --git a/usr.bin/basename/basename.1 b/usr.bin/basename/basename.1 index d15de2c19edf..2bbb31e16094 100644 --- a/usr.bin/basename/basename.1 +++ b/usr.bin/basename/basename.1 @@ -114,7 +114,7 @@ compatible. The .Nm utility first appeared in -.At 7 . +.At v7 . The .Nm dirname utility first appeared in From nobody Wed Oct 4 12:08:49 2023 X-Original-To: dev-commits-src-branches@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 4S0tl54Dvqz4vp1d; Wed, 4 Oct 2023 12:08: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0tl53gPBz3Hlt; Wed, 4 Oct 2023 12:08:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421329; 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=yAGinDsszOYA/A/pCbmrodbNuLMk/es6iJ/R9qm+TzE=; b=bCTHYHOcLi1vKrmSTh3kykTzrp+FZ0grDuLJeCMEa8R8ch1UxDqxCLK8dtnD5sKuzUEmWL wWwNzYkSFFtn0KSyszWnhGy3wzgEi2Ho/5IJr+HTRrxARYykFb1x8E1AxVI+/+T3NjZbAm TQ55fxTTaWQeEOpiiz/AZQat10Avo+QWkPa8u9EyFul8KdF2j+Uk49cfgz9Pyf6bic6EFi P7XhbscxmREpSQkvC3OMwfCtTzYdlQZ1E3IhY4CxZht1m8UwZm6LR6C/+Z7HO84xudYbB0 XV0t3GDFoAmzo1F0nLBd3gT9sqYTJNG1i6d56uB7PqrINgWZClfRfBmn+rt1GA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696421329; a=rsa-sha256; cv=none; b=Tt+axftRG0Q7P+W9lozRawo/YEbytpqI6V+YM5oW34/33ZSQo23PjPCgffrAYWa00xuBZM itM13rkuOoh0TnwxRZogH1bvod5THwkwULp/40WFoOVVIQXQIYVe4mjw6CGA7DxAO8TpL1 tLJQZ/eUnMdn7lFDWrWPhYRjEb4pQtRMPFqir4j6SOyuTeswntNpcxzqG77I5ZESAvFCGn 1fJGNOdCw7q8WTm89yqJAgcbMM3VdZJX2usU9n6UuYxSf6c7wStO/rKSUPPRbeuU+3nHpk qAs8QoHkl0gUc0ZzRbwWR6SduECkGQNzfOA3DYXtjBq7ML7sVNgba7bNjHoATw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421329; 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=yAGinDsszOYA/A/pCbmrodbNuLMk/es6iJ/R9qm+TzE=; b=Y06OHH/ZTjZ+Shx8ZW/6GFOuVhlNGZC8dwJb3mqYooIemFQgCSU6/q9hdCtQgp+utwDKio 2eJh10wI+xri3dh73leIIZyl/owcTc5HSdsa0Iwv6kSO09bx0TD/aDAFtRcBZKkevLFHUH AZ107PNp7r/YjKJJTZjZKnu+2WPqe1QXJpHnC1879Fn7nLTMEWppzZliZOeXL43bEWDjvX TbjF5V+yaLJpuP09v8wENDYnXPBWHLvcazkdue0s93ec0b0x4XBMuHVZ+JTsFr4YauEi4Z XQfF7lD+LJACXkDW3mpVq5g2/T2GI1xKh8w84TsrpTg6FXaLZ8t+y46NGUyVDg== 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 4S0tl52hd6zcV4; Wed, 4 Oct 2023 12:08:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394C8new053134; Wed, 4 Oct 2023 12:08:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394C8nbT053131; Wed, 4 Oct 2023 12:08:49 GMT (envelope-from git) Date: Wed, 4 Oct 2023 12:08:49 GMT Message-Id: <202310041208.394C8nbT053131@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Guzik Subject: git: 21a42a7c22c9 - stable/13 - vfs: drop one vnode list lock trip during vnlru free recycle List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 21a42a7c22c9bf921ba9d250c81bd41e70c63ea9 Auto-Submitted: auto-generated The branch stable/13 has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=21a42a7c22c9bf921ba9d250c81bd41e70c63ea9 commit 21a42a7c22c9bf921ba9d250c81bd41e70c63ea9 Author: Mateusz Guzik AuthorDate: 2023-09-14 14:35:40 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-04 12:04:15 +0000 vfs: drop one vnode list lock trip during vnlru free recycle vnlru_free_impl would take the lock prior to returning even though most frequent caller does not need it. Unsurprisingly vnode_list mtx is the primary bottleneck when recycling and avoiding the useless lock trip helps. Setting maxvnodes to 400000 and running 20 parallel finds each with a dedicated directory tree of 1 million vnodes in total: before: 4.50s user 1225.71s system 1979% cpu 1:02.14 total after: 4.20s user 806.23s system 1973% cpu 41.059 total That's 34% reduction in total real time. With this the block *remains* the primary bottleneck when running on ZFS. (cherry picked from commit 74be676d87745eb727642f6f8329236c848929d5) --- sys/kern/vfs_subr.c | 43 +++++++++++++++++++++++++++++++++++-------- 1 file changed, 35 insertions(+), 8 deletions(-) diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index 209d6ac37cda..40f7a6d33c20 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -1278,13 +1278,14 @@ vnlru_free_impl(int count, struct vfsops *mnt_op, struct vnode *mvp) mtx_assert(&vnode_list_mtx, MA_OWNED); if (count > max_vnlru_free) count = max_vnlru_free; + if (count == 0) { + mtx_unlock(&vnode_list_mtx); + return (0); + } ocount = count; retried = false; vp = mvp; for (;;) { - if (count == 0) { - break; - } vp = TAILQ_NEXT(vp, v_vnodelist); if (__predict_false(vp == NULL)) { /* @@ -1307,6 +1308,7 @@ vnlru_free_impl(int count, struct vfsops *mnt_op, struct vnode *mvp) */ TAILQ_REMOVE(&vnode_list, mvp, v_vnodelist); TAILQ_INSERT_TAIL(&vnode_list, mvp, v_vnodelist); + mtx_unlock(&vnode_list_mtx); break; } if (__predict_false(vp->v_type == VMARKER)) @@ -1354,18 +1356,28 @@ vnlru_free_impl(int count, struct vfsops *mnt_op, struct vnode *mvp) */ vtryrecycle(vp); count--; + if (count == 0) { + break; + } mtx_lock(&vnode_list_mtx); vp = mvp; } + mtx_assert(&vnode_list_mtx, MA_NOTOWNED); return (ocount - count); } +/* + * XXX: returns without vnode_list_mtx locked! + */ static int vnlru_free_locked(int count) { + int ret; mtx_assert(&vnode_list_mtx, MA_OWNED); - return (vnlru_free_impl(count, NULL, vnode_list_free_marker)); + ret = vnlru_free_impl(count, NULL, vnode_list_free_marker); + mtx_assert(&vnode_list_mtx, MA_NOTOWNED); + return (ret); } void @@ -1377,7 +1389,7 @@ vnlru_free_vfsops(int count, struct vfsops *mnt_op, struct vnode *mvp) VNPASS(mvp->v_type == VMARKER, mvp); mtx_lock(&vnode_list_mtx); vnlru_free_impl(count, mnt_op, mvp); - mtx_unlock(&vnode_list_mtx); + mtx_assert(&vnode_list_mtx, MA_NOTOWNED); } /* @@ -1549,7 +1561,7 @@ vnlru_under_unlocked(u_long rnumvnodes, u_long limit) } static void -vnlru_kick(void) +vnlru_kick_locked(void) { mtx_assert(&vnode_list_mtx, MA_OWNED); @@ -1559,6 +1571,15 @@ vnlru_kick(void) } } +static void +vnlru_kick(void) +{ + + mtx_lock(&vnode_list_mtx); + vnlru_kick_locked(); + mtx_unlock(&vnode_list_mtx); +} + static void vnlru_proc(void) { @@ -1589,6 +1610,7 @@ vnlru_proc(void) */ if (rnumvnodes > desiredvnodes) { vnlru_free_locked(rnumvnodes - desiredvnodes); + mtx_lock(&vnode_list_mtx); rnumvnodes = atomic_load_long(&numvnodes); } /* @@ -1767,6 +1789,7 @@ vn_alloc_hard(struct mount *mp) rnumvnodes = atomic_load_long(&numvnodes); if (rnumvnodes + 1 < desiredvnodes) { vn_alloc_cyclecount = 0; + mtx_unlock(&vnode_list_mtx); goto alloc; } rfreevnodes = vnlru_read_freevnodes(); @@ -1786,22 +1809,26 @@ vn_alloc_hard(struct mount *mp) */ if (vnlru_free_locked(1) > 0) goto alloc; + mtx_assert(&vnode_list_mtx, MA_NOTOWNED); if (mp == NULL || (mp->mnt_kern_flag & MNTK_SUSPEND) == 0) { /* * Wait for space for a new vnode. */ - vnlru_kick(); + mtx_lock(&vnode_list_mtx); + vnlru_kick_locked(); vn_alloc_sleeps++; msleep(&vnlruproc_sig, &vnode_list_mtx, PVFS, "vlruwk", hz); if (atomic_load_long(&numvnodes) + 1 > desiredvnodes && vnlru_read_freevnodes() > 1) vnlru_free_locked(1); + else + mtx_unlock(&vnode_list_mtx); } alloc: + mtx_assert(&vnode_list_mtx, MA_NOTOWNED); rnumvnodes = atomic_fetchadd_long(&numvnodes, 1) + 1; if (vnlru_under(rnumvnodes, vlowat)) vnlru_kick(); - mtx_unlock(&vnode_list_mtx); return (uma_zalloc_smr(vnode_zone, M_WAITOK)); } From nobody Wed Oct 4 12:08:50 2023 X-Original-To: dev-commits-src-branches@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 4S0tl65VVTz4vntJ; Wed, 4 Oct 2023 12:08: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0tl64T0Mz3Hyg; Wed, 4 Oct 2023 12:08:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421330; 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=YDc9Y/2q3KcFnS3Kc1le+XlTyD46WJXOK2prC3mke68=; b=JfADtfVTbuiF97ahdl+Xr7CvtLkbCjq/MytfxdP8zlPG7oTMezqeMfkzkX2xIJd6LRtPgy tTHpV1COEQPNo615tzXhggerX+WmH+3z4KOMuY+j+1Vqnc8+M48kpvSbtpvOliwa5BQ3wW +mmi9KojiJKiKvDxsp8wFkznrX81CLfaY+ujgaxXpQukrTCCwkTu7CqIsubL6l6JsEMnY3 kvUCfjrL/MEP8ZtUIV++UXzQCxNebTRAy7poCxNgD/OR0GZUnWLM6XvoMQW975vs4WRfcY Fy6gIgbVbSbu3bjNp9JZKmLCbVTv3ndHxOEMpXm2NhBJw3zsg3ulu0wYPrG3zw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696421330; a=rsa-sha256; cv=none; b=dHbVyej3bF3Be1QsJtCdcMOgW6omzlLamIjkek2Lmy03PDJCfKScpnKlUupMZ64x/Pqwrn /hx3WeNqxinKvh3KG/ngjov0THbXcgFXYek/OsTWv7TPQShka9i4sI8Vguj5cG8C2i8jmi NEqlpuCiX/abpNHh9fQGpr0lpgdBBGs7SLv74TwfaaMch8hybgnb4fAbOOsJRH3+GpTRRS IJjsh0agsv8WdA88BnaJ+zRFGmHpZOhU7FlMphOBdZGFpw6nbzuQDjoa9P3TzDxzBtKHHD vBoy/BOrJCx+zP3e+m3TW738lYK85B/bxqpDQJ1nkqZqhMum/pbNtnvD0cfyKw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421330; 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=YDc9Y/2q3KcFnS3Kc1le+XlTyD46WJXOK2prC3mke68=; b=X9wu4L1fy/+7ASwT1r2UvFi7h4PmZwpni0jFRItu8I2e5tXfvqFkSsJ9t/8hfeJ50ve7/V DEC5lZNBp+ftwPERq9ffAldcrohVfvcC5cu8NQQjs3CG1LeWmVnMu2oWGVKiSzlMtrwZB5 5y1tlvL5w2hE6dmhsgAokBas39PXxq4n6nhWs8taiU/KJNXE2mE4ev/iXvw0K28exoNzBF 4RXIt3GdvDlAHD74VaydNq3oSJL0p/NzDvjJMUKmEPILESpawmVH/J+vVZGvcDujO3n0ho /h7R/u6iHfYZpeH0hzsKram88ZGOw06Gj8sfNua5flKRvUBsn8pqJ4I9Rg9H5Q== 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 4S0tl63Z2qzcM6; Wed, 4 Oct 2023 12:08:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394C8oXN053188; Wed, 4 Oct 2023 12:08:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394C8or7053185; Wed, 4 Oct 2023 12:08:50 GMT (envelope-from git) Date: Wed, 4 Oct 2023 12:08:50 GMT Message-Id: <202310041208.394C8or7053185@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Guzik Subject: git: 3a99c0acc1e6 - stable/13 - vfs: don't kick vnlru if it is already running List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 3a99c0acc1e6184862ab83b173fe740ccff9c3f6 Auto-Submitted: auto-generated The branch stable/13 has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=3a99c0acc1e6184862ab83b173fe740ccff9c3f6 commit 3a99c0acc1e6184862ab83b173fe740ccff9c3f6 Author: Mateusz Guzik AuthorDate: 2023-09-14 16:27:47 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-04 12:04:15 +0000 vfs: don't kick vnlru if it is already running Further shaves some lock trips. (cherry picked from commit 76f1153790b6d2e1a4f0389c3ac24e41d08f9ba6) --- sys/kern/vfs_subr.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index 40f7a6d33c20..f58c8920dc4f 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -1572,9 +1572,11 @@ vnlru_kick_locked(void) } static void -vnlru_kick(void) +vnlru_kick_cond(void) { + if (vnlruproc_sig) + return; mtx_lock(&vnode_list_mtx); vnlru_kick_locked(); mtx_unlock(&vnode_list_mtx); @@ -1828,7 +1830,7 @@ alloc: mtx_assert(&vnode_list_mtx, MA_NOTOWNED); rnumvnodes = atomic_fetchadd_long(&numvnodes, 1) + 1; if (vnlru_under(rnumvnodes, vlowat)) - vnlru_kick(); + vnlru_kick_cond(); return (uma_zalloc_smr(vnode_zone, M_WAITOK)); } From nobody Wed Oct 4 12:08:51 2023 X-Original-To: dev-commits-src-branches@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 4S0tl75mTCz4vpBf; Wed, 4 Oct 2023 12:08: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0tl75GjWz3HxG; Wed, 4 Oct 2023 12:08:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421331; 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=yd0D7zwQxz9L6Q+UfBVk0T1SzMMJqkKZX/rvOPNLQM0=; b=CgM+WJQRo2pdDvKpeEsY2tYWegJfSpoUELc0GbtmleTF4whkQG1b8DgV6qAYmJR3SqTN8+ XU305FEBxQh3SRKtjO2FklxH8TtHzu5lSJkJptVBb9+Wxkoxl4LjHIZvi2ityUcmVuT/Pv 6Cg4B7gTPDh7J4vykFywQYUm0x3/uitPwGuQq6kBDmq3hszAYLtVeMWPSVwYPhnxaCZWb2 jx050oHd7gt2kyHh+CjtecP28Rxohh4HdoowXqDhfn4ogab8umJhn6l3d2ksE4XrJe4u3c DqAkTEwF9r6uYTIYU9PsKgk5NuVwt7dJrB5Q1tJhaJex9Fpb5fBtmvSAdzttgQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696421331; a=rsa-sha256; cv=none; b=h22KgH0DvvFW8TVfu2YfG5tIuRg2/0XYapB0orlcs9pgALrhkCXDMNCO1k4OZqN1qoKWtz fIpo4/FFaLsZmenj+4Y5OBYn62E9GccMOoRaSXHntpsw+npxUJUi+d0g1LaR+Wr+LvFjl5 s2UWH0tUoW1ee4b+sJqhlUwzNrlUNPHWrsr4qe9hA/kYouNqnnz/5NHCcaWinfpgXtRQrM D0nbBErss0GUI9TSxzhzYJ2C+9+1AYOz1IPtxiclE9w5Xe7mABDptWvN6ZL2AWZO/Afdt8 4EI3Sac1BdAzjeJjAnA7CrQk8xJYUnMcbkNe9oP1YQEUbWCyajVP9qVGwyIPAA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421331; 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=yd0D7zwQxz9L6Q+UfBVk0T1SzMMJqkKZX/rvOPNLQM0=; b=mNdGknqixOrysJ+aBMDnoX7DTqEyFHvczP9AymAWnK2kFqv1ztcW9IUeDMIp70M10/ROWW 7WduAlWIm/aVlOSlqUbxoKI7tBZrmAzOCuAQs2G6pEmym6t5EpvA7sxYjilUv4vLQSKYk0 TPejFqzN4btcbhILvAPDLJoeQ04fKbcSNJixpT2pNPFkNT0O+oaqCKcDYzQu0ih5Ynqkaj 8k2C16ewvFXqHpWcTPKXrf/zQyfIKLdH9AFpAQIsvAs6vS+pwhlDYHvVseClS8f6HrpskF 0Qp+hpTvfe80UMPGOhflwbWk8BdFeUBKVbgXyEU5eNw/I/sr7dea3p8aHG4reg== 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 4S0tl74MR9zc3W; Wed, 4 Oct 2023 12:08:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394C8pZX053236; Wed, 4 Oct 2023 12:08:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394C8pnv053233; Wed, 4 Oct 2023 12:08:51 GMT (envelope-from git) Date: Wed, 4 Oct 2023 12:08:51 GMT Message-Id: <202310041208.394C8pnv053233@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Guzik Subject: git: 2167265cb801 - stable/13 - vfs: fix stale comment about freevnodes management List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 2167265cb801f1eeea3a1dd768fa1d9779d10a6e Auto-Submitted: auto-generated The branch stable/13 has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=2167265cb801f1eeea3a1dd768fa1d9779d10a6e commit 2167265cb801f1eeea3a1dd768fa1d9779d10a6e Author: Mateusz Guzik AuthorDate: 2023-09-14 17:28:32 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-04 12:04:15 +0000 vfs: fix stale comment about freevnodes management (cherry picked from commit 9dc0c983b0931f359c2ff10d47ad835ef74e929a) --- sys/kern/vfs_subr.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index f58c8920dc4f..41fd5052968c 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -1459,12 +1459,12 @@ static struct proc *vnlruproc; static int vnlruproc_sig; /* - * The main freevnodes counter is only updated when threads requeue their vnode - * batches. CPUs are conditionally walked to compute a more accurate total. + * The main freevnodes counter is only updated when a counter local to CPU + * diverges from 0 by more than VNLRU_FREEVNODES_SLOP. CPUs are conditionally + * walked to compute a more accurate total. * - * Limit how much of a slop are we willing to tolerate. Note: the actual value - * at any given moment can still exceed slop, but it should not be by significant - * margin in practice. + * Note: the actual value at any given moment can still exceed slop, but it + * should not be by significant margin in practice. */ #define VNLRU_FREEVNODES_SLOP 126 From nobody Wed Oct 4 12:08:52 2023 X-Original-To: dev-commits-src-branches@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 4S0tl873Wkz4vnyh; Wed, 4 Oct 2023 12:08: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0tl86Fnhz3Hvb; Wed, 4 Oct 2023 12:08:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421332; 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=ebp/+qN2Jxf3oblh2sgqfXCthVGfQ/HQkPsnuXrplsM=; b=M7hc1FJaHmNM5HmT5/5rnuXx2x1/gEC1V8N3NtI0iLlKgOOWe/qLQDubargmW9zRImQXar JMvrkRvpj5Dh/7GbgTzHbs7Htdbm6jLWdiuffjq4s7+JS19KcwfmzXw2sAs3rK/OMa/uPu rWQJc/boSXUUKHOLSnqZ6TH0YGs6HvFOFSSq7wFjOeS+03vz7hkMDPoKI9+mg3RNHRh9rE J7f0GOpo2RmaVDIe9YDGgFfVQ7J7+v5I+OtU0+fOuOiLt5l4PPjwOf3QyKP2FyWK9Zo9l7 Dl580GQZQhBFAaWnwIVfT7MqgyjdF4JRBU7yDkbwns1wGLSFMIY+XHTia1gNVQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696421332; a=rsa-sha256; cv=none; b=RV0F3QBSO+ZyJo59ieAr4Pyyznqppq/s/sDNbQl7bdpo0Vavx+zW1q3ApHdB2PuncJbJcL ckGZSWK6xrmIr8y0fg4HWA1ftu96jx8kDNNIJ7qguHyXL7VWzesI4kxSWgHy1aCc/JwOzo Q70H/PUWKCklw3EfVwPEKjdpI2fLb7lNO3Cw47xIBlOfRHtBt13F/teV4UF6recUS+OIXf BRrZ8XlADu/jOs994/lFudtu2Nc+A5wK9e6uXTpf37Z0i/i7cQmxpQ+uSlsuktHp/Q93Ep IDt7UbPoufHPDFK0m2mOsCrXUWf6SGBtnsT223JUSYgco23Gu+2WuD/u0EItqA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421332; 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=ebp/+qN2Jxf3oblh2sgqfXCthVGfQ/HQkPsnuXrplsM=; b=IBj48nPcYVsneAqs1oHMyJm5uaKgPajuWBUjwiYACCrcxzAaspD0jOrE+bjRkLd/V4xs60 zP213EJgkrFaOtod+VFoAOGQ2M1u8pJEycTZz/P3H65RMlhpxH0lA1Gpy9jim45IxFh7N8 Rhr/qjYPKC4lwAJ6Akydlp2y1WrDgCriuXSgc1A7SNNro5pUOFTPZLkmOzk8MfMzXxnB7a eJ7wQDdpuSQLMpUDpQwbAnNkomRpI1UBymQan5Cba0PTqiJa11L5kUgbGbK1UlqRwNTA0P JF3OBpEzLOXGKXIf5qRP4S3cE+kyM/uXj5tykwRLmlf6K9Xhul06kL0K6E4Pvg== 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 4S0tl85Lw7zcgT; Wed, 4 Oct 2023 12:08:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394C8q5W053272; Wed, 4 Oct 2023 12:08:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394C8qhN053269; Wed, 4 Oct 2023 12:08:52 GMT (envelope-from git) Date: Wed, 4 Oct 2023 12:08:52 GMT Message-Id: <202310041208.394C8qhN053269@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Guzik Subject: git: 1573dad63632 - stable/13 - vfs: retire vnlru_under_unlocked List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 1573dad63632b2545516e3aa9b5bfc9a0f06281a Auto-Submitted: auto-generated The branch stable/13 has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=1573dad63632b2545516e3aa9b5bfc9a0f06281a commit 1573dad63632b2545516e3aa9b5bfc9a0f06281a Author: Mateusz Guzik AuthorDate: 2023-09-14 23:05:51 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-04 12:04:16 +0000 vfs: retire vnlru_under_unlocked It only looks at the centralized value which in corner cases can end up being negative. (cherry picked from commit ba5dc166e0f390c703042910b637a83c705c8af3) --- sys/kern/vfs_subr.c | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index 41fd5052968c..04bc26014db7 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -1543,23 +1543,6 @@ vnlru_under(u_long rnumvnodes, u_long limit) return (space < limit); } -static bool -vnlru_under_unlocked(u_long rnumvnodes, u_long limit) -{ - long rfreevnodes, space; - - if (__predict_false(rnumvnodes > desiredvnodes)) - return (true); - - space = desiredvnodes - rnumvnodes; - if (space < limit) { - rfreevnodes = atomic_load_long(&freevnodes); - if (rfreevnodes > wantfreevnodes) - space += rfreevnodes - wantfreevnodes; - } - return (space < limit); -} - static void vnlru_kick_locked(void) { @@ -1842,7 +1825,7 @@ vn_alloc(struct mount *mp) if (__predict_false(vn_alloc_cyclecount != 0)) return (vn_alloc_hard(mp)); rnumvnodes = atomic_fetchadd_long(&numvnodes, 1) + 1; - if (__predict_false(vnlru_under_unlocked(rnumvnodes, vlowat))) { + if (__predict_false(vnlru_under(rnumvnodes, vlowat))) { atomic_subtract_long(&numvnodes, 1); return (vn_alloc_hard(mp)); } From nobody Wed Oct 4 12:08:53 2023 X-Original-To: dev-commits-src-branches@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 4S0tlB0v20z4vp8q; Wed, 4 Oct 2023 12:08:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0tlB05qNz3J6R; Wed, 4 Oct 2023 12:08:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421334; 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=yHW7+htdkuGB3MFLq0rlOMghg17f0BHPeuNvcIgTsWE=; b=WswfLSv4NBJ9Q54BY+drIorliSDyFntsZzxMeuruG4dBeFYFgV8PKdYx3D1SPs8K46sfph XBB/rwg09U1fOJOLHw9D28cHIsckHKuW/OuekCjqzSC7CzgmNGve0a+ytECcUcZnIH5Ggw qjTUHlv2LyLZltfKPqr7cdZbdT/eZz07nQQ+9QTRnzxRDw0lFOGrfTPuB807/syykEPuky AK6yJSeIVgoinNlH9yI1ghN1vV9QFmubIyb4DitvCbdPMs4MCgrtVvmRGVQ+KX0dHycD4P F/dcEFEpwZf1tbZugEJ20qmORW7VVaJRCM2cpDMCIf6gvW9K1BVSMzgr1JEvnw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696421334; a=rsa-sha256; cv=none; b=j8hlqQvLwafcbuDuOs9EJXeFdMZbzyWACQti6So6keB7xRJfakqiZfcA6Mj/j2K+mg6CTd 2+W11qEh8Sk9fPCD7Wi+hJJRuDXW6RGOkTQ05wa3FuYR3h4l6vKqdmuGl3wQr1GRwLWJG0 pJNUmheVO3cTrpo6lYUUM1KIyABnqOgyZ5Wum+NYopAEGlYNQ+kVmPuoePS4Hdp39q2D8z dFVMFhN6bf+GAF3dNY5J0+8nGLuY6FU5qVxoPuadUIEkJBSIfFlsPf0phCt9fYwiZHrlW0 XHWxPcxXic9N0AehXaeQD/zQFxcFq7kS8TW/28Ye5aM3r7ur8LcA4LFijWjQXQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421334; 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=yHW7+htdkuGB3MFLq0rlOMghg17f0BHPeuNvcIgTsWE=; b=wvG74z/Iv0ctF2W5OMlSZyJwyRCrNg0IJFX+f6CE20DBB2n2HRJaDD29HYQVHLUEUEzBh0 y+J/BLhegIrcfxWLs0L8BZNwleI7AZEvky0TG986o1o+7saAYpGZUZhuj4rID/Qbms/mTi MbCIE1sFcWpZjs4jqsU+Wg5/zKpSlHeQS1ig5irJGYgIUtqsITDmuAWWfNMGFYUBCkdbhT rcAMNB++cpkefngQ0/He5kdN4lhzpoPvU3HFBSXnphX4nkImgXQUzOwhskbG/jqraG2Xfq AUu1XhPyLb3t9U09rQbNhvxyW5Jb1pwcshu/we+QFsk5+qwYo+X30498DNhh5Q== 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 4S0tl968cbzccN; Wed, 4 Oct 2023 12:08:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394C8rTe053324; Wed, 4 Oct 2023 12:08:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394C8rED053321; Wed, 4 Oct 2023 12:08:53 GMT (envelope-from git) Date: Wed, 4 Oct 2023 12:08:53 GMT Message-Id: <202310041208.394C8rED053321@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Guzik Subject: git: e863caad0e74 - stable/13 - vfs: use vnlru_read_freevnodes for the freevnodes sysctl List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: e863caad0e749e0c1b9e18bcb97e52297c71acb7 Auto-Submitted: auto-generated The branch stable/13 has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=e863caad0e749e0c1b9e18bcb97e52297c71acb7 commit e863caad0e749e0c1b9e18bcb97e52297c71acb7 Author: Mateusz Guzik AuthorDate: 2023-09-14 23:53:11 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-04 12:04:16 +0000 vfs: use vnlru_read_freevnodes for the freevnodes sysctl For a more accurate result. (cherry picked from commit 03bfee175269960c67cab64d761bbb5eb9ac5878) --- sys/kern/vfs_subr.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index 04bc26014db7..2fc5c1ef7a91 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -183,8 +183,6 @@ static struct vnode *vnode_list_reclaim_marker; */ static long wantfreevnodes; static long __exclusive_cache_line freevnodes; -SYSCTL_ULONG(_vfs, OID_AUTO, freevnodes, CTLFLAG_RD, - &freevnodes, 0, "Number of \"free\" vnodes"); static long freevnodes_old; static counter_u64_t recycles_count; @@ -349,6 +347,19 @@ SYSCTL_PROC(_kern, KERN_MAXVNODES, maxvnodes, CTLTYPE_ULONG | CTLFLAG_MPSAFE | CTLFLAG_RW, NULL, 0, sysctl_maxvnodes, "LU", "Target for maximum number of vnodes"); +static int +sysctl_freevnodes(SYSCTL_HANDLER_ARGS) +{ + u_long rfreevnodes; + + rfreevnodes = vnlru_read_freevnodes(); + return (sysctl_handle_long(oidp, &rfreevnodes, 0, req)); +} + +SYSCTL_PROC(_vfs, OID_AUTO, freevnodes, + CTLTYPE_ULONG | CTLFLAG_MPSAFE | CTLFLAG_RD, NULL, 0, sysctl_freevnodes, + "LU", "Number of \"free\" vnodes"); + static int sysctl_wantfreevnodes(SYSCTL_HANDLER_ARGS) { From nobody Wed Oct 4 12:08:54 2023 X-Original-To: dev-commits-src-branches@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 4S0tlC3xdjz4vpBm; Wed, 4 Oct 2023 12:08: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0tlC1HVWz3JF6; Wed, 4 Oct 2023 12:08:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421335; 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=C/86dGbqBqYVv+Q/RTAM3IcZlVAJYIoMv304aUdUJRQ=; b=s8JuZOxXoV0OQNcQYe448SLm+4OJkajXhuaOfx3fiT5A62rT9F4plWNBe4hX0oQYl07d5x see8ka2En5ZUBR31SKtOtwxbooNBFN1kegY98INipeNhQA62l2c4sOG0EKLXYnzEbDVtHw zISRYf4jpR2M/9sDI5T986R8dK+02JVD3gljGohmO3jmmvlOO0XkSHa9nC17IfgPxJgLRd y1LsPmkBjTqe88V8zzThWJchdgeL7Fp4sDTTeDT1RJG/bVB3GGUOjZcJeOpL6uXWd7xtpk yjyGg0cjpHv2OZHnskYNTuObEWH57hbbEniC/gUw8BHfDQeKuMaKVCBaMvjYtA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696421335; a=rsa-sha256; cv=none; b=qON+n36LmwHrdIzfmyBJW698uPiKyUBEu9MB9lPoyWAhkpnh8XKkHwpMmvYa4fjPxg0JZ9 SsC508kZC3fvLKXRafn/9h0iBd8Hb9PPWRbtAtwM0UrnZ43O4u9A26Pi10ui5yIPC5RVZd myKbrwBZJ/gUDnO+Z/CfWhFv+iniFVCSD1U02HqIRiGLw2oIQctjbeAVpYGWCXqoc3k7HX V71MVU3BWseyvuPuIYs/jK9UNjvLyAH3CqNEVnZBJFyS9ExRzNHRgHFzQME0JCMVou5i8y 4ucqMtG2dwc0hx8vfyfeyB6ooE8pNwcdrt8OEoxfqOyLATTP9VpWWZ8RL/afBQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421335; 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=C/86dGbqBqYVv+Q/RTAM3IcZlVAJYIoMv304aUdUJRQ=; b=WRMdj0FVmAf0fTIFhGld1j5AHMhHZXRvaV/h4DIOy4KHC7aobl6974S2lCDiddp+s6vHqH W8b45JslWOJb9YZg0BDsreKwt3w4OADd52gst9FipSaMbPDv3hMBJiLwbXg3Osz9xO776m WFMgI03zCvBg6/8YeZmtLku9+l/1R05J5Nh4c0OjotjxCpHQ3BbsrBRyClNjvLa+p1QWxm ap1DkLDpHFhxuSxtUFP4r3hONW7IVxvjnSv+x+PRTQC+lWMsS6bVCEV1zym8/Yh3TCe8nF UbKWlQeMg3MUvO2Z2naIA3ubFH1PxbehzhfiuRYACAJSCyJ/SpzKlD92uxdhyQ== 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 4S0tlC0FWRzc3X; Wed, 4 Oct 2023 12:08:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394C8sgd053363; Wed, 4 Oct 2023 12:08:54 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394C8sge053360; Wed, 4 Oct 2023 12:08:54 GMT (envelope-from git) Date: Wed, 4 Oct 2023 12:08:54 GMT Message-Id: <202310041208.394C8sge053360@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Guzik Subject: git: 067133ad6024 - stable/13 - vfs: retire kern.minvnodes List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 067133ad6024f5d41ed7fa34009a6bbf6b4ffc7c Auto-Submitted: auto-generated The branch stable/13 has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=067133ad6024f5d41ed7fa34009a6bbf6b4ffc7c commit 067133ad6024f5d41ed7fa34009a6bbf6b4ffc7c Author: Mateusz Guzik AuthorDate: 2023-09-16 07:33:36 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-04 12:04:16 +0000 vfs: retire kern.minvnodes It was marked as legacy in 2005. (cherry picked from commit 2a689cadf092a3319d7619c3f4aa242011c20c8e) --- sys/kern/vfs_subr.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index 2fc5c1ef7a91..c41798c56e18 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -384,8 +384,6 @@ SYSCTL_PROC(_vfs, OID_AUTO, wantfreevnodes, CTLTYPE_ULONG | CTLFLAG_MPSAFE | CTLFLAG_RW, NULL, 0, sysctl_wantfreevnodes, "LU", "Target for minimum number of \"free\" vnodes"); -SYSCTL_ULONG(_kern, OID_AUTO, minvnodes, CTLFLAG_RW, - &wantfreevnodes, 0, "Old name for vfs.wantfreevnodes (legacy)"); static int vnlru_nowhere; SYSCTL_INT(_debug, OID_AUTO, vnlru_nowhere, CTLFLAG_RW, &vnlru_nowhere, 0, "Number of times the vnlru process ran without success"); From nobody Wed Oct 4 12:08:56 2023 X-Original-To: dev-commits-src-branches@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 4S0tlD3KJwz4vp6R; Wed, 4 Oct 2023 12:08: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0tlD24KFz3JD3; Wed, 4 Oct 2023 12:08:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421336; 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=bUcN/kKWa+sMgQ3uxU+34oWS5fL0naiXyAlxWADfJGI=; b=Vl3vh8tDlELpuOMhrZ0JUTyf1qAUeKxh6J1LwYk5VD6wEG8uikVQdzTRgd41Ur4vOzp4H+ 8pJP43DMaMyZs3v/JO+puP8Ydc6mgVTew+7+7L05ADLlCQ+BrmYlUlb3dlLohRh72W5LTt 9zJ9/Z9opaYTm6ugrE+4ZkbZsFCRn3d03dbWI/ePEL2z4JsG207HnI7huhglV5hsYXmjX8 COUy3dIYIufxil0o5AIbLNOyDhtSDEE7u/bxM0SAeTb3DVNP3YpGTQHhanSfZM8lFrlmkS n09Cq+6V4WvX1Jixo6EFVdRcuQ/Qsy/CfWSo4Cu9+wesqDgrTxIZ+Gi75+VfZQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696421336; a=rsa-sha256; cv=none; b=CB1Kx1/M/mM+WWAGZ3U3ftubqxEdMHVgKG67lPj/DsSZDBCTG5bpgGzv0FxRNsBoaLlmEV yROvkKKepva/CKXOvpNXnvAetjUjUWQkdUsyvYl2ycIri1SymyKj1PUuNEV9VmI4wEKzjl 1ilecbfDBnknvB9fYs91UIIXyCb5qM3BMFdzrD0Vhhzq4B6AgFCdmOT1qwszoY4afGQHex ELvES3P8baDhtOHV8BX0NGgQ6i7UY2bKkkTu1waPPreF8JZx07QzB+eRy4+l2nmOlcoOWs L/KAZTEEe8a690uuljbZsHUmLSd1cxhjAGHDtlZxDMoIoz5m2MhLWeYgXP/UmQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421336; 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=bUcN/kKWa+sMgQ3uxU+34oWS5fL0naiXyAlxWADfJGI=; b=nwhOGBzqGxazR91iOeOFECOdOxNll75WwIpbxWvd0VOsNLK1qMD7EprOBj0tLKwD0L3e+j qThm0Z+234aQCgS492H/OFPHZ2m6JNbn57kFEQIEnjh9+WRYO9DI3+mR4tjBfu1Hv7MNRr xws7V7NQ2nIBW9yKpdIvdHvlivOTziXo3YSIbv90Fh9EueCQTuKtl5u0xk6yRH2kL5zIxs dL5c9dzD78mh/DKaqbPjfckojUusb1czKjtTa/XzHharE76xVK2WgG8SwPjafmkVykLg5a kbyYBu/qe0hmlEaR1zI/vBMiNDjhqelcKbGCujrMY0/qRJzhdwlIv43nmnSYtA== 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 4S0tlD1BNzzcgV; Wed, 4 Oct 2023 12:08:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394C8uRM053408; Wed, 4 Oct 2023 12:08:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394C8uGP053405; Wed, 4 Oct 2023 12:08:56 GMT (envelope-from git) Date: Wed, 4 Oct 2023 12:08:56 GMT Message-Id: <202310041208.394C8uGP053405@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Guzik Subject: git: 77a8bd148796 - stable/13 - vfs: group vnode-related sysctls under vfs.vnode List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 77a8bd1487966357dcb16cc27bbf269d9922e5a2 Auto-Submitted: auto-generated The branch stable/13 has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=77a8bd1487966357dcb16cc27bbf269d9922e5a2 commit 77a8bd1487966357dcb16cc27bbf269d9922e5a2 Author: Mateusz Guzik AuthorDate: 2023-09-15 21:08:38 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-04 12:05:56 +0000 vfs: group vnode-related sysctls under vfs.vnode Instead of having things scattered through vfs, debug and kern trees. Old names remain for compatibility. Sample output of "sysctl vfs.vnode": vfs.vnode.vnlru.failed_runs: 0 vfs.vnode.vnlru.recycles_free: 0 vfs.vnode.vnlru.recycles: 0 vfs.vnode.stats.alloc_sleeps: 0 vfs.vnode.stats.free: 1310 vfs.vnode.stats.skipped_requeues: 0 vfs.vnode.stats.created: 1686 vfs.vnode.stats.count: 1641 vfs.vnode.param.wantfree: 2097152 vfs.vnode.param.limit: 8388608 (cherry picked from commit d3e6478912431309aad36211b6c39b0d741312dc) --- sys/kern/vfs_subr.c | 32 ++++++++++++++++++++++++++++++-- 1 file changed, 30 insertions(+), 2 deletions(-) diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index c41798c56e18..8c8f69c88726 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -125,6 +125,15 @@ static int v_inval_buf_range_locked(struct vnode *vp, struct bufobj *bo, daddr_t startlbn, daddr_t endlbn); static void vnlru_recalc(void); +static SYSCTL_NODE(_vfs, OID_AUTO, vnode, CTLFLAG_RW | CTLFLAG_MPSAFE, 0, + "vnode configuration and statistics"); +static SYSCTL_NODE(_vfs_vnode, OID_AUTO, param, CTLFLAG_RW | CTLFLAG_MPSAFE, 0, + "vnode configuration"); +static SYSCTL_NODE(_vfs_vnode, OID_AUTO, stats, CTLFLAG_RW | CTLFLAG_MPSAFE, 0, + "vnode statistics"); +static SYSCTL_NODE(_vfs_vnode, OID_AUTO, vnlru, CTLFLAG_RW | CTLFLAG_MPSAFE, 0, + "vnode recycling"); + /* * Number of vnodes in existence. Increased whenever getnewvnode() * allocates a new vnode, decreased in vdropl() for VIRF_DOOMED vnode. @@ -132,10 +141,14 @@ static void vnlru_recalc(void); static u_long __exclusive_cache_line numvnodes; SYSCTL_ULONG(_vfs, OID_AUTO, numvnodes, CTLFLAG_RD, &numvnodes, 0, + "Number of vnodes in existence (legacy)"); +SYSCTL_ULONG(_vfs_vnode_stats, OID_AUTO, count, CTLFLAG_RD, &numvnodes, 0, "Number of vnodes in existence"); static counter_u64_t vnodes_created; SYSCTL_COUNTER_U64(_vfs, OID_AUTO, vnodes_created, CTLFLAG_RD, &vnodes_created, + "Number of vnodes created by getnewvnode (legacy)"); +SYSCTL_COUNTER_U64(_vfs_vnode_stats, OID_AUTO, created, CTLFLAG_RD, &vnodes_created, "Number of vnodes created by getnewvnode"); /* @@ -187,14 +200,18 @@ static long freevnodes_old; static counter_u64_t recycles_count; SYSCTL_COUNTER_U64(_vfs, OID_AUTO, recycles, CTLFLAG_RD, &recycles_count, + "Number of vnodes recycled to meet vnode cache targets (legacy)"); +SYSCTL_COUNTER_U64(_vfs_vnode_vnlru, OID_AUTO, recycles, CTLFLAG_RD, &recycles_count, "Number of vnodes recycled to meet vnode cache targets"); static counter_u64_t recycles_free_count; SYSCTL_COUNTER_U64(_vfs, OID_AUTO, recycles_free, CTLFLAG_RD, &recycles_free_count, + "Number of free vnodes recycled to meet vnode cache targets (legacy)"); +SYSCTL_COUNTER_U64(_vfs_vnode_vnlru, OID_AUTO, recycles_free, CTLFLAG_RD, &recycles_free_count, "Number of free vnodes recycled to meet vnode cache targets"); static counter_u64_t vnode_skipped_requeues; -SYSCTL_COUNTER_U64(_vfs, OID_AUTO, vnode_skipped_requeues, CTLFLAG_RD, &vnode_skipped_requeues, +SYSCTL_COUNTER_U64(_vfs_vnode_stats, OID_AUTO, skipped_requeues, CTLFLAG_RD, &vnode_skipped_requeues, "Number of times LRU requeue was skipped due to lock contention"); static u_long deferred_inact; @@ -344,6 +361,9 @@ sysctl_maxvnodes(SYSCTL_HANDLER_ARGS) } SYSCTL_PROC(_kern, KERN_MAXVNODES, maxvnodes, + CTLTYPE_ULONG | CTLFLAG_MPSAFE | CTLFLAG_RW, NULL, 0, sysctl_maxvnodes, + "LU", "Target for maximum number of vnodes (legacy)"); +SYSCTL_PROC(_vfs_vnode_param, OID_AUTO, limit, CTLTYPE_ULONG | CTLFLAG_MPSAFE | CTLFLAG_RW, NULL, 0, sysctl_maxvnodes, "LU", "Target for maximum number of vnodes"); @@ -357,6 +377,9 @@ sysctl_freevnodes(SYSCTL_HANDLER_ARGS) } SYSCTL_PROC(_vfs, OID_AUTO, freevnodes, + CTLTYPE_ULONG | CTLFLAG_MPSAFE | CTLFLAG_RD, NULL, 0, sysctl_freevnodes, + "LU", "Number of \"free\" vnodes (legacy)"); +SYSCTL_PROC(_vfs_vnode_stats, OID_AUTO, free, CTLTYPE_ULONG | CTLFLAG_MPSAFE | CTLFLAG_RD, NULL, 0, sysctl_freevnodes, "LU", "Number of \"free\" vnodes"); @@ -381,12 +404,17 @@ sysctl_wantfreevnodes(SYSCTL_HANDLER_ARGS) } SYSCTL_PROC(_vfs, OID_AUTO, wantfreevnodes, + CTLTYPE_ULONG | CTLFLAG_MPSAFE | CTLFLAG_RW, NULL, 0, sysctl_wantfreevnodes, + "LU", "Target for minimum number of \"free\" vnodes (legacy)"); +SYSCTL_PROC(_vfs_vnode_param, OID_AUTO, wantfree, CTLTYPE_ULONG | CTLFLAG_MPSAFE | CTLFLAG_RW, NULL, 0, sysctl_wantfreevnodes, "LU", "Target for minimum number of \"free\" vnodes"); static int vnlru_nowhere; SYSCTL_INT(_debug, OID_AUTO, vnlru_nowhere, CTLFLAG_RW, &vnlru_nowhere, 0, "Number of times the vnlru process ran without success"); +SYSCTL_INT(_vfs_vnode_vnlru, OID_AUTO, failed_runs, CTLFLAG_RD | CTLFLAG_STATS, + &vnlru_nowhere, 0, "Number of times the vnlru process ran without success"); static int sysctl_try_reclaim_vnode(SYSCTL_HANDLER_ARGS) @@ -1771,7 +1799,7 @@ vtryrecycle(struct vnode *vp) static u_long vn_alloc_cyclecount; static u_long vn_alloc_sleeps; -SYSCTL_ULONG(_vfs, OID_AUTO, vnode_alloc_sleeps, CTLFLAG_RD, &vn_alloc_sleeps, 0, +SYSCTL_ULONG(_vfs_vnode_stats, OID_AUTO, alloc_sleeps, CTLFLAG_RD, &vn_alloc_sleeps, 0, "Number of times vnode allocation blocked waiting on vnlru"); static struct vnode * __noinline From nobody Wed Oct 4 12:08:57 2023 X-Original-To: dev-commits-src-branches@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 4S0tlF3vxmz4vp1v; Wed, 4 Oct 2023 12:08:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0tlF3GdHz3JLj; Wed, 4 Oct 2023 12:08:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421337; 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=x3nx/FhuVbLjKwTFEeDlEQoPvtle8T/eKJfLOLKGquY=; b=dz5KmZIkLjoizAJ9sWgHYbHbB//0EqbWhmcib3NuV85bzVTDdzI5nJw/BkzdmTNfrvfaHs UJrDJ5J61KB4KmuYzDnLOFBe1U8Z5qSs4d0C9jtppbTdOGuItrlhCpvaFe2uxg/iRZpAcH cbxHsukwvT1Nt2TC/kOdjJiLy1JZJHkHa/YJrl3K/P8+U4/pVRWK7YZkJiUaPk+kDpvXX7 u3bkfgOVIikVGN6pfYo94PYnx/FYvJdPhrcyGKvPn6bjgfxxxopVZtjL/UKjWWFPHF/l11 gMa232gJnq4vJpZ1GPrdf0lA9GB6scy616Z05Ec1jks7iSsCWuAp7CdRC34ZLQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696421337; a=rsa-sha256; cv=none; b=wFmlbMgIGuoOw/zG9+9yi09hWJaUV7+DJJrhoOKIGkitgH5ZlR9a31/T0javkccjMdz3oG ym2nwBLpu5eq0fsLMZcQnKBkmfN6MWvz4zbbsf2/eChFAb+V8XdOdYTsCN1rccH7yuf45L zXrLgMcgRJBk8udTeG9huhDxzjBTcw3HVhgZbNVjeVGy1VgLa4ET0ORkbWVumHUD5lhAG1 Lq7WFtlYej+GUjYgXivP+zFQxbSe6+1jvgZt4Y/zyQPB21xodIMk3twe9wjNBzY5bt8p52 wFCt2jQmpkg11HINzmyvE2/iOSUKoTefqPDGQrv2qOXTX5F514LAItSW5nrP6Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421337; 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=x3nx/FhuVbLjKwTFEeDlEQoPvtle8T/eKJfLOLKGquY=; b=xJPC186BgPBuW8GOgoPF9Qc/6hQ5JARoQLOP//hdJAtmwmz8xHUipjQi4oR/xnGwRcksjY 5UBI3KcKlSVloXL4K5kOY3KTdjnIHbF0tbxUAAuTLXGBP5JdYl2B4lg4dkLhKonax4MVpp 2HU9ZwN5SZ0fJWKXam39VIFVPJ9+gQBby76zikID+t3t1gdkzzMj1MHAgbfHWt0spOG6iM sslETYKb5HMurZjMRLGHpBf7lf7/iCRykMwDoehfBEjoj/nmaC0I7YFJL7dyfm4CJwSe7K Nq84JTRNnbkCLC49aPS1rLqw8VCoobyrOe5zfrS9W6NvMG8AZteTDYp1HJ6W4A== 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 4S0tlF2KkRzcWl; Wed, 4 Oct 2023 12:08:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394C8vw5053449; Wed, 4 Oct 2023 12:08:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394C8vYY053446; Wed, 4 Oct 2023 12:08:57 GMT (envelope-from git) Date: Wed, 4 Oct 2023 12:08:57 GMT Message-Id: <202310041208.394C8vYY053446@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Guzik Subject: git: 99496960345e - stable/13 - vfs: s/u_long vstir/bool vstir/ List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 99496960345e0400ab10e03b1ff580bdc4bfec1f Auto-Submitted: auto-generated The branch stable/13 has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=99496960345e0400ab10e03b1ff580bdc4bfec1f commit 99496960345e0400ab10e03b1ff580bdc4bfec1f Author: Mateusz Guzik AuthorDate: 2023-09-16 08:19:24 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-04 12:05:58 +0000 vfs: s/u_long vstir/bool vstir/ (cherry picked from commit 509d843a982b39a531a558c65794ffffcdf93ae8) --- sys/kern/vfs_subr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index 8c8f69c88726..b125438923bf 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -324,7 +324,7 @@ u_long desiredvnodes; static u_long gapvnodes; /* gap between wanted and desired */ static u_long vhiwat; /* enough extras after expansion */ static u_long vlowat; /* minimal extras before expansion */ -static u_long vstir; /* nonzero to stir non-free vnodes */ +static bool vstir; /* nonzero to stir non-free vnodes */ static volatile int vsmalltrigger = 8; /* pref to keep if > this many pages */ static u_long vnlru_read_freevnodes(void); @@ -1644,7 +1644,7 @@ vnlru_proc(void) */ if (vstir && force == 0) { force = 1; - vstir = 0; + vstir = false; } if (force == 0 && !vnlru_under(rnumvnodes, vlowat)) { vnlruproc_sig = 0; @@ -1817,7 +1817,7 @@ vn_alloc_hard(struct mount *mp) rfreevnodes = vnlru_read_freevnodes(); if (vn_alloc_cyclecount++ >= rfreevnodes) { vn_alloc_cyclecount = 0; - vstir = 1; + vstir = true; } /* * Grow the vnode cache if it will not be above its target max From nobody Wed Oct 4 12:08:58 2023 X-Original-To: dev-commits-src-branches@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 4S0tlG5XrYz4vp20; Wed, 4 Oct 2023 12:08: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0tlG4KCWz3JTl; Wed, 4 Oct 2023 12:08:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421338; 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=gipxOST8gE/Q+sOGL2qFGRvmAA6Tvw/LjGcQKS00EpU=; b=JYmI1bPCsy+dzyngtrSTf98S9bvPg3+4432OaxYNp/9BmfJ6V1ANMLBfEztcqYfr5taJXp lF2OhJIjU1U6j7LyErxnkb8zOaP7quXgOGuUfRRHNcYspw5DOP0s+Nulbd/xbUd3R2SEiS Wj0zThswMYJCm1EG9bx67xOvfMUh8gzMz8JDmfFVqMWKxJF96VuuL81QeVZkN5X1PUFj2p mkfLpeFSXoznKe6bZnVT+acfE7wqUVexy6EMf991aElKAnPJfGtjEbqHfn4l9sP1D3HyKN XUUxXShk4EBr1qinXRZ6uj63cEPCmW02nHGweqT+JYrySPHdyLmeCcsiMBoblA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696421338; a=rsa-sha256; cv=none; b=KX/eqqTARUGa6OE7h4AhdsdxFm5Dseynk8sJ6gN1lCkd/Hwaum4JZDBZgzgD0G7JwC62RF +6tUZbTsoyVxXI1I6EGGdK7h7lIKZvkxYJerhozV2C1E1nwADjToFqJ5nL9A701hwH4zVa D199UleJB4W07JjuwDqmkGdVZd2b0brW3KCEDMzpUqr9Pf7afShgNxpEDZyGhMCDgCXPc8 6ITL6zHQDAThNEJ5mVDguxnwc3YWpkZG/72/lKMiKdAId6JNjtmqjuXdypwd0+xNDbFMK4 KplV0q+RG+jxxMCdYJVcwpAI6aVFjSBoofj7B10h0jxPosBptax923AofxDsIg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421338; 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=gipxOST8gE/Q+sOGL2qFGRvmAA6Tvw/LjGcQKS00EpU=; b=DB8Xrhz3IK1Ll6qTIqWuoDH/XI8aFfBfrC5xwizzlH5SJWaG+QwXmE4Rg/bApPXZ4hNtWS qv+IG6182242ZxSrP0W/lllGxmm0Nyp9zc5Y/fuT0N8i6+lD8L8H/soJV1FJRgEiU6SjDz mxObzLa2D5skrTh7P1E/mtlaFZx5e/mJiTIH1CFBy6Zw1pzfqR59KL3WRZr+/Hcr2sZ+qb uc+i/eFKIAjeX5A7HS9WwHmtCec54SHzNfacEVvR/VsjXJgh6WHgEeZR0wJJnT3cCZK+W7 W5mU8TTTiuLESXLfZwW9K3KGpiL5s1SOBQcHL/gf5s2TL+PeJGWM3tJTJ6iW2g== 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 4S0tlG3L4kzccP; Wed, 4 Oct 2023 12:08:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394C8wq4053486; Wed, 4 Oct 2023 12:08:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394C8wNB053483; Wed, 4 Oct 2023 12:08:58 GMT (envelope-from git) Date: Wed, 4 Oct 2023 12:08:58 GMT Message-Id: <202310041208.394C8wNB053483@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Guzik Subject: git: 4bddcc418971 - stable/13 - vfs: stabilize freevnodes_old List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4bddcc418971bf21fb5e760248045f8a222a9a80 Auto-Submitted: auto-generated The branch stable/13 has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=4bddcc418971bf21fb5e760248045f8a222a9a80 commit 4bddcc418971bf21fb5e760248045f8a222a9a80 Author: Mateusz Guzik AuthorDate: 2023-09-16 15:41:12 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-04 12:05:58 +0000 vfs: stabilize freevnodes_old In face of parallel callers. (cherry picked from commit ef89b78bb1f60484cc743fa590d623ad896ca8e9) --- sys/kern/vfs_subr.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index b125438923bf..37554858173f 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -1545,21 +1545,22 @@ vfs_freevnodes_dec(void) static u_long vnlru_read_freevnodes(void) { - long slop, rfreevnodes; + long slop, rfreevnodes, rfreevnodes_old; int cpu; rfreevnodes = atomic_load_long(&freevnodes); + rfreevnodes_old = atomic_load_long(&freevnodes_old); - if (rfreevnodes > freevnodes_old) - slop = rfreevnodes - freevnodes_old; + if (rfreevnodes > rfreevnodes_old) + slop = rfreevnodes - rfreevnodes_old; else - slop = freevnodes_old - rfreevnodes; + slop = rfreevnodes_old - rfreevnodes; if (slop < VNLRU_FREEVNODES_SLOP) return (rfreevnodes >= 0 ? rfreevnodes : 0); - freevnodes_old = rfreevnodes; CPU_FOREACH(cpu) { - freevnodes_old += cpuid_to_pcpu[cpu]->pc_vfs_freevnodes; + rfreevnodes += cpuid_to_pcpu[cpu]->pc_vfs_freevnodes; } + atomic_store_long(&freevnodes_old, rfreevnodes); return (freevnodes_old >= 0 ? freevnodes_old : 0); } From nobody Wed Oct 4 12:08:59 2023 X-Original-To: dev-commits-src-branches@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 4S0tlH6M8Hz4vpFC; Wed, 4 Oct 2023 12:08: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0tlH5XZ6z3JQ3; Wed, 4 Oct 2023 12:08:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421339; 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=UsCxaAQ52WH3gXEYXB3bpopmG0cpHYTQDWSeKbhh5Uk=; b=ImjxzRmnb/snvkuUvl67/heMk/+XX44g0RtIyLGSiG8209j7mPn9nO6p9nKBcBM0T1pz9L eaOLxYec7z5Gz0VVDdWa+/G9SZWm68T9p32jveAOj2wYVbKc+MUkw7uONbWqC2wqP8mGzW jrXC/4k/kzvbtaWlW13jE0j51JxpXTZKp+Z48ghgqFOB3QQSQgkh41pmaTU5sjJojRDszb CWjnLfAwhfgpBNNJ8HFBKbjI1Vxi3XPlV8EgjfSfU3AU8vx1wJCH/EhAqk0QqtBX3wmltx dyt+FOmYmMkmQIQ7igS1Ao4HIBBbhDpegkZGL3XC03xPu8KtGYHauWiZ5jLSxA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696421339; a=rsa-sha256; cv=none; b=sKW/Ffj1j2HaWLGq218cDT+RolYnS3hDptWDg8rGnx+3+JyCf9c6CWafnwKYITtVxI7+1G aYFtCxB+2gWRzeUcliG7qCY0CV3OW24kwMxuINUK2dj+WVRaajbFCw1tHbD+SMPf3XQqq7 lEwlNxOgU9YgrUeFGOdse1cQgPUyWQZpDX9lb/UjmOM7ls9N6+HsfICArk7VwJObFjmeLp Tge9CTnDWqkrOiJHhVPnRqDc3qQxFTRyTeiWOqOPnRhpk1EaNjICGKeIrzOZpmcZ4RG0kP hsr3hX9E1/gB6VIA7MFNXLudyMBHVZyNttDHuGJ3pxG//jvuSY8ij300mw3zZA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421339; 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=UsCxaAQ52WH3gXEYXB3bpopmG0cpHYTQDWSeKbhh5Uk=; b=ZRWG08vpsuaLR4J+0kw/2IyyO737Nkv/cDcV3S9A8wafgvGU3/MOEXhzCP/XKs+Z7QLIFe c9BAFOhN1aZOVLI+QNl5VEH4vxMr+JWSyyN5W/ya+Q1ZVXQ78rHOOmZ9mxXatHdNX164js DYKgj+LqTKWo/YpMjdEdgRgj17xWIvKIorg6dkcDvVwvmyLf17TU4YpHDcMwXOow9hqbsB Gj6I3le2cm2WuzeptAnp5CYv9L94fSpL/LYen3Ou7N5VM+uQ8WZrinSA8XRNyc0eYfp+gV a8BeXQ99iBfycxCW92ZqIVaeppi6WNnE9DYf0arJwMGM+Cl5VHqovuMWQ/HaLw== 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 4S0tlH4ZVGzcWm; Wed, 4 Oct 2023 12:08:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394C8xhP053557; Wed, 4 Oct 2023 12:08:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394C8xl9053553; Wed, 4 Oct 2023 12:08:59 GMT (envelope-from git) Date: Wed, 4 Oct 2023 12:08:59 GMT Message-Id: <202310041208.394C8xl9053553@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Guzik Subject: git: 7110784928f9 - stable/13 - vfs: count how many times vnlru got woken up due to vnode shortage List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 7110784928f9fc9dccbf9315230eabbd57a24702 Auto-Submitted: auto-generated The branch stable/13 has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=7110784928f9fc9dccbf9315230eabbd57a24702 commit 7110784928f9fc9dccbf9315230eabbd57a24702 Author: Mateusz Guzik AuthorDate: 2023-09-16 17:26:39 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-04 12:05:58 +0000 vfs: count how many times vnlru got woken up due to vnode shortage (cherry picked from commit 9080190b970c7026695571f90b95fdcf7056ec67) --- sys/kern/vfs_subr.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index 37554858173f..7d8e6c6c6cc5 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -1494,6 +1494,10 @@ vnlru_recalc(void) */ static struct proc *vnlruproc; static int vnlruproc_sig; +static u_long vnlruproc_kicks; + +SYSCTL_ULONG(_vfs_vnode_vnlru, OID_AUTO, kicks, CTLFLAG_RD, &vnlruproc_kicks, 0, + "Number of times vnlru got woken up due to vnode shortage"); /* * The main freevnodes counter is only updated when a counter local to CPU @@ -1588,6 +1592,7 @@ vnlru_kick_locked(void) mtx_assert(&vnode_list_mtx, MA_OWNED); if (vnlruproc_sig == 0) { vnlruproc_sig = 1; + vnlruproc_kicks++; wakeup(vnlruproc); } } From nobody Wed Oct 4 12:09:00 2023 X-Original-To: dev-commits-src-branches@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 4S0tlK2vSlz4vp90; Wed, 4 Oct 2023 12:09: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0tlJ6brqz3JVX; Wed, 4 Oct 2023 12:09:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421340; 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=ZLfdZ0njH2L1zL6QPRIlsbzydtKUoGhXXCiegzEf5OU=; b=smSte5hmJsG0jt+8pNV5n4qT0x4v/yu/MoVvAzg2GzwLDgf6XyF06boVO4x7rw3EzgyTVI ahwL+1nhXQqdzDQ/Flk37CzFjJnribOFa9IfP20ID+Hcu+7W8pGcfxokzBEcXQbJCky5VL S9H1RWP9QbfDlF4UC5AZAqSHLXYUaOhVDPmWC++G7g9DJYimb3bDL7VCxucVbiMvDjoSjQ zxBjHBLZywIUws44IirhKqHvQfC2hxVM1F0X3uBhVbvgKUwVhpEZ7cGVnZeIRgwQauMIMs TswVxkteBOQ3LlI7j/Xoo2+87mJ6VKCAineFcWAt6RMvtY3gfFbjCCMnktZkbg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696421340; a=rsa-sha256; cv=none; b=A+jZJAm4eT7e82pOVG3UgP51vi5v2Loo1W+QxEtK5sbZidICe197tt3xW7jviZ31JSw0Lx tG8oERTq/KR/JLLWAF4Iq5gRvK1ZxBl8r4KZBg0CmxvMUjBi1FDFHa8Y2IP0s75ZT0Wr8c Uhl4mTqgqMqpxoufMtVR5dFKffHDvm/5x364UioHEpBu+igGYXth/qhElq6zb85st2vU6s F/RF4fT9LZFh/yms2DzB5kaAeS8111w8nUK5Wmn0SQP7TP1AjH5n3ZSIudavDTHzqmFF2G rhh6Lmh+Fs3oBmHNnZ+4qdLz3hey1ocerRxd1L4ZQkFT+HnomjfKkToe9vlrrA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421340; 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=ZLfdZ0njH2L1zL6QPRIlsbzydtKUoGhXXCiegzEf5OU=; b=IEl4BKeb0bAO8mmxmKbzgWZZCTN/CN0vUkDsUPByCgBeq831rG1bsCdGujXkDQYGAXd//d v0ZXw8BpjhoBZb5eE0H5SJrxyO1XonSp2Y9+ag8lT58OqaQUkpagXCzoh+a5XIwP+bfImy aeC6w9LmCQGnPV0d4jgN2vRTNQdezE1IfH6/GmiIDuxV73WB9azyQOcuCijLj8ql2ZWj+G shnN4ny47YPU86byb1qDxNKwYeaUtmnckn7Ur03tcKN5DgS4T6sa06WZbR6D8SrB9Cc2nE vVN7bDoPOR4DUAvTXUvz7arUlaW9CgLk6lX5YYN3r8megvTXKXdwVU/QCUn3EQ== 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 4S0tlJ5jhxzcgW; Wed, 4 Oct 2023 12:09:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394C90ml053628; Wed, 4 Oct 2023 12:09:00 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394C900T053625; Wed, 4 Oct 2023 12:09:00 GMT (envelope-from git) Date: Wed, 4 Oct 2023 12:09:00 GMT Message-Id: <202310041209.394C900T053625@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Guzik Subject: git: 8d5b00a5713d - stable/13 - vfs cache: fix a hang when bumping vnode limit too high List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 8d5b00a5713d91c18fa726fe832fb4df3751b419 Auto-Submitted: auto-generated The branch stable/13 has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=8d5b00a5713d91c18fa726fe832fb4df3751b419 commit 8d5b00a5713d91c18fa726fe832fb4df3751b419 Author: Mateusz Guzik AuthorDate: 2023-09-02 14:27:33 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-04 12:05:58 +0000 vfs cache: fix a hang when bumping vnode limit too high Overflow in cache_changesize would make the value flip to 0 and stay there as 0 << 1 does not do anything. Note callers limit the outcome to something below u_int. Also note there entire vnode handling thing both in vfs layer as a whole and this file can't decide whether to long, u_long or u_int. (cherry picked from commit 32988c1499f8698b41e15ed40a46d271e757bba3) --- sys/kern/vfs_cache.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/sys/kern/vfs_cache.c b/sys/kern/vfs_cache.c index 62698cdb2141..151d0d2ac8a1 100644 --- a/sys/kern/vfs_cache.c +++ b/sys/kern/vfs_cache.c @@ -2601,10 +2601,10 @@ cache_enter_time_flags(struct vnode *dvp, struct vnode *vp, struct componentname cache_enter_time(dvp, vp, cnp, tsp, dtsp); } -static u_int -cache_roundup_2(u_int val) +static u_long +cache_roundup_2(u_long val) { - u_int res; + u_long res; for (res = 1; res <= val; res <<= 1) continue; @@ -2620,7 +2620,7 @@ nchinittbl(u_long elements, u_long *hashmask) hashsize = cache_roundup_2(elements) / 2; - hashtbl = malloc((u_long)hashsize * sizeof(*hashtbl), M_VFSCACHE, M_WAITOK); + hashtbl = malloc(hashsize * sizeof(*hashtbl), M_VFSCACHE, M_WAITOK); for (i = 0; i < hashsize; i++) CK_SLIST_INIT(&hashtbl[i]); *hashmask = hashsize - 1; @@ -2766,7 +2766,7 @@ cache_changesize(u_long newmaxvnodes) struct namecache *ncp; uint32_t hash; u_long newncsize; - int i; + u_long i; newncsize = newmaxvnodes * ncsizefactor; newmaxvnodes = cache_roundup_2(newmaxvnodes * 2); From nobody Wed Oct 4 12:09:01 2023 X-Original-To: dev-commits-src-branches@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 4S0tlL1nX3z4vpFD; Wed, 4 Oct 2023 12:09: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0tlL0XkJz3JVl; Wed, 4 Oct 2023 12:09:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421342; 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=W04a02gVMJZMWWAcDO2ZFRnlrsoSdTuJi7cBu7S6UAk=; b=WU5NS5H2sMYBctGnhu/Ruz8+sud5aAoFzKsJgxN/6hKBw86aGuOyCWg5ARwQfPAxsmlxsT 1bu/e5ifNjbfs+nQhJD59NBXwnwNujByY6Y33EQNpjv8dxV3dtoeqt7aJ+qu4JdFy6DFLG tkdZPsDVNcXKwOooZLymBxQRpzAbrpXZxp7X/rmpAaIbbXZsx+te6zEnxAoPbKxX1oVftd 2f9wE8143v2oUlAFMmcYdIrBb3irtVWqj+StsTjpmGk0WAnjamCuK9ecY3RmSTTG2prKx+ tnn6cVaqRbxH4Iz0gSapxp/CVCnFZO1MqXMfbJoNyieUjBBTXjtLYuw7DL0bFw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696421342; a=rsa-sha256; cv=none; b=vg05RT1ozFkFbpnpesaV3SJ7SZ8C1lgkb4cc5uDe8nB8ybng+/tCkbk+ELAO7DZgra+5rP 0oUIoZWPJssWzdjhWWly2q6gTY9nhXTojzoH+taRytXMiGDlw2u27d/oZgVarivIQF8yH3 QB1j89UqFzWyWZoiC1eJttWI37y6Dp3jGRp1ezUg52HjM99TBZ6KazZi/XzEf3OiRmdf+4 CNGT1MMNeLZcXX69KF4i/vNduRjx1jmqJHofIC7jUajnlE7VWr7guTGcFcZKlFEg+xWsUQ OCGipZgNLkXqaZyZQl2EZNAUPx+Z0qqPB9HNf7GgV91cz8Mx8qOoSaVCwkUCjw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696421342; 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=W04a02gVMJZMWWAcDO2ZFRnlrsoSdTuJi7cBu7S6UAk=; b=DPcts7CCVfU7xcEazWVb+gQTZWpYiA0dBqVMHMYVTRLVfab63IS5STyiz9sJ8EUTGimQMM lcdCqW9xTpldN9FPzRoHkmQLDGycL72CrdfE3aNNik0H8LjOus+ZGYi/RyZP3P0FcdstJT tugPchYT1l3p/b5d24MkizzvyzUr/I1jwVDtoRzn/za5J9Wli/7UBZiPAoYS7jheXNdsTQ uMNvhbdKFt/DML5XQvirR479/dlHQvwxQYbijBS0y2ebQ7Dw46lL3YnTf+RTYW+vxaspov qYTnvSBOOTr02ZP87bBItXCnRKWXpAZE/d/pILCTZgFS8m0DCW7BFAefKRSRag== 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 4S0tlK6mNrzcJH; Wed, 4 Oct 2023 12:09:01 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394C91JJ053679; Wed, 4 Oct 2023 12:09:01 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394C91de053676; Wed, 4 Oct 2023 12:09:01 GMT (envelope-from git) Date: Wed, 4 Oct 2023 12:09:01 GMT Message-Id: <202310041209.394C91de053676@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Guzik Subject: git: 46cc15529fbf - stable/13 - vfs cache: garbage collect the fullpathfail2 counter List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 46cc15529fbfee0df5a124a3221c4446f0902fe3 Auto-Submitted: auto-generated The branch stable/13 has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=46cc15529fbfee0df5a124a3221c4446f0902fe3 commit 46cc15529fbfee0df5a124a3221c4446f0902fe3 Author: Mateusz Guzik AuthorDate: 2023-09-14 20:25:54 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-04 12:05:59 +0000 vfs cache: garbage collect the fullpathfail2 counter The conditions it checks cannot legally be true (modulo races against forced unmount), so assert on it instead. (cherry picked from commit 07f52c4b5a4f7a658bf7ed29eadd5c4d52a4f3b2) --- sys/kern/vfs_cache.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/sys/kern/vfs_cache.c b/sys/kern/vfs_cache.c index 151d0d2ac8a1..a50e8010fb88 100644 --- a/sys/kern/vfs_cache.c +++ b/sys/kern/vfs_cache.c @@ -546,7 +546,6 @@ STATNODE_COUNTER(negzaps, numnegzaps, STATNODE_COUNTER(neghits, numneghits, "Number of cache hits (negative)"); /* These count for vn_getcwd(), too. */ STATNODE_COUNTER(fullpathcalls, numfullpathcalls, "Number of fullpath search calls"); -STATNODE_COUNTER(fullpathfail1, numfullpathfail1, "Number of fullpath search errors (ENOTDIR)"); STATNODE_COUNTER(fullpathfail2, numfullpathfail2, "Number of fullpath search errors (VOP_VPTOCNP failures)"); STATNODE_COUNTER(fullpathfail4, numfullpathfail4, "Number of fullpath search errors (ENOMEM)"); @@ -3384,14 +3383,7 @@ vn_fullpath_dir(struct vnode *vp, struct vnode *rdir, char *buf, char **retbuf, vp = vp1; continue; } - if (vp->v_type != VDIR) { - vrele(vp); - counter_u64_add(numfullpathfail1, 1); - error = ENOTDIR; - SDT_PROBE3(vfs, namecache, fullpath, return, - error, vp, NULL); - break; - } + VNPASS(vp->v_type == VDIR || VN_IS_DOOMED(vp), vp); error = vn_vptocnp(&vp, buf, &buflen); if (error) break; From nobody Wed Oct 4 13:23:17 2023 X-Original-To: dev-commits-src-branches@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 4S0wP73v4jz4vvqx; Wed, 4 Oct 2023 13:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0wP73Zshz3Vs7; Wed, 4 Oct 2023 13:23:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696425803; 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=DfNci7wwEyT1/N//GBp0S1VmgwMNBBrcA3/Gw/dU3l8=; b=urWXJCi6WtUMJv9CaO6Zog8xbjIgSMQPF5C5/P+NOOFwXAq2389lJ/QTBS6gZMGbo2K0KK zwmUr5MZfdty0btEoYZ0vhkM0dTa3FnWpeMgHnlTxq/ZGlD6GwozqRy1KUo9Xi6TxY6o55 cggE+9STMCDfQGqEJEoU/Qf0ie5dhUuS+bDUSwZtGxgTgvYPtvvxGkmCI6mojpMyIPS/Tt fagM55/TRuQyZ04nv5zJiThDWT43MF8a0gvF180cEV7SPjvtVRGOZGV9jgW8kUdJ5vDjOR dakRQoWSii6HaK8ArKyzFiWu1oFWtdmpxwrGDiaHgfExWG+3USfj8PI+cnc6bg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696425803; a=rsa-sha256; cv=none; b=bbUhI2J3FXOieo0LlaAVrfNOYguOrah8j42ic7FyE0/tR+R5M1v+COudrGsU8/SJsO9NsG mkfX+4hQAHSTAc8gWkZ1vhEyKFR0eyGUdRjTmhl4YlMLKBLATi+AGN5wIHvE0RjPe6mZMu dlR/qBs+V3W5qK3VHiaOruqztMo2RlfuVKfD1sVmB88FW1uc4VHo5N7dxrCZug1ETlbK6J esFY50UDfMGoKjLCcBUb9fqp/dmRvz4D0ExUTfSFF36igIvnkBfwmBP7YVKZH9gyBwijx5 2G4ngdni39+F4eIhPqjViVp8PEfRBW4TH74sSQRMVwrMuuDcp7PqiiMDullagg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696425803; 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=DfNci7wwEyT1/N//GBp0S1VmgwMNBBrcA3/Gw/dU3l8=; b=kTygdxzvP0S6Y88w1Wl9eJkm1vUBT7RZH0rIwFXKvez+DhpxZbUSp0+o+3TNaTBKPUqlj6 sw2gWLoNw8cbrxERJid1ufBbY38Z0d5PtnBCX2GAxuDOGjmpK1lgjNGfuH0W2+JmMWiuQH 09RDyuP9jMFfIMu0Q9/N4qH0hMZ9g46jfCTaczWwX0lZ4tI94mRYo9loyTWDbPwVi84lBH 9rDEEgU7AIrnu9ctoYe8fkMS97XKiegvLhpbjDVasYU6zJz7ExpQwPZdg3zr0lMLI8RWhW fDBYCY0RXei0RNdwVYnpRMsjwyU5VCYjGe4/wvysroC/z25hntPvWL6dwI+O/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 4S0wP72bYqzfRb; Wed, 4 Oct 2023 13:23:23 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394DNN9u086354; Wed, 4 Oct 2023 13:23:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394DNHB5086343; Wed, 4 Oct 2023 13:23:17 GMT (envelope-from git) Date: Wed, 4 Oct 2023 13:23:17 GMT Message-Id: <202310041323.394DNHB5086343@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Martin Matuska Subject: git: a21cb0234b89 - stable/14 - zfs: merge openzfs/zfs@8015e2ea6 (zfs-2.2-release) into stable/14 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mm X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: a21cb0234b896d8e524840d8b06927f5e8ee1b13 Auto-Submitted: auto-generated The branch stable/14 has been updated by mm: URL: https://cgit.FreeBSD.org/src/commit/?id=a21cb0234b896d8e524840d8b06927f5e8ee1b13 commit a21cb0234b896d8e524840d8b06927f5e8ee1b13 Merge: 9afc0c849e6e 8015e2ea66b4 Author: Martin Matuska AuthorDate: 2023-10-04 12:54:05 +0000 Commit: Martin Matuska CommitDate: 2023-10-04 13:03:41 +0000 zfs: merge openzfs/zfs@8015e2ea6 (zfs-2.2-release) into stable/14 Notable upstream pull request merges: #15240 e9dc31c74 Update the behavior of mountpoint property #15240 c53bc3837 Improve the handling of sharesmb,sharenfs properties #15298 0ce1b2ca1 Invoke zdb by guid to avoid import errors #15301 0aabd6b48 ZIL: Avoid dbuf_read() in ztest_get_data() #15308 9e36c576f Don't allocate from new metaslabs #15312 229ca7d73 Fix ENOSPC for extended quota #15321 3079bf2e6 Restrict short block cloning requests #15322 8015e2ea6 Add '-u' - nomount flag for zfs set #15324 b34bf2d5f Tweak rebuild in-flight hard limit #15331 608741d06 Report ashift of L2ARC devices in zdb #15333 0d870a177 Fix invalid pointer access in trace_dbuf.h Obtained from: OpenZFS OpenZFS commit: 8015e2ea66b4f6233877fef29a8a35594f33558d sys/contrib/openzfs/cmd/zdb/zdb.c | 2 +- sys/contrib/openzfs/cmd/zfs/zfs_main.c | 52 ++++++----- sys/contrib/openzfs/cmd/ztest.c | 24 ++--- sys/contrib/openzfs/config/zfs-build.m4 | 11 +++ .../openzfs/contrib/bash_completion.d/Makefile.am | 2 - sys/contrib/openzfs/contrib/debian/control | 2 +- .../contrib/debian/openzfs-zfsutils.install | 1 - sys/contrib/openzfs/contrib/debian/rules.in | 5 - sys/contrib/openzfs/include/libzfs.h | 8 ++ .../openzfs/include/os/linux/zfs/sys/trace_dbuf.h | 8 +- sys/contrib/openzfs/lib/libshare/os/freebsd/nfs.c | 3 +- sys/contrib/openzfs/lib/libshare/os/linux/nfs.c | 47 +++++++++- sys/contrib/openzfs/lib/libzfs/libzfs.abi | 7 ++ sys/contrib/openzfs/lib/libzfs/libzfs_changelist.c | 46 +++++---- sys/contrib/openzfs/lib/libzfs/libzfs_dataset.c | 18 +++- sys/contrib/openzfs/man/man7/zfsprops.7 | 26 +++++- sys/contrib/openzfs/man/man8/zfs-set.8 | 7 ++ sys/contrib/openzfs/module/zfs/dsl_dir.c | 22 ++--- sys/contrib/openzfs/module/zfs/metaslab.c | 9 ++ sys/contrib/openzfs/module/zfs/vdev_label.c | 10 ++ sys/contrib/openzfs/module/zfs/vdev_rebuild.c | 4 +- sys/contrib/openzfs/module/zfs/zfs_vnops.c | 13 +++ sys/contrib/openzfs/tests/runfiles/common.run | 2 +- sys/contrib/openzfs/tests/runfiles/sanity.run | 2 +- .../openzfs/tests/test-runner/bin/zts-report.py.in | 4 +- .../openzfs/tests/zfs-tests/tests/Makefile.am | 1 + ...ock_cloning_copyfilerange_fallback_same_txg.ksh | 5 +- .../cli_root/zfs_mount/zfs_mount_006_pos.ksh | 2 +- .../cli_root/zfs_mount/zfs_mount_008_pos.ksh | 4 +- .../cli_root/zfs_mount/zfs_mount_012_pos.ksh | 15 ++- .../cli_root/zfs_set/mountpoint_002_pos.ksh | 12 ++- .../cli_root/zfs_set/zfs_set_003_neg.ksh | 10 +- .../cli_root/zfs_set/zfs_set_nomount.ksh | 103 +++++++++++++++++++++ .../cli_root/zpool_trim/zpool_trim_partial.ksh | 2 +- .../zpool_trim/zpool_trim_verify_trimmed.ksh | 2 +- .../tests/functional/no_space/enospc_rm.ksh | 12 ++- .../tests/functional/trim/autotrim_config.ksh | 2 +- .../tests/functional/trim/autotrim_integrity.ksh | 2 +- .../functional/trim/autotrim_trim_integrity.ksh | 2 +- .../tests/functional/trim/trim_config.ksh | 2 +- .../tests/functional/trim/trim_integrity.ksh | 2 +- sys/modules/zfs/zfs_config.h | 4 +- sys/modules/zfs/zfs_gitrev.h | 2 +- 43 files changed, 398 insertions(+), 121 deletions(-) diff --cc sys/contrib/openzfs/tests/zfs-tests/tests/functional/cli_root/zfs_set/zfs_set_nomount.ksh index 000000000000,ebf08711423c..ebf08711423c mode 000000,100755..100755 --- a/sys/contrib/openzfs/tests/zfs-tests/tests/functional/cli_root/zfs_set/zfs_set_nomount.ksh +++ b/sys/contrib/openzfs/tests/zfs-tests/tests/functional/cli_root/zfs_set/zfs_set_nomount.ksh diff --cc sys/modules/zfs/zfs_config.h index 059989a79d1c,000000000000..3d527ecbd00f mode 100644,000000..100644 --- a/sys/modules/zfs/zfs_config.h +++ b/sys/modules/zfs/zfs_config.h @@@ -1,1134 -1,0 +1,1134 @@@ +/* + */ + +/* zfs_config.h. Generated from zfs_config.h.in by configure. */ +/* zfs_config.h.in. Generated from configure.ac by autoheader. */ + +/* Define to 1 if translation of program messages to the user's native + language is requested. */ +/* #undef ENABLE_NLS */ + +/* bio_end_io_t wants 1 arg */ +/* #undef HAVE_1ARG_BIO_END_IO_T */ + +/* lookup_bdev() wants 1 arg */ +/* #undef HAVE_1ARG_LOOKUP_BDEV */ + +/* submit_bio() wants 1 arg */ +/* #undef HAVE_1ARG_SUBMIT_BIO */ + +/* bdi_setup_and_register() wants 2 args */ +/* #undef HAVE_2ARGS_BDI_SETUP_AND_REGISTER */ + +/* vfs_getattr wants 2 args */ +/* #undef HAVE_2ARGS_VFS_GETATTR */ + +/* zlib_deflate_workspacesize() wants 2 args */ +/* #undef HAVE_2ARGS_ZLIB_DEFLATE_WORKSPACESIZE */ + +/* bdi_setup_and_register() wants 3 args */ +/* #undef HAVE_3ARGS_BDI_SETUP_AND_REGISTER */ + +/* vfs_getattr wants 3 args */ +/* #undef HAVE_3ARGS_VFS_GETATTR */ + +/* vfs_getattr wants 4 args */ +/* #undef HAVE_4ARGS_VFS_GETATTR */ + +/* kernel has access_ok with 'type' parameter */ +/* #undef HAVE_ACCESS_OK_TYPE */ + +/* posix_acl has refcount_t */ +/* #undef HAVE_ACL_REFCOUNT */ + +/* add_disk() returns int */ +/* #undef HAVE_ADD_DISK_RET */ + +/* Define if host toolchain supports AES */ +#define HAVE_AES 1 + +/* Define if you have [rt] */ +#define HAVE_AIO_H 1 + +#ifdef __amd64__ +#ifndef RESCUE +/* Define if host toolchain supports AVX */ +#define HAVE_AVX 1 +#endif + +/* Define if host toolchain supports AVX2 */ +#define HAVE_AVX2 1 + +/* Define if host toolchain supports AVX512BW */ +#define HAVE_AVX512BW 1 + +/* Define if host toolchain supports AVX512CD */ +#define HAVE_AVX512CD 1 + +/* Define if host toolchain supports AVX512DQ */ +#define HAVE_AVX512DQ 1 + +/* Define if host toolchain supports AVX512ER */ +#define HAVE_AVX512ER 1 + +/* Define if host toolchain supports AVX512F */ +#define HAVE_AVX512F 1 + +/* Define if host toolchain supports AVX512IFMA */ +#define HAVE_AVX512IFMA 1 + +/* Define if host toolchain supports AVX512PF */ +#define HAVE_AVX512PF 1 + +/* Define if host toolchain supports AVX512VBMI */ +#define HAVE_AVX512VBMI 1 + +/* Define if host toolchain supports AVX512VL */ +#define HAVE_AVX512VL 1 +#endif + +/* bdevname() is available */ +/* #undef HAVE_BDEVNAME */ + +/* bdev_check_media_change() exists */ +/* #undef HAVE_BDEV_CHECK_MEDIA_CHANGE */ + +/* bdev_*_io_acct() available */ +/* #undef HAVE_BDEV_IO_ACCT_63 */ + +/* bdev_*_io_acct() available */ +/* #undef HAVE_BDEV_IO_ACCT_OLD */ + +/* bdev_kobj() exists */ +/* #undef HAVE_BDEV_KOBJ */ + +/* bdev_max_discard_sectors() is available */ +/* #undef HAVE_BDEV_MAX_DISCARD_SECTORS */ + +/* bdev_max_secure_erase_sectors() is available */ +/* #undef HAVE_BDEV_MAX_SECURE_ERASE_SECTORS */ + +/* block_device_operations->submit_bio() returns void */ +/* #undef HAVE_BDEV_SUBMIT_BIO_RETURNS_VOID */ + +/* bdev_whole() is available */ +/* #undef HAVE_BDEV_WHOLE */ + +/* bio_alloc() takes 4 arguments */ +/* #undef HAVE_BIO_ALLOC_4ARG */ + +/* bio->bi_bdev->bd_disk exists */ +/* #undef HAVE_BIO_BDEV_DISK */ + +/* bio->bi_opf is defined */ +/* #undef HAVE_BIO_BI_OPF */ + +/* bio->bi_status exists */ +/* #undef HAVE_BIO_BI_STATUS */ + +/* bio has bi_iter */ +/* #undef HAVE_BIO_BVEC_ITER */ + +/* bio_*_io_acct() available */ +/* #undef HAVE_BIO_IO_ACCT */ + +/* bio_max_segs() is implemented */ +/* #undef HAVE_BIO_MAX_SEGS */ + +/* bio_set_dev() is available */ +/* #undef HAVE_BIO_SET_DEV */ + +/* bio_set_dev() GPL-only */ +/* #undef HAVE_BIO_SET_DEV_GPL_ONLY */ + +/* bio_set_dev() is a macro */ +/* #undef HAVE_BIO_SET_DEV_MACRO */ + +/* bio_set_op_attrs is available */ +/* #undef HAVE_BIO_SET_OP_ATTRS */ + +/* blkdev_get_by_path() exists and takes 4 args */ +/* #undef HAVE_BLKDEV_GET_BY_PATH_4ARG */ + +/* blkdev_get_by_path() handles ERESTARTSYS */ +/* #undef HAVE_BLKDEV_GET_ERESTARTSYS */ + +/* blkdev_issue_discard() is available */ +/* #undef HAVE_BLKDEV_ISSUE_DISCARD */ + +/* blkdev_issue_secure_erase() is available */ +/* #undef HAVE_BLKDEV_ISSUE_SECURE_ERASE */ + +/* blkdev_put() accepts void* as arg 2 */ +/* #undef HAVE_BLKDEV_PUT_HOLDER */ + +/* blkdev_reread_part() exists */ +/* #undef HAVE_BLKDEV_REREAD_PART */ + +/* blkg_tryget() is available */ +/* #undef HAVE_BLKG_TRYGET */ + +/* blkg_tryget() GPL-only */ +/* #undef HAVE_BLKG_TRYGET_GPL_ONLY */ + +/* blk_alloc_disk() exists */ +/* #undef HAVE_BLK_ALLOC_DISK */ + +/* blk_alloc_queue() expects request function */ +/* #undef HAVE_BLK_ALLOC_QUEUE_REQUEST_FN */ + +/* blk_alloc_queue_rh() expects request function */ +/* #undef HAVE_BLK_ALLOC_QUEUE_REQUEST_FN_RH */ + +/* blk_cleanup_disk() exists */ +/* #undef HAVE_BLK_CLEANUP_DISK */ + +/* blk_mode_t is defined */ +/* #undef HAVE_BLK_MODE_T */ + +/* block multiqueue is available */ +/* #undef HAVE_BLK_MQ */ + +/* blk queue backing_dev_info is dynamic */ +/* #undef HAVE_BLK_QUEUE_BDI_DYNAMIC */ + +/* blk_queue_discard() is available */ +/* #undef HAVE_BLK_QUEUE_DISCARD */ + +/* blk_queue_flag_clear() exists */ +/* #undef HAVE_BLK_QUEUE_FLAG_CLEAR */ + +/* blk_queue_flag_set() exists */ +/* #undef HAVE_BLK_QUEUE_FLAG_SET */ + +/* blk_queue_flush() is available */ +/* #undef HAVE_BLK_QUEUE_FLUSH */ + +/* blk_queue_flush() is GPL-only */ +/* #undef HAVE_BLK_QUEUE_FLUSH_GPL_ONLY */ + +/* blk_queue_secdiscard() is available */ +/* #undef HAVE_BLK_QUEUE_SECDISCARD */ + +/* blk_queue_secure_erase() is available */ +/* #undef HAVE_BLK_QUEUE_SECURE_ERASE */ + +/* blk_queue_update_readahead() exists */ +/* #undef HAVE_BLK_QUEUE_UPDATE_READAHEAD */ + +/* blk_queue_write_cache() exists */ +/* #undef HAVE_BLK_QUEUE_WRITE_CACHE */ + +/* blk_queue_write_cache() is GPL-only */ +/* #undef HAVE_BLK_QUEUE_WRITE_CACHE_GPL_ONLY */ + +/* BLK_STS_RESV_CONFLICT is defined */ +/* #undef HAVE_BLK_STS_RESV_CONFLICT */ + +/* Define if release() in block_device_operations takes 1 arg */ +/* #undef HAVE_BLOCK_DEVICE_OPERATIONS_RELEASE_1ARG */ + +/* Define if revalidate_disk() in block_device_operations */ +/* #undef HAVE_BLOCK_DEVICE_OPERATIONS_REVALIDATE_DISK */ + +/* Define to 1 if you have the Mac OS X function CFLocaleCopyCurrent in the + CoreFoundation framework. */ +/* #undef HAVE_CFLOCALECOPYCURRENT */ + +/* 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 */ + +/* check_disk_change() exists */ +/* #undef HAVE_CHECK_DISK_CHANGE */ + +/* clear_inode() is available */ +/* #undef HAVE_CLEAR_INODE */ + +/* dentry uses const struct dentry_operations */ +/* #undef HAVE_CONST_DENTRY_OPERATIONS */ + +/* copy_from_iter() is available */ +/* #undef HAVE_COPY_FROM_ITER */ + +/* copy_splice_read exists */ +/* #undef HAVE_COPY_SPLICE_READ */ + +/* copy_to_iter() is available */ +/* #undef HAVE_COPY_TO_ITER */ + +/* cpu_has_feature() is GPL-only */ +/* #undef HAVE_CPU_HAS_FEATURE_GPL_ONLY */ + +/* yes */ +/* #undef HAVE_CPU_HOTPLUG */ + +/* current_time() exists */ +/* #undef HAVE_CURRENT_TIME */ + +/* Define if the GNU dcgettext() function is already present or preinstalled. + */ +/* #undef HAVE_DCGETTEXT */ + +/* DECLARE_EVENT_CLASS() is available */ +/* #undef HAVE_DECLARE_EVENT_CLASS */ + +/* dentry aliases are in d_u member */ +/* #undef HAVE_DENTRY_D_U_ALIASES */ + +/* dequeue_signal() takes 4 arguments */ +/* #undef HAVE_DEQUEUE_SIGNAL_4ARG */ + +/* lookup_bdev() wants dev_t arg */ +/* #undef HAVE_DEVT_LOOKUP_BDEV */ + +/* sops->dirty_inode() wants flags */ +/* #undef HAVE_DIRTY_INODE_WITH_FLAGS */ + +/* disk_check_media_change() exists */ +/* #undef HAVE_DISK_CHECK_MEDIA_CHANGE */ + +/* disk_*_io_acct() available */ +/* #undef HAVE_DISK_IO_ACCT */ + +/* disk_update_readahead() exists */ +/* #undef HAVE_DISK_UPDATE_READAHEAD */ + +/* Define to 1 if you have the header file. */ +#define HAVE_DLFCN_H 1 + +/* d_make_root() is available */ +/* #undef HAVE_D_MAKE_ROOT */ + +/* d_prune_aliases() is available */ +/* #undef HAVE_D_PRUNE_ALIASES */ + +/* dops->d_revalidate() operation takes nameidata */ +/* #undef HAVE_D_REVALIDATE_NAMEIDATA */ + +/* eops->encode_fh() wants child and parent inodes */ +/* #undef HAVE_ENCODE_FH_WITH_INODE */ + +/* sops->evict_inode() exists */ +/* #undef HAVE_EVICT_INODE */ + +/* FALLOC_FL_ZERO_RANGE is defined */ +/* #undef HAVE_FALLOC_FL_ZERO_RANGE */ + +/* fault_in_iov_iter_readable() is available */ +/* #undef HAVE_FAULT_IN_IOV_ITER_READABLE */ + +/* filemap_range_has_page() is available */ +/* #undef HAVE_FILEMAP_RANGE_HAS_PAGE */ + +/* fops->aio_fsync() exists */ +/* #undef HAVE_FILE_AIO_FSYNC */ + +/* file_dentry() is available */ +/* #undef HAVE_FILE_DENTRY */ + +/* fops->fadvise() exists */ +/* #undef HAVE_FILE_FADVISE */ + +/* file_inode() is available */ +/* #undef HAVE_FILE_INODE */ + +/* flush_dcache_page() is GPL-only */ +/* #undef HAVE_FLUSH_DCACHE_PAGE_GPL_ONLY */ + +/* iops->follow_link() cookie */ +/* #undef HAVE_FOLLOW_LINK_COOKIE */ + +/* iops->follow_link() nameidata */ +/* #undef HAVE_FOLLOW_LINK_NAMEIDATA */ + +/* Define if compiler supports -Wformat-overflow */ +/* #undef HAVE_FORMAT_OVERFLOW */ + +/* fops->fsync() with range */ +/* #undef HAVE_FSYNC_RANGE */ + +/* fops->fsync() without dentry */ +/* #undef HAVE_FSYNC_WITHOUT_DENTRY */ + +/* yes */ +/* #undef HAVE_GENERIC_FADVISE */ + +/* generic_fillattr requires struct mnt_idmap* */ +/* #undef HAVE_GENERIC_FILLATTR_IDMAP */ + +/* generic_fillattr requires struct user_namespace* */ +/* #undef HAVE_GENERIC_FILLATTR_USERNS */ + +/* generic_*_io_acct() 3 arg available */ +/* #undef HAVE_GENERIC_IO_ACCT_3ARG */ + +/* generic_*_io_acct() 4 arg available */ +/* #undef HAVE_GENERIC_IO_ACCT_4ARG */ + +/* generic_readlink is global */ +/* #undef HAVE_GENERIC_READLINK */ + +/* generic_setxattr() exists */ +/* #undef HAVE_GENERIC_SETXATTR */ + +/* generic_write_checks() takes kiocb */ +/* #undef HAVE_GENERIC_WRITE_CHECKS_KIOCB */ + +/* Define if the GNU gettext() function is already present or preinstalled. */ +/* #undef HAVE_GETTEXT */ + +/* iops->get_acl() exists */ +/* #undef HAVE_GET_ACL */ + +/* iops->get_acl() takes rcu */ +/* #undef HAVE_GET_ACL_RCU */ + +/* has iops->get_inode_acl() */ +/* #undef HAVE_GET_INODE_ACL */ + +/* iops->get_link() cookie */ +/* #undef HAVE_GET_LINK_COOKIE */ + +/* iops->get_link() delayed */ +/* #undef HAVE_GET_LINK_DELAYED */ + +/* group_info->gid exists */ +/* #undef HAVE_GROUP_INFO_GID */ + +/* has_capability() is available */ +/* #undef HAVE_HAS_CAPABILITY */ + +/* iattr->ia_vfsuid and iattr->ia_vfsgid exist */ +/* #undef HAVE_IATTR_VFSID */ + +/* Define if you have the iconv() function and it works. */ +#define HAVE_ICONV 1 + +/* iops->getattr() takes struct mnt_idmap* */ +/* #undef HAVE_IDMAP_IOPS_GETATTR */ + +/* iops->setattr() takes struct mnt_idmap* */ +/* #undef HAVE_IDMAP_IOPS_SETATTR */ + +/* APIs for idmapped mount are present */ +/* #undef HAVE_IDMAP_MNT_API */ + +/* Define if compiler supports -Wimplicit-fallthrough */ +/* #undef HAVE_IMPLICIT_FALLTHROUGH */ + +/* Define if compiler supports -Winfinite-recursion */ +/* #undef HAVE_INFINITE_RECURSION */ + +/* yes */ +/* #undef HAVE_INODE_LOCK_SHARED */ + +/* inode_owner_or_capable() exists */ +/* #undef HAVE_INODE_OWNER_OR_CAPABLE */ + +/* inode_owner_or_capable() takes mnt_idmap */ +/* #undef HAVE_INODE_OWNER_OR_CAPABLE_IDMAP */ + +/* inode_owner_or_capable() takes user_ns */ +/* #undef HAVE_INODE_OWNER_OR_CAPABLE_USERNS */ + +/* inode_set_flags() exists */ +/* #undef HAVE_INODE_SET_FLAGS */ + +/* inode_set_iversion() exists */ +/* #undef HAVE_INODE_SET_IVERSION */ + +/* inode->i_*time's are timespec64 */ +/* #undef HAVE_INODE_TIMESPEC64_TIMES */ + +/* timestamp_truncate() exists */ +/* #undef HAVE_INODE_TIMESTAMP_TRUNCATE */ + +/* Define to 1 if you have the header file. */ +#define HAVE_INTTYPES_H 1 + +/* in_compat_syscall() is available */ +/* #undef HAVE_IN_COMPAT_SYSCALL */ + +/* iops->create() takes struct mnt_idmap* */ +/* #undef HAVE_IOPS_CREATE_IDMAP */ + +/* iops->create() takes struct user_namespace* */ +/* #undef HAVE_IOPS_CREATE_USERNS */ + +/* iops->mkdir() takes struct mnt_idmap* */ +/* #undef HAVE_IOPS_MKDIR_IDMAP */ + +/* iops->mkdir() takes struct user_namespace* */ +/* #undef HAVE_IOPS_MKDIR_USERNS */ + +/* iops->mknod() takes struct mnt_idmap* */ +/* #undef HAVE_IOPS_MKNOD_IDMAP */ + +/* iops->mknod() takes struct user_namespace* */ +/* #undef HAVE_IOPS_MKNOD_USERNS */ + +/* iops->permission() takes struct mnt_idmap* */ +/* #undef HAVE_IOPS_PERMISSION_IDMAP */ + +/* iops->permission() takes struct user_namespace* */ +/* #undef HAVE_IOPS_PERMISSION_USERNS */ + +/* iops->rename() takes struct mnt_idmap* */ +/* #undef HAVE_IOPS_RENAME_IDMAP */ + +/* iops->rename() takes struct user_namespace* */ +/* #undef HAVE_IOPS_RENAME_USERNS */ + +/* iops->setattr() exists */ +/* #undef HAVE_IOPS_SETATTR */ + +/* iops->symlink() takes struct mnt_idmap* */ +/* #undef HAVE_IOPS_SYMLINK_IDMAP */ + +/* iops->symlink() takes struct user_namespace* */ +/* #undef HAVE_IOPS_SYMLINK_USERNS */ + +/* iov_iter_advance() is available */ +/* #undef HAVE_IOV_ITER_ADVANCE */ + +/* iov_iter_count() is available */ +/* #undef HAVE_IOV_ITER_COUNT */ + +/* iov_iter_fault_in_readable() is available */ +/* #undef HAVE_IOV_ITER_FAULT_IN_READABLE */ + +/* iov_iter_revert() is available */ +/* #undef HAVE_IOV_ITER_REVERT */ + +/* iov_iter_type() is available */ +/* #undef HAVE_IOV_ITER_TYPE */ + +/* iov_iter types are available */ +/* #undef HAVE_IOV_ITER_TYPES */ + +/* yes */ +/* #undef HAVE_IO_SCHEDULE_TIMEOUT */ + +/* Define to 1 if you have the `issetugid' function. */ +#define HAVE_ISSETUGID 1 + +/* iter_iov() is available */ +/* #undef HAVE_ITER_IOV */ + +/* kernel has kernel_fpu_* functions */ +/* #undef HAVE_KERNEL_FPU */ + +/* kernel has asm/fpu/api.h */ +/* #undef HAVE_KERNEL_FPU_API_HEADER */ + +/* kernel fpu internal */ +/* #undef HAVE_KERNEL_FPU_INTERNAL */ + +/* kernel has asm/fpu/internal.h */ +/* #undef HAVE_KERNEL_FPU_INTERNAL_HEADER */ + +/* uncached_acl_sentinel() exists */ +/* #undef HAVE_KERNEL_GET_ACL_HANDLE_CACHE */ + +/* Define if compiler supports -Winfinite-recursion */ +/* #undef HAVE_KERNEL_INFINITE_RECURSION */ + +/* kernel does stack verification */ +/* #undef HAVE_KERNEL_OBJTOOL */ + +/* kernel has linux/objtool.h */ +/* #undef HAVE_KERNEL_OBJTOOL_HEADER */ + +/* kernel_read() take loff_t pointer */ +/* #undef HAVE_KERNEL_READ_PPOS */ + +/* timer_list.function gets a timer_list */ +/* #undef HAVE_KERNEL_TIMER_FUNCTION_TIMER_LIST */ + +/* struct timer_list has a flags member */ +/* #undef HAVE_KERNEL_TIMER_LIST_FLAGS */ + +/* timer_setup() is available */ +/* #undef HAVE_KERNEL_TIMER_SETUP */ + +/* kernel_write() take loff_t pointer */ +/* #undef HAVE_KERNEL_WRITE_PPOS */ + +/* kmem_cache_create_usercopy() exists */ +/* #undef HAVE_KMEM_CACHE_CREATE_USERCOPY */ + +/* kstrtoul() exists */ +/* #undef HAVE_KSTRTOUL */ + +/* ktime_get_coarse_real_ts64() exists */ +/* #undef HAVE_KTIME_GET_COARSE_REAL_TS64 */ + +/* ktime_get_raw_ts64() exists */ +/* #undef HAVE_KTIME_GET_RAW_TS64 */ + +/* kvmalloc exists */ +/* #undef HAVE_KVMALLOC */ + +/* Define if you have [aio] */ +/* #undef HAVE_LIBAIO */ + +/* Define if you have [blkid] */ +/* #undef HAVE_LIBBLKID */ + +/* Define if you have [crypto] */ +#define HAVE_LIBCRYPTO 1 + +/* Define if you have [tirpc] */ +/* #undef HAVE_LIBTIRPC */ + +/* Define if you have [udev] */ +/* #undef HAVE_LIBUDEV */ + +/* Define if you have [uuid] */ +/* #undef HAVE_LIBUUID */ + +/* linux/blk-cgroup.h exists */ +/* #undef HAVE_LINUX_BLK_CGROUP_HEADER */ + +/* lseek_execute() is available */ +/* #undef HAVE_LSEEK_EXECUTE */ + +/* makedev() is declared in sys/mkdev.h */ +/* #undef HAVE_MAKEDEV_IN_MKDEV */ + +/* makedev() is declared in sys/sysmacros.h */ +/* #undef HAVE_MAKEDEV_IN_SYSMACROS */ + +/* Noting that make_request_fn() returns blk_qc_t */ +/* #undef HAVE_MAKE_REQUEST_FN_RET_QC */ + +/* Noting that make_request_fn() returns void */ +/* #undef HAVE_MAKE_REQUEST_FN_RET_VOID */ + +/* iops->mkdir() takes umode_t */ +/* #undef HAVE_MKDIR_UMODE_T */ + +/* Define to 1 if you have the `mlockall' function. */ +#define HAVE_MLOCKALL 1 + +/* lookup_bdev() wants mode arg */ +/* #undef HAVE_MODE_LOOKUP_BDEV */ + +/* Define if host toolchain supports MOVBE */ +#define HAVE_MOVBE 1 + +/* new_sync_read()/new_sync_write() are available */ +/* #undef HAVE_NEW_SYNC_READ */ + +/* folio_wait_bit() exists */ +/* #undef HAVE_PAGEMAP_FOLIO_WAIT_BIT */ + +/* part_to_dev() exists */ +/* #undef HAVE_PART_TO_DEV */ + +/* iops->getattr() takes a path */ +/* #undef HAVE_PATH_IOPS_GETATTR */ + +/* Define if host toolchain supports PCLMULQDQ */ +#define HAVE_PCLMULQDQ 1 + +/* percpu_counter_add_batch() is defined */ +/* #undef HAVE_PERCPU_COUNTER_ADD_BATCH */ + +/* percpu_counter_init() wants gfp_t */ +/* #undef HAVE_PERCPU_COUNTER_INIT_WITH_GFP */ + +/* posix_acl_chmod() exists */ +/* #undef HAVE_POSIX_ACL_CHMOD */ + +/* posix_acl_from_xattr() needs user_ns */ +/* #undef HAVE_POSIX_ACL_FROM_XATTR_USERNS */ + +/* posix_acl_release() is available */ +/* #undef HAVE_POSIX_ACL_RELEASE */ + +/* posix_acl_release() is GPL-only */ +/* #undef HAVE_POSIX_ACL_RELEASE_GPL_ONLY */ + +/* posix_acl_valid() wants user namespace */ +/* #undef HAVE_POSIX_ACL_VALID_WITH_NS */ + +/* proc_ops structure exists */ +/* #undef HAVE_PROC_OPS_STRUCT */ + +/* iops->put_link() cookie */ +/* #undef HAVE_PUT_LINK_COOKIE */ + +/* iops->put_link() delayed */ +/* #undef HAVE_PUT_LINK_DELAYED */ + +/* iops->put_link() nameidata */ +/* #undef HAVE_PUT_LINK_NAMEIDATA */ + +/* If available, contains the Python version number currently in use. */ +#define HAVE_PYTHON "3.7" + +/* qat is enabled and existed */ +/* #undef HAVE_QAT */ + +/* struct reclaim_state has reclaimed */ +/* #undef HAVE_RECLAIM_STATE_RECLAIMED */ + +/* register_shrinker is vararg */ +/* #undef HAVE_REGISTER_SHRINKER_VARARG */ + +/* register_sysctl_table exists */ +/* #undef HAVE_REGISTER_SYSCTL_TABLE */ + +/* iops->rename2() exists */ +/* #undef HAVE_RENAME2 */ + +/* struct inode_operations_wrapper takes .rename2() */ +/* #undef HAVE_RENAME2_OPERATIONS_WRAPPER */ + +/* iops->rename() wants flags */ +/* #undef HAVE_RENAME_WANTS_FLAGS */ + +/* REQ_DISCARD is defined */ +/* #undef HAVE_REQ_DISCARD */ + +/* REQ_FLUSH is defined */ +/* #undef HAVE_REQ_FLUSH */ + +/* REQ_OP_DISCARD is defined */ +/* #undef HAVE_REQ_OP_DISCARD */ + +/* REQ_OP_FLUSH is defined */ +/* #undef HAVE_REQ_OP_FLUSH */ + +/* REQ_OP_SECURE_ERASE is defined */ +/* #undef HAVE_REQ_OP_SECURE_ERASE */ + +/* REQ_PREFLUSH is defined */ +/* #undef HAVE_REQ_PREFLUSH */ + +/* revalidate_disk() is available */ +/* #undef HAVE_REVALIDATE_DISK */ + +/* revalidate_disk_size() is available */ +/* #undef HAVE_REVALIDATE_DISK_SIZE */ + +/* struct rw_semaphore has member activity */ +/* #undef HAVE_RWSEM_ACTIVITY */ + +/* struct rw_semaphore has atomic_long_t member count */ +/* #undef HAVE_RWSEM_ATOMIC_LONG_COUNT */ + +/* linux/sched/signal.h exists */ +/* #undef HAVE_SCHED_SIGNAL_HEADER */ + +/* Define to 1 if you have the header file. */ +#define HAVE_SECURITY_PAM_MODULES_H 1 + +/* setattr_prepare() accepts mnt_idmap */ +/* #undef HAVE_SETATTR_PREPARE_IDMAP */ + +/* setattr_prepare() is available, doesn't accept user_namespace */ +/* #undef HAVE_SETATTR_PREPARE_NO_USERNS */ + +/* setattr_prepare() accepts user_namespace */ +/* #undef HAVE_SETATTR_PREPARE_USERNS */ + +/* iops->set_acl() exists, takes 3 args */ +/* #undef HAVE_SET_ACL */ + +/* iops->set_acl() takes 4 args, arg1 is struct mnt_idmap * */ +/* #undef HAVE_SET_ACL_IDMAP_DENTRY */ + +/* iops->set_acl() takes 4 args */ +/* #undef HAVE_SET_ACL_USERNS */ + +/* iops->set_acl() takes 4 args, arg2 is struct dentry * */ +/* #undef HAVE_SET_ACL_USERNS_DENTRY_ARG2 */ + +/* set_cached_acl() is usable */ +/* #undef HAVE_SET_CACHED_ACL_USABLE */ + +/* set_special_state() exists */ +/* #undef HAVE_SET_SPECIAL_STATE */ + +/* struct shrink_control exists */ +/* #undef HAVE_SHRINK_CONTROL_STRUCT */ + +/* kernel_siginfo_t exists */ +/* #undef HAVE_SIGINFO */ + +/* signal_stop() exists */ +/* #undef HAVE_SIGNAL_STOP */ + +/* new shrinker callback wants 2 args */ +/* #undef HAVE_SINGLE_SHRINKER_CALLBACK */ + +/* cs->count_objects exists */ +/* #undef HAVE_SPLIT_SHRINKER_CALLBACK */ + +#if defined(__amd64__) || defined(__i386__) +/* Define if host toolchain supports SSE */ +#define HAVE_SSE 1 + +/* Define if host toolchain supports SSE2 */ +#define HAVE_SSE2 1 + +/* Define if host toolchain supports SSE3 */ +#define HAVE_SSE3 1 + +/* Define if host toolchain supports SSE4.1 */ +#define HAVE_SSE4_1 1 + +/* Define if host toolchain supports SSE4.2 */ +#define HAVE_SSE4_2 1 + +/* Define if host toolchain supports SSSE3 */ +#define HAVE_SSSE3 1 +#endif + +/* STACK_FRAME_NON_STANDARD is defined */ +/* #undef HAVE_STACK_FRAME_NON_STANDARD */ + +/* standalone exists */ +/* #undef HAVE_STANDALONE_LINUX_STDARG */ + +/* 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 the `strlcat' function. */ +#define HAVE_STRLCAT 1 + +/* Define to 1 if you have the `strlcpy' function. */ +#define HAVE_STRLCPY 1 + +/* submit_bio is member of struct block_device_operations */ +/* #undef HAVE_SUBMIT_BIO_IN_BLOCK_DEVICE_OPERATIONS */ + +/* super_setup_bdi_name() exits */ +/* #undef HAVE_SUPER_SETUP_BDI_NAME */ + +/* super_block->s_user_ns exists */ +/* #undef HAVE_SUPER_USER_NS */ + +/* struct kobj_type has default_groups */ +/* #undef HAVE_SYSFS_DEFAULT_GROUPS */ + +/* 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 + +/* i_op->tmpfile() exists */ +/* #undef HAVE_TMPFILE */ + +/* i_op->tmpfile() uses old dentry signature */ +/* #undef HAVE_TMPFILE_DENTRY */ + +/* i_op->tmpfile() has mnt_idmap */ +/* #undef HAVE_TMPFILE_IDMAP */ + +/* i_op->tmpfile() has userns */ +/* #undef HAVE_TMPFILE_USERNS */ + +/* totalhigh_pages() exists */ +/* #undef HAVE_TOTALHIGH_PAGES */ + +/* kernel has totalram_pages() */ +/* #undef HAVE_TOTALRAM_PAGES_FUNC */ + +/* Define to 1 if you have the `udev_device_get_is_initialized' function. */ +/* #undef HAVE_UDEV_DEVICE_GET_IS_INITIALIZED */ + +/* kernel has __kernel_fpu_* functions */ +/* #undef HAVE_UNDERSCORE_KERNEL_FPU */ + +/* Define to 1 if you have the header file. */ +#define HAVE_UNISTD_H 1 + +/* iops->getattr() takes struct user_namespace* */ +/* #undef HAVE_USERNS_IOPS_GETATTR */ + +/* iops->setattr() takes struct user_namespace* */ +/* #undef HAVE_USERNS_IOPS_SETATTR */ + +/* user_namespace->ns.inum exists */ +/* #undef HAVE_USER_NS_COMMON_INUM */ + +/* iops->getattr() takes a vfsmount */ +/* #undef HAVE_VFSMOUNT_IOPS_GETATTR */ + +/* fops->clone_file_range() is available */ +/* #undef HAVE_VFS_CLONE_FILE_RANGE */ + +/* fops->copy_file_range() is available */ +/* #undef HAVE_VFS_COPY_FILE_RANGE */ + +/* fops->dedupe_file_range() is available */ +/* #undef HAVE_VFS_DEDUPE_FILE_RANGE */ + +/* aops->direct_IO() uses iovec */ +/* #undef HAVE_VFS_DIRECT_IO_IOVEC */ + +/* aops->direct_IO() uses iov_iter without rw */ +/* #undef HAVE_VFS_DIRECT_IO_ITER */ + +/* aops->direct_IO() uses iov_iter with offset */ +/* #undef HAVE_VFS_DIRECT_IO_ITER_OFFSET */ + +/* aops->direct_IO() uses iov_iter with rw and offset */ +/* #undef HAVE_VFS_DIRECT_IO_ITER_RW_OFFSET */ + +/* filemap_dirty_folio exists */ +/* #undef HAVE_VFS_FILEMAP_DIRTY_FOLIO */ *** 243 LINES SKIPPED *** From nobody Wed Oct 4 13:43:37 2023 X-Original-To: dev-commits-src-branches@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 4S0wrV0WdLz4vxtJ; Wed, 4 Oct 2023 13:43: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0wrV028Sz3YT7; Wed, 4 Oct 2023 13:43:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427018; 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=oJGzwB+iwIADL9nHlsCMBWC7CnP5/8/AuReKmHAbQ6M=; b=EvpE9dIEQypfg6/wgA1WTjjUolxAGcdobTocHxO2XO0sbEkwAhGDOZVKUxwJ85SpMF59+8 gN+9kb3Z7FM+oY8uAfwbZMw2xGb4CN41m+SFLC6vEsvTB3+uBzWPO5j/wg8zXBxk1PgGgS rpblKnQ4rU2mhYoSGswsf82X1RWzblxYUeol11vaCj/0HIZ8GOeQUzu5eQVbwy0rl7xpCX cK7ypk6ALo3cOB+SR6wa8jIDx7xZT4iYD60JCa22Dhd1882fgDGErEhYR3viGBnVVug3yn vuYznDuJu73wvrRLniYN4pW1DjAbYWmML2JQDKGhL5iIabywQWvY26sfRQZXfw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696427018; a=rsa-sha256; cv=none; b=nxLU7+zxlU7LZxscs6474omBndnwFWI7o8HWVbHLdJxPNmkeNSvgZ1XI1LJdcCIV3R1q2J 3cQhk0O+YnSTWZ22gCdREEjbIJiu1o03qQ2QgvZHzabLiRHfLDOBYYKmLQorAU3QdmtHpI GCEjPcbUI8KBkh7T3tYpHjqSzjFAYOQIOwTy4p7nP7C+Do/A14WUGwTKQRu8dKepgrP3jr g+o6413iPPRQ5F0iwjq7J3rDSItd4eHI7G+mSHWOlmNVdzJy0aWpwFn7rRn+gzTOoNsGh2 +XEzRgQaaZ4jbja5n1fs4cHdqPQMgu12v/6sm5TJoUVR7zdebi+PxQH5ZA3+GQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427018; 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=oJGzwB+iwIADL9nHlsCMBWC7CnP5/8/AuReKmHAbQ6M=; b=xKm7IDXylTITOj5iYkEWfSFqWjoCf77S1Wjai+EBO6BgF4CZAEGa/SAkdAuBO6RL2pG505 n/MrGXovyTncENIXwbWL6a/w3FTJy/ljipSbkrwwm2MRCn6xhy8DI2szDqALcyQKITPbP+ d3M5FEKab6P5ZtWq0uFpFmPe9N/twBVJesJ073RfMeo71ckl+37xTSRmnRS9sRSUscuw0g m7G1/X129SReC2iV6bLFZkDEn2RTb9rnN+771zrT/8//mROKOWohuECpwwC8ZW0Tf3NFlX YCud9j9cVjM9+FTLNuGOSrXxVbI9z2tM3+lXZVs4FT8NiezpfLGkn1GPwSo6RQ== 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 4S0wrT6BPHzfxD; Wed, 4 Oct 2023 13:43:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394Dhbda019688; Wed, 4 Oct 2023 13:43:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394Dhbjo019685; Wed, 4 Oct 2023 13:43:37 GMT (envelope-from git) Date: Wed, 4 Oct 2023 13:43:37 GMT Message-Id: <202310041343.394Dhbjo019685@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 32ca3712a8c4 - stable/13 - hdac: Defer interrupt allocation in hdac_attach() List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: 32ca3712a8c4295d14770ad9cc55c1c837d834ad Auto-Submitted: auto-generated The branch stable/13 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=32ca3712a8c4295d14770ad9cc55c1c837d834ad commit 32ca3712a8c4295d14770ad9cc55c1c837d834ad Author: Mark Johnston AuthorDate: 2023-09-27 12:23:58 +0000 Commit: Mark Johnston CommitDate: 2023-10-04 13:43:14 +0000 hdac: Defer interrupt allocation in hdac_attach() hdac_attach() registers an interrupt handler before allocating various driver resources which are accessed by the interrupt handler. On some platforms we observe what appear to be spurious interrupts upon a cold boot, resulting in panics. Partially work around the problem by deferring irq allocation until after other resources are allocated. I think this is not a complete solution, but is correct and sufficient to work around the problems reported in the PR. PR: 268393 Tested by: Alexander Sherikov Tested by: Oleh Hushchenkov MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D41883 (cherry picked from commit 015daf5221f7588b9258fe0242cee09bde39fe21) --- sys/dev/sound/pci/hda/hdac.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/sys/dev/sound/pci/hda/hdac.c b/sys/dev/sound/pci/hda/hdac.c index 82b1baacfa98..3d2c4001d68d 100644 --- a/sys/dev/sound/pci/hda/hdac.c +++ b/sys/dev/sound/pci/hda/hdac.c @@ -1272,9 +1272,6 @@ hdac_attach(device_t dev) /* Allocate resources */ result = hdac_mem_alloc(sc); - if (result != 0) - goto hdac_attach_fail; - result = hdac_irq_alloc(sc); if (result != 0) goto hdac_attach_fail; @@ -1349,6 +1346,10 @@ hdac_attach(device_t dev) hdac_corb_init(sc); hdac_rirb_init(sc); + result = hdac_irq_alloc(sc); + if (result != 0) + goto hdac_attach_fail; + /* Defer remaining of initialization until interrupts are enabled */ sc->intrhook.ich_func = hdac_attach2; sc->intrhook.ich_arg = (void *)sc; From nobody Wed Oct 4 13:43:38 2023 X-Original-To: dev-commits-src-branches@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 4S0wrW1VDxz4vxYp; Wed, 4 Oct 2023 13:43: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0wrW13hPz3Yfh; Wed, 4 Oct 2023 13:43:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427019; 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=5byqIyyg53WnMmbqRabjQjwqr+UARw7E5shuTbU+QTI=; b=M6llblw7pSlIcL+tt+OD/PtXkJrpAzehO3okkH+3iy/CUv6wx8zbwdivaHhHc71pmHKYxe w7O0np7n8T3QRmaxRmvr6ovnffA4DW0VizSxkfZWTHuusLtcWQngMgLOPNWTwBMnCmgd+L STDsk4bNO2GEvoxZUtn/tR7HPOngurlIizpdd+SbhP9blvPDZBllNIGmzGA+nsfeVGOHiW 31S9McpGqUlOp9SOinzvOjtX/X2yo+ayj7RKFlLmnmtcA02n4lYZ8l87YtQDpTDMg7qxy7 r7HkXpvGjj2IFTndpop6tZf48QckCsGg/E1dU4e5s7kDpkaunB5XTtCE7KxeYQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696427019; a=rsa-sha256; cv=none; b=VOgzucAx2G65Z3KMnjVkWeS8fsk68rokOUTCqzr6Z0Gf8SPecpXXtLTSgXPeCkVB0KGPti TrWIyRgvda/sU4WqD7HGt5FfGzETCPpglBwpCnKUPezp8AkhIZowg0M8jSooBo04TO8uLJ ha3WhsETyLjd+A0fvLnRmK8UmvNEboRYRz+Rn5kdqIkToJp6+SfXi1BknCJnK27Q1xRHdm ufKRTOlXPS7A8d+3h5jI9xAkVJjg3nA6CaQvqOOZ4kzoJY9RPFcuk6GFMFJyGPrRgwynj4 ZShTDwUjaDGiDKFmVVb1m2ytbilWs9prmi+iZsbhNHTx6dW1ibJNi+8Yppoo5A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427019; 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=5byqIyyg53WnMmbqRabjQjwqr+UARw7E5shuTbU+QTI=; b=TxHVTK3jtAdt5fsr2hyeSek6VZWiNA5c9vId6nVZOwPfWXsF0GBSmNestXnkqUeCe7y+TZ G75sQe/iGnH/vfdXjiWOwzNxqoXZv0DfEEgPCr87IgIfErw/N3hTqQXMWtnNGJqXmu8X63 /GTByYzGrf/8/vfTLDrNQNiQjsj8Y1k6Vhi0XLbX1J5kupg0UM6TGRkrvGIzyeSsJ6KrFX IxYm7Lu+D1g9o1NyKiV2kzhiVK4ZRRBPX8Zdapm+mJ0EMy3fBTyG1Zyk+I7kK3txFg362F xJD/Qqdi3F/2a3+mlO3ajy12ULEpHDPVhiediBjL4rKcxG5DQlkFWFfJYpmwOw== 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 4S0wrW08CmzgB5; Wed, 4 Oct 2023 13:43:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394DhcfE019745; Wed, 4 Oct 2023 13:43:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394DhcVE019742; Wed, 4 Oct 2023 13:43:38 GMT (envelope-from git) Date: Wed, 4 Oct 2023 13:43:38 GMT Message-Id: <202310041343.394DhcVE019742@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 2464d8c5e296 - stable/13 - glabel.8: Warn against using generic labels on a shared device List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/13 X-Git-Reftype: branch X-Git-Commit: 2464d8c5e296a02de882310398e73077225cac00 Auto-Submitted: auto-generated The branch stable/13 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=2464d8c5e296a02de882310398e73077225cac00 commit 2464d8c5e296a02de882310398e73077225cac00 Author: Mark Johnston AuthorDate: 2022-05-26 13:48:17 +0000 Commit: Mark Johnston CommitDate: 2023-10-04 13:43:22 +0000 glabel.8: Warn against using generic labels on a shared device Also suggest against creating a generic label on a device which already contains a filesystem. PR: 264166 Reviewed by: imp, delphij, Pau Amma MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D35326 (cherry picked from commit 81f36fbc98dd74ca923938e0329919d426811b0c) --- lib/geom/label/glabel.8 | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/lib/geom/label/glabel.8 b/lib/geom/label/glabel.8 index 5283a604e45b..a23f425bc5e1 100644 --- a/lib/geom/label/glabel.8 +++ b/lib/geom/label/glabel.8 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd March 12, 2017 +.Dd September 27, 2023 .Dt GLABEL 8 .Os .Sh NAME @@ -141,6 +141,26 @@ Generic labels created and managed solely by are created in the .Pa /dev/label/ directory. +Note that generic, automatic labels occupy some space on the device +and thus should not be added to a device already containing a file system. +In particular, +.Nm +reserves the last sector of the device to store the label information. +If the device already contains a file system, +.Nm +will overwrite the last sector, possibly damaging the file system, and the +file system may later overwrite the label sector. +Instead, create a label before initializing the file system, and initialize +that file system on the device created by +.Nm +under the +.Pa /dev/label/ +directory. +Then the file system will correctly account for the space occupied by the +generic label, +since the +.Nm +device will be one sector smaller than the device from which it was created. .Pp Note that for all label types, nested GEOM classes will cause additional device nodes to be created, with context-specific data appended to their From nobody Wed Oct 4 13:43:45 2023 X-Original-To: dev-commits-src-branches@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 4S0wrd6Ddzz4vxqw; Wed, 4 Oct 2023 13:43:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0wrd5jxqz3Ysj; Wed, 4 Oct 2023 13:43:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427025; 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=vsfwIJ/vMpctys7mlcxneyq+o1hbK+OFVags1MF3gAM=; b=M6vgbdXSILCBe/00SV5vGi1RKvVjU2YbIyXt4AbSZBwR8RfXg/iIiyvTRDmAIVJFx1Rfom Ao5M7VioqLMIdPaEk0MrDDgsJpmqydcKojyF5BpBzskSlSUx5hwgGolN2CbZqLvB6OPwnK 9soKQt2FIFvSYkd00roiRRcCpdBBbZ3BTV5HXjmXZjOqIDl6609an15hqIuqjwV+LGAOBD fF4cnP95l6FWQLe2s7vkcsFHDpB3c2Kbk23WlKr5oFfRXf6wA8NiPQxNPkp6s8pwvy5Gp5 oRSbPi9fjuXBwoID/G8W/0CvMJzXm2FP8Jp3l2JJV54xwQFztvDycnLnS936+g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696427025; a=rsa-sha256; cv=none; b=QpxrjVML1vrYEyHxDWnr0ksVzOodRzRJdQKPq4VaiFeLw/NdcEeZkj8x8X3Hv9kgFMrxwH W9DNAZ03QtF9CkihVfKPw/5G+3yxmZ5Z9yw3cHTSDKsJCHAVDS3OciViSGLnO2yzE2Lz6l 8nh52p9CoRnScJIOoTpD0kJRAo+tQl1CHwHw1McaOT0nyXsuS0DHBaxUaoYdlqI5ZlASRW VtRo+GBIcuBpVaPoIoYR4Vjqo3peDyRfEjsRJTgfukDWWLrZPIjv7WvMNzNGjx5Uv7CEZH 4cuXSojtuq69UxSsPOY6Z6Rlin5IX0j7IuFTZ3hxieiFgZzgzgSQv1n6ccj47w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427025; 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=vsfwIJ/vMpctys7mlcxneyq+o1hbK+OFVags1MF3gAM=; b=w6nDXaxHDJ2Nv5Ck5GifyDKNEtvG8Dw5xVPlHZxDwOWCcgdvUmIvj+/R+V6S2FmBbPf3PL DWH8ergOGQXmRN/ye4dTUR50vMSv8ETxGNSKC2iFZrd3chf4hxgQMR9QpZ0SJ7qywgoNJs FFAB5bTB68wZ6nNok5f5864h6gKqbV5XYzqGIBeI9qq42jR4DiN/hSWs5h73RVSFq/us95 G/4VRZs3357a6jfsT47SiGMaf2UDUH2plkZcCl50uw/K+dOfKEL1sEbRAAAZKI0n3u+POj KCzRn0H8Frr0WryUsE2wJ6notxP/Rt/wFtEWGIPvkshABRXkwX3NM89BCryaTQ== 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 4S0wrd4klTzfxG; Wed, 4 Oct 2023 13:43:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394DhjXI019957; Wed, 4 Oct 2023 13:43:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394Dhj8L019954; Wed, 4 Oct 2023 13:43:45 GMT (envelope-from git) Date: Wed, 4 Oct 2023 13:43:45 GMT Message-Id: <202310041343.394Dhj8L019954@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: b11568083f09 - stable/14 - glabel.8: Warn against using generic labels on a shared device List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: b11568083f09f48caf11d78d25ab58fc65793bcf Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=b11568083f09f48caf11d78d25ab58fc65793bcf commit b11568083f09f48caf11d78d25ab58fc65793bcf Author: Mark Johnston AuthorDate: 2022-05-26 13:48:17 +0000 Commit: Mark Johnston CommitDate: 2023-10-04 13:41:29 +0000 glabel.8: Warn against using generic labels on a shared device Also suggest against creating a generic label on a device which already contains a filesystem. PR: 264166 Reviewed by: imp, delphij, Pau Amma MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D35326 (cherry picked from commit 81f36fbc98dd74ca923938e0329919d426811b0c) --- lib/geom/label/glabel.8 | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/lib/geom/label/glabel.8 b/lib/geom/label/glabel.8 index 5283a604e45b..a23f425bc5e1 100644 --- a/lib/geom/label/glabel.8 +++ b/lib/geom/label/glabel.8 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd March 12, 2017 +.Dd September 27, 2023 .Dt GLABEL 8 .Os .Sh NAME @@ -141,6 +141,26 @@ Generic labels created and managed solely by are created in the .Pa /dev/label/ directory. +Note that generic, automatic labels occupy some space on the device +and thus should not be added to a device already containing a file system. +In particular, +.Nm +reserves the last sector of the device to store the label information. +If the device already contains a file system, +.Nm +will overwrite the last sector, possibly damaging the file system, and the +file system may later overwrite the label sector. +Instead, create a label before initializing the file system, and initialize +that file system on the device created by +.Nm +under the +.Pa /dev/label/ +directory. +Then the file system will correctly account for the space occupied by the +generic label, +since the +.Nm +device will be one sector smaller than the device from which it was created. .Pp Note that for all label types, nested GEOM classes will cause additional device nodes to be created, with context-specific data appended to their From nobody Wed Oct 4 13:43:46 2023 X-Original-To: dev-commits-src-branches@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 4S0wrg2Zsjz4vxr1; Wed, 4 Oct 2023 13:43: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0wrf6NQzz3ZCB; Wed, 4 Oct 2023 13:43:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427026; 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=P93G1fDDQDRwDw92xAaoRr4PWQKXkpbxypcCPjzRXpg=; b=ZkewE/ESP+3Csl6O8A6r019vKHWJQ0YwdPzM/NIrCgmOWkjVrC2tvI7d/33fQKhhEebU9O 42LtIX16j69hsYZnqLzfkjZ3K4jfM9rno3imLkk2opuwOyz92c/cDiyjjNgneQqD6nMdK3 kgbC9MWrlONqhRQeN+DhtblN060b9T+GwlFRqEjw8sV21PbppaAGFGf8IZcs+jEq3JdVQM VetJzA1xIu4u3OsxegAHOMzk90lVvN8aI7X4Ga91suDJnuKK8vGTn40AhMtBHcemHTGkyd f62DEPI4CPpbfb0MJ5MJ2IAhMre0Lf35c9xi2xL/9b/VUfNvOIfit0PmgcDQjw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696427026; a=rsa-sha256; cv=none; b=gCvwABx+VVftkl00s/vvZSdOIVd7rOPrLsSrfXTwkgRNWMC4bi2eEiYFQqS1+5MuaTjvIO r+zvry09bqKsO9AElgxkwpCiUQ4/oRfSTqN/Qo573o2iwr7xGJRh/9O5lOX9RA6Z51yW7j dLNon9N11YpSQLYO5wMAU4h7++RUsiIhsTLYL/8wE3N462ujDBwymSQiSeobhhax5uJnnK tg7bnXVellLvmn8majkL6iS7PjkRr79OLJQelFbF8JaGAq0KoDFsGuzur7kyxeAfBWiAwu 1cf1KC9hmRbnvzRpt4VZ+Z4wYD3jqVet+aWPkVokyviFVKKhgkGpimMar16Bog== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427026; 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=P93G1fDDQDRwDw92xAaoRr4PWQKXkpbxypcCPjzRXpg=; b=H+OpNE/phD9itat+Iyb9FyZK6WmB3gftF+VMQKU0YVMEGnsi+sNMJvvt/b9zzC/qcRdM5O n/fseZB4zqiyuo9H+QRY63GNxoP1Gzw4RdLOHjAfrTaJ/mdE4OcGqmz17a7U+5fveBllk6 C10FNaKDUMcSvhxKdY2gVxcIaDVAKRUfzVd8FpCD+iwSg/l2lZFKZKUiQY77tE2jtoziXM QoDlipepTH+7uJZnv7/ZZIf39DmH7852GXwvzRwOGGxe0CByDLr0NTO2qws1/XK03PJFIf 88X5dDwn4Ndq1n9LMp725c+KF2NcueN2iLNc2IRupmMJW+gOn3aJMGYDf0c1IA== 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 4S0wrf5L6pzfYS; Wed, 4 Oct 2023 13:43:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394DhkQT020004; Wed, 4 Oct 2023 13:43:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394Dhku4020001; Wed, 4 Oct 2023 13:43:46 GMT (envelope-from git) Date: Wed, 4 Oct 2023 13:43:46 GMT Message-Id: <202310041343.394Dhku4020001@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 20c494a9d3f2 - stable/14 - unix: Fix a lock order reveral List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 20c494a9d3f20e2942c99ca517d0e983a0ac73e8 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=20c494a9d3f20e2942c99ca517d0e983a0ac73e8 commit 20c494a9d3f20e2942c99ca517d0e983a0ac73e8 Author: Mark Johnston AuthorDate: 2023-09-27 12:24:11 +0000 Commit: Mark Johnston CommitDate: 2023-10-04 13:41:38 +0000 unix: Fix a lock order reveral Running the test suite yields: lock order reversal: 1st 0xfffff80004bc6700 unp (unp, sleep mutex) @ sys/kern/uipc_usrreq.c:390 2nd 0xffffffff81a94b30 unp_link_rwlock (unp_link_rwlock, rw) @ sys/kern/uipc_usrreq.c:2934 lock order unp -> unp_link_rwlock attempted at: 0xffffffff80bc216e at witness_checkorder+0xbbe 0xffffffff80b493a5 at _rw_wlock_cookie+0x65 0xffffffff80c0a8e2 at unp_discard+0x22 0xffffffff80c0a888 at unp_freerights+0x38 0xffffffff80c09fdd at unp_scan+0x9d 0xffffffff80c0f9a7 at uipc_sosend_dgram+0x727 0xffffffff80c00a79 at sousrsend+0x79 0xffffffff80c072d0 at kern_sendit+0x1c0 0xffffffff80c074d7 at sendit+0xb7 0xffffffff80c076f3 at sys_sendmsg+0x63 0xffffffff8104d957 at amd64_syscall+0x6b7 0xffffffff8101f9eb at fast_syscall_common+0xf8 This happens when uipc_sosend_dgram() discards a control message because the receive socket buffer is full. The overflow handling frees internalized file references in the socket buffer before freeing mbufs. It does this with socket PCBs locked, leading to the LOR. Defer handling of file references until the PCBs are unlocked. Reviewed by: glebius MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D41884 (cherry picked from commit 61a14ddfe012ca7b57a101725e5c654269f200ca) --- sys/kern/uipc_usrreq.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/kern/uipc_usrreq.c b/sys/kern/uipc_usrreq.c index 291ff7cf8cae..f12693f3982a 100644 --- a/sys/kern/uipc_usrreq.c +++ b/sys/kern/uipc_usrreq.c @@ -1332,8 +1332,10 @@ uipc_sosend_dgram(struct socket *so, struct sockaddr *addr, struct uio *uio, } else { soroverflow_locked(so2); error = ENOBUFS; - if (f->m_next->m_type == MT_CONTROL) - unp_scan(f->m_next, unp_freerights); + if (f->m_next->m_type == MT_CONTROL) { + c = f->m_next; + f->m_next = NULL; + } } if (addr != NULL) From nobody Wed Oct 4 13:43:47 2023 X-Original-To: dev-commits-src-branches@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 4S0wrh0mPmz4vxZ1; Wed, 4 Oct 2023 13:43: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0wrh08DRz3Z0D; Wed, 4 Oct 2023 13:43:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427028; 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=5chuR6igoSf7D4ruDgLB/MJw9DjaukEnMrYUU8iKISU=; b=eQJqkomlrWLZE6GOlCtCxMbLm9+ZNNivy7lBRY18sxheNuA82727SvF8a1HwvtRidZQ0MZ Img+cRyg5UCK+RASfBzmP+Bno2JiEDM7eUMMNTZhdpkly5hNKK2l8KQ/6gw0mBMu8rWjsb TNyrhz5EGR8tY1/mRMtpDyisHfub6r+N/dY8qOW+RUwwRdl10laFRYgjTJHTmUgSqrXlej czjgi1eMZ396DwAqZyUzuYz08BVHERt8cknaSVObThHH1X94WDS+Hv3pkRBMlK2GcysmNY WbOLN8UrwjSwzmyeHoLReu7fwrTtYhelEk2v59nXmnQgoAvMSsCIGXqpjTLOTQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696427028; a=rsa-sha256; cv=none; b=P+sHVrkqZVocdrdAZVhdi+K/rsJo4q72iwfZeqqVRqgZxMfjDzAuOQtER7Qw5jcM2K1VEA asO5qZJXpXTFX3VlkT7ZTysNzbhnCu3ECav6aooBUc0XvagY/I3DkOzaevHEDfNsXgNOcy qaAO6QCSNLC1Oq/xObSBvy1Ln/+m4x0NdwzJRMuohnicJtHzBXGn4X7WDAjEwMGUo/QBW3 X/6RktOP27Ms6iyNPdSyv6AwK0XtWsbGLW28m2cszo6SdmZDM2Rw+SlcNe/5h4ebKTBCus FPhxst038KzUIom7cW0zhdmb3yVyW+9TVVjvYH2VU0Nc9nVeWOcwd5gjTlpbeA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427028; 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=5chuR6igoSf7D4ruDgLB/MJw9DjaukEnMrYUU8iKISU=; b=Kmk9HGE44JI6UM7C75WA2oebO2pd9/lm7grKtBPe5jqYxjeTtlo1JGrXoNPstxrU0TtovZ wNJPK3FqlGvTnd1nrWXbxaMHo2lgh7hzTyO4cRnGM3mtZCNxcDkzCuo1IRjiVA1XTZo+g9 HqTbq/EFPlTTkIX11IzdHqUOQyokF6FbcwKbfsxAicC25WdNgxwi0prA4HNNY+0L0czPJy RQ4OsYio4sfmcxZRQTfvy7FYrGiiGzlkagvz9CRiFqcJlgJiPh2wSZ6QTaJzMID/O5yvy/ QBTJdcKLYNqHL+JjKr2wmz8tKWu4TnkCzct7GaJaO9kq9vgnI/NxfNfKqobZhQ== 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 4S0wrg6JllzfxH; Wed, 4 Oct 2023 13:43:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394DhlwC020049; Wed, 4 Oct 2023 13:43:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394DhlRM020046; Wed, 4 Oct 2023 13:43:47 GMT (envelope-from git) Date: Wed, 4 Oct 2023 13:43:47 GMT Message-Id: <202310041343.394DhlRM020046@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 1e8737f4e884 - stable/14 - hdac: Defer interrupt allocation in hdac_attach() List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 1e8737f4e884fdf4b966056662e4e6003d3379d9 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=1e8737f4e884fdf4b966056662e4e6003d3379d9 commit 1e8737f4e884fdf4b966056662e4e6003d3379d9 Author: Mark Johnston AuthorDate: 2023-09-27 12:23:58 +0000 Commit: Mark Johnston CommitDate: 2023-10-04 13:41:52 +0000 hdac: Defer interrupt allocation in hdac_attach() hdac_attach() registers an interrupt handler before allocating various driver resources which are accessed by the interrupt handler. On some platforms we observe what appear to be spurious interrupts upon a cold boot, resulting in panics. Partially work around the problem by deferring irq allocation until after other resources are allocated. I think this is not a complete solution, but is correct and sufficient to work around the problems reported in the PR. PR: 268393 Tested by: Alexander Sherikov Tested by: Oleh Hushchenkov MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D41883 (cherry picked from commit 015daf5221f7588b9258fe0242cee09bde39fe21) --- sys/dev/sound/pci/hda/hdac.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/sys/dev/sound/pci/hda/hdac.c b/sys/dev/sound/pci/hda/hdac.c index 422f7f930ea5..2cf9239499af 100644 --- a/sys/dev/sound/pci/hda/hdac.c +++ b/sys/dev/sound/pci/hda/hdac.c @@ -1270,9 +1270,6 @@ hdac_attach(device_t dev) /* Allocate resources */ result = hdac_mem_alloc(sc); - if (result != 0) - goto hdac_attach_fail; - result = hdac_irq_alloc(sc); if (result != 0) goto hdac_attach_fail; @@ -1347,6 +1344,10 @@ hdac_attach(device_t dev) hdac_corb_init(sc); hdac_rirb_init(sc); + result = hdac_irq_alloc(sc); + if (result != 0) + goto hdac_attach_fail; + /* Defer remaining of initialization until interrupts are enabled */ sc->intrhook.ich_func = hdac_attach2; sc->intrhook.ich_arg = (void *)sc; From nobody Wed Oct 4 13:43:48 2023 X-Original-To: dev-commits-src-branches@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 4S0wrj1wsXz4vy0B; Wed, 4 Oct 2023 13:43: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0wrj1D63z3ZJB; Wed, 4 Oct 2023 13:43:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427029; 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=DpWBeyxmzn3nVz8tCP84aDVExSsU9SvLp7aatm61g10=; b=mR9h2MPqtm6vnJCx9fVoRSeQe5WySnuubdwj0r0vC/YI3HyCycdbK+s1dlHHWc75X9j8c5 1m3wClObHb2AvnTz43zmDQkeEYHVHwWzyXiSrn3Af9sBKcLt2HEz/N6ogoLskbdJRbvx2T yFjlUG1yzLyxuqReBBvnleIDd/fM41NSq2NbjLD7ez1u4n+lInyG1Tpj0XHNE0VCdLgjry eyHwhdmvHTy7PvfhM7ExpWFXpeEmYrCCJLwDKsMRRSpakqBXjNqEE91rdgqa2jad+XqPNK Txwcx1NEdhwrieVQDXoK6BXmU/V17OxJhciQbC67z5WjEdr8/LcUOfMEPOu8YQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696427029; a=rsa-sha256; cv=none; b=gUMu0UbccddAy8H6Dti6wkogSnunDZAvNq+30HbEci3Au5qEyMp++Shll54vevYQIZPGQW /9x0qUqKDdvZshFlgZk9dbCiirXcxOt187pe8+Hkxnyp4JAFmegjR0bhJHmrDzyT34J6dq 8wC9W88iV1sK9SYM2N2Y/4sVCGW7HG5UaxBTZhNqpEqKuJ2VnIEWF7PPeazZUcn6gg+0rI PsZNJ1MmXNpuTTIqa+vJOuCWodGz8GB8TJfVpVWir3xINKOb0OZfTJqOY8rXwRQ7VllVEV 2jWDhBu5kKTJDMFupO+TXJIwzrDhlgdbypvkdeY4MeznMKtNBhAKzfG2L2+RUw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427029; 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=DpWBeyxmzn3nVz8tCP84aDVExSsU9SvLp7aatm61g10=; b=O1bdjnTBsFNawWaYmsAdQGXgVCcBZjJovMuFQiZzT+dff8oYNruUitwyiW3ak5wTfu8dkA f6S+eUxeuzlCklp04FD77nuMxOpikR79cetPw3hH8zz5/Rffd1dpXH5Rvu7IqjhwEDA4ot OAr3XHDPW1p6cZDah/BtiDFRfulftEYHD6DI8NEHmaflRf0YKR5JSb4O0MV/gt/76vxoaC K9loN604glnes541AjDuVDcxnVQpXdVPrSvcV4CICPEkrDWsmM2xU4mxYb7GjdSYllRoNn Z+j4v4w8x0FWmtKLlz+ynfUc4rvBHj3UahHtb6IksxI4Ho30KPGpYBP/W+R2IA== 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 4S0wrj0DggzfYT; Wed, 4 Oct 2023 13:43:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394Dhmqb020110; Wed, 4 Oct 2023 13:43:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394Dhmte020107; Wed, 4 Oct 2023 13:43:48 GMT (envelope-from git) Date: Wed, 4 Oct 2023 13:43:48 GMT Message-Id: <202310041343.394Dhmte020107@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: d4a5d7a15544 - stable/14 - makefs/zfs tests: Run zdb prior to importing makefs-created pools List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: d4a5d7a15544d5e561f4235b9b40457e2c52626a Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=d4a5d7a15544d5e561f4235b9b40457e2c52626a commit d4a5d7a15544d5e561f4235b9b40457e2c52626a Author: Mark Johnston AuthorDate: 2023-09-27 15:58:34 +0000 Commit: Mark Johnston CommitDate: 2023-10-04 13:42:07 +0000 makefs/zfs tests: Run zdb prior to importing makefs-created pools zdb contains quite a few assertions that can help catch bugs. MFC after: 1 week Sponsored by: The FreeBSD Foundation (cherry picked from commit 87534f95dd2ed51e01165e0072cb1c7790809a8b) --- usr.sbin/makefs/tests/makefs_zfs_tests.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/usr.sbin/makefs/tests/makefs_zfs_tests.sh b/usr.sbin/makefs/tests/makefs_zfs_tests.sh index 250a313481d9..e8da4cc87055 100644 --- a/usr.sbin/makefs/tests/makefs_zfs_tests.sh +++ b/usr.sbin/makefs/tests/makefs_zfs_tests.sh @@ -56,6 +56,8 @@ import_image() { atf_check -e empty -o save:$TEST_MD_DEVICE_FILE -s exit:0 \ mdconfig -a -f $TEST_IMAGE + atf_check -o ignore -e empty -s exit:0 \ + zdb -e -p /dev/$(cat $TEST_MD_DEVICE_FILE) -mmm -ddddd $ZFS_POOL_NAME atf_check zpool import -R $TEST_MOUNT_DIR $ZFS_POOL_NAME echo "$ZFS_POOL_NAME" > $TEST_ZFS_POOL_NAME } From nobody Wed Oct 4 13:43:50 2023 X-Original-To: dev-commits-src-branches@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 4S0wrk2hXPz4vxc0; Wed, 4 Oct 2023 13:43: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0wrk28f9z3ZPM; Wed, 4 Oct 2023 13:43:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427030; 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=tWJ7qYG6mpGD6Qj7Tb6r5O0R8YAj/Tkhxl6k55z+j8A=; b=beNdBsh1AInZrQgPGeoT76ZE6VuvbfPF4fraRRm97lD+h1qosHvTIrPLSUheiQ6mzaBZwC zpnWMp9gFadXuKzAcw5aWXkWbWYWTQzD8wApnr24ii5UO13/v54eJEBbc3LcjZG3dzLAYL UiqBfmDog6bS89O/4QJjRoE5uAvzUiLwog8PSTOADaTTgFGpLrHpQo3IuARvDRerR6tk6e YZDDwL69wA4DOx3Kd5A3j0+X2ig8he8c8u9pGtqKLS3nooYqjwqdWbCrHuZ4yllf0DgvoQ zP33olcMKO4bh/h+x0UsQL/SNNUNhsX4RW/q/Uf6j845lKuEx0Vc3x+1yZ5l/Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696427030; a=rsa-sha256; cv=none; b=dWD/T99w/yYT/odmWlKPhl6XTW/EUhEOv8E34tdnHBlSzT/7EvJMpBr4XLhoB3DfXFUcga e03obhJg74JO9/UW1Lj+qASXGjDIrTmsLa1TJCC5wRYIVaAvGeJ8pMgUz9MrDMCvVzP15N IxrpjMXoG8dLmprpifY8Hr9eTxM6NwPF9IC+rwxMpH2OGpYfWz2QFi21BcA8jZCHCiR8wn nniswF2CWvbk6HZYfLasBPS++A0y08L9OKoPVN4MrM7PEYrpmNcaXKxkpJTGlwjlAUYiZ+ w9IBMw2GqlzMDc5or5k05hNhyE9hfR7yhoQtXmcjrcGfxT0IA7J5yCktrvzk9A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427030; 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=tWJ7qYG6mpGD6Qj7Tb6r5O0R8YAj/Tkhxl6k55z+j8A=; b=lfrHN44qJqFP2kWdK+7jhWQkicWauFmWhV8qutazN8X/HiexmPmVnVt9xdZNCpOHQhaBdb feZIaRApqGo7wIFncswsakiO9nUczJHgf0McBnAddSSBGRdSmkuwaj8zRO7qQN1WvtAB0E FWx8g7b/onXaw7QmBxLFTZtSWdratztdKPPmBeCZPsYhuVCJiohNhwDujv2iarEqDDnh1X btdXEjprvW1WmYMPPwVg8Ox4OSUf9cy3sL9c8dSLbtZn9Du4620lL4IE6DE2vvhQPFmC6M Jt1lklpQmwwI8WH6eRAjiYgU9YVq5T0M1iCHPvD2xJwqCmxPDon4hr6wpQQhHQ== 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 4S0wrk1C3qzfxJ; Wed, 4 Oct 2023 13:43:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394DhoE6020164; Wed, 4 Oct 2023 13:43:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394DhoPq020161; Wed, 4 Oct 2023 13:43:50 GMT (envelope-from git) Date: Wed, 4 Oct 2023 13:43:50 GMT Message-Id: <202310041343.394DhoPq020161@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: ea5173e57255 - stable/14 - makefs/zfs: Set the objset block pointer fill field correctly List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: ea5173e5725564da4b95a5b98410b8cd43520dab Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=ea5173e5725564da4b95a5b98410b8cd43520dab commit ea5173e5725564da4b95a5b98410b8cd43520dab Author: Mark Johnston AuthorDate: 2023-09-27 15:56:33 +0000 Commit: Mark Johnston CommitDate: 2023-10-04 13:42:14 +0000 makefs/zfs: Set the objset block pointer fill field correctly It is supposed to contain the number of objects allocated from the set, excluding the meta dnode. Reported by: mav MFC after: 1 week Sponsored by: The FreeBSD Foundation (cherry picked from commit 46402fd21631b7d4686f8c341d92db6bcb190e5d) --- usr.sbin/makefs/zfs/objset.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/usr.sbin/makefs/zfs/objset.c b/usr.sbin/makefs/zfs/objset.c index 22277c150712..3e3dcdeced4b 100644 --- a/usr.sbin/makefs/zfs/objset.c +++ b/usr.sbin/makefs/zfs/objset.c @@ -121,6 +121,7 @@ _objset_write(zfs_opt_t *zfs, zfs_objset_t *os, struct dnode_cursor *c, STAILQ_FOREACH_SAFE(chunk, &os->dnodechunks, next, tmp) { unsigned int i; + assert(chunk->nextfree > 0); assert(chunk->nextfree <= os->dnodecount); assert(chunk->nextfree <= DNODES_PER_CHUNK); @@ -149,8 +150,8 @@ _objset_write(zfs_opt_t *zfs, zfs_objset_t *os, struct dnode_cursor *c, * Write the object set itself. The saved block pointer will be copied * into the referencing DSL dataset or the uberblocks. */ - vdev_pwrite_data(zfs, DMU_OT_OBJSET, ZIO_CHECKSUM_FLETCHER_4, 0, 1, - os->phys, os->osblksz, os->osloc, &os->osbp); + vdev_pwrite_data(zfs, DMU_OT_OBJSET, ZIO_CHECKSUM_FLETCHER_4, 0, + os->dnodecount - 1, os->phys, os->osblksz, os->osloc, &os->osbp); } void From nobody Wed Oct 4 13:43:51 2023 X-Original-To: dev-commits-src-branches@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 4S0wrl4Jrdz4vy6q; Wed, 4 Oct 2023 13:43: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0wrl3MGyz3ZV6; Wed, 4 Oct 2023 13:43:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427031; 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=KfVa7/K29DLL/m7xWZKxldsc0pBv+yd4ItMiYbOfZYE=; b=gOVdCEVGYP+6PScpGNY0eOl7UVKXEoCQQ7HJRlFm/i1JBKUZhvcuUwTw7JEWeLGKtt4E/G hykWJFBTc5YvSNZNo2PfT0OUZjxYL5rPlD+Nb8qCncTn5x/Ul6yFoiWCOCBgoweG4VeD41 ekmFo5HP8g/iWfugobQP88AID4VegQNFJcYIYsxgnFCiFdKyi73gWSLWUn+fvJP9MWseqW YGcSwjBBlgLZym5Snq5kt+bp8nvLxOYqsPnj3CxhL98N7lVP6gyMXqGc+tEgoM/OhnH2kY sm1lSFAuzKoLZYmwMZs4Quohcny+9J1GTrDGQDQ8iJBN2xwShwee/7rQ/XlVlA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696427031; a=rsa-sha256; cv=none; b=t3GfJbKitXZj+YSR2zK6HpKwO/hZ2CghM6ILEQclrhjYTcFiEE4rXrz4+nKwnUcR5Er3ng mGVkGQ9tV6n47hqmCIjeYa3tSRNg2QWIXgvn+LgC4uXVFeKq6kDnDskZeC6ldxy6Ok1Sgr qYAbjId8D4gitcfzTGtE5vnlDNCUlCob0YhE2ya2Hh/DR/8rNoeV1FZBPR2oxAIeQTRXIH eWNJ/NfZZFNNlnT1st0foky3dD/vcLo9etzE4yP5cf//v1DLm7eQH+g/yPgfBL7UeZW5az nmFYL3IITMxnpXhjnCcrWw+BUrmJeK25Qi6BjbSQMJTGH3dUZVsSKGCd9ytTVA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427031; 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=KfVa7/K29DLL/m7xWZKxldsc0pBv+yd4ItMiYbOfZYE=; b=YNE4HWw0oBEYeqKPBUfLWcu1k0qztmzXlRAA5FsfM5drF/WZ8rEC2wWZsUiGtsHUJQC8RJ Xjigo6fEJ6XrtUdtL+qOMs/L1CA9F8ECbsqW05ExUFihOyjb9nH7SWH7sSgT4bR+o9zj2M 4LVKWrBH73pG4T2wiZYb+l4muHJaJI+5ZhmFTVPiSyzn7+/ZA0TbiKfiWrG2LbX3NE2rR4 0nBHXbeMDIouL/2WVwuJUxNmlCfewCchiyoH9GbHyhJ8NV1+cJmdqx3Rl+O35kUMiduZDj 7uARsv5hUepLDveNqFZqjExh+NPCAaSXLNy11BLEsyoN7GBDdpfwGNipbLHtuQ== 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 4S0wrl29Zgzfvk; Wed, 4 Oct 2023 13:43:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394DhpYb020206; Wed, 4 Oct 2023 13:43:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394Dhpw3020203; Wed, 4 Oct 2023 13:43:51 GMT (envelope-from git) Date: Wed, 4 Oct 2023 13:43:51 GMT Message-Id: <202310041343.394Dhpw3020203@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 0074d0551ded - stable/14 - makefs/zfs: Remove a nonsensical comment List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 0074d0551ded1652155a23c6a8d04043c8ede1fd Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=0074d0551ded1652155a23c6a8d04043c8ede1fd commit 0074d0551ded1652155a23c6a8d04043c8ede1fd Author: Mark Johnston AuthorDate: 2023-09-27 22:21:37 +0000 Commit: Mark Johnston CommitDate: 2023-10-04 13:42:23 +0000 makefs/zfs: Remove a nonsensical comment When populating files, makefs needs to copy their contents into userspace in order to compute a checksum, so copy_file_range(2) is out of the question. Though, it could possibly be used when building other types of filesystems. MFC after: 1 week Sponsored by: The FreeBSD Foundation (cherry picked from commit 60c95af88f6a63fb7c2c86c6ff9c18743f6bbf0d) --- usr.sbin/makefs/zfs/fs.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/usr.sbin/makefs/zfs/fs.c b/usr.sbin/makefs/zfs/fs.c index a4968d5f91e8..0d85ea8eb9d8 100644 --- a/usr.sbin/makefs/zfs/fs.c +++ b/usr.sbin/makefs/zfs/fs.c @@ -551,8 +551,6 @@ fs_populate_file(fsnode *cur, struct fs_populate_arg *arg) /* * Fill up our buffer, handling partial reads. - * - * It might be profitable to use copy_file_range(2) here. */ sofar = 0; target = MIN(size - foff, (off_t)bufsz); From nobody Wed Oct 4 13:43:52 2023 X-Original-To: dev-commits-src-branches@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 4S0wrn0m4Qz4vxc7; Wed, 4 Oct 2023 13:43: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0wrm4lLwz3ZKf; Wed, 4 Oct 2023 13:43:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427032; 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=/LtBwPaYbrfPUMHCemnmgwz+Effm6KjLLNZINHzvYBk=; b=G7EBxa5DYpKzHLeHcl2MQZkjpRqPHx1yzUcpslnGMXGBT3h9rl3XloLc9Uxrbz038ZzHQ+ fYhz4HsMrIZps52lXJn8AXl1rng9SrThB6YtRJY1MKj4FV7AONeJqroEjj3asFxuiCUILO xY8KsWiSEmcqx1jq277X97BuhubvtqC6Ce4Y6UpmS4oxQlSa1NkO8jQWTMhehsGZWVCUs2 FgMX3iEPkUr7hoxU+X4qV7aRkfVKLIt9Gw7uzPmBiEbbFqk/210I5dFEdrCao53U2flcvR TSU0ioAzTPyzbkQs1vk+vM7sm03U5K1nk0GtUrrzDiPZ/PssMogApCjfTzvCeQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696427032; a=rsa-sha256; cv=none; b=R6qoszgRnFQ9SRKPfQwJ+TodX5vlNoloLtLDOGVFiqDAyitOyh7rKJ96ZCVEQ132/ORtjF 0x9xvvaC30Ki+388Dvw1eZ5Ljl+AyRgxOU/K4vrFblG7XbCIVaU4eqU95BWh/SGx4wS7Bv sGgmIxTIoPyAV6zkMU4FkJegCre6AVOaw38eoFq5CDnwL0VSzHL9aozqHSZLwL/10CU+s+ J11xVrNR9B9On3MUtqA2PgjNUrtdnJ4t6UJZUvSkolIW9t3Vqkd/nr6soLBtMLxN7y3HwM mXZa6morrVAimlso7vfEfIaC569ihy+yZtG39jPpIMkXVhvCslcO/Or5Dq359A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427032; 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=/LtBwPaYbrfPUMHCemnmgwz+Effm6KjLLNZINHzvYBk=; b=g8w0NiN/O9FNSSYl0WiAEtUBM4sSL6ISw3STnngMULdTZFwvf7PTnQU66d3vKDWwwemkSB RQVEe8CLhcLQ9l/Trg1ZqW8MQK9zE/u5j2PJbjrqkgflrRRS5Rfxc8AiuKlZ8IB8CFAkre NiGioVd8g/UStX+hBRVcYlCbUrreZx7zMEyDJM0C44suTnb1sfaX+Jhirk2SL4PRmryQ6A 2p4h5Hp7vW7Xspz3+SyweyOUZwa1k0WDMDDAsCaGOonmtmryEoKG7TePKrBj7wzQKHI8iM 7JI6qZ2LeAXbTcaEFxG2AML4lk2xGIw/tw/sd4RWu23QgclvSmlsGGBNMGvceQ== 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 4S0wrm34Q8zfYV; Wed, 4 Oct 2023 13:43:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394Dhqpe020272; Wed, 4 Oct 2023 13:43:52 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394Dhqr1020269; Wed, 4 Oct 2023 13:43:52 GMT (envelope-from git) Date: Wed, 4 Oct 2023 13:43:52 GMT Message-Id: <202310041343.394Dhqr1020269@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 5175923ef4ac - stable/14 - makefs/zfs: Ensure that the last block of a file has the right size List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 5175923ef4acb6faff370177fb60700721f13f92 Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=5175923ef4acb6faff370177fb60700721f13f92 commit 5175923ef4acb6faff370177fb60700721f13f92 Author: Mark Johnston AuthorDate: 2023-09-28 20:16:17 +0000 Commit: Mark Johnston CommitDate: 2023-10-04 13:42:37 +0000 makefs/zfs: Ensure that the last block of a file has the right size When copying a file's contents into the pool, a loop copies blocks of the maximum size (128KB), allocating space from the vdev for each block. The space allocator rounds up to the nearest block size, but for files larger than the maximum size, this can result in the last block having a smaller logical size than the rest of the blocks belonging to that dnode. This violates some ZFS invariants when appending to that file. Modify fs_populate_file() to use the same block size for the final block. Reported by: cperciva MFC after: 1 week Sponsored by: The FreeBSD Foundation (cherry picked from commit ef20cd33d3287ebead0d30f2e177fc57a97dc2d5) --- usr.sbin/makefs/zfs/fs.c | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/usr.sbin/makefs/zfs/fs.c b/usr.sbin/makefs/zfs/fs.c index 0d85ea8eb9d8..b0a4c639f256 100644 --- a/usr.sbin/makefs/zfs/fs.c +++ b/usr.sbin/makefs/zfs/fs.c @@ -515,7 +515,7 @@ fs_populate_file(fsnode *cur, struct fs_populate_arg *arg) uint64_t dnid; ssize_t n; size_t bufsz; - off_t size, target; + off_t nbytes, reqbytes, size; int fd; assert(cur->type == S_IFREG); @@ -546,29 +546,30 @@ fs_populate_file(fsnode *cur, struct fs_populate_arg *arg) bufsz = sizeof(zfs->filebuf); size = cur->inode->st.st_size; c = dnode_cursor_init(zfs, arg->fs->os, dnode, size, 0); - for (off_t foff = 0; foff < size; foff += target) { + for (off_t foff = 0; foff < size; foff += nbytes) { off_t loc, sofar; /* * Fill up our buffer, handling partial reads. */ sofar = 0; - target = MIN(size - foff, (off_t)bufsz); + nbytes = MIN(size - foff, (off_t)bufsz); do { - n = read(fd, buf + sofar, target); + n = read(fd, buf + sofar, nbytes); if (n < 0) err(1, "reading from '%s'", cur->name); if (n == 0) errx(1, "unexpected EOF reading '%s'", cur->name); sofar += n; - } while (sofar < target); + } while (sofar < nbytes); - if (target < (off_t)bufsz) - memset(buf + target, 0, bufsz - target); + if (nbytes < (off_t)bufsz) + memset(buf + nbytes, 0, bufsz - nbytes); - loc = objset_space_alloc(zfs, arg->fs->os, &target); - vdev_pwrite_dnode_indir(zfs, dnode, 0, 1, buf, target, loc, + reqbytes = foff == 0 ? nbytes : MAXBLOCKSIZE; + loc = objset_space_alloc(zfs, arg->fs->os, &reqbytes); + vdev_pwrite_dnode_indir(zfs, dnode, 0, 1, buf, reqbytes, loc, dnode_cursor_next(zfs, c, foff)); } eclose(fd); From nobody Wed Oct 4 13:43:53 2023 X-Original-To: dev-commits-src-branches@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 4S0wrn61yQz4vy0L; Wed, 4 Oct 2023 13:43: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0wrn5Y1hz3ZVs; Wed, 4 Oct 2023 13:43:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427033; 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=xPe4SvYTRjfO4mStTe2tEQd7NG30LTz/BWFVQy95Cqk=; b=j7HdQKye4egbQURTArCy6gZcySV/WhtSxW6xeIzOxQUUK0GAFCb6h9zuq2w3K76vQUfDhF XAeRcY6oJKv+0aaMbs6MDNTgJW5oC1dVmoQj1iwk+3I3kSCoajKZ8UuiM6b1q26fO7vMlI jZdXNRPOMGmeGDPM7/9mg+zkDNkI4yxgE/cPkfCcQ5E71sabCpTYkFV6HzKjTvnctWMdV1 JTVXgd5gnqCElZt99V0uv8+UWam6PCET//fvACGfuurSPRNr8kzKwuejDRynPit+ApsLXV Xtyf2jSexT1jdCS0cTnXIpZcVtx4EGOkI3D5E2/DwoSLOf5q8fl9KHexiaN3bw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696427033; a=rsa-sha256; cv=none; b=bvAgRIKZTu/zQEO/tpWCvRU42FT0UAgldt6mZ3+g9zF/LWhiSra8FEObuvP/Vt/Fhc4dRL hhP7erEZAI5kp4CcjpVOMGpYBOFtKuhMJ5zOeCAFLfGISfiCR9iWrGCCSwFJfRU66c6/UQ JUpG+9ZIJGaBykCs/42forbx/zcTh73UZheflU9fw/I4NmGM8pLK6Ws4HNcYrzOdoobruj r/sdCpPl+DVxkge6A9DCtsCdu1ptUShmODKgrav70hM8/BFg+1hnawr3pWuf29UHCaE5tT RNR3I5YbLORC3kzE6YEgBG4OWJ8gnYKchR697NtS1B+EUpeHa9acKUIvN4Rp/A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696427033; 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=xPe4SvYTRjfO4mStTe2tEQd7NG30LTz/BWFVQy95Cqk=; b=reSjjJbX8oIM+DBnGMuWASX2azVC8/mLpTiDaMexZbrsIRfql0bz6PxV+PROlwWjfWS9dp 7mykAbC6wBaJSiJU+HyRz3mdi5HHEvuP/eQBk/li9zTYJtjmvopbJBeckgoqcTlBiHTblp DLgFPW9yd/dJWf8XfH9GfFwwVYnkkbY8SYXy9/DlQuurIwEhn/OXwveGj7IXW6gyQKWbbg Hl3mkJpc00/g7nHzJ7qG2yxXykhfa4GDgN+Z/ABICFJakjtrfHTIMijPKUOvrlAz6D9vLn wcVtZiDNY78QG/TU9hTtK9Rrv5ce6p1k899YAuZCx2+T/1B7Jm786HDc0AnQkA== 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 4S0wrn4ZY5zfxK; Wed, 4 Oct 2023 13:43:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394Dhr1m020339; Wed, 4 Oct 2023 13:43:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394DhrBA020336; Wed, 4 Oct 2023 13:43:53 GMT (envelope-from git) Date: Wed, 4 Oct 2023 13:43:53 GMT Message-Id: <202310041343.394DhrBA020336@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 162787ac4947 - stable/14 - makefs/zfs tests: Add a test case which appends to a file after import List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 162787ac494720edcae8bf2fd26b8a8f952f55fc Auto-Submitted: auto-generated The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=162787ac494720edcae8bf2fd26b8a8f952f55fc commit 162787ac494720edcae8bf2fd26b8a8f952f55fc Author: Mark Johnston AuthorDate: 2023-09-28 20:25:06 +0000 Commit: Mark Johnston CommitDate: 2023-10-04 13:42:48 +0000 makefs/zfs tests: Add a test case which appends to a file after import MFC after: 1 week Sponsored by: The FreeBSD Foundation (cherry picked from commit b6da7f2fd127f447aa20843666b98d3a1d07b8c9) --- usr.sbin/makefs/tests/makefs_zfs_tests.sh | 35 +++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/usr.sbin/makefs/tests/makefs_zfs_tests.sh b/usr.sbin/makefs/tests/makefs_zfs_tests.sh index e8da4cc87055..9173600dc555 100644 --- a/usr.sbin/makefs/tests/makefs_zfs_tests.sh +++ b/usr.sbin/makefs/tests/makefs_zfs_tests.sh @@ -191,6 +191,40 @@ empty_fs_cleanup() common_cleanup } +atf_test_case file_extend cleanup +file_extend_body() +{ + local i start + + create_test_dirs + + # Create a file slightly longer than the maximum block size. + start=132 + dd if=/dev/random of=${TEST_INPUTS_DIR}/foo bs=1k count=$start + md5 -q ${TEST_INPUTS_DIR}/foo > foo.md5 + + atf_check $MAKEFS -s 10g -o rootpath=/ -o poolname=$ZFS_POOL_NAME \ + $TEST_IMAGE $TEST_INPUTS_DIR + + import_image + + check_image_contents + + i=0 + while [ $i -lt 1000 ]; do + dd if=/dev/random of=${TEST_MOUNT_DIR}/foo bs=1k count=1 \ + seek=$(($i + $start)) conv=notrunc + # Make sure that the first $start blocks are unmodified. + dd if=${TEST_MOUNT_DIR}/foo bs=1k count=$start of=foo.copy + atf_check -o file:foo.md5 md5 -q foo.copy + i=$(($i + 1)) + done +} +file_extend_cleanup() +{ + common_cleanup +} + atf_test_case file_sizes cleanup file_sizes_body() { @@ -699,6 +733,7 @@ atf_init_test_cases() atf_add_test_case dataset_removal atf_add_test_case empty_dir atf_add_test_case empty_fs + atf_add_test_case file_extend atf_add_test_case file_sizes atf_add_test_case hard_links atf_add_test_case indirect_dnode_array From nobody Wed Oct 4 15:23:37 2023 X-Original-To: dev-commits-src-branches@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 4S0z3s3PCdz4w6WX; Wed, 4 Oct 2023 15:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z3s2f4Dz4M8C; Wed, 4 Oct 2023 15:23:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433017; 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=2Z+DafY4N/G8pVLlHXvn43bQWGeT7Gh/XF8pYhkpLSk=; b=TOmbPqq2wftROd8wxS0qPBHgG2DcWQ0BhuS9cFpNHPOvtWVYqfV0FDyUlvzjHJ9kt/dEvI 8XS4oXBYsu29CvuUv+NsVIvaWHXlOqEbgk10rsakJJX6cNFbeHoLjNrH9Zb/MnZjJliV7y J8Q8xU7kwEh3ANved069wBL6SSwZ7mdIQGs6yEhuqPQWi8XwDlzdFSBRVKQhppYiq/e98C cx7ge8OvpQSSH+b8mkOmonejbPiXEVcfG8fDic62CVDLCSCMzRSoW/6qBp2E7cmMVjTC73 Bk5+nkQT7CvR0xJg8/40Nnu3TDUmVIX3UInZT5KaCqbJ5Q/Gl9MbUmp4YQjkjQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433017; a=rsa-sha256; cv=none; b=gTHsBOqETD4rEFLHhf9Q6LdaeoFasbIr/U+nMZAocHaCNda2kWDR4xwhpRYm20U8+Bxb7Q aqUw9NtmE/+V6ZN3yhzgrkfYNhbgMnY/qJ6NTb3qs3TSw+D7umHzWbOpkxyuX9aOE4Z4iE qig30yKeu1iZd/Kw+Q+zwpl/gtqMFCvH544kpFp96UAeqyrXuBQJc78JVTuTYs0tRF/qBB mytTq9fcB8b014JpJThS7doQm9RYoPQjWFs6Ht5lSU3AYBKm8fMQpqAcc9wN4mBSkTGU4b fi9T1zE4LiDenvwAW8g7V5hrZxszQWb3wUXbNhHw8A7NqEHkaq3A5tf2XedHKQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433017; 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=2Z+DafY4N/G8pVLlHXvn43bQWGeT7Gh/XF8pYhkpLSk=; b=dvLEESX7yf7ldSvrft98uHNn44sS+2SZ8TcgLu5TgAHeQGhpw9uJ0Zza/fLvbSzjZvLACu cGTdCk82pEvo+GzvVNxcxa6WI+AF5gc8jzLucMyzp9DvZbTJ18D+9ekP94P3ss7zaV/QAF 26FCcRZ7VGEVr6+eDOZW3slU2XdwZ491wKohBpXH9Kjsz8sqy17LXyyIdAFk+hXH0l8Adi AvjY1Zsba4RpXiceU8DeS9EKPSmEKgTvRjveiNNdu86r/yOIFqO0VUJuQtAJ2fHebfwMMN l2BWwlJVpjBYlWc11sAgKNyPmpWEEXAMEsM4uD+2+IOO0q/Jv2nxEmu5gbNe9w== 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 4S0z3s1jjBzjJb; Wed, 4 Oct 2023 15:23:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNbs3086607; Wed, 4 Oct 2023 15:23:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNb7U086604; Wed, 4 Oct 2023 15:23:37 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:37 GMT Message-Id: <202310041523.394FNb7U086604@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 54523452030a - stable/14 - tools/wlanstats: fix -Wunused-but-set-variable List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 54523452030a7490b93b7cee2b827886becd8960 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=54523452030a7490b93b7cee2b827886becd8960 commit 54523452030a7490b93b7cee2b827886becd8960 Author: Bjoern A. Zeeb AuthorDate: 2023-09-11 14:11:52 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:17 +0000 tools/wlanstats: fix -Wunused-but-set-variable The "allnodes" code is currently #if 0 so also #if 0 the setting of the command line option and variable in order to keep wlanstats compiling. Sponsored by: The FreeBSD Foundation (cherry picked from commit 530c13c5401c1f29f8325cf851d96778852a1ba3) --- tools/tools/net80211/wlanstats/main.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tools/tools/net80211/wlanstats/main.c b/tools/tools/net80211/wlanstats/main.c index 4c0cf4db0505..ac100a70622e 100644 --- a/tools/tools/net80211/wlanstats/main.c +++ b/tools/tools/net80211/wlanstats/main.c @@ -168,18 +168,26 @@ main(int argc, char *argv[]) struct ether_addr *ea; const uint8_t *mac = NULL; const char *ifname; +#if 0 int allnodes = 0; +#endif int c, mode; ifname = getenv("WLAN"); if (ifname == NULL) ifname = "wlan0"; wf = wlanstats_new(ifname, getfmt("default")); +#if 0 while ((c = getopt(argc, argv, "ahi:lm:o:")) != -1) { +#else + while ((c = getopt(argc, argv, "hi:lm:o:")) != -1) { +#endif switch (c) { +#if 0 case 'a': allnodes++; break; +#endif case 'h': usage(); exit(0); From nobody Wed Oct 4 15:23:38 2023 X-Original-To: dev-commits-src-branches@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 4S0z3t584kz4w6GN; Wed, 4 Oct 2023 15:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z3t4SjPz4MHs; Wed, 4 Oct 2023 15:23:38 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433018; 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=g5BxVnPaVmmSPBK5qaIcYQCnopMnqc+KX4rwJ8suPr4=; b=jbNrXMpe66yESNobF8BcaI5DGqNNpzoXH6zN3B/WxBGoNDDWvvTq+k7eMvrSt+MyE5Ks3X 0z+9aLqce8YzyL7kdiOpcA/O2+LkWLA8B0RkdWSwWmtXPQu0F1sgW/AozffL4/KnYsQuNw clOHJC+EUq8h1uWJ0kFzhbB65FbfI/kVRxQ73/uClCnIMkX3foxCDvpb3jGMjbLig11BK6 OvcOaAakYPUsNxMmxh32iUxcXbMGqKzc9xpC7w/iWbfJ4yMKVDsRrwSoTfKamcB6fm3iNZ Ue//dayuLofRHIZUVvBlaQrlU9VfRXMwrcP4ghd763256YyO2z93ITf5gxkBTQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433018; a=rsa-sha256; cv=none; b=pq5F57laj7HdZbA/9P9mT9nVdccJqb9jLxUuFCv7diGUVuc0r/aZFQtJxlZYpO9lGYRGs3 Yvg7XxmVyQUYl6T2bE0q9Ok85umTv0cvtdwoJyZ7ACevfetAgFGxWaSRq0iulMcnLxbf9+ ytzJezJdA2evtnIGYAxdp6R1xmK0EqGVjyx1O+RDF6NWu7sG8lxkuflGeGNsXBcuM8xGf4 d1ucmnMN9uSLfr1PAzk7MkIefFDU8rcuxbp8N3xMBjGix9hAtU8QxsVk+nnRsltbkD+st+ yGTEGlCtRvfZnHU819q3eCWi9wMcpQuoh20E+R95PHMaZwRlFIvCrszbfMzFAg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433018; 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=g5BxVnPaVmmSPBK5qaIcYQCnopMnqc+KX4rwJ8suPr4=; b=R00P9UmJChy8EeDnjA4Z4+KOBMkMuFAoLaTruxRCvsd/7BbXasYjvu8SS3/DvCin1RWKBY 2ET2b/tWsvxRYx9UUlopQiRAUegtDIlvEj7u94EJRwPdHIs1ttIZcS6z6nwcEtc91uDTTK 9+VWdqxgVWIyPsuz+sHNvQ7GOXqKohP+v89ZtRqhgwzBw0SrL5GfGOVns4lguUxMCuHjKk UzT6bsSeaqHtvOSq+DwY6F8iwK17rlmdUUfhwZo0IZeVWQHnCh6FmB3aZVmsO5gUZwTEpr kq81sbWqk1w2rFhwAJvwK/Easr0s9DE6iZQ6jnGm3gaJkkO3IOYyyceNWXBFBA== 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 4S0z3t2kk1zjdJ; Wed, 4 Oct 2023 15:23:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNc5D086656; Wed, 4 Oct 2023 15:23:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNcef086653; Wed, 4 Oct 2023 15:23:38 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:38 GMT Message-Id: <202310041523.394FNcef086653@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 76a10a216784 - stable/14 - net80211: fix ddb print alignment List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 76a10a216784f5c11939244c269a43759870ea68 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=76a10a216784f5c11939244c269a43759870ea68 commit 76a10a216784f5c11939244c269a43759870ea68 Author: Bjoern A. Zeeb AuthorDate: 2023-09-11 14:23:20 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:17 +0000 net80211: fix ddb print alignment Add missing \ts after new lines to properly align output of ddb show commands. Sponsored by: The FreeBSD Foundation (cherry picked from commit c45d05b71817e478953d6f235d921c2b4acc82de) --- sys/net80211/ieee80211_ddb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/net80211/ieee80211_ddb.c b/sys/net80211/ieee80211_ddb.c index 7a6ee49d7705..4e2df134c7a9 100644 --- a/sys/net80211/ieee80211_ddb.c +++ b/sys/net80211/ieee80211_ddb.c @@ -506,7 +506,7 @@ _db_show_vap(const struct ieee80211vap *vap, int showmesh, int showprocs) db_printf(" ht_sta_assoc %u", vap->iv_ht_sta_assoc); db_printf(" ht40_sta_assoc %u", vap->iv_ht40_sta_assoc); db_printf("\n"); - db_printf(" nonerpsta %u", vap->iv_nonerpsta); + db_printf("\tnonerpsta %u", vap->iv_nonerpsta); db_printf(" longslotsta %u", vap->iv_longslotsta); db_printf(" lastnonerp %d", vap->iv_lastnonerp); db_printf(" lastnonht %d", vap->iv_lastnonht); @@ -550,7 +550,7 @@ _db_show_com(const struct ieee80211com *ic, int showvaps, int showsta, db_printf(" phytype %d", ic->ic_phytype); db_printf(" opmode %s", ieee80211_opmode_name[ic->ic_opmode]); db_printf("\n"); - db_printf(" inact %p", &ic->ic_inact); + db_printf("\tinact %p", &ic->ic_inact); db_printf("\n"); db_printf("\tflags=%b\n", ic->ic_flags, IEEE80211_F_BITS); From nobody Wed Oct 4 15:23:39 2023 X-Original-To: dev-commits-src-branches@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 4S0z3v5PGTz4w6dh; Wed, 4 Oct 2023 15:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z3v4pFkz4MJP; Wed, 4 Oct 2023 15:23:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433019; 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=AAZknI050IRJHKENpKa6+6QbtVCgMsAbGNzamiB4z1Q=; b=nijWvdf3ujLbXVmfwb+L3WHkgxvTZTW64eDEyeV9rB4LVSRr462v4r0iH7g8tHeu/0NOrr FtNrsXqIjChSa33BJSmEuhSmC4AG+rIdHkb2PwMRLWwUrxUO7EAVn899X9oUU5/ELcbvcR DxiZzsTqSeWnzM9/0wzhU+H5DyFKLgJyg07nb/FkHqFoKwJBfR2T4imFOlKVItwMUti0H/ MuSPz/MePcroN+DOphWwM0p0fVjc9EwCEkJfABclZ+khjkciKEpPATHe3YR3qDWg/hsnBY WZcOTQjEQae3diMtDDfn607aOLOv+BjL3pCC4tfFyLsAyamaqtoWF2CUk1qYgg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433019; a=rsa-sha256; cv=none; b=f32oO++mXyN+C43rgCuUjfyuV2vJDK/+nnT5GHz1b95nkss+ACes4bMNQWungAJWtriEye gSc/UH6/eUIGlCRnPqHBjm29kC907MFGd8Aho4eIILf6p4UDBhkpRDXCTOVFVk9NKWF++t us60rmCrKJ51sGFkSICG6gV+ERbq8wrNiA6xzq78SMa9eOXO7pk58hSZTzPC1zTRyW7hri 0JS7X0vvZJrwCWzhXW59yQ/pvgudpEsYTISmxil0JxdRqmSz9/1dlLLdVm6AW0hMTIJWPd /QkkCqQtWds85YzPrN6431gMJW3X4N8VZ8AhNPU6K0GaFS9GDF+t867djmw1qA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433019; 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=AAZknI050IRJHKENpKa6+6QbtVCgMsAbGNzamiB4z1Q=; b=NeaCp8dNemn/gMEzVhThyJ2gHHaF2mpqjewGlAx7WatrNtzYA8LhzyYlDzRFRi+mMxnvfb Tc+9X41QtiysSSdbRsAhDnd2WXmH3TQBQPDBrq3JnGx91Acpb3GF3K1QwNGo0ZpmqzmJQo FJ1rT+DKrO1wjusn1Wr1Za64zHIJP7glRc7E41XetGF+x8T98zcT2FfWwxrom65ffZiu7Q sAPpds1WEfdcNfcPN3BvD8wgKtWAp4kvwVriOiLj//9CCjjAjRKPoRcup3v6pd0gZTNbFe R7EbP/LjSznSKpuUEfVpL7psmVg7SopRtdyo3gyGZsQbJwmE+4LIthHJTh7bjg== 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 4S0z3v3j3SzjdK; Wed, 4 Oct 2023 15:23:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNde5086698; Wed, 4 Oct 2023 15:23:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNdi0086695; Wed, 4 Oct 2023 15:23:39 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:39 GMT Message-Id: <202310041523.394FNdi0086695@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 20ca85c50d78 - stable/14 - net80211: improve scan debugging List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 20ca85c50d782dab4bf4306db4ac0e6164a42b53 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=20ca85c50d782dab4bf4306db4ac0e6164a42b53 commit 20ca85c50d782dab4bf4306db4ac0e6164a42b53 Author: Bjoern A. Zeeb AuthorDate: 2023-09-14 17:36:29 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:17 +0000 net80211: improve scan debugging While debugging other problems I ran into the case where net80211 was thinking a scan was ongoing and new scans could not be started but given other logging there was clearly no more scan running. It was hard after the fact to quickly determine enough state to reconstruct or validate assumptions. Improve a MSG_SCAN debug logging and implement _db_show_scan() ddb output which can be printed along with show com /S or /a. Sponsored by: The FreeBSD Foundation (cherry picked from commit 33396ec29f1daae31f4738f0da98dce168ca73c6) --- sys/net80211/ieee80211_ddb.c | 74 ++++++++++++++++++++++++++++++++++++++---- sys/net80211/ieee80211_ioctl.c | 6 ++-- sys/net80211/ieee80211_scan.h | 6 +++- 3 files changed, 77 insertions(+), 9 deletions(-) diff --git a/sys/net80211/ieee80211_ddb.c b/sys/net80211/ieee80211_ddb.c index 4e2df134c7a9..525814d202b1 100644 --- a/sys/net80211/ieee80211_ddb.c +++ b/sys/net80211/ieee80211_ddb.c @@ -67,7 +67,7 @@ static void _db_show_sta(const struct ieee80211_node *); static void _db_show_vap(const struct ieee80211vap *, int, int); static void _db_show_com(const struct ieee80211com *, - int showvaps, int showsta, int showmesh, int showprocs); + int showvaps, int showsta, int showmesh, int showprocs, int); static void _db_show_all_vaps(void *, struct ieee80211com *); @@ -132,7 +132,7 @@ DB_SHOW_COMMAND(vap, db_show_vap) DB_SHOW_COMMAND(com, db_show_com) { const struct ieee80211com *ic; - int i, showprocs = 0, showvaps = 0, showsta = 0, showmesh = 0; + int i, showprocs = 0, showvaps = 0, showsta = 0, showmesh = 0, showscan = 0; if (!have_addr) { db_printf("usage: show com \n"); @@ -141,7 +141,10 @@ DB_SHOW_COMMAND(com, db_show_com) for (i = 0; modif[i] != '\0'; i++) switch (modif[i]) { case 'a': - showsta = showmesh = showvaps = showprocs = 1; + showsta = showmesh = showvaps = showprocs = showscan = 1; + break; + case 'S': + showscan = 1; break; case 's': showsta = 1; @@ -158,7 +161,7 @@ DB_SHOW_COMMAND(com, db_show_com) } ic = (const struct ieee80211com *) addr; - _db_show_com(ic, showvaps, showsta, showmesh, showprocs); + _db_show_com(ic, showvaps, showsta, showmesh, showprocs, showscan); } DB_SHOW_ALL_COMMAND(vaps, db_show_all_vaps) @@ -345,6 +348,61 @@ _db_show_tdma(const char *sep, const struct ieee80211_tdma_state *ts, int showpr } #endif /* IEEE80211_SUPPORT_TDMA */ +static void +_db_show_scan(const struct ieee80211_scan_state *ss, int showprocs) +{ + int i; + const struct ieee80211_scanner *ss_ops; + + db_printf("SCAN %p:", ss); + db_printf(" vap %p ic %p", ss->ss_vap, ss->ss_ic); + db_printf("\n"); + + db_printf("\tss_ops %p (%s) ss_priv %p", + ss->ss_ops, ss->ss_ops->scan_name, ss->ss_priv); + db_printf("\n"); + if (showprocs) { + ss_ops = ss->ss_ops; + DB_PRINTSYM("\t", "scan_attach", ss_ops->scan_attach); + DB_PRINTSYM("\t", "scan_detach", ss_ops->scan_detach); + DB_PRINTSYM("\t", "scan_start", ss_ops->scan_start); + DB_PRINTSYM("\t", "scan_restart", ss_ops->scan_restart); + DB_PRINTSYM("\t", "scan_cancel", ss_ops->scan_cancel); + DB_PRINTSYM("\t", "scan_end", ss_ops->scan_end); + DB_PRINTSYM("\t", "scan_flush", ss_ops->scan_flush); + DB_PRINTSYM("\t", "scan_pickchan", ss_ops->scan_pickchan); + DB_PRINTSYM("\t", "scan_add", ss_ops->scan_add); + DB_PRINTSYM("\t", "scan_age", ss_ops->scan_age); + DB_PRINTSYM("\t", "scan_assoc_fail", ss_ops->scan_assoc_fail); + DB_PRINTSYM("\t", "scan_assoc_success", ss_ops->scan_assoc_success); + DB_PRINTSYM("\t", "scan_iterate", ss_ops->scan_iterate); + DB_PRINTSYM("\t", "scan_spare0", ss_ops->scan_spare0); + DB_PRINTSYM("\t", "scan_spare1", ss_ops->scan_spare1); + DB_PRINTSYM("\t", "scan_spare2", ss_ops->scan_spare2); + DB_PRINTSYM("\t", "scan_spare3", ss_ops->scan_spare3); + } + + db_printf("\tss_flags %b", ss->ss_flags, IEEE80211_SS_FLAGS_BITS); + db_printf("\n"); + + db_printf("\tss_nssid %u", ss->ss_nssid); + for (i = 0; i < ss->ss_nssid && i < IEEE80211_SCAN_MAX_SSID; i++) + _db_show_ssid(" ss_nssid[%d]", i, + ss->ss_ssid[i].len, ss->ss_ssid[i].ssid); + db_printf("\n"); + + db_printf("\tss_chans:\n"); + for (i = 0; i < ss->ss_last && i < IEEE80211_SCAN_MAX; i++) { + db_printf("\t%-3d", i); + _db_show_channel(" ", ss->ss_chans[i]); + db_printf("\n"); + } + + db_printf("\tss_next %u ss_last %u ss_mindwell %lu ss_maxdwell %lu", + ss->ss_next, ss->ss_last, ss->ss_mindwell, ss->ss_maxdwell); + db_printf("\n"); +} + static void _db_show_vap(const struct ieee80211vap *vap, int showmesh, int showprocs) { @@ -532,7 +590,7 @@ _db_show_vap(const struct ieee80211vap *vap, int showmesh, int showprocs) static void _db_show_com(const struct ieee80211com *ic, int showvaps, int showsta, - int showmesh, int showprocs) + int showmesh, int showprocs, int showscan) { struct ieee80211vap *vap; @@ -679,6 +737,10 @@ _db_show_com(const struct ieee80211com *ic, int showvaps, int showsta, DB_PRINTSYM("\t", "ic_addba_response", ic->ic_addba_response); DB_PRINTSYM("\t", "ic_addba_stop", ic->ic_addba_stop); } + if (showscan) { + db_printf("\n"); + _db_show_scan(ic->ic_scan, showprocs); + } if (showvaps && !TAILQ_EMPTY(&ic->ic_vaps)) { db_printf("\n"); TAILQ_FOREACH(vap, &ic->ic_vaps, iv_next) @@ -707,7 +769,7 @@ _db_show_all_vaps(void *arg, struct ieee80211com *ic) db_printf(" %s(%p)", if_name(vap->iv_ifp), vap); db_printf("\n"); } else - _db_show_com(ic, 1, 1, 1, 1); + _db_show_com(ic, 1, 1, 1, 1, 1); } static void diff --git a/sys/net80211/ieee80211_ioctl.c b/sys/net80211/ieee80211_ioctl.c index 6fe39f588bab..674d163e3e67 100644 --- a/sys/net80211/ieee80211_ioctl.c +++ b/sys/net80211/ieee80211_ioctl.c @@ -2590,8 +2590,10 @@ ieee80211_scanreq(struct ieee80211vap *vap, struct ieee80211_scan_req *sr) sr->sr_flags |= IEEE80211_IOC_SCAN_NOPICK; IEEE80211_DPRINTF(vap, IEEE80211_MSG_SCAN, - "%s: flags 0x%x%s duration 0x%x mindwell %u maxdwell %u nssid %d\n", - __func__, sr->sr_flags, + "%s: vap %p iv_state %#x (%s) flags 0x%x%s " + "duration 0x%x mindwell %u maxdwell %u nssid %d\n", + __func__, vap, vap->iv_state, ieee80211_state_name[vap->iv_state], + sr->sr_flags, (vap->iv_ifp->if_flags & IFF_UP) == 0 ? " (!IFF_UP)" : "", sr->sr_duration, sr->sr_mindwell, sr->sr_maxdwell, sr->sr_nssid); /* diff --git a/sys/net80211/ieee80211_scan.h b/sys/net80211/ieee80211_scan.h index 4274f3948db6..a33864b102e2 100644 --- a/sys/net80211/ieee80211_scan.h +++ b/sys/net80211/ieee80211_scan.h @@ -147,6 +147,10 @@ struct ieee80211_scan_state { unsigned long ss_maxdwell; /* max dwell on channel */ }; +#define IEEE80211_SS_FLAGS_BITS \ + "\20\1NOPICK\2ACTIVE\3PICK1ST\4BGSCAN\5ONCE\6NOBCAST\7NOJOIN" \ + "\15GOTPICK" + /* * The upper 16 bits of the flags word is used to communicate * information to the scanning code that is NOT recorded in @@ -328,7 +332,7 @@ struct ieee80211_scanner { void (*scan_spare0)(void); void (*scan_spare1)(void); void (*scan_spare2)(void); - void (*scan_spare4)(void); + void (*scan_spare3)(void); }; void ieee80211_scanner_register(enum ieee80211_opmode, const struct ieee80211_scanner *); From nobody Wed Oct 4 15:23:40 2023 X-Original-To: dev-commits-src-branches@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 4S0z3w6VRlz4w6dk; Wed, 4 Oct 2023 15:23:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z3w5hysz4MpV; Wed, 4 Oct 2023 15:23:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433020; 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=cOM0k4kV4SvhZmqk7gObb3Kv6iv+MMZ2EtW4wIG2uMc=; b=lMVZU1piDiu6huzBXNZvfek/nOO9VIrEoEz8O4APkuCnt6+oE9gsHXpjkqWsoJBxeVmowN 7joeAHbGfeCTTfu+7E7LfmpEOx0bxwqUw/wFbaRdfJ+e8grN+0FWmZsV7LmgXOVfcdpMzz SD7arOwVmzfL9xO0FMfdeEr6xrsRB55FmwJurh3C1TwYITC9feLScHy5oV6+U86zQW8W53 sl5VVAXthJd415G1IWJ2az6hyvThzHuHgPI/yOBDrvEET4OWqXUI0SF32Y3ypyt8gm9W/U 61z9HKeYq8e1JJSEEJE6YgYMQU7t+954qlpEyxcya1s/RlONzV9T2RnHsYVYBA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433020; a=rsa-sha256; cv=none; b=SjxKEgev2zNP+fo1HVhoSMRJENFFqVB8btFsF+Drt2wnKZiq/V/ESP185GeehyuOkVjwqI KIhQ+MhV1kZbPeMmuVCgo40X/6sf+dYPadSYsBtMtky+vDJHni5m/AhiiF0M+we9+PexVV 1n4f8rqJEkZwYTBOf/LrbmkdUf/A3l9A7TdpOiRz4UC0DyvYg2pd/5JuoimLqiQF5BPsmS 1ySaMd43pAb/5qV52DXNyxBL3tKDvu2/y1k2vzredc//DrXkeJBXtBrJ2kaNKUhFCB3UG2 Q3JE6haz/Vmof6R1gPznn7iXsDu+D3PET0B6iUO4lIuHSODTQK1yClXS0f0tRw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433020; 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=cOM0k4kV4SvhZmqk7gObb3Kv6iv+MMZ2EtW4wIG2uMc=; b=jxQaERitG14LeKfIFYkuHPjzV07izpX9/LNnlCwK8khhO5yGpRvxQcPuILjEshjtm3and8 X3bzw7YYScQCWLlCC2Mk8ilUPjgtO2BAxHJwyp7Zu4JhPebrtG3jmUjqKnsMHGQ2j2r3fT 0D/LcaDa3HYpcnEAiy8+L1BsYEgMC35Q3QS+0J4g+SARsaz2MH6Q0l/I2LLLAl4GB4NKaY huLjQCoI9Q26k/ycavQKANeRWHI4yzbCHwLianUXyLWwRckYayYm/IYewh+Kr9D6gVuNS3 pNmH198sDtihyMpm2jg5pdQVK0is2iSLHRstQpKd/XGWCHVCXBZmWkaONYVdTQ== 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 4S0z3w4kf6zjSP; Wed, 4 Oct 2023 15:23:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNe9i086749; Wed, 4 Oct 2023 15:23:40 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNemi086746; Wed, 4 Oct 2023 15:23:40 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:40 GMT Message-Id: <202310041523.394FNemi086746@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 32d951c53f44 - stable/14 - net80211: mark argument to scan_curchan_task() __unused List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 32d951c53f443a4b7533b5f5099d464fa38f19a8 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=32d951c53f443a4b7533b5f5099d464fa38f19a8 commit 32d951c53f443a4b7533b5f5099d464fa38f19a8 Author: Bjoern A. Zeeb AuthorDate: 2023-09-14 17:34:01 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:17 +0000 net80211: mark argument to scan_curchan_task() __unused Mostly as documentation mark an unused argument to scan_curchan_task() as __unused. We may possibly want to check all callers in the future and see if the argument was supposed to be useful or should be entirely removed. Sponsored by: The FreeBSD Foundation (cherry picked from commit 778da03b1271f52051620ec9b053524727961c9e) --- sys/net80211/ieee80211_scan_sw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/net80211/ieee80211_scan_sw.c b/sys/net80211/ieee80211_scan_sw.c index ac97b7c14cbc..0aaa80a6c48d 100644 --- a/sys/net80211/ieee80211_scan_sw.c +++ b/sys/net80211/ieee80211_scan_sw.c @@ -674,7 +674,7 @@ scan_start(void *arg, int pending) } static void -scan_curchan_task(void *arg, int pending) +scan_curchan_task(void *arg, int pending __unused) { struct ieee80211_scan_state *ss = arg; struct scan_state *ss_priv = SCAN_PRIVATE(ss); From nobody Wed Oct 4 15:23:41 2023 X-Original-To: dev-commits-src-branches@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 4S0z3y109Pz4w6dl; Wed, 4 Oct 2023 15:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z3x6R1Lz4Mrt; Wed, 4 Oct 2023 15:23:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433021; 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=IdrQ8ZHkKO6Q39UEELiNEeDLpndMoh0zeRR7jwcD6eE=; b=rITh1tMNKURlIkf6p6zY0Qrppr0JoCDlb713sKpsxX/do9W6qUbc/NBEICeAQqc+tJux83 zi5YIDmLxZRcDWp4UqjVpKjPtQGFDCZh6TFqU5WQ1lw8/8NrRoHGM26JugajoBRWKz/oGR qbplxpyFnUMTcIYqZeXYbgWGPdYd+oeOcV6ismlNhFXwPqgKYiyxd3C0JfLWGNAp8CQCkX MNs/nGePNh7jKiwsd1X0QRDLUKyAxYjAxKm62hm7X3zzgOkmcTgPZjJEFhx8w60ByHgu4w adw4lPTYgs4E9TgjMZ2DUc0+1D3mDGtl/fc5KqS8Dkv1GPS8uamlyOBjAb2JmQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433021; a=rsa-sha256; cv=none; b=aelkf0b3LEivcyp8yLNIllGUs/9WA/cULtmUueNSuP1sjVdeu93vqzw1yaBba1AlnNXZtw xKozvWa/ucTr4KqqoEQX7+891bd+fTtgEaPMlj/mioxSOKd3CBT0jiwvFMaeYm7aJH7r2z 4BwxcqTiJDBfe1kilPbhFQCqWwDXrgzqmvr7JaO1DyzMHNcFANC+m/J1kuAGeqcL1dL4ss FjuCXoMk+2TTn4u3E/4YeMqJYZX3YbmfzivdyHTDeLCzInmf6UKaZpAwjTBW0Oxv5GvL94 yZzHxEgO6FxKV0XnWpkh2xoKzuPa3Z3+W8zTAlFHLIfUjV0NjeV9nS648Ukl2A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433021; 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=IdrQ8ZHkKO6Q39UEELiNEeDLpndMoh0zeRR7jwcD6eE=; b=AjcY7UbrzJx0Ms1W16CcLjdBqFrbfzNNGbJv/Yys8kPpRw798IOziQOh86VlzlEoUCjc7m jNK31/hL00KJTmve3UCB6uS7Flp87WM8yc74GmCipLcYQNePcVncaed+182ooLb+BLaLyf JVkYfQWTl5r3gRstL7TQ4OrX2RA8thXJhV6nqw1Ez258cmmwVUlOTaA8QYfPIyeUENHTJf faw+qU+pMAeEpizT8rV+CGS6wCKQ+6jBc08QXBxGVQVKfCSZBtxbDpzIE6Z9Bx7yCH/4Jm GzAP1Q57RzPy/cwSxsFco4ZRQ9DBw9GOoC0HN2EV0AALF6hNT0AQs/yrgn3Y3A== 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 4S0z3x5XSnzjBJ; Wed, 4 Oct 2023 15:23:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNfin086810; Wed, 4 Oct 2023 15:23:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNfr9086807; Wed, 4 Oct 2023 15:23:41 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:41 GMT Message-Id: <202310041523.394FNfr9086807@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: b011575ecd8b - stable/14 - net80211: improve ddb output for sta and rate List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: b011575ecd8b442d5f9d697ef88fed84f3c651ef Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=b011575ecd8b442d5f9d697ef88fed84f3c651ef commit b011575ecd8b442d5f9d697ef88fed84f3c651ef Author: Bjoern A. Zeeb AuthorDate: 2023-10-02 13:53:33 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:17 +0000 net80211: improve ddb output for sta and rate Add more missing fields to the ddb output of sta (including spares so people will notice if they use them to adjust ddb as well). There are still more missing fields (some left as reminder in an uncompiled __notyet__ block). Add _db_show_rate() to print iv_rate as well optionally including function pointers. Sponsored by: The FreeBSD Foundation (cherry picked from commit 4ed35b7d1eb5dddfd04f574ac122651d532d2df9) --- sys/net80211/ieee80211_ddb.c | 53 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) diff --git a/sys/net80211/ieee80211_ddb.c b/sys/net80211/ieee80211_ddb.c index 525814d202b1..e4a09a58049b 100644 --- a/sys/net80211/ieee80211_ddb.c +++ b/sys/net80211/ieee80211_ddb.c @@ -48,6 +48,7 @@ #include #include +#include #ifdef IEEE80211_SUPPORT_TDMA #include #endif @@ -327,6 +328,31 @@ _db_show_sta(const struct ieee80211_node *ni) ni->ni_vht_pad1, ni->ni_vht_spare[0], ni->ni_vht_spare[1], ni->ni_vht_spare[2], ni->ni_vht_spare[3], ni->ni_vht_spare[4], ni->ni_vht_spare[5], ni->ni_vht_spare[6], ni->ni_vht_spare[7]); + + db_printf("\tni_tx_superg[] = {"); + for (i = 0; i < WME_NUM_TID; i++) + db_printf(" %p%s", ni->ni_tx_superg[i], (i == 0) ? "" : ","); + db_printf(" }\n"); + + db_printf("\tni_rctls = %p", ni->ni_rctls); + db_printf("\tni_drv_data = %p", ni->ni_drv_data); + db_printf("\n"); + + db_printf("\tni_spare[3] = { %#jx %#jx %#jx }", + ni->ni_spare[0], ni->ni_spare[1], ni->ni_spare[2]); + db_printf("\n"); + +#ifdef __notyet__ + struct ieee80211_psq ni_psq; /* power save queue */ + struct ieee80211_nodestats ni_stats; /* per-node statistics */ + + /* quiet time IE state for the given node */ + uint32_t ni_quiet_ie_set; /* Quiet time IE was seen */ + struct ieee80211_quiet_ie ni_quiet_ie; /* last seen quiet IE */ + + /* U-APSD */ + uint8_t ni_uapsd; /* U-APSD per-node flags matching WMM STA QoS Info field */ +#endif } #ifdef IEEE80211_SUPPORT_TDMA @@ -403,6 +429,31 @@ _db_show_scan(const struct ieee80211_scan_state *ss, int showprocs) db_printf("\n"); } +static void +_db_show_rate(const struct ieee80211_ratectl *rate, const void *rs, + const int showprocs) +{ + + db_printf("\tiv_rate %p", rate); + db_printf(" iv_rs %p", rs); + db_printf("\n"); + if (showprocs) { + db_printf("\t ir_name %s", rate->ir_name); + db_printf("\n"); + DB_PRINTSYM("\t ", "ir_attach", rate->ir_attach); + DB_PRINTSYM("\t ", "ir_detach", rate->ir_detach); + DB_PRINTSYM("\t ", "ir_init", rate->ir_init); + DB_PRINTSYM("\t ", "ir_deinit", rate->ir_deinit); + DB_PRINTSYM("\t ", "ir_node_init", rate->ir_node_init); + DB_PRINTSYM("\t ", "ir_node_deinit", rate->ir_node_deinit); + DB_PRINTSYM("\t ", "ir_rate", rate->ir_rate); + DB_PRINTSYM("\t ", "ir_tx_complete", rate->ir_tx_complete); + DB_PRINTSYM("\t ", "ir_tx_update", rate->ir_tx_update); + DB_PRINTSYM("\t ", "ir_setinterval", rate->ir_setinterval); + DB_PRINTSYM("\t ", "ir_node_stats", rate->ir_node_stats); + } +} + static void _db_show_vap(const struct ieee80211vap *vap, int showmesh, int showprocs) { @@ -569,6 +620,8 @@ _db_show_vap(const struct ieee80211vap *vap, int showmesh, int showprocs) db_printf(" lastnonerp %d", vap->iv_lastnonerp); db_printf(" lastnonht %d", vap->iv_lastnonht); db_printf("\n"); + if (vap->iv_rate != NULL) + _db_show_rate(vap->iv_rate, vap->iv_rs, showprocs); if (showprocs) { DB_PRINTSYM("\t", "iv_key_alloc", vap->iv_key_alloc); From nobody Wed Oct 4 15:23:42 2023 X-Original-To: dev-commits-src-branches@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 4S0z3z1yqTz4w6QT; Wed, 4 Oct 2023 15:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z3z0LbYz4Ml0; Wed, 4 Oct 2023 15:23:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433023; 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=dqgSCC54bhwHJNsif5Asp6eR+o+y7caihu6+wWcXrtc=; b=FcmliHtghKWXAdbErukTYeNeGNgSs3LGOzI1rDodH6O/fxG+wNPyUeU+jcvkX85D5xSaZI 5gAHWGxyNW3BqHtioK3VxbWTkK5tsGWXPxlEAuRgKsdkMRxw1I2nQe8MkEE8iMb3mn2Hfj sAbPYB+M8rMdUi4dlLlBRPY7u+y/Z1XtQLepYJ6UhwXFKPoz4pNV1PhE1LKRVlxU8CKExt fRMVPtM2/Kmez8VxyJvd+ijdOBFBdB61lW9pAuoJkbh6dqlC2ciQ11+hssGglKUnJJ8YjO bdsrrJ5n28TPiR5E8SAnxHsn/+1RfW9xa28Xx6NgJzwHPgIsSyLTMkc+SfGuZw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433023; a=rsa-sha256; cv=none; b=WpvPFeBGEEYEFk0Nvd3zgo7ABaC0/mZVlwrHVAygzSDSF3aUsTVWBHl1m9DhisWOQ0G4ur +1rjmoI18m2in4ouw0Fc+4QhcJps5o4/PAlXHaoU3osRhhC+6rFqzV54SXiZupGWDyizXc F03dLc6JIN2ivegc5hay2/ozg0e/WwLtfgb1UeS3ypZIZ/CSfujC3pjSxXa0w8U08awOJ0 z04cmrlQvRPwhCGiohZmyEIzY5H20/K/a0UsiNnLrygo6CG7WhVERCkqYiN05MxWHkGLhF beyzj7ZbdosQgWuKmgRVCO35TOWQ7vYLG7+j3oxnN/KDxdmqPzW8N+aX2afb3w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433023; 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=dqgSCC54bhwHJNsif5Asp6eR+o+y7caihu6+wWcXrtc=; b=OmauEb8JdzI10K5LcazLlB4eQ4gvPhS98WjY3nqGXRVvBnJZ3l+acXk8m/kS0pvMaI8wYn pJPjWJa5G90FlbggAXTd5zEjE238gsVEwtHth35tSVa7KKz5YUF1luhNjwHNXMFD6jI3st A7H9JFqdKdUKvds3nCI3zlom8DsUA3EEX3aPvwBpXol5ET8l8He1YvonlbMb77ga9tx/LR o0zFkQd4YcbALdlkMTTye6mFTQxblau0TvZgRnnOD1lWMMl31ggurVuMorpWu5IzUJHV26 NG+DS7Eucs384uFOjarvIlqwWDM1gaR3r4ft/eHT3TfkGS+Ve2DI74yl8jHBdw== 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 4S0z3y6YgLzjVJ; Wed, 4 Oct 2023 15:23:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNgLK086855; Wed, 4 Oct 2023 15:23:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNg8A086852; Wed, 4 Oct 2023 15:23:42 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:42 GMT Message-Id: <202310041523.394FNg8A086852@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 6104a9f9c520 - stable/14 - net80211: introduce two extra ieee80211_notify_scan_done() List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 6104a9f9c5206c9ba23eec29217dff642f26722c Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=6104a9f9c5206c9ba23eec29217dff642f26722c commit 6104a9f9c5206c9ba23eec29217dff642f26722c Author: Bjoern A. Zeeb AuthorDate: 2023-09-21 11:51:23 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:18 +0000 net80211: introduce two extra ieee80211_notify_scan_done() We have multiple problems with scanning currently, one being that an initial scan restarts itself and we are unable to start another scan. wpa_supplicant in that case never shows scan results. Starting wpa_cli you may see: <3>CTRL-EVENT-SCAN-FAILED ret=-1 retry=1 messages. Add two extra calls to ieee80211_notify_scan_done() at the end of scans (before possible restarts). That will get wpa_supplicant to get scan results and possibly start associating to a BSSID and get us out of scan. This is kind-of a bandaid but on short notice may help to improve the situation for some. Based on analysis by: enweiwu Submitted by: enweiwu (initial version) Sponsored by: The FreeBSD Foundation Tested by: cy, (others I cannot find email/PR for anymore) Reviewed by: cy Differential Revision: https://reviews.freebsd.org/D38661 (cherry picked from commit 3f382eb23b9fee75d05276a44feb5351d956238e) --- sys/net80211/ieee80211_scan_sw.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/net80211/ieee80211_scan_sw.c b/sys/net80211/ieee80211_scan_sw.c index 0aaa80a6c48d..62f6bf24d42a 100644 --- a/sys/net80211/ieee80211_scan_sw.c +++ b/sys/net80211/ieee80211_scan_sw.c @@ -388,9 +388,10 @@ ieee80211_swscan_bg_scan(const struct ieee80211_scanner *scan, * scan_start method to populate it. */ ss->ss_next = 0; - if (ss->ss_last != 0) + if (ss->ss_last != 0) { + ieee80211_notify_scan_done(vap); ss->ss_ops->scan_restart(ss, vap); - else { + } else { ss->ss_ops->scan_start(ss, vap); #ifdef IEEE80211_DEBUG if (ieee80211_msg_scan(vap)) @@ -857,6 +858,7 @@ scan_end(struct ieee80211_scan_state *ss, int scandone) else vap->iv_stats.is_scan_passive++; + ieee80211_notify_scan_done(vap); ss->ss_ops->scan_restart(ss, vap); /* XXX? */ ieee80211_runtask(ic, &ss_priv->ss_scan_start); IEEE80211_UNLOCK(ic); From nobody Wed Oct 4 15:23:43 2023 X-Original-To: dev-commits-src-branches@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 4S0z401tFBz4w6LX; Wed, 4 Oct 2023 15:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z401M25z4N1H; Wed, 4 Oct 2023 15:23:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433024; 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=9DfLnf+PLEa86eARgEDePZua4X/MnV1hiaQeNuE5A0o=; b=cRUMDhBvS2WPfh/56+uHKBnnOwvi9V+/DwRIPGBbq6XZ7pm2wZale88rAUyntCzYnPqms0 DxwYs3Abaz8Q+DN2QzG44Fq4g6m1GAb5W8I9F0dNh4sPp8y32qvHlISHie9CR94qFMizyF +BEyANSUY9+SKOE9ySKxYjXLWPOqq/b4n/2Y6bAaKqRtm2kA/j+NChVZbsj7V2vPeCxP+3 RSwDQNIRMzOjp8BodLOhRuKeeQAbrHgwEfYjD35PASrWZcdAkfKOi8uDZkDHbLuhOdjNVO 1OYFksClQ8WI+5bo6wpZyuVrIb79WIXcLX3FVYy8oJc8HJKm9n5fMwWFaHuw9g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433024; a=rsa-sha256; cv=none; b=CRtYNkdAxDIFYcJdaVknmMlbyfgbTUH7HUQk2P4dseBsowAU1beLuqG1t6feU5TOjHmnkf jlxUkqcJ4baFwxhLYClbIkGwcLpF/ChFESjXJejnRQyZnHQtothR7JL5Z23nC1i5AkMo49 7dT3YhNNn+Yq0J4JiUOKn2amO21K3ZjI0jnmjyrP31+xSUxxhuYw7AoS5+OH7LF9tcit14 sScDYTViDHfqa+44kQdP2Mlf+jHPq7m/x5corBzs9/NFvjm6hItvxWQZArxZeqpr9Vyh8p ABUXYMMrtzryCRN9haWZ06D/XKxEReb8e3UnObv5d9X3nvbnlLcTGJaPATc/jQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433024; 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=9DfLnf+PLEa86eARgEDePZua4X/MnV1hiaQeNuE5A0o=; b=L23gM2HHW/O2kjKGXYpEkdDQCAEDHp+N+2G6/siTA8JRqMAZNzj1j9VG49H41Y6o6T5Fc6 wvWjyMoXrsezI/ATIxM1jJHZ08nHlCmlncggyLr7Mu+S3jPpdXvPaMEz8EA1g03ws3txVS Z0UtZm2CsXWEbptlRW2HIQ03xEdfQP/A6yis9/w/3mnVRF2GHXXywZFxx0IOUZy3HptW8C B9ememwXQPN3ZXp/O6Q7s2aHkpV5MqbTTqoyjEjU/XUuC2Lm0HNRvoTKcUfPre45wqtThP p93kgCB2LPwxhuuzzn7x6WtpiNC/FKNvnUwAY5FamAwOdkSfcdJLFEOEdnr+5w== 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 4S0z400RYBzjmC; Wed, 4 Oct 2023 15:23:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNhqm086903; Wed, 4 Oct 2023 15:23:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNh54086900; Wed, 4 Oct 2023 15:23:43 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:43 GMT Message-Id: <202310041523.394FNh54086900@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 46e5d2b0c6e0 - stable/14 - LinuxKPI: skbuff: remove assumption about mac_header List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 46e5d2b0c6e01fd0789a6ef543c8b9f52852301b Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=46e5d2b0c6e01fd0789a6ef543c8b9f52852301b commit 46e5d2b0c6e01fd0789a6ef543c8b9f52852301b Author: Bjoern A. Zeeb AuthorDate: 2023-09-08 12:47:03 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:18 +0000 LinuxKPI: skbuff: remove assumption about mac_header It seems the mac_header can be set to offset 0 for frames received. Remove the warning splattering messages to the console for each packet. Sponsored by: The FreeBSD Foundation (cherry picked from commit f0e59b6903c881859d7f4eaf269b2336b774c7bc) --- sys/compat/linuxkpi/common/include/linux/skbuff.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/skbuff.h b/sys/compat/linuxkpi/common/include/linux/skbuff.h index c917b3f09ac9..f8ce212e7853 100644 --- a/sys/compat/linuxkpi/common/include/linux/skbuff.h +++ b/sys/compat/linuxkpi/common/include/linux/skbuff.h @@ -935,10 +935,9 @@ static inline uint8_t * skb_mac_header(const struct sk_buff *skb) { SKB_TRACE(skb); - /* Make sure the mac_header was set as otherwise we return garbage. */ - WARN_ON(skb->mac_header == 0); return (skb->head + skb->mac_header); } + static inline void skb_reset_mac_header(struct sk_buff *skb) { From nobody Wed Oct 4 15:23:45 2023 X-Original-To: dev-commits-src-branches@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 4S0z415Ws3z4w6Gl; Wed, 4 Oct 2023 15:23:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z41425jz4N09; Wed, 4 Oct 2023 15:23:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433025; 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=QFPv8hV7J9GIFiK8Y4UBLNCaogaNWuT5VniC+tvsi00=; b=XGq2uzbm0llfI0zGNlx/tfHOUXc/QJcLIBgR1YSMo3v34EgV4m1WhgimmpDBrpaN+xLhhx BmSVvaA3bgnaC1cqtQsXkhEwgWpB8q5nuX7JxsY0jpcj6VZiiaWCPK1fODxfo8LYpIjNfh UcfrTMyRZh1BzmH1xS0vKCItgvKhkECDet4brxaNVSwza2gtCIlQUdyQ4GMSkNVBuAHAEM Z869pVMe43ZmvE8XMovNpFZqm6cMDSVhtV2aHy77H+3feZWuP9n3iiZ1LfiHODUM17KxQY SrQUUbuPwOGIN524SkDktgx3RqcSNZn9hL/MNhwv+hWOi+81nvM/T1iuT+238Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433025; a=rsa-sha256; cv=none; b=Q0RGUB+Q26IizoOhp2NrlwAcoEw3DtEwWZNPnmRsDbpeZkar7P7OqRsWoCUcDBgz/BaLFO FxQ5bgu98uos1HUQ598cY/O9kOp3kqiFGKuHtOe5Wq2jMRHqk4WlFziAiUhpfpxdiM0Ejr SeUihBj3CXLT+Sf+wPg2ae/pBM/+3WVOMyLeyEAp/Oaulb2u1DkIpc/Xw2yjPRCFm55CeN mvKObdWTW20lt3xLJIcwk0emK9RHivXE3vkd+KNfKOF8/vTHmxwk3Ga95FYkaVYSLrGSj2 qEtU8pR5cPxd34LNUcBfnOLkD4PIhCCAk/FuD7XFFeFPFDcOt7YNlhvJ4yLo1g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433025; 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=QFPv8hV7J9GIFiK8Y4UBLNCaogaNWuT5VniC+tvsi00=; b=RmDr2BwLmGfp5H5rrKkD5hz5c9ceweF5Zb6G5xdFhSqEy0ccY7G1pBjzvlCVcwA3j+xtfR 4tM+UZO0MrpPoVJQBDE8yCS0KRv9ZRShHoloJzSUep5ZZ23i6o1GNmGtee8CaskYBYlT+v ULbT1PN5tGwQ+CEuRtZHTF3xuwD5seBaCKFgiSLzQazNuQrV20tblJ6HZcOOt4rMlH2xk9 96K0EoXXuadUSaQIryikMJ5xRUzF7IwAL3UpITR1ZbHznFTOrCMO3NzFDKOljT29gtQO6S hAcTOBBlTYlxcvtJi8cfQKisxlv+90Da5U15cQMTC5bskhk2sywez9LpDvdeeg== 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 4S0z411YFTzjJf; Wed, 4 Oct 2023 15:23:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNjsE086963; Wed, 4 Oct 2023 15:23:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNjmq086960; Wed, 4 Oct 2023 15:23:45 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:45 GMT Message-Id: <202310041523.394FNjmq086960@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 204fb7d8530e - stable/14 - LinuxKPI: 802.11: make sure bssid for scans (probe_req) is set List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 204fb7d8530e6c097ff0142959a3f7d55cf7e375 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=204fb7d8530e6c097ff0142959a3f7d55cf7e375 commit 204fb7d8530e6c097ff0142959a3f7d55cf7e375 Author: Bjoern A. Zeeb AuthorDate: 2023-09-14 17:48:19 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:18 +0000 LinuxKPI: 802.11: make sure bssid for scans (probe_req) is set In b0f73768220e9 we added bssid[] to struct cfg80211_scan_request likely while working on mt76 and did not need it (yet) back then. iwlwifi started to use the field in Linux f1fec51cda70f (April 2023). Without it set firmware crashes when trying to send probe requests ((empty) SSID also given to hw_scan). For now always set the field to the wildcard BSSID. Sponsored by: The FreeBSD Foundation (cherry picked from commit e1e90be05017c335862c938fd9d577e56f02af30) --- sys/compat/linuxkpi/common/src/linux_80211.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 51d5bc2c4fc1..4b9cc598740b 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -2728,6 +2728,7 @@ sw_scan: memcpy(hw_req->req.mac_addr, xxx, IEEE80211_ADDR_LEN); memset(hw_req->req.mac_addr_mask, 0xxx, IEEE80211_ADDR_LEN); #endif + eth_broadcast_addr(hw_req->req.bssid); hw_req->req.n_channels = nchan; cpp = (struct linuxkpi_ieee80211_channel **)(hw_req + 1); From nobody Wed Oct 4 15:23:46 2023 X-Original-To: dev-commits-src-branches@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 4S0z425PZyz4w6Lh; Wed, 4 Oct 2023 15:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z423NVpz4N22; Wed, 4 Oct 2023 15:23:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433026; 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=0KRc3ZZrm/ueSzHHT9qjr+dNFrf+Q6yPrbw8FI4XsIY=; b=WtFnqD+UnTCoDkndcMlIitax17w2C0DAMp3Ybh2ELISbWKaDYk/oiH+VYRT7gO0TjXOgdf iVZmYycZSBLpUlmlzmky2Y9EIYCBjqx5D+kKtULJfuDB3Y56B1rxxBmN1EloEVXWt5ZSa7 8+cWriRcY5aFBSOBTloi7bkLmBoWKx0SZJJ6uQR4aYpadQSe6ptWVzSLRKv5rjw5PpxTjM uC9EYpiaQBLGiAr5PdenjvK5goB2rbCrGcpH0yBZZLwcKTYmf6lyQxj4XvQZqu6YzOtui/ Rjco/p5YEHecer5oiz8rbDII8VdJg5T0EwIDBfUcARnNXaXSV2C0ZYUQuX3C7g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433026; a=rsa-sha256; cv=none; b=eZGrsCrZl5fU0gGUoXQm0FD4Obi7jxNgjJXdQD5k72nR4jugZY528mVYEVxmj72BBf4+aA KLTVnKvsvnQpwK+Ll7SHVPxqyTK2k1tGSHzWJZCGLStwwSPxZoNxmBjRV8QsVF0V1BY3Z6 a76TL4T8Rz2oPjspC+djmCc3cTcDrQnt7pjUxACYlAhb/VMXdrXqmJgh3/80kksuD/unAa OUZ4QPAAZAixHdqKBAmT+eBshXHYiKDR7IpQE9GhL29OoRArkfXCISzSK2f339YRLxa4A8 Oiy3SJkmoEPy/2ptk/FX7ps/hSjoumdSdLr95qPT963EQfgM1WkqN7DKXyn1iQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433026; 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=0KRc3ZZrm/ueSzHHT9qjr+dNFrf+Q6yPrbw8FI4XsIY=; b=glmn+f9T29hpmqXLA5yVgCn3Pf/LrUczGyUtQrLH4s6U/pA8i5iIHL2PGhOQBG1SOx8cUY bSgqB0N0C9yT2/kABMhFcWwxVYTSPtzDgMhO+mGaYQD6RY0n5I9X+InnNHycwTG9PhgO0n 65OVP4YBYOOpCPs18GLuVe7OWFzrDmRcfSAvapuz2mHf2E8/mCSdyp8RZjXcsx3VKqZT1S Mi7ghjF+as8FlyUXjRTOUtPj2fwIXqFdUSHOVNa6cL9+u0k2AWCYlmVpsEbw/I7t4AYZ2C ///3e66mJJn7u7E4L0bCoy4BEJrNmDG4EgqSgG6ThBmSkrT/5wacP19LqaPI2Q== 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 4S0z422VSCzjdQ; Wed, 4 Oct 2023 15:23:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNksc087012; Wed, 4 Oct 2023 15:23:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNk6n087009; Wed, 4 Oct 2023 15:23:46 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:46 GMT Message-Id: <202310041523.394FNk6n087009@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: a513f65b92b6 - stable/14 - iwlwifi: fix a bug in iwl_ssid_exist() List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: a513f65b92b672830c89acfa04b93c3b77d3f97d Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=a513f65b92b672830c89acfa04b93c3b77d3f97d commit a513f65b92b672830c89acfa04b93c3b77d3f97d Author: Bjoern A. Zeeb AuthorDate: 2023-09-14 17:22:04 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:18 +0000 iwlwifi: fix a bug in iwl_ssid_exist() Rather than always comparing a given SSID to the first SSID of the IE list, compare it to the the iterator one. That way duplicates can be found. Sponsored by: The FreeBSD Foundation (cherry picked from commit ee7077f24f5b02bde8cf5c202848128f18733398) --- sys/contrib/dev/iwlwifi/mvm/scan.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sys/contrib/dev/iwlwifi/mvm/scan.c b/sys/contrib/dev/iwlwifi/mvm/scan.c index a4077053e374..8c5d6860914b 100644 --- a/sys/contrib/dev/iwlwifi/mvm/scan.c +++ b/sys/contrib/dev/iwlwifi/mvm/scan.c @@ -447,7 +447,11 @@ static int iwl_ssid_exist(u8 *ssid, u8 ssid_len, struct iwl_ssid_ie *ssid_list) if (!ssid_list[i].len) break; if (ssid_list[i].len == ssid_len && +#if defined(__linux__) !memcmp(ssid_list->ssid, ssid, ssid_len)) +#elif defined(__FreeBSD__) + !memcmp(ssid_list[i].ssid, ssid, ssid_len)) +#endif return i; } return -1; From nobody Wed Oct 4 15:23:47 2023 X-Original-To: dev-commits-src-branches@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 4S0z435JcTz4w6Wt; Wed, 4 Oct 2023 15:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z434C72z4NFP; Wed, 4 Oct 2023 15:23:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433027; 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=WJat4+HeVrCMHUFygXH4Zz/mcS2FHQtDBujj8TFzIzc=; b=jxJG/2+P7bVpU2ec+9uB9g9V+qaw+jL+NwJqjLuqqIkC2EUhInzpyaG16OnbzPafhoGyvC qLf0KgxIHiWXKPWiGsTuPKsjylA+1fSEyyW/IWcA5Dt2O46u1wfFi+tOzIkcnTI1svg3ZX yUBRlnKlFrkBRSQldCSYMugOB687/t9sgTuG9o1EVqqD0GwpwYRetZXN36sgbv1DFb1okU cfMSPZ24iNe8Ap/upzWpAmOyzwZyPFUsV+Su9O5dFfYdupYvnj0omYAaPSnRrqz3KqsH2x YbOkTA0kCXwadgN0NB5SiqYYmE8MmrzIfECstbA3x9c40XB5ssW/+U2FReYd2Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433027; a=rsa-sha256; cv=none; b=F29f4raWkiMkzk/MORyV0WUqUmaaJ0+sX8AOjD3h1E0rKmQKa23IAP4LDap9VRuNOIk5DG kzx+zUJw8UnMEFTqRK22Ta9tHxl1zq81mHBBc2Sj6wYi5X4sOSVYVjwYDOnAQNjbCAMu3r ympPw4wgqu3ScddlxCpbSwWpU3BSuF7fwSKCOrUSYRBPAphh4XkqHEua2rsZdsentTjhdY u4+SEWbW80TTtcy51yM/O2ByRqsTF6M8wmbOhv+0QtGMOShg3/xqIwuMSOzVcapXLOqURJ lTgFgOSQ6yaCnQ4DMYM0UuRxkQRCHLhH+NzfdLnXwdNxtgAq8XFTY2p3e0nSDQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433027; 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=WJat4+HeVrCMHUFygXH4Zz/mcS2FHQtDBujj8TFzIzc=; b=oKSxNlWa9Ak/TkTxRvZ0PZJWD/FkWAgex9L83JpHGsDcKg2HA181z+WK7vazRssd8B5SOC yw1i7bZKfoDHZpOMInWUevw2tqtn/OeNChXzABUyf9zl9hJW0osX4Rn7SFrhGppm53kLGz iyi/mnqhnIA5gOQyJJR2OOmqZQVphbob3575nRtbPDXnAh0l1cU/iq9rtjqTf1eYEA2DrL js3BjBIO91QoNsuSQUPJO5B0LkvOlwmEpNaBx/8vEyZbK4FbPyvl/Z5iCL+T2lgMDSHQsU WZCtJoD2peZ3SMszGcHM+9sf2w+ASDqpI+gRRx0zWZ2EPAYcuQdSAfPsTjqcAA== 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 4S0z433Hd6zj7X; Wed, 4 Oct 2023 15:23:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNlJH087073; Wed, 4 Oct 2023 15:23:47 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNls2087070; Wed, 4 Oct 2023 15:23:47 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:47 GMT Message-Id: <202310041523.394FNls2087070@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 96655d8a7db4 - stable/14 - LinuxKPI: 802.11: fix counting the number of supbands List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 96655d8a7db48f0944aebf07ffdcaa8a23aaa35a Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=96655d8a7db48f0944aebf07ffdcaa8a23aaa35a commit 96655d8a7db48f0944aebf07ffdcaa8a23aaa35a Author: Bjoern A. Zeeb AuthorDate: 2023-09-14 17:57:53 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:18 +0000 LinuxKPI: 802.11: fix counting the number of supbands While the main purpose was to assign an(y) early chandef with the loop, later additions made use of it to also count supbands as well as to initialise max_rates. Due to the main goal we can exit the loop early and not properly count and initialise supbands and max_rates. Move the terminating condition into the loop and make it a continue rather than ending the loop. Fixes: d9945d7821b9b ("improve hw_scan") Sponsored by: The FreeBSD Foundation (cherry picked from commit f454a4a10dc027474a85269cb4a3f50bbbf90528) --- sys/compat/linuxkpi/common/src/linux_80211.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 4b9cc598740b..cb919bfd3f5b 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -3760,8 +3760,7 @@ linuxkpi_ieee80211_ifattach(struct ieee80211_hw *hw) * in any band so we can scale [(ext) sup rates] IE(s) accordingly. */ lhw->supbands = lhw->max_rates = 0; - for (band = 0; band < NUM_NL80211_BANDS && - hw->conf.chandef.chan == NULL; band++) { + for (band = 0; band < NUM_NL80211_BANDS; band++) { struct ieee80211_supported_band *supband; struct linuxkpi_ieee80211_channel *channels; @@ -3772,6 +3771,10 @@ linuxkpi_ieee80211_ifattach(struct ieee80211_hw *hw) lhw->supbands++; lhw->max_rates = max(lhw->max_rates, supband->n_bitrates); + /* If we have a channel, we need to keep counting supbands. */ + if (hw->conf.chandef.chan != NULL) + continue; + channels = supband->channels; for (i = 0; i < supband->n_channels; i++) { From nobody Wed Oct 4 15:23:48 2023 X-Original-To: dev-commits-src-branches@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 4S0z446LWlz4w6hb; Wed, 4 Oct 2023 15:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z4459QXz4N7k; Wed, 4 Oct 2023 15:23:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433028; 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=TvcVcLH6dVp7+ffpTcZ4WW0eQX+ru0Xdlt7B2+HSJQI=; b=DDe3QEIVP+WOhBuGg77vqJy84wKLYiwgn66luZ2NIzcpi629IWoAZ49HSzP4b75RdyyKAz zCjv7Oimd/7y6agg4KX8IZeeCwZ3lNQPAXXfDok4MC8cFhQEf4aMwgtnpl9mDBVH7VGvLA 6ZuLPJOfbyJvsJSRvYnM/J48QPcw56k15IP50NznHUGOUgM34PI93jEH8CHPDeg1W9CZCl TIzQRt+CNqhvjSVeLJcFs6xs+LFl9Fh3T9ZsyJnO1X0f+FoRSqE5J6QXcVKjjA8BIe40jH 3V4D9mziEWpwRYrRvAPgcw01qclXJ7/vsHJewAubm47cOGj8K3tuoXEaDg7m5Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433028; a=rsa-sha256; cv=none; b=GINE3ylkQJjg3Ptx7nleChhngCh8Pf7FAur6pBw6Hx1Z7EZh7aBng5WD4dnoGCPjTsKyex XolSCXkFrDrmKfxFCmIXsQeXKTQPdkdFWf1v/mhhBf2yb4FaTmVlkS8ulAnvGvbVYFOzLM mTZ/2K8iNcXgceVFY67RQ8/oZOaJR8zGhIs0a9R3GcpWtFTisWTF0mRFENg1lPep7+XyCk 07aM2yBcZFLnzdB7vnmhYwZ3ZO+75y9VC94T2yXa7jkGZ0RRw2VwhWal2DrWh4QAf5MZZM BQH+4VnxIoVCUCj8AQs3agMHExCJkdrsn1CQGL/jb/UWS25rGJg+LZVe/dbavQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433028; 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=TvcVcLH6dVp7+ffpTcZ4WW0eQX+ru0Xdlt7B2+HSJQI=; b=DINxSaN4uuttyWAuw/vxggqoMFWi6gzy7YP4MxGN+kWP1KOF/SCT34+3/Sez4DmAZTXILI xYLLB+udk1o8kpPimffyoGv2MW3KY/F5En4AHUeWFhBF6KB39xibkPM2Ou2e+2dC16mjU7 RgcWjNJMQzdF25zL0fZ189jHLCpTGk0g/1zaGWZDHgQmdrCllVr6HyS/Vk0UBamjQcN/fV l4r6W2V1ziexcWzjOa4MLi+69LXGR2t6ezKvwe/oI/OQbqCxuv420fUEFSxZbFsHFrd0pU RWyakM2TUsd5PUT2l96yUqrIJCqo8y6q9WD406anrwbQXK0zo40rAljYxbt+ZQ== 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 4S0z444G62zjdR; Wed, 4 Oct 2023 15:23:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNmqQ087129; Wed, 4 Oct 2023 15:23:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNmu6087126; Wed, 4 Oct 2023 15:23:48 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:48 GMT Message-Id: <202310041523.394FNmu6087126@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 493d6255434c - stable/14 - net80211 / drivers: remove public use of ieee80211_node_incref() List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 493d6255434ce70ea99b1ccdbea5c88169013bd2 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=493d6255434ce70ea99b1ccdbea5c88169013bd2 commit 493d6255434ce70ea99b1ccdbea5c88169013bd2 Author: Bjoern A. Zeeb AuthorDate: 2023-10-02 14:44:29 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:18 +0000 net80211 / drivers: remove public use of ieee80211_node_incref() ieee80211_node_incref() is the FreeBSD implementation of ieee80211_ref_node(). Not being interested in the node returned it was used as a shortcut in 3 drivers (ath, uath, wpi). Replace the call with the public KPI of ieee80211_ref_node() and ignore the result. This leaves us with the single internal call going ieee80211_ref_node() -> ieee80211_node_incref() and that should help increasing portability but also limiting the places to trace for node reference operations. Sponsored by: The FreeBSD Foundation (cherry picked from commit f156cd892b55c04a39fa06d1899e6e316de77f03) --- sys/dev/ath/if_ath_tx.c | 2 +- sys/dev/usb/wlan/if_uath.c | 2 +- sys/dev/wpi/if_wpi.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/dev/ath/if_ath_tx.c b/sys/dev/ath/if_ath_tx.c index 1fd3adef738e..69d0b5c00848 100644 --- a/sys/dev/ath/if_ath_tx.c +++ b/sys/dev/ath/if_ath_tx.c @@ -288,7 +288,7 @@ ath_txfrag_setup(struct ath_softc *sc, ath_bufhead *frags, ath_txfrag_cleanup(sc, frags, ni); break; } - ieee80211_node_incref(ni); + (void) ieee80211_ref_node(ni); TAILQ_INSERT_TAIL(frags, bf, bf_list); } ATH_TXBUF_UNLOCK(sc); diff --git a/sys/dev/usb/wlan/if_uath.c b/sys/dev/usb/wlan/if_uath.c index 378dd717a3eb..04190821d9b9 100644 --- a/sys/dev/usb/wlan/if_uath.c +++ b/sys/dev/usb/wlan/if_uath.c @@ -1657,7 +1657,7 @@ uath_txfrag_setup(struct uath_softc *sc, uath_datahead *frags, uath_txfrag_cleanup(sc, frags, ni); break; } - ieee80211_node_incref(ni); + (void) ieee80211_ref_node(ni); STAILQ_INSERT_TAIL(frags, bf, next); } diff --git a/sys/dev/wpi/if_wpi.c b/sys/dev/wpi/if_wpi.c index c9c2a8f6854e..5ceb037803b8 100644 --- a/sys/dev/wpi/if_wpi.c +++ b/sys/dev/wpi/if_wpi.c @@ -2768,7 +2768,7 @@ wpi_cmd2(struct wpi_softc *sc, struct wpi_buf *buf) ring->pending = 0; sc->sc_update_tx_ring(sc, ring); } else - ieee80211_node_incref(data->ni); + (void) ieee80211_ref_node(data->ni); end: DPRINTF(sc, WPI_DEBUG_TRACE, error ? TRACE_STR_END_ERR : TRACE_STR_END, __func__); From nobody Wed Oct 4 15:23:49 2023 X-Original-To: dev-commits-src-branches@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 4S0z460pZYz4w6Gt; Wed, 4 Oct 2023 15:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z456w8jz4NLt; Wed, 4 Oct 2023 15:23:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433030; 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=UQAlD/10d3EQPdvWY9Y/KRD39Tfw1tJ6b3eJzxNCIPw=; b=ByQVeRx6O6jXczpzxQdAjhiA4Y4hjoNByYVBMYV4bO957IiacbrSiU4NLZKRbHjzmhMmgP yNUKEFO7QeVVlu8b52zEeF96FjRAbdwRra4l0n/G3KlydamYzThiOomCGlnyTDjYzEnwRi PlZhzoHfi2++3hLqtXVZ3lb5QO5dCNR+qDeHCjazINoR+zSUC5u0x/Ify3BAzSjapBf3nT 2CaGi+kf8bGhku9wBnGyHNwUcVVbsHqmKVcaeHinzsqbZ1WZmDRyTAPD6py1+gMUMTsP/Y quHekKX6U8tu9NTI3sZ95EAQ1++MGrXTDpUDACT+fCiKDY68LmJI4/bwdAHZCg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433030; a=rsa-sha256; cv=none; b=dq3InMsoorfbSGprscE+8/FnFAvETT7tCTjRt7sfFZ0i6Htkl83wVDBIIb/7AHOjU+Ql6y h19HQFKHNAejE2agG4UeGI2N4qLAPZbSK09YYFnEBgAz9N/w9Od9Q9a4mLRNvv+ggYTTFh URY5wDQZmlSRpwOdwIkGHUSv9FP+2cjiHvckUDUh68u6ZuHnSBfpT4/kZRwhpK3WNccmVH Ew43LYu1NGmzvpglBsH+03VMqskmj7LA6M0b+IeShnUrH9aNPREayrexlCGZhhVFsnCZLD uVUhthiVoTuzYQOsa6N3cbllaT+/HHK9bwPH94pmjT70Ynwq+jH+tKAt8gOuNQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433030; 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=UQAlD/10d3EQPdvWY9Y/KRD39Tfw1tJ6b3eJzxNCIPw=; b=LkWrJvFI1nmG25nt7TP1tRUY4E7SdZFCwW2PgIoMCuaGljL31RcKi7VdJjz4e98cJVafUY r8lwTZB5sfkbP8jOpAko4mSpVSG4CxgjqQFQBkwVaBz3N4dnbP/qIsNpuj9eGAapwNZj6N MUO9jGzfP8FUS7sv9eiOAHYbbubzvddjfwvuqcLMsGxe2TBFbY/LZznvUyX95bvOq6O70O Hhe+L4NK7pPhiunhcahL6FqOOStCikiftNi1hg+MZ0HxCGMMnV4Ph6Gccbftb2NM9txOww QfoWpMm2kiFFzCD/YaTFftlIcpxGL5erU/jca1MgrAzEzKKYI8PznPG8I23JjQ== 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 4S0z455QkMzjVP; Wed, 4 Oct 2023 15:23:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNnlG087174; Wed, 4 Oct 2023 15:23:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNnqW087171; Wed, 4 Oct 2023 15:23:49 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:49 GMT Message-Id: <202310041523.394FNnqW087171@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 53ef38313a6d - stable/14 - LinuxKPI: 802.11: improve lkpi_ic_vap_delete() List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 53ef38313a6dd70e5d929a3d014cc62db807793f Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=53ef38313a6dd70e5d929a3d014cc62db807793f commit 53ef38313a6dd70e5d929a3d014cc62db807793f Author: Bjoern A. Zeeb AuthorDate: 2023-09-30 15:20:53 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:18 +0000 LinuxKPI: 802.11: improve lkpi_ic_vap_delete() Changing the order of cleanup in lkpi_ic_vap_delete() will avoid firmware crashes or a direct panic as observed as ieee80211_vap_detach() will do most cleanup for us and get us into the correct state. Calling mo_stop() in lkpi_ic_vap_delete() seems to stop the problem that further VAPs could not be created (error 17) after the first one being destroyed. Sponsored by: The FreeBSD Foundation PR: 269842 (cherry picked from commit dbf7691999abe501e0ebc0fe4d8d9e97718d3890) (cherry picked from commit 6c38c6b1b917957d420902213f318bf0153214f2) --- sys/compat/linuxkpi/common/src/linux_80211.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index cb919bfd3f5b..5e7a3ff91b9f 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -2424,10 +2424,17 @@ lkpi_ic_vap_delete(struct ieee80211vap *vap) LKPI_80211_LHW_LVIF_LOCK(lhw); TAILQ_REMOVE(&lhw->lvif_head, lvif, lvif_entry); LKPI_80211_LHW_LVIF_UNLOCK(lhw); - lkpi_80211_mo_remove_interface(hw, vif); ieee80211_ratectl_deinit(vap); ieee80211_vap_detach(vap); + + IMPROVE("clear up other bits in this state"); + + lkpi_80211_mo_remove_interface(hw, vif); + + /* Single VAP, so we can do this here. */ + lkpi_80211_mo_stop(hw); + mtx_destroy(&lvif->mtx); free(lvif, M_80211_VAP); } From nobody Wed Oct 4 15:23:50 2023 X-Original-To: dev-commits-src-branches@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 4S0z471KLjz4w6M3; Wed, 4 Oct 2023 15:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z4702d8z4NPX; Wed, 4 Oct 2023 15:23:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433031; 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=TF1FJCpkoBHRbYA45CBhutHZaTixF3zIXxNO4uP8Ia8=; b=jYoa51pAvO435G+pBYuY28U5RcRRHgcJ0dT0CrLkXhWsdZ1QwgiDq7WraM8N8PVS15PN9C bFMl2kAsSLaEzGWWa6L1NYRJLIFArAU0KRVOF36Ia4RgqmD8kYTchRpFYKaHKOwvc6SjeR BunPl1ypP84gXgzpw7HP/GZ9euqnxCMpfStNZTvfTmZYlwMglwQwzg4TbeHx9bdCffa9NC wfSZMMwrW8yCcez6FtzAf34aJwN0E0nTzNx48HZHXiXgK4ULjke8IOrDixCDsi5g+haNJW d3AlstD4qEbJyVfgn+XC0xBLeYlyW0V5JERA8BJDxy1QvwvhjWHA16L2RhiBEA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433031; a=rsa-sha256; cv=none; b=tFotq2T/XnuvhK5ReuwYHyFWEw1qA6bFy8or/V7arrHf6roEKRFMi7O4O9Ps1IALdojf17 SoJ5dSFHGDuS6zxvrQ+hFp+fhJDw9tarmbRN5lCxMKLzuf6mMPZxLzCa2ta+9m/W5QQXax x/Rs+o1xAq3BoIwiy3Ez0CkRV5KSxa0IEzJ4tQXxGnp02ODuLIFZ3/URVknxYi+juorF6C gEI+ULgpydewi9mUTBiTuml0SWJj/Kq4zAao5YCEb+VHEcu76NJzh2PXOdWDpYoeBtYMRt BI0itaPgfTr5WJrVcfZ2ZVQ0FR0Jebp+j0YEERLUWJ8CJiMuREsKROR8qk9BIA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433031; 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=TF1FJCpkoBHRbYA45CBhutHZaTixF3zIXxNO4uP8Ia8=; b=nAK8DMS4qNPc6MnY7DPsGXlw+17fNo3kuCjePnwE4H4B0tJmMCyucINDF5O5Pd2v/QoB64 /J293ul79VDe9x5ywdlrDmyM2p8fl7EjT3s/i00Tuw9p0Kfb8aHyuGAg6j/QGgJTMNljsv 5NCFTPNV7TWGj/ek6VRimJVioRBFnDc6XXyrdeCA8E3gu6dpJeHMJ1cTwG0tLgXn3feZ7k /qwQfL27x8bgZys8u++hIUJYxNycAH3yXhK1z0BXUq5ABW7U3g0QOpmHZ8EyrU8qCc8Z5Z R2aL4EFaBHwwj2g7A8H68+G/Fd3LAOBjgr8BCqPE0bucmnV0Zcqcp85XG6CUpA== 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 4S0z466FnxzjSW; Wed, 4 Oct 2023 15:23:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNoJG087234; Wed, 4 Oct 2023 15:23:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNo0R087231; Wed, 4 Oct 2023 15:23:50 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:50 GMT Message-Id: <202310041523.394FNo0R087231@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 70e2b1f49c18 - stable/14 - LinuxKPI: 802.11: avoid symbol clash on UP to AC mapping List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 70e2b1f49c18c8ff5ca81a49abb0bdaa62708766 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=70e2b1f49c18c8ff5ca81a49abb0bdaa62708766 commit 70e2b1f49c18c8ff5ca81a49abb0bdaa62708766 Author: Bjoern A. Zeeb AuthorDate: 2023-09-24 11:55:11 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:19 +0000 LinuxKPI: 802.11: avoid symbol clash on UP to AC mapping tid_to_mac80211_ac is an exported symbol in and likely based on iwlwifi, which leads to a symbol clash in NetBSD. Rename our local LinuxKPI copy to a better name and add a comment where to find a copy of the mapping table. Sponsored by: The FreeBSD Foundation Reported by: Phil Nelson (phil netbsd org) (cherry picked from commit fb3c249ed93c834d70f8361215bc40a9e9004d3b) --- sys/compat/linuxkpi/common/src/linux_80211.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 5e7a3ff91b9f..c8232e6f33cc 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -116,7 +116,8 @@ const uint8_t rfc1042_header[6] = { 0xaa, 0xaa, 0x03, 0x00, 0x00, 0x00 }; /* IEEE 802.11-05/0257r1 */ const uint8_t bridge_tunnel_header[6] = { 0xaa, 0xaa, 0x03, 0x00, 0x00, 0xf8 }; -const uint8_t tid_to_mac80211_ac[] = { +/* IEEE 802.11e Table 20i-UP-to-AC mappings. */ +static const uint8_t ieee80211e_up_to_ac[] = { IEEE80211_AC_BE, IEEE80211_AC_BK, IEEE80211_AC_BK, @@ -242,7 +243,7 @@ lkpi_lsta_alloc(struct ieee80211vap *vap, const uint8_t mac[IEEE80211_ADDR_LEN], IMPROVE("AP/if we support non-STA here too"); ltxq->txq.ac = IEEE80211_AC_VO; } else { - ltxq->txq.ac = tid_to_mac80211_ac[tid & 7]; + ltxq->txq.ac = ieee80211e_up_to_ac[tid & 7]; } ltxq->seen_dequeue = false; ltxq->stopped = false; @@ -3243,7 +3244,7 @@ lkpi_80211_txq_tx_one(struct lkpi_sta *lsta, struct mbuf *m) ac = IEEE80211_AC_BE; } else { skb->priority = tid & IEEE80211_QOS_CTL_TID_MASK; - ac = tid_to_mac80211_ac[tid & 7]; + ac = ieee80211e_up_to_ac[tid & 7]; } skb_set_queue_mapping(skb, ac); From nobody Wed Oct 4 15:23:51 2023 X-Original-To: dev-commits-src-branches@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 4S0z483RLFz4w6Gw; Wed, 4 Oct 2023 15:23: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S0z4813Svz4NSD; Wed, 4 Oct 2023 15:23:52 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433032; 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=rODIo4cBUhvoG8vx3ifnbpIzWm0HiGlTv5sI4c0UdaA=; b=qEqp6FfCYZSFJ7Nk732tukyirUWqStgz8P//9xm/wq22JqJWCSNoMpmGo5O9VrF+e/BxlK IEb4bbmWx4nGTBZOIEUNnZokdxM9bjMF0IkC0ivxzboaKS4f4KaOk7hr7zvXpoPQ+upbQL n3FxAKspFmloEKkv0QG46SQLyQa2/ZTmqNb/d7/siGKWBTo0sakFtv3uY9nn8PqoGXJK2l 3kwML8GDywoXIlUDZ5cLFHs/MD6msRYfm70WjgsHyiOFb4J4rOgyp1ajm7Qm802/BpBoTU pwZzZPWCS2+4ExlfTzwubcGLkT48eYftrXIFXJEIC4+Irw0GoJsrtE24nBNJRw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696433032; a=rsa-sha256; cv=none; b=U10fDGHFGZtht/LH1ECv5PPRv0RPBOk327SYrOxMCHhZfh55QouvZnclXJUl4WxwlUz/p7 sN7kyd9ibPbWegxgU1tIE1AqWbvhGXqaYjd5/5KUtRCEdJYgiCmikydUuf19PRZfPy3CGX MaJnp285JaWkSwtRVByWqfb1R5r/EhUYbMyaTJ12XHGhonDlt6SVZVOih5b8Y0FJzzLodw UC2jrVXIrwLkmG/ox+x3+wZ8Y7ZrC5Wn3Vd6ADrKNkTtiFBT5DSW/lZ5yM3+v6xPo2T5uF vLpx0jEjB5vlLV8K35cafqXieIbW9cMLB44M0DrzQb0jmkmRyJMV0jnMcUBblw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696433032; 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=rODIo4cBUhvoG8vx3ifnbpIzWm0HiGlTv5sI4c0UdaA=; b=oDlgjB+MIIyMpDCwrHUrI+iSl5jYlwEj/bRgyJYaMNpP9Y/f1nV82XG8AAcW7Iy/6LOqOM QIg123vFJ+BwpX3C7GG04L8YAILa2vzzqhiSmBCvWfYZVfgAnku+ZtVoweXNOiDCx8NcFl N0gjSnBl2hFA0KJKOuSXz5qo7WKXYAIlK2peXqqJySUzjpKGrfj+9lNqyTFQwKIjRcM80M OFEiEEh37QgF8iFy+4nmF5jtOrNf+8f2LGCOMn8Sz/On3gHPs/M0JyzK3qtwGdpXtyvb9i M68f9naiZ/Cwdhkew5nBlL+akp/BxgrMsMxlwHsaaVOzaTPrn2yRzHj5Ir7g2A== 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 4S0z480985zjZd; Wed, 4 Oct 2023 15:23:52 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 394FNpCt087285; Wed, 4 Oct 2023 15:23:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 394FNpMn087282; Wed, 4 Oct 2023 15:23:51 GMT (envelope-from git) Date: Wed, 4 Oct 2023 15:23:51 GMT Message-Id: <202310041523.394FNpMn087282@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: a3e10c2b1418 - stable/14 - LinuxKPI: 802.11: fill regulatory_hint() with some life List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: a3e10c2b141879a68cff691f0176a2f6ac8ea04e Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=a3e10c2b141879a68cff691f0176a2f6ac8ea04e commit a3e10c2b141879a68cff691f0176a2f6ac8ea04e Author: Bjoern A. Zeeb AuthorDate: 2023-09-25 17:54:20 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-04 15:19:19 +0000 LinuxKPI: 802.11: fill regulatory_hint() with some life Start implementing regulatory_hint() using a .c file based allocation helper function so we could change structures in the future with better chances to keep compatibility. This sets wiphy->regd needed by various LinuxKPI based WiFi drivers. Sponsored by: The FreeBSD Foundation (cherry picked from commit 673d62fc359b0cb7a70af42c36d2fa54fb29452a) --- sys/compat/linuxkpi/common/include/net/cfg80211.h | 20 ++++++++++++++++++-- sys/compat/linuxkpi/common/src/linux_80211.c | 10 ++++++++++ 2 files changed, 28 insertions(+), 2 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/net/cfg80211.h b/sys/compat/linuxkpi/common/include/net/cfg80211.h index 56ca9a231d2d..7e57ce67cc26 100644 --- a/sys/compat/linuxkpi/common/include/net/cfg80211.h +++ b/sys/compat/linuxkpi/common/include/net/cfg80211.h @@ -1260,6 +1260,8 @@ struct cfg80211_bss *linuxkpi_cfg80211_get_bss(struct wiphy *, const uint8_t *, size_t, enum ieee80211_bss_type, enum ieee80211_privacy); void linuxkpi_cfg80211_put_bss(struct wiphy *, struct cfg80211_bss *); void linuxkpi_cfg80211_bss_flush(struct wiphy *); +struct linuxkpi_ieee80211_regdomain * + lkpi_get_linuxkpi_ieee80211_regdomain(size_t); /* -------------------------------------------------------------------------- */ @@ -1587,8 +1589,22 @@ regulatory_set_wiphy_regd(struct wiphy *wiphy, static __inline int regulatory_hint(struct wiphy *wiphy, const uint8_t *alpha2) { - TODO(); - return (-ENXIO); + struct linuxkpi_ieee80211_regdomain *regd; + + if (wiphy->regd != NULL) + return (-EBUSY); + + regd = lkpi_get_linuxkpi_ieee80211_regdomain(0); + if (regd == NULL) + return (-ENOMEM); + + regd->alpha2[0] = alpha2[0]; + regd->alpha2[1] = alpha2[1]; + wiphy->regd = regd; + + IMPROVE("are there flags who is managing? update net8011?"); + + return (0); } static __inline const char * diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index c8232e6f33cc..978a82ad2ceb 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -3954,6 +3954,16 @@ linuxkpi_ieee80211_iterate_stations_atomic(struct ieee80211_hw *hw, LKPI_80211_LHW_LVIF_UNLOCK(lhw); } +struct linuxkpi_ieee80211_regdomain * +lkpi_get_linuxkpi_ieee80211_regdomain(size_t n) +{ + struct linuxkpi_ieee80211_regdomain *regd; + + regd = kzalloc(sizeof(*regd) + n * sizeof(struct ieee80211_reg_rule), + GFP_KERNEL); + return (regd); +} + int linuxkpi_regulatory_set_wiphy_regd_sync(struct wiphy *wiphy, struct linuxkpi_ieee80211_regdomain *regd) From nobody Thu Oct 5 00:01:38 2023 X-Original-To: dev-commits-src-branches@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 4S1BYb1CR4z4wkCC; Thu, 5 Oct 2023 00:01: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1BYb0GrMz4knT; Thu, 5 Oct 2023 00:01:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696464099; 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=rdpJERkba2HT/L09iKgmFK7L4OO8OcL8xhW3cWcoKNo=; b=xrj5W6XXP048PitRYWOpTp3CLQw0OsZZzt1/Tej0hEZqto7LBipOseykA2WJUZ+0E0LhSq ohgEVPv9wz7bgiSKTce/tDZfqB6CqRUlx+w3qma/kErnx+RTHiFpqje9ZZ4M4vgVaRaT2u /vzIXgoQTI7O7jefI8f8GKaLGl08LkEU/a7l8BtQxLJirQeg8YES29sdhheE4su7EgmbWe 4moMhvbVhAoNpU9XNdavnS+lVMp5OC7t7D7Ad6hoGqDVmRW01v2qWe7zcDNB4gL++TBJmM 8u2dWJ6iIim2iB69es2PuijaECDmSdsmfSr7oD042ye6azkoINAvnlb1MwsxDA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696464099; a=rsa-sha256; cv=none; b=U2iZC43sR6e7OAY5xRKpm5eMBWhdhtYaMNMMaPkmUxISJ30KqBxG+W+ZXByGmfTbbzcCOh 66Lx+rRvZcuY6/qDPFYdMqMF112/UcnEu8itYEYFNtdzIo55xt1LluSLzUnwKIMSj1Vy4L tvbCd3lAz7+ZLj0PpS0G8yJUVM7znfKBXHIDwJCyb+efKI+9os0ikW3+aDASMFgK+liih4 SR8ZmLFC1paGY8YZwBCRtRUO5w28B+JN0seAMpd9a9PwyQwh/42/oGqYzskv4pE6sNotl/ WoDUnyvbYDATGV1ojsRE9AVXxMuCYozfNvIWUf3yrW+KiBOMe2tnr4DTO5VIhA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696464099; 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=rdpJERkba2HT/L09iKgmFK7L4OO8OcL8xhW3cWcoKNo=; b=nKR/ubWMUGcK1odeVnt2o82g66yjEc2ARNW69V0fvH5Kl94ULw4A+1V4NfkXVuFn4oH3gv T8dTYCkVJg9ciwLssyIiPBTYz5NsfuQeQiFowLYYzmfVhoSpHzCi3J6JCzwMOOV+WWTU7P BTZO4bum3MPH+P4gdlORo9ZvpjIQzL9BPsKaPXXn2195wFU3DTiQVA7tYp5RONp2ikYqHV LXs4MtqhL2zu77iroFUQR+DIKoOY68L2J3i+jp16/La/eyyW5fnE2y2rS8Sf0wQg4GAizE axqzvyHDksr8C2KWJE6UmgwsBR2JIWoElIJHhDr/iVHogwrV+tnNfdWCs1YUkg== 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 4S1BYZ6PkWzyV3; Thu, 5 Oct 2023 00:01:38 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39501cuo051575; Thu, 5 Oct 2023 00:01:38 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39501cEx051572; Thu, 5 Oct 2023 00:01:38 GMT (envelope-from git) Date: Thu, 5 Oct 2023 00:01:38 GMT Message-Id: <202310050001.39501cEx051572@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: b9c361e4af26 - stable/14 - libc: Rewrite quick_exit() and at_quick_exit() using C11 atomics. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: b9c361e4af26547b7a373d5dda4eb7a6fee4f7c6 Auto-Submitted: auto-generated The branch stable/14 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=b9c361e4af26547b7a373d5dda4eb7a6fee4f7c6 commit b9c361e4af26547b7a373d5dda4eb7a6fee4f7c6 Author: Dag-Erling Smørgrav AuthorDate: 2023-09-26 20:06:27 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2023-10-04 23:59:43 +0000 libc: Rewrite quick_exit() and at_quick_exit() using C11 atomics. Compiler memory barriers do not prevent the CPU from executing the code out of order. Switch to C11 atomics. This also lets us get rid of the mutex; instead, loop until the compare_exchange succeeds. While here, change the return value of at_quick_exit() on failure to the more traditional -1, matching atexit(). Sponsored by: Klara, Inc. Reviewed by: Olivier Certner, kevans, kib Differential Revision: https://reviews.freebsd.org/D41936 (cherry picked from commit 1dc3abb052430279e47c8922d22b30922adcf0f6) libc: Add a rudimentary test for quick_exit(3). Sponsored by: Klara, Inc. Reviewed by: kib Differential Revision: https://reviews.freebsd.org/D41937 (cherry picked from commit c7dd4601aeebbc1bbe131cbe6747476c124b47fe) --- lib/libc/stdlib/quick_exit.c | 40 +++++++--------- lib/libc/tests/stdlib/Makefile | 1 + lib/libc/tests/stdlib/quick_exit_test.c | 81 +++++++++++++++++++++++++++++++++ 3 files changed, 98 insertions(+), 24 deletions(-) diff --git a/lib/libc/stdlib/quick_exit.c b/lib/libc/stdlib/quick_exit.c index 05db690cb6e7..4dee7b20bd2b 100644 --- a/lib/libc/stdlib/quick_exit.c +++ b/lib/libc/stdlib/quick_exit.c @@ -2,6 +2,7 @@ * SPDX-License-Identifier: BSD-2-Clause * * Copyright (c) 2011 David Chisnall + * Copyright (c) 2023 Klara, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -27,44 +28,35 @@ */ #include -#include + +#include #include -#include /** - * Linked list of quick exit handlers. This is simpler than the atexit() - * version, because it is not required to support C++ destructors or - * DSO-specific cleanups. + * Linked list of quick exit handlers. These will be invoked in reverse + * order of insertion when quick_exit() is called. This is simpler than + * the atexit() version, because it is not required to support C++ + * destructors or DSO-specific cleanups. */ struct quick_exit_handler { struct quick_exit_handler *next; void (*cleanup)(void); }; -/** - * Lock protecting the handlers list. - */ -static pthread_mutex_t atexit_mutex = PTHREAD_MUTEX_INITIALIZER; -/** - * Stack of cleanup handlers. These will be invoked in reverse order when - */ -static struct quick_exit_handler *handlers; +static _Atomic(struct quick_exit_handler *) handlers; int at_quick_exit(void (*func)(void)) { struct quick_exit_handler *h; - - h = malloc(sizeof(*h)); - if (NULL == h) - return (1); + if ((h = calloc(1, sizeof(*h))) == NULL) { + return (-1); + } h->cleanup = func; - pthread_mutex_lock(&atexit_mutex); - h->next = handlers; - __compiler_membar(); - handlers = h; - pthread_mutex_unlock(&atexit_mutex); + while (!atomic_compare_exchange_strong(&handlers, &h->next, h)) { + /* nothing */ ; + } return (0); } @@ -77,8 +69,8 @@ quick_exit(int status) * XXX: The C++ spec requires us to call std::terminate if there is an * exception here. */ - for (h = handlers; NULL != h; h = h->next) { - __compiler_membar(); + for (h = atomic_load_explicit(&handlers, memory_order_acquire); + h != NULL; h = h->next) { h->cleanup(); } _Exit(status); diff --git a/lib/libc/tests/stdlib/Makefile b/lib/libc/tests/stdlib/Makefile index a2a6420aba41..860e530389df 100644 --- a/lib/libc/tests/stdlib/Makefile +++ b/lib/libc/tests/stdlib/Makefile @@ -12,6 +12,7 @@ ATF_TESTS_C+= qsort_b_test ATF_TESTS_C+= qsort_r_compat_test ATF_TESTS_C+= qsort_r_test ATF_TESTS_C+= qsort_s_test +ATF_TESTS_C+= quick_exit_test ATF_TESTS_C+= set_constraint_handler_s_test ATF_TESTS_C+= strfmon_test ATF_TESTS_C+= tsearch_test diff --git a/lib/libc/tests/stdlib/quick_exit_test.c b/lib/libc/tests/stdlib/quick_exit_test.c new file mode 100644 index 000000000000..9feed8a6fa63 --- /dev/null +++ b/lib/libc/tests/stdlib/quick_exit_test.c @@ -0,0 +1,81 @@ +/*- + * Copyright (c) 2023 Klara, Inc. + * + * SPDX-License-Identifier: BSD-2-Clause + */ + +#include + +#include +#include +#include + +#include + +static void func_a(void) +{ + if (write(STDOUT_FILENO, "a", 1) != 1) + _Exit(1); +} + +static void func_b(void) +{ + if (write(STDOUT_FILENO, "b", 1) != 1) + _Exit(1); +} + +static void func_c(void) +{ + if (write(STDOUT_FILENO, "c", 1) != 1) + _Exit(1); +} + +static void child(void) +{ + // this will be received by the parent + printf("hello, "); + fflush(stdout); + // this won't, because quick_exit() does not flush + printf("world"); + // these will be called in reverse order, producing "abc" + if (at_quick_exit(func_c) != 0 || + at_quick_exit(func_b) != 0 || + at_quick_exit(func_a) != 0) + _Exit(1); + quick_exit(0); +} + +ATF_TC_WITHOUT_HEAD(quick_exit); +ATF_TC_BODY(quick_exit, tc) +{ + char buf[100] = ""; + ssize_t len; + int p[2], wstatus = 0; + pid_t pid; + + ATF_REQUIRE(pipe(p) == 0); + pid = fork(); + if (pid == 0) { + if (dup2(p[1], STDOUT_FILENO) < 0) + _Exit(1); + (void)close(p[1]); + (void)close(p[0]); + child(); + _Exit(1); + } + ATF_REQUIRE_MSG(pid > 0, + "expect fork() to succeed"); + ATF_CHECK_EQ_MSG(pid, waitpid(pid, &wstatus, 0), + "expect to collect child process"); + ATF_CHECK_EQ_MSG(0, wstatus, + "expect child to exit cleanly"); + ATF_CHECK_MSG((len = read(p[0], buf, sizeof(buf))) > 0, + "expect to receive output from child"); + ATF_CHECK_STREQ("hello, abc", buf); +} + +ATF_TP_ADD_TCS(tp) +{ + ATF_TP_ADD_TC(tp, quick_exit); + return (atf_no_error()); +} From nobody Thu Oct 5 00:01:39 2023 X-Original-To: dev-commits-src-branches@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 4S1BYc2bv4z4wkJ2; Thu, 5 Oct 2023 00:01:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1BYc1Zb3z4kZ6; Thu, 5 Oct 2023 00:01:40 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696464100; 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=SmtIpDfYICeLglyrxBLDp/p5d46zE+ozXuytpQy2/E8=; b=t08kI0U+Ls0obKc7ITTUE8MQwVlqDCsvtDTRLTa7g1LkFuQeFNkda8sf5EgZDT9mGLHBEt IHxfzAtKxQHhf00YQ1V+tEiSsXVP4G9V7D9KNk6/8t0XeaayfboHAdwg7xmAYU9YbYtO9z 1mn+6ByR7WE9vrpfBiOGl/rLpN5g23ZI0vixTQGnaNRdbCywKH/NPfsLDb5e07gSkv534b JmkJl+HgwSuT4VlyiE8V7nURotGsvos1QDqbLAdLfEc//tBs9nrqOzwQPVW/gWTYe2tH0m i0BX2qQunDR/OH1Nk1CMcdMa6Ezaqr8SDcqFN4xaFInNcvkb80Eujj4DgqLlyA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696464100; a=rsa-sha256; cv=none; b=nIjvGH5zXLl/JfOu7Q8L9+nOZ/rKh46m9tO/Botxjp4FmBcb25kFi4eCKa7TAypF1UU6Fw 1xaNljc/gRFrm/z3HRw3aqRRjPHdLTAc/if6mi6AjKJEBf1KpZXZjzEgL+loypaAxxxsFb IHMWiC+NEtZsRhPGbfN1V1f3NFAbAcn/YKltkRV4lHEJL5GxYes5YEw6wIYn6xTbOnKGax LAlxUFegTQOWgXFkf/Mnf6VVrf5s1/hVQGXfiO9NyU1fqMll8YCG9zgqY1WaoV8MyYZKpY 5HRMOvt+sO35w73MzW02/JRB0yg1eyUi6IKlViZP3NLCQteQwfxYfgXqUpW56w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696464100; 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=SmtIpDfYICeLglyrxBLDp/p5d46zE+ozXuytpQy2/E8=; b=IMETtufsW3GfKKesRiQMgtOGecpcaYRThCv5pl37FeGiHxqha2lDJDkksq6FaR2Jp/8jMC 7aVpnLAKNDhCCNq7meF4iTr2P9R6/uyk4FaaYBLqJcVScrQxhbCr3E5wkRV0xgwTH2N06E gL1iEtfOAzQiF/BDIMyhkxTXgYG5KS5Sy96CWlDtQZnd2+VsTGRUnS6maE1ZF7sxwYiYWk TMCOuH1mIWuCAUErhRxDxnsXoMUSPiBxtD0XBjnwve5Bpqi2+LFuezj2lBHx/WEV3fYlDa 4eujCBBQ5O/CPMmEi7OouUoA7akHiCjNhwiAUg+/+EiWNBlP6Z+4C0d9TUUSjw== 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 4S1BYc0YrHzyHv; Thu, 5 Oct 2023 00:01:40 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39501dBT051624; Thu, 5 Oct 2023 00:01:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39501da2051621; Thu, 5 Oct 2023 00:01:39 GMT (envelope-from git) Date: Thu, 5 Oct 2023 00:01:39 GMT Message-Id: <202310050001.39501da2051621@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: b3cef2d2f538 - stable/14 - split: Further option parsing improvements. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: b3cef2d2f538671551b30c918267bfbe246d225c Auto-Submitted: auto-generated The branch stable/14 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=b3cef2d2f538671551b30c918267bfbe246d225c commit b3cef2d2f538671551b30c918267bfbe246d225c Author: Dag-Erling Smørgrav AuthorDate: 2023-09-28 16:29:52 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2023-10-04 23:59:44 +0000 split: Further option parsing improvements. * Whenever possible, use strtonum() to parse numeric arguments. * Improve usefulness and consistency of error messages. * While here, fix some type and style issues. Sponsored by: Klara, Inc. Reviewed by: christos, kevans Differential Revision: https://reviews.freebsd.org/D42010 (cherry picked from commit d7399551b02861b910b15c7b7a78a2835644aa45) split: Improve GNU compatibility. * Like GNU split, turn autoextend back on if given -a0. * Add a test case that verifies that -a turns autoextend off. * Add a test case that verifies that -a0 turns autoextend back on. Sponsored by: Klara, Inc. Reviewed by: christos, kevans Differential Revision: https://reviews.freebsd.org/D42011 (cherry picked from commit d9d69a6f6fc1f8d80df9ce6493e8ab9388781615) --- usr.bin/split/split.c | 89 ++++++++++++++++++++++----------------- usr.bin/split/tests/split_test.sh | 19 +++++++++ 2 files changed, 70 insertions(+), 38 deletions(-) diff --git a/usr.bin/split/split.c b/usr.bin/split/split.c index af1ed69c9482..e246a0d4adfc 100644 --- a/usr.bin/split/split.c +++ b/usr.bin/split/split.c @@ -63,7 +63,7 @@ static const char sccsid[] = "@(#)split.c 8.2 (Berkeley) 4/16/94"; #define DEFLINE 1000 /* Default num lines per file. */ static off_t bytecnt; /* Byte count to split on. */ -static off_t chunks = 0; /* Chunks count to split into. */ +static long chunks; /* Chunks count to split into. */ static bool clobber = true; /* Whether to overwrite existing output files. */ static long numlines; /* Line count to split on. */ static int file_open; /* If a file open. */ @@ -73,7 +73,7 @@ static regex_t rgx; static int pflag; static bool dflag; static long sufflen = 2; /* File name suffix length. */ -static int autosfx = 1; /* Whether to auto-extend the suffix length. */ +static bool autosfx = true; /* Whether to auto-extend the suffix length. */ static void newfile(void); static void split1(void); @@ -84,8 +84,8 @@ static void usage(void) __dead2; int main(int argc, char **argv) { - const char *p; - char *ep; + char errbuf[64]; + const char *p, *errstr; int ch, error; setlocale(LC_ALL, ""); @@ -106,20 +106,27 @@ main(int argc, char **argv) while (numlines >= 0 && *p >= '0' && *p <= '9') numlines = numlines * 10 + *p++ - '0'; if (numlines <= 0 || *p != '\0') - errx(EX_USAGE, "%c%s: illegal line count", ch, - optarg ? optarg : ""); + errx(EX_USAGE, "%c%s: line count is invalid", + ch, optarg ? optarg : ""); break; case 'a': /* Suffix length */ - if ((sufflen = strtol(optarg, &ep, 10)) <= 0 || *ep) - errx(EX_USAGE, - "%s: illegal suffix length", optarg); - autosfx = 0; + sufflen = strtonum(optarg, 0, INT_MAX, &errstr); + if (errstr != NULL) { + errx(EX_USAGE, "%s: suffix length is %s", + optarg, errstr); + } + if (sufflen == 0) { + sufflen = 2; + autosfx = true; + } else { + autosfx = false; + } break; case 'b': /* Byte count. */ - errno = 0; - error = expand_number(optarg, &bytecnt); - if (error == -1) - errx(EX_USAGE, "%s: offset too large", optarg); + if (expand_number(optarg, &bytecnt) != 0) { + errx(EX_USAGE, "%s: byte count is invalid", + optarg); + } break; case 'c': /* Continue, don't overwrite output files. */ clobber = false; @@ -130,22 +137,27 @@ main(int argc, char **argv) case 'l': /* Line count. */ if (numlines != 0) usage(); - if ((numlines = strtol(optarg, &ep, 10)) <= 0 || *ep) - errx(EX_USAGE, - "%s: illegal line count", optarg); + numlines = strtonum(optarg, 1, LONG_MAX, &errstr); + if (errstr != NULL) { + errx(EX_USAGE, "%s: line count is %s", + optarg, errstr); + } break; case 'n': /* Chunks. */ - if (!isdigit((unsigned char)optarg[0]) || - (chunks = (size_t)strtoul(optarg, &ep, 10)) == 0 || - *ep != '\0') { - errx(EX_USAGE, "%s: illegal number of chunks", - optarg); + chunks = strtonum(optarg, 1, LONG_MAX, &errstr); + if (errstr != NULL) { + errx(EX_USAGE, "%s: number of chunks is %s", + optarg, errstr); } break; case 'p': /* pattern matching. */ - if (regcomp(&rgx, optarg, REG_EXTENDED|REG_NOSUB) != 0) - errx(EX_USAGE, "%s: illegal regexp", optarg); + error = regcomp(&rgx, optarg, REG_EXTENDED|REG_NOSUB); + if (error != 0) { + regerror(error, &rgx, errbuf, sizeof(errbuf)); + errx(EX_USAGE, "%s: regex is invalid: %s", + optarg, errbuf); + } pflag = 1; break; default: @@ -163,9 +175,10 @@ main(int argc, char **argv) --argc; } if (argc > 0) { /* File name prefix. */ - if (strlcpy(fname, *argv, sizeof(fname)) >= sizeof(fname)) - errx(EX_USAGE, "file name prefix is too long: %s", + if (strlcpy(fname, *argv, sizeof(fname)) >= sizeof(fname)) { + errx(EX_USAGE, "%s: file name prefix is too long", *argv); + } ++argv; --argc; } @@ -182,16 +195,16 @@ main(int argc, char **argv) else if (bytecnt != 0 || chunks != 0) usage(); - if (bytecnt && chunks) + if (bytecnt != 0 && chunks != 0) usage(); if (ifd == -1) /* Stdin by default. */ ifd = 0; - if (bytecnt) { + if (bytecnt != 0) { split1(); exit (0); - } else if (chunks) { + } else if (chunks != 0) { split3(); exit (0); } @@ -225,7 +238,7 @@ split1(void) /* NOTREACHED */ default: if (!file_open) { - if (!chunks || (nfiles < chunks)) { + if (chunks == 0 || nfiles < chunks) { newfile(); nfiles++; } @@ -236,24 +249,24 @@ split1(void) err(EX_IOERR, "write"); len -= dist; for (C = bfr + dist; len >= bytecnt; - len -= bytecnt, C += bytecnt) { - if (!chunks || (nfiles < chunks)) { - newfile(); + len -= bytecnt, C += bytecnt) { + if (chunks == 0 || nfiles < chunks) { + newfile(); nfiles++; } - if (write(ofd, - C, bytecnt) != bytecnt) + if (write(ofd, C, bytecnt) != bytecnt) err(EX_IOERR, "write"); } if (len != 0) { - if (!chunks || (nfiles < chunks)) { - newfile(); + if (chunks == 0 || nfiles < chunks) { + newfile(); nfiles++; } if (write(ofd, C, len) != len) err(EX_IOERR, "write"); - } else + } else { file_open = 0; + } bcnt = len; } else { bcnt += len; diff --git a/usr.bin/split/tests/split_test.sh b/usr.bin/split/tests/split_test.sh index c9b87c01618c..48065719055a 100755 --- a/usr.bin/split/tests/split_test.sh +++ b/usr.bin/split/tests/split_test.sh @@ -209,6 +209,23 @@ autoextend_body() atf_check -o inline:"$((26*25+1))\n" cat xzaaa } +atf_test_case noautoextend +noautoextend_body() +{ + seq $((26*26)) >input + atf_check split -a2 -l1 input + atf_check -o inline:"$((26*26))\n" cat xzz +} + +atf_test_case reautoextend +reautoextend_body() +{ + seq $((26*25+1)) >input + atf_check split -a2 -a0 -l1 input + atf_check -o inline:"$((26*25))\n" cat xyz + atf_check -o inline:"$((26*25+1))\n" cat xzaaa +} + atf_test_case continue continue_body() { @@ -249,6 +266,8 @@ atf_init_test_cases() atf_add_test_case larger_suffix_length atf_add_test_case pattern atf_add_test_case autoextend + atf_add_test_case noautoextend + atf_add_test_case reautoextend atf_add_test_case continue atf_add_test_case undocumented_kludge atf_add_test_case duplicate_linecount From nobody Thu Oct 5 06:53:53 2023 X-Original-To: dev-commits-src-branches@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 4S1MjG1YT8z4wZmD; Thu, 5 Oct 2023 06:53:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1MjG1519z4QFw; Thu, 5 Oct 2023 06:53:54 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696488834; 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=1m5QY8CPXW77sYcv+0RZt9/7dTtBnkPj7QbpzfeQQHU=; b=qsZHlZCLbD19CV6rcdXbhsG8Ilh7glKX4JQWxu83VSjhJfj8CpLtr9zisqPXt5ftXcBHEH o2NpEkTmePP1cBLi0oaxR41NkihbPWXWUetrKMmYyEktOCZGm49AIVjxZERQO64HaiwwQ2 YV0qodnIBVclZAEEjYE9s63yYoMczxKlXmReRdUi5eSJkppF7h6k6QSh/fQ3fqBFuyPytC w/WUv14Msfvu7XJdyZ/1m+KsSXAWHA7ajqKREkMraCfFY2Dv8kuMoVJfUIWhTryV06sE6Z fSBKk8Z3VFXzny8nlhJ//JCer65JbrKD/yA6K2DIFmwKGOIAZN2RUkxkKYQ9eg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696488834; a=rsa-sha256; cv=none; b=RMM5jFS7lxgrBYT0+TcN384WiXKwvTR9oAHO7fHiG5HZwWHqeNQ+dyy4xlSkZCafDG7Nst YbWh/vaydNfuF5MnnEwX0MaLMfB1N4+MqWFyu+cV0IIsc5YlAbhddB0Qb7s7xsQLepsUYm l2ifktfMs9eeGPCbFKSu+7P7KYIbUYUpX3nWxOshgNgYahxBoiCPlaprATan7WL8rG5cPS zXWx4FpU4XTDv1WRGOgt/vprHKAYPUr45F5+ZrdA3tQBZNPIJ+XbGff/7kT3dbQD0zl4nx zILIra4w7F7+DlgXZCI30L09KCp2T3YiBDDdbDiscmdD84JcWBvk0/uveEKwWQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696488834; 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=1m5QY8CPXW77sYcv+0RZt9/7dTtBnkPj7QbpzfeQQHU=; b=WepLnXtRtTzQHmOLd5msf66BKxdLlzt2xIxcV2iKmgoQDeubPwW7Nc62LjnzUPzLZHiava F9RqHBI6jnttCAco4ywlx3LGw11poWkMkBW0qLQ5jyee7lGnXOyf59Xq0KHhM0eEZdCrlq E/sYjtVsHRDvyIT+le3afjho0F5utVOtf+WUM4pgopS6Ak1h+ZuE6SKxtnvBvfRjSe74F/ D/CO+VSfi3D9MRkgTx8IWpvT0o8FTVcaUehtMqU+PnzQm89stvmwhXA+uScSE4zXTMHN/q dDYGZY/4EA5FGHWP4IWGfkOh9bbyTUpNPhqPmdhD/KaJ3wx/Q2jpvFMKkZ8hmg== 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 4S1MjG08Xzz19jq; Thu, 5 Oct 2023 06:53:54 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3956rr3s042167; Thu, 5 Oct 2023 06:53:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3956rrHd042164; Thu, 5 Oct 2023 06:53:53 GMT (envelope-from git) Date: Thu, 5 Oct 2023 06:53:53 GMT Message-Id: <202310050653.3956rrHd042164@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: e4545d163576 - releng/14.0 - ObsoleteFiles: cleanup old libclang_rt files for powerpc64 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: e4545d163576947da4e982e321b5670dc6b0e62f Auto-Submitted: auto-generated The branch releng/14.0 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=e4545d163576947da4e982e321b5670dc6b0e62f commit e4545d163576947da4e982e321b5670dc6b0e62f Author: Dimitry Andric AuthorDate: 2023-09-14 16:39:31 +0000 Commit: Dimitry Andric CommitDate: 2023-10-05 06:53:32 +0000 ObsoleteFiles: cleanup old libclang_rt files for powerpc64 PR: 273776 Approved by: re (gjb) MFC after: 3 days (cherry picked from commit b9c012a60b6e98f7c3e765859195302cf3ae7f6c) (cherry picked from commit f03512540805694c75edb72f3aaaccbe47e69bd4) --- ObsoleteFiles.inc | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index a59151dad4ea..45670b228aaf 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -382,10 +382,13 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-armhf.so OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-i386.so +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-powerpc64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-powerpc64.so OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-i386.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-riscv64.a @@ -396,9 +399,11 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-i386.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_static-i386.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_static-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_static-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.cfi-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.cfi-arm.a @@ -418,8 +423,10 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.fuzzer_interceptors-x86_ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.fuzzer_no_main-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.fuzzer_no_main-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan-aarch64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan_cxx-aarch64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan_cxx-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan_cxx-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-arm.a @@ -437,34 +444,41 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-i386.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-i386.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan-aarch64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan_cxx-aarch64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan_cxx-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan_cxx-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-i386.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-i386.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-i386.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-aarch64.a From nobody Thu Oct 5 06:53:55 2023 X-Original-To: dev-commits-src-branches@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 4S1MjH2gFfz4wZS1; Thu, 5 Oct 2023 06:53: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1MjH224fz4QfM; Thu, 5 Oct 2023 06:53:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696488835; 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=xcjdQYrlLXYf5teUIlL59CF/vInd+QMQJ1nHWR32T00=; b=trw8gIyaXrgEip6DfNLTyGNTElEu242rhwMorWwDYgIaQXvyt2m80oUx4wGo2t9yPuKyt4 uW5xKVM5yM54RT6ynVIrl8o9j04ZZkiQr7YJsWlJvZeK/73Z9x8ui7Y7gPaiX9Qa6Bfglc MBdi1baBdny9vFKOtWl8TYI5Lj9nhqFjTde+jNHFL5O+VaJfYnaYyAN0ZkMB7vtg82M1vh RekODHVYrEi83pXafCTcRqdmDB93VYYWVvgmvNZkojZOtt6MrrqA1cOL7mAce1iUtrU0Yl EJIZAQz/V/BY8ncMa5MEqI/S3cO2Abhmt3fF0Kx4CNIpgp+MNf3cqzmB4AinSg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696488835; a=rsa-sha256; cv=none; b=hHunZ8YYanh2kQV5qSNgqg7xfWY5D55WjykYmsKWKbPbipcObJkbAwRolcix7PV8XY0fEv d2Hq/xHFv7FQq6K7UAweCSf6BI5fVreh8JPZ4aJCwpmF1Pv/iyBgo23UBuQnQSIYk6Ho3r ciHMuNDEy/BNx4f6uNVUr7rYRH8G0Lpfkd1A/eN5UeF75ZZhS0vGBlcXX8eDurKbHFNkvR 12g39GOxPKuUgIeYxNlQxrvZrzTWo2qkT/C5luaS3fl0kd7VsRrsHGBUJZEESE6P2nLxD9 DHKxJfdGTRBqt7ilttDczodoBG02YZ5Y+wIC91ccggOrEC1L91UuWYZv5Woa/w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696488835; 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=xcjdQYrlLXYf5teUIlL59CF/vInd+QMQJ1nHWR32T00=; b=iOVrEzK243s9xiaHH2NpESvqZfkL4pbN4eOLpChJohpJdz/s2CHWpyfS+k0FSW2L8XQ5f4 z9DAdVuQXQk3CHwZBX+a+ebrN27M4tJzmfTieqmvbBBhBBc5DxcRHSOS/CGRKzD5AuOK79 ofocsT0igimV9VW/RBt5ecbVDdPv6m/zOozsNOQU8m0n6Ntug3mRAri5Px5hZwqKyvXYSe KqpOYAhKGtU5NQXc9PP5d3R6utFftoO4HCkoXkPzXOFlr0DBKautd54vu2QUt9UtXhnmDL iIX0qopoEogRMQaTW5mO4CINGasjN+BVBIcji0dMHEyWDgzknG8MaHlF1QbhRA== 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 4S1MjH13zwz19T6; Thu, 5 Oct 2023 06:53:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3956rtPX042215; Thu, 5 Oct 2023 06:53:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3956rt3o042212; Thu, 5 Oct 2023 06:53:55 GMT (envelope-from git) Date: Thu, 5 Oct 2023 06:53:55 GMT Message-Id: <202310050653.3956rt3o042212@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: 716d96e90988 - releng/14.0 - ObsoleteFiles: cleanup old libclang_rt files for powerpc64le List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 716d96e90988e57713dd00680a0bf8c596f141d9 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=716d96e90988e57713dd00680a0bf8c596f141d9 commit 716d96e90988e57713dd00680a0bf8c596f141d9 Author: Dimitry Andric AuthorDate: 2023-09-16 07:47:19 +0000 Commit: Dimitry Andric CommitDate: 2023-10-05 06:53:32 +0000 ObsoleteFiles: cleanup old libclang_rt files for powerpc64le PR: 273776 Approved by: re (gjb) MFC after: 3 days (cherry picked from commit cadbf320b352b3691cdfa90ad8ba818efca4ea68) (cherry picked from commit 0cf2f7f35877161a3d48877fcd249a9a32d9cc70) --- ObsoleteFiles.inc | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index 45670b228aaf..eec5c4231f7e 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -384,11 +384,14 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-i386.so OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-powerpc64.so +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-powerpc64le.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-powerpc64le.so OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-powerpc64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-preinit-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan-riscv64.a @@ -400,10 +403,12 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-powerpc64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_cxx-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_static-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_static-powerpc64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_static-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.asan_static-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.cfi-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.cfi-arm.a @@ -424,9 +429,11 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.fuzzer_no_main-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.fuzzer_no_main-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan-powerpc64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan_cxx-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan_cxx-powerpc64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan_cxx-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.msan_cxx-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-arm.a @@ -435,6 +442,8 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64le.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64le.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64lele.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.safestack-aarch64.a @@ -445,6 +454,7 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-powerpc64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-aarch64.a @@ -452,19 +462,23 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-powerpc64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.stats_client-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan-powerpc64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan_cxx-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan_cxx-powerpc64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan_cxx-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.tsan_cxx-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-powerpc64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_minimal-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-aarch64.a @@ -472,6 +486,7 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-powerpc64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-aarch64.a @@ -479,6 +494,7 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-arm OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-powerpc64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.ubsan_standalone_cxx-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-aarch64.a From nobody Thu Oct 5 06:53:56 2023 X-Original-To: dev-commits-src-branches@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 4S1MjK09f5z4wZpb; Thu, 5 Oct 2023 06:53:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1MjJ3DFsz4Qc6; Thu, 5 Oct 2023 06:53:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696488836; 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=pxp8nkLDeLnso3eQDQfZ0vLHSrHzW6Ml5U5gc0g6QCA=; b=eGhPAUaegf3LsDkiyFeu7K7sepANZ0bqHGOR1E1iCExuI5t5KLReH0PwtN0kxSCMmE7+r3 1bNvcudfaatR4B4DsJ974dZAgS2b8AgjbKfrlYNCIayph8DS8SZ0LZ0bR8beOiVVcFABKw lSQdka0KwXYBkpAr70R/3iNTDuJPzJ3jWOu9ZEx1gwjrB/JkIcHTXnyxlCqyA227twRl7C cVh7LsuuqKWshK4hj1tKAycUF1jBPPfLZL2qRN8R+cz//aFclOON2YwX9YPcmMHKchavbw pgZhXOOJrbMJp4zKr7BS2LnR15BnAir4Bc136n3tOCVGe2AhOONKCV9Z2ZJwMg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696488836; a=rsa-sha256; cv=none; b=SVagT05IilKVXsySHyYFiHnt9RLDX02RDiMjum4FnBjBrSMHDRJeewcrlUx+SDDfmDj/Ol mKvggPRiVTzwjcAaUpu2N7zkRMiBbx8nTad+kNphoPzaq+R4dXac33CN660FI2qENX0EsC BQNo/+4IpZhb4yKmDnoivw2MRCakZNsfaifHI2avd/RZDr8jCdGUtBYLwNX+5bH6bu+Mvj M/F8Jb8lcupcfwChBdpNNK68g1cXupcWHh9RewUjE2aNIwQyHVaMxuZF8IixI7WatumHSC Rk1wr4yJPh9KpmoKf8WQYFNvRvyw2AkJnuFvNyvtxK7R/ihXpjYiQHXHIVIVrA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696488836; 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=pxp8nkLDeLnso3eQDQfZ0vLHSrHzW6Ml5U5gc0g6QCA=; b=SlNoi1iIArTl2is0l8PUTG0l2tXwywpxaVyZ90AJzM9bpwIzd69NcGSAWsWA+WQm5C2Ylr nyGMUW6BKBGJBeV8a3UFnrDwz824tLFcfcNV5YOkdX7QHUjzj18BiSmBrR5aukWGr76EXO 1eRucDxPE180qqELs+9UBewvnd2zL2X1EDBuuyVtPmS11xewtUjm+9Nz2pk9Os8XH6Yrpb dYm8m+MSdliyppdW0D1YMDif8SOk4tUmAgn8jyaIG+Amx3oROh5rVvvaouGs3u6kU84yDN LB5DlTZChJ9KZptD32eHtcu6G/XPw2lYWvNriE3po4i6omuBBl+IJhW4KfYJ3w== 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 4S1MjJ221Vz19T7; Thu, 5 Oct 2023 06:53:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3956ruxu042268; Thu, 5 Oct 2023 06:53:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3956ruYS042264; Thu, 5 Oct 2023 06:53:56 GMT (envelope-from git) Date: Thu, 5 Oct 2023 06:53:56 GMT Message-Id: <202310050653.3956ruYS042264@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: 1bab7cb52ca4 - releng/14.0 - ObsoleteFiles: cleanup more old libclang_rt files for powerpc64le List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 1bab7cb52ca453c438563502acb78d7d4251dbce Auto-Submitted: auto-generated The branch releng/14.0 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=1bab7cb52ca453c438563502acb78d7d4251dbce commit 1bab7cb52ca453c438563502acb78d7d4251dbce Author: Dimitry Andric AuthorDate: 2023-09-19 11:45:57 +0000 Commit: Dimitry Andric CommitDate: 2023-10-05 06:53:32 +0000 ObsoleteFiles: cleanup more old libclang_rt files for powerpc64le PR: 273776 Approved by: re (gjb) MFC after: 3 days (cherry picked from commit 8a99263e9da1f04ede967cfa1ea6d52d258dcbe5) (cherry picked from commit 237b0c5b22c95683c2367ef0a82f54c309309db4) --- ObsoleteFiles.inc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index eec5c4231f7e..df9d286cd039 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -503,14 +503,18 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-armhf.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-basic-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-basic-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-basic-armhf.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-basic-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-basic-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-fdr-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-fdr-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-fdr-armhf.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-fdr-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-fdr-x86_64.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-profiling-aarch64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-profiling-arm.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-profiling-armhf.a +OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-profiling-powerpc64le.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-profiling-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.xray-x86_64.a OLD_DIRS+=usr/lib/clang/15.0.7/lib/freebsd From nobody Thu Oct 5 06:53:57 2023 X-Original-To: dev-commits-src-branches@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 4S1MjK6c41z4wZvK; Thu, 5 Oct 2023 06:53:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1MjK3kMlz4QRF; Thu, 5 Oct 2023 06:53:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696488837; 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=YUw/+0EHNJY0pwnSFkjc4Ii1RbaM92WP/FW/NOlGrE0=; b=uWFWyBBSiMDc7/6HNuQTnKeWaEW5AlpT5J8ldeZD3vsHCP9EjJX+AqH/2baxTnabg8hYeB ZfVclsuZbRimQtiU3gKW4q4FtHbxnuHqLok8l7QudgBkNZ/Vd69/Px/zRThRNQbY2L2DXX KXW9PK74Ek6dsAsk8qTayzRrU9u0e3DpXHrW5kjn1Go45JNMS5Hl1k24nurqiUE3OMnW8p OrWyGBrdTF1569mar25DqkYmktNgZ4HIMyAQv3R9EDM9su0NcoiQUmkeWcOHOGTJQVSwGn 7R/+9HKjHhm+1pNWSCJ+f4WaphD7hDV1azT1lBpo66vhlwtADsmnOMVkRYeqzA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696488837; a=rsa-sha256; cv=none; b=x8943T/cqZGHlsD1q32ywL8UmeAfGYyQ+iQQY5PUiAvnrpqy/pf1pQCOzQTh0CwaNfQ6N6 0zIuHQK4jSPmTnGHw9G1lTrBuK9y3aSw5Y3NSx1JMRCWcySORNFsG2d80T/FlUEpIKYjYH Gm9oeJh72rMy/HqFIf4KiNGYYIsF5oODti7R6P8M8fqHyZ3nF7OAH01tNr0H/KjPV8ecbV E89DO1ReFBhFSm+sZ9MMk/gm3T7OOlb65Nt73lah+a/ryx8aEn0FBT/Jtq9LZFX59F7H99 3hMzcP0BYFyx+H0xxxBFGKEO89/jXg5jbCuGAUGuCkb4nCMXEMRwAnttP65FTQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696488837; 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=YUw/+0EHNJY0pwnSFkjc4Ii1RbaM92WP/FW/NOlGrE0=; b=Q7sxh7QZlSTFWVmvOVtkx3tgfQacnJwZdpQWK50n1fMzsrzy8A4Bg5xL//HPk3F63KkyU8 UmrRrCqa7a9CLCFUqOoziA/oUtY+qvUIZ6hcWfqPu5vzBAW+XzM1WQOP1bW5QSX4az5UeO f1h4WVFS5XEGeVuvyLZHKEQdAkkg8dt9x/e7p7OEOz5GHhEf0ouNFAA19iZcX/7d8wZXsj StWL0O1TEKJGO4jwS8yfVCBnF2oGGmmkJ9FbpUGVCy8neqUtz2ZfQ6YmqxXA8twd/XwPRu HKzYW5wvAzHo+Q2qfrXOSwUzamv7KTaLUBB9a0bn57YdrLEnlkQmQcsc76oeig== 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 4S1MjK2qxWz19T8; Thu, 5 Oct 2023 06:53:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3956rvLp042325; Thu, 5 Oct 2023 06:53:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3956rvCt042322; Thu, 5 Oct 2023 06:53:57 GMT (envelope-from git) Date: Thu, 5 Oct 2023 06:53:57 GMT Message-Id: <202310050653.3956rvCt042322@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: 83b704e29ef6 - releng/14.0 - ObsoleteFiles: remove duplicated and incorrect libclang_rt powerpc64le entries List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 83b704e29ef625864db5c2d268a70aad7b8b1026 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=83b704e29ef625864db5c2d268a70aad7b8b1026 commit 83b704e29ef625864db5c2d268a70aad7b8b1026 Author: Dimitry Andric AuthorDate: 2023-09-29 18:41:52 +0000 Commit: Dimitry Andric CommitDate: 2023-10-05 06:53:32 +0000 ObsoleteFiles: remove duplicated and incorrect libclang_rt powerpc64le entries PR: 273776 Approved by: re (gjb) MFC after: 3 days (cherry picked from commit e2d3168d1207561df2e1cf0a2a8d13c198e5f8d3) (cherry picked from commit 2d5eb9b95a9d99c0a80994fc932f6ad0589f69ed) --- ObsoleteFiles.inc | 2 -- 1 file changed, 2 deletions(-) diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index df9d286cd039..589f6b968e9d 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -442,8 +442,6 @@ OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-i386.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64le.a -OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64le.a -OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-powerpc64lele.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-riscv64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.profile-x86_64.a OLD_FILES+=usr/lib/clang/15.0.7/lib/freebsd/libclang_rt.safestack-aarch64.a From nobody Thu Oct 5 07:26:30 2023 X-Original-To: dev-commits-src-branches@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 4S1NQt36kQz4wfh0; Thu, 5 Oct 2023 07:26:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1NQt2fS2z4VLZ; Thu, 5 Oct 2023 07:26:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696490790; 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=fJde0wwwbH20byxRVjMUm84JAY/zI5uPKX6SQc4XvZ0=; b=Y8WDSlmTvggEbO02AtQ/XpvIBzwZq7vgNoo+Tpq7Gm1LPojS97+eOMuZmns5XZxn6P0j28 6tJsBOwhKtF8iyNP7T4bVonxVVcuLzOoBW2C3CrwwtZlLacSQgtXbfBD66QClOSORlVIYz VsUHasCpGSj3t1oF6WSNy2uPYvg0Hsil+I614nAWpzeJZWDoxaQCCkCGmJfkr+5g3MbDGK k9eLQqSJsjndxELIhePR1X37KZ+hrCcHKpsNdxPvVv1bdW7G1ej5zP+5kOo539RBmICt4r R3TRxxaQ6ZWAJ+JspEJ70iT8YPEGvwPH2i+KtyM+zW+2Bsg3TO9JRU9iQ/DOZw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696490790; a=rsa-sha256; cv=none; b=ssds+9NfcU2WGj9Lvp2Rp0Yn5Q5qoxcqvzqYaPiI5uUlMbZLIw3SujjCCJdaUvQMHtiqHu 992Jl1xaRWS6k4SHzWLdZKxn1NnPGNulMozTtFTbKa0uIJFNLa4S9zT5AogUXo3W4B274z aLntUwaIR+v6CKGLzVJR0BsVmjoZtfV+O2lyl+YUxvsJu6KXQC613RTy7OomuNHCkoP+KL 3+/FMTLCL/U9OStfI48RvXRgG+HJoayZ97RC9YjtZxVTWzM4Sek9GsmsGJYmBI3G/4jWFe WP/Oklv1AR9ibCc5y5odToS+BDU0rA2b31h0QJPBpsyz0ZzJCHEZOgH6UlSD0w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696490790; 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=fJde0wwwbH20byxRVjMUm84JAY/zI5uPKX6SQc4XvZ0=; b=F7YZb50zW8c0e8MefyB4SprAgiRFF1IePEYVk4hLYLiyOB5ByyYKDfp/9onSudZ0P8XEH2 CNxtqDYP3xFHba2FR2Xr3TWncQbrTj2LX5D8gOzQPLTZsmJKKsgPavk/1tYmdzbio6qDIB 9+LR6yjTAEZs9orHL2ifNcBEipQtb8KqYUzXrya/0BMz7mjobDRHXOCvvTaD6k/ZN/Pn9t cYDi/UlIhsfJqEY2d4xAAp47jrPsSuVITeck0bc2jYOnbzS+QEkxdeQj4DgaW/tRbpUjLi 0xSuqSNE5NPerWO3KxRpdg1ka/JlkzLsprJNOnSvaGkyPzB5+nu8JqILqRfE4g== 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 4S1NQt1Vxsz1BJT; Thu, 5 Oct 2023 07:26:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3957QUJD093183; Thu, 5 Oct 2023 07:26:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3957QUN3093180; Thu, 5 Oct 2023 07:26:30 GMT (envelope-from git) Date: Thu, 5 Oct 2023 07:26:30 GMT Message-Id: <202310050726.3957QUN3093180@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: fb058a9a40a5 - stable/14 - libfetch: don't rely on ca_root_nss for certificate validation List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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: fb058a9a40a5adc82721ed822fb4fba213446a7b Auto-Submitted: auto-generated The branch stable/14 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=fb058a9a40a5adc82721ed822fb4fba213446a7b commit fb058a9a40a5adc82721ed822fb4fba213446a7b Author: Michael Osipov AuthorDate: 2023-10-03 05:53:20 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2023-10-05 00:03:16 +0000 libfetch: don't rely on ca_root_nss for certificate validation Before certctl(8), there was no system trust store, and libfetch relied on the CA certificate bundle from the ca_root_nss port to verify peers. We now have a system trust store and a reliable mechanism for manipulating it (to explicitly add, remove, or revoke certificates), but if ca_root_nss is installed, libfetch will still prefer that to the system trust store. With this change, unless explicitly overridden, libfetch will rely on OpenSSL to pick up the default system trust store. PR: 256902 MFC after: 3 days Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D42059 (cherry picked from commit 09f5c1e118bb4eca77b83a0d08f559b20f60aa59) --- lib/libfetch/common.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/lib/libfetch/common.c b/lib/libfetch/common.c index fd2091791620..dfa742577585 100644 --- a/lib/libfetch/common.c +++ b/lib/libfetch/common.c @@ -1055,8 +1055,6 @@ fetch_ssl_setup_transport_layer(SSL_CTX *ctx, int verbose) /* * Configure peer verification based on environment. */ -#define LOCAL_CERT_FILE _PATH_LOCALBASE "/etc/ssl/cert.pem" -#define BASE_CERT_FILE "/etc/ssl/cert.pem" static int fetch_ssl_setup_peer_verification(SSL_CTX *ctx, int verbose) { @@ -1066,12 +1064,6 @@ fetch_ssl_setup_peer_verification(SSL_CTX *ctx, int verbose) if (getenv("SSL_NO_VERIFY_PEER") == NULL) { ca_cert_file = getenv("SSL_CA_CERT_FILE"); - if (ca_cert_file == NULL && - access(LOCAL_CERT_FILE, R_OK) == 0) - ca_cert_file = LOCAL_CERT_FILE; - if (ca_cert_file == NULL && - access(BASE_CERT_FILE, R_OK) == 0) - ca_cert_file = BASE_CERT_FILE; ca_cert_path = getenv("SSL_CA_CERT_PATH"); if (verbose) { fetch_info("Peer verification enabled"); From nobody Thu Oct 5 15:10:16 2023 X-Original-To: dev-commits-src-branches@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 4S1Zk11V74z4vjjv; Thu, 5 Oct 2023 15:10: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1Zk1141Zz4XBn; Thu, 5 Oct 2023 15:10:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696518617; 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=7x8som8QDy264UGe78DPPZQPuEh/YWY8q7fyX5Hz8nI=; b=ZZ4bHuACU9dYn2G4wwoduPNGvoXL9+bfV7yQqPKPvLP5DUR480DfGCNkfqA29dWxfAx8ki YapWSHoemDK7Pp0SN54ZTa6JTTrK363NKlQuAvY/1b7zY2JJMZDPG0O0/JAFcb3XlBhWbi 33fm2SHU7FmYkzDg6wwggKxQR5BHQN7pKAg7YR2aMQQ/qH2RqVEvflSOSKYTcsWdMAS+8j KwSdQmljZNgAWIvDlXT1fZ+2CoVMEPHfPK9bYJjEqDfQluGEKdICtigtp4urw0vHQ/A/gB 3HH2hNru/tHQ97niLJAyhZCTyuVN1tsZJ6JIGvZJ5ctZxrfAYFfxOE3EmZ2g7Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696518617; a=rsa-sha256; cv=none; b=ZQ7ZeY/bC5VU6zdLcPgeIOzf2cJTSNUwq7Wk3KkdCdUGbSPkn2bn2AwKgrbMjU8doU7iRn 5nFAWodXAgJHIJB7KSQmmoKOlq1xAr/QvPuMU3pqq+g3+fbYFBWiIHGIijIsxV7Ty4Kzjt fkX+BJwjwQdn5WYte9pwr1dzE18spWNPrTd4cTbo8r5iWqRZdmHV86QFVos5UpgbsmMOnm lf3J+s5EHfr+hSPTdiXoyCoFjkumLgfk6byw4R7cYA4iE1AsxvWSnP+aFnu/n7pY1vXkBO PJzvRsE1yBOtjVSPEfD+GHpBe7PSqUVAqi22jCCQAPSnL55oCPPNaLlCo8Dy3g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696518617; 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=7x8som8QDy264UGe78DPPZQPuEh/YWY8q7fyX5Hz8nI=; b=c94AyCipsOegrU4NZ55StJE3POfkIEcHVkSRpDeOKekeLMAT1+hXkRT4Mn5RHgkxcZmy2o SA1NSfrsZYI/lMJs2W5bnvK184PU+fgoZSxcv94r+5n7m/VtAk9lsy4tTr72JBL2hr0Y1K dlpXfaT8Q1mthF+1tw/o98GwHw74Dy9SdoxGorSRkuXVVshj0rbJ5zfHgv2Oi4hvak2bFH 5nMeadodFWRX2b/muTYjVPmiXUrGwC9hDDiE41peQH6MHTp3uZe7NhrC1T3bn735oh+mbh bgxvdZum+TzMsYbgvBVg1tiqJiGLDfuMFWciSSwYPrNmCGAGDVSWC2qNI7yuVg== 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 4S1Zk106dDz1PWx; Thu, 5 Oct 2023 15:10:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395FAGWL070775; Thu, 5 Oct 2023 15:10:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395FAGg9070770; Thu, 5 Oct 2023 15:10:16 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:10:16 GMT Message-Id: <202310051510.395FAGg9070770@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: e1105ded372d - releng/14.0 - unix: Fix a lock order reveral List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: e1105ded372d6993cd8c14721a33c01fbe355111 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=e1105ded372d6993cd8c14721a33c01fbe355111 commit e1105ded372d6993cd8c14721a33c01fbe355111 Author: Mark Johnston AuthorDate: 2023-09-27 12:24:11 +0000 Commit: Mark Johnston CommitDate: 2023-10-05 14:01:14 +0000 unix: Fix a lock order reveral Running the test suite yields: lock order reversal: 1st 0xfffff80004bc6700 unp (unp, sleep mutex) @ sys/kern/uipc_usrreq.c:390 2nd 0xffffffff81a94b30 unp_link_rwlock (unp_link_rwlock, rw) @ sys/kern/uipc_usrreq.c:2934 lock order unp -> unp_link_rwlock attempted at: 0xffffffff80bc216e at witness_checkorder+0xbbe 0xffffffff80b493a5 at _rw_wlock_cookie+0x65 0xffffffff80c0a8e2 at unp_discard+0x22 0xffffffff80c0a888 at unp_freerights+0x38 0xffffffff80c09fdd at unp_scan+0x9d 0xffffffff80c0f9a7 at uipc_sosend_dgram+0x727 0xffffffff80c00a79 at sousrsend+0x79 0xffffffff80c072d0 at kern_sendit+0x1c0 0xffffffff80c074d7 at sendit+0xb7 0xffffffff80c076f3 at sys_sendmsg+0x63 0xffffffff8104d957 at amd64_syscall+0x6b7 0xffffffff8101f9eb at fast_syscall_common+0xf8 This happens when uipc_sosend_dgram() discards a control message because the receive socket buffer is full. The overflow handling frees internalized file references in the socket buffer before freeing mbufs. It does this with socket PCBs locked, leading to the LOR. Defer handling of file references until the PCBs are unlocked. Approved by: re (gjb) Reviewed by: glebius MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D41884 (cherry picked from commit 61a14ddfe012ca7b57a101725e5c654269f200ca) (cherry picked from commit 20c494a9d3f20e2942c99ca517d0e983a0ac73e8) --- sys/kern/uipc_usrreq.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/kern/uipc_usrreq.c b/sys/kern/uipc_usrreq.c index 291ff7cf8cae..f12693f3982a 100644 --- a/sys/kern/uipc_usrreq.c +++ b/sys/kern/uipc_usrreq.c @@ -1332,8 +1332,10 @@ uipc_sosend_dgram(struct socket *so, struct sockaddr *addr, struct uio *uio, } else { soroverflow_locked(so2); error = ENOBUFS; - if (f->m_next->m_type == MT_CONTROL) - unp_scan(f->m_next, unp_freerights); + if (f->m_next->m_type == MT_CONTROL) { + c = f->m_next; + f->m_next = NULL; + } } if (addr != NULL) From nobody Thu Oct 5 15:10:18 2023 X-Original-To: dev-commits-src-branches@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 4S1Zk22Zwrz4vjdr; Thu, 5 Oct 2023 15:10: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1Zk21rzkz4XQG; Thu, 5 Oct 2023 15:10:18 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696518618; 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=aeuFRYsHaV/oLsA7bbrBQS0+gIsRYWOgL+P2vvkCrFU=; b=kY1XecLFDzVtb3xp8Bzj63qBPCV1Q2KcKkWLwvkZoNUkV398xhg/CzROWAHmQ+RsBv+Qb5 kGQhVSkEzMJfpYzJzX9gn5yErqAa8KZb2fgSz0gWeHP8btBMIBhNAvFQ6Uq96q3030sW0f mn6I9hxYgcQPkXuY7tZDh8YNvEVuNhdAElM+lkYr6vlYxc1n32rHb8ruvlAgHtKRTJNQNq locYUZfVcKbETMuysIror/lztfNNxQyw0MWp7xVflBsPlL+gRSR12taioc51QMbwTBbVlv XjkF40iThQAF2/TMMJUAAiwgS936YkLcDUj6IDZTIti+8viAEpYUJpmk17cXcQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696518618; a=rsa-sha256; cv=none; b=eGIh2luzwqOj1JbBzqdfLooFXPg4pdVcaQuQCPD30XGjKod1sYY6Oy7PD3KXC6r7epRqqQ AgiHVFpddYoMVd27fRPX7sXkiiLCuCE6Yr/ZtY4iaTugJmrt4T2rouCBK9wJf983bsOevG 3VazR3kw67XuAto+zZ0F9qW7BEXeDXW/r3mzp/UKN0o/Ko0LBw5ZFzGqV5TPVRXpJPEKjl NOO4X1ODHU566XK6/DGceokCCX0OZuXGk0/KHuZvWHyp9hdtG2TJK4SYcjBWmlZ54ucoKZ WzfosnTwOkqnI/zYer9gIGdEmjjNF3mmvWgzYSWlwzTkcQcg9Wgp+4Qoz2CwHA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696518618; 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=aeuFRYsHaV/oLsA7bbrBQS0+gIsRYWOgL+P2vvkCrFU=; b=Zsd40zD7maDSIEH7wY8R7mY5EO45GHi6ECcogS3g1kkhZVEA+dIL/7DKzjMNoD9UhbkEN5 18Uq0E26nk4ZqOaXHn09AWmzN1AdL+3EeysZgVvA8C3Usdy2EV2s30pkCKi6yXPvNJhW9P l0j0U6BKytqOSOGqBLvciqoUQNFg/CpEXgKp6HQtsrsYNxKQ7nEAJ/2KE08IjSsF8JRLv0 Cqyg0Ug9LinjOb9S/22DOSO2zPASKXF195l7u76/laH99r76fQ6GDRIQRJwtdRC4Dv/yBg f5OgPh0rdkex51q4ehuNPRTw4tejJQPAscjWd9AGMiJySGadx3BduQFMzVyY5w== 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 4S1Zk20y19z1PZ6; Thu, 5 Oct 2023 15:10:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395FAIoF071380; Thu, 5 Oct 2023 15:10:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395FAIM2071377; Thu, 5 Oct 2023 15:10:18 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:10:18 GMT Message-Id: <202310051510.395FAIM2071377@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 901d81c3e0f4 - releng/14.0 - hdac: Defer interrupt allocation in hdac_attach() List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 901d81c3e0f43cb0e4e10bb42ab9f0a71cfcda0a Auto-Submitted: auto-generated The branch releng/14.0 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=901d81c3e0f43cb0e4e10bb42ab9f0a71cfcda0a commit 901d81c3e0f43cb0e4e10bb42ab9f0a71cfcda0a Author: Mark Johnston AuthorDate: 2023-09-27 12:23:58 +0000 Commit: Mark Johnston CommitDate: 2023-10-05 14:01:19 +0000 hdac: Defer interrupt allocation in hdac_attach() hdac_attach() registers an interrupt handler before allocating various driver resources which are accessed by the interrupt handler. On some platforms we observe what appear to be spurious interrupts upon a cold boot, resulting in panics. Partially work around the problem by deferring irq allocation until after other resources are allocated. I think this is not a complete solution, but is correct and sufficient to work around the problems reported in the PR. Approved by: re (gjb) PR: 268393 Tested by: Alexander Sherikov Tested by: Oleh Hushchenkov MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D41883 (cherry picked from commit 015daf5221f7588b9258fe0242cee09bde39fe21) (cherry picked from commit 1e8737f4e884fdf4b966056662e4e6003d3379d9) --- sys/dev/sound/pci/hda/hdac.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/sys/dev/sound/pci/hda/hdac.c b/sys/dev/sound/pci/hda/hdac.c index 422f7f930ea5..2cf9239499af 100644 --- a/sys/dev/sound/pci/hda/hdac.c +++ b/sys/dev/sound/pci/hda/hdac.c @@ -1270,9 +1270,6 @@ hdac_attach(device_t dev) /* Allocate resources */ result = hdac_mem_alloc(sc); - if (result != 0) - goto hdac_attach_fail; - result = hdac_irq_alloc(sc); if (result != 0) goto hdac_attach_fail; @@ -1347,6 +1344,10 @@ hdac_attach(device_t dev) hdac_corb_init(sc); hdac_rirb_init(sc); + result = hdac_irq_alloc(sc); + if (result != 0) + goto hdac_attach_fail; + /* Defer remaining of initialization until interrupts are enabled */ sc->intrhook.ich_func = hdac_attach2; sc->intrhook.ich_arg = (void *)sc; From nobody Thu Oct 5 15:10:19 2023 X-Original-To: dev-commits-src-branches@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 4S1Zk33TJgz4vjk4; Thu, 5 Oct 2023 15:10: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1Zk32ygzz4XT1; Thu, 5 Oct 2023 15:10:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696518619; 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=EGuNG5EHDloGYOLzn0nvxRiboyjUakAbDelPw7Y++OI=; b=MntTJzv/jJ5s9JQsgwp94JA7qd74tfYhcGaE6i3j9B4XBwIAlq/sVoRv0XpL2adGV0pVOb m8qR+udNswkVVLcWU9VVEOWGmZ4RRk6qelfsw49dUN+kSFVRqhSuv5/owQLpTS8k51stEa T6lFRxuiPP9RnbieK4EoiafH+Yq3fYrGJ0VqVvihcZX8QesCZaSwgzOp/aDojIrE20MyMz Yu5SiHJz0S6tGzpxC33MA1imuDHKbG6stS/fVq1NSE2nH6rUbF145XXk5rhQEHnUYqTCeO 0ejqBUKSWbjMwGlUZ/yGbFUPX39YiFee5PETHwXPJwoLes2njKK4r4x3sb4hog== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696518619; a=rsa-sha256; cv=none; b=ApjXSWFWWcq/bO4Oa2tQcWeWMfsB63Pt8vBS6907WFhpfEKWLxk8qjPk7m0X6sKs1XD/fq gPiRRn5jUM0yfOvctWIOLzo+MQz2RxMKUTikePEjZkT+YWC8Tav+YoGGX0BxP/jJj9B1KQ q7H7R/E+xiodFVV/lX/yY3GXdDrvavEdxpYu3JwSANpfZmTXbaOy/r23F1ickMEE/rEN4D ZCEKij4cXG+q3RIGzradBvaojEplVs0rf7y/Eu/mD9phRJITAcRLkSaM4PSVMZmfEVJWVp bWUvvLsXW9/LSLc9hl9m3+q7PLeAR4O+zudGxAcZLwKoTCAgG/YQiIw1p9vq4g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696518619; 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=EGuNG5EHDloGYOLzn0nvxRiboyjUakAbDelPw7Y++OI=; b=qVi9+/pnvqqOtH2xmhq0UMmmdn0kfAcqQZBpcRblmjqdS+B/g0lN8wi2LkDVTWtFy+8sAq 5tAspXto1eA8+z6e2qU7RR6nZBfIqDf20efGBKFhZWnoK5+ziGPvmjziwpk567MWpJz1PW /bU+vWpsr4iji3UAx5E3g1OgS+4UFmwJe7Lr15dC5WbWsP2XaObCfazCcl4D0teTC03nc6 /9wKQaeRekDr2xU7e+/hqA0C9LBddnUs02v9kQjnoyddJk14t9sfSLI7+yc/Hl+8lhl+uG +oVBzZW0ugVRdIdIRCtDZaIVKQwULUGUl3VKmWUerk4ZBkHqgsMROfYnirDVmQ== 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 4S1Zk322Dpz1PNR; Thu, 5 Oct 2023 15:10:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395FAJPe071434; Thu, 5 Oct 2023 15:10:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395FAJ7b071431; Thu, 5 Oct 2023 15:10:19 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:10:19 GMT Message-Id: <202310051510.395FAJ7b071431@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 7377d7440fcd - releng/14.0 - makefs/zfs: Set the objset block pointer fill field correctly List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 7377d7440fcd60fd58d6a4b51a61f1a7b921eae1 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=7377d7440fcd60fd58d6a4b51a61f1a7b921eae1 commit 7377d7440fcd60fd58d6a4b51a61f1a7b921eae1 Author: Mark Johnston AuthorDate: 2023-09-27 15:56:33 +0000 Commit: Mark Johnston CommitDate: 2023-10-05 14:01:23 +0000 makefs/zfs: Set the objset block pointer fill field correctly It is supposed to contain the number of objects allocated from the set, excluding the meta dnode. Approved by: re (gjb) Reported by: mav MFC after: 1 week Sponsored by: The FreeBSD Foundation (cherry picked from commit 46402fd21631b7d4686f8c341d92db6bcb190e5d) (cherry picked from commit ea5173e5725564da4b95a5b98410b8cd43520dab) --- usr.sbin/makefs/zfs/objset.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/usr.sbin/makefs/zfs/objset.c b/usr.sbin/makefs/zfs/objset.c index 22277c150712..3e3dcdeced4b 100644 --- a/usr.sbin/makefs/zfs/objset.c +++ b/usr.sbin/makefs/zfs/objset.c @@ -121,6 +121,7 @@ _objset_write(zfs_opt_t *zfs, zfs_objset_t *os, struct dnode_cursor *c, STAILQ_FOREACH_SAFE(chunk, &os->dnodechunks, next, tmp) { unsigned int i; + assert(chunk->nextfree > 0); assert(chunk->nextfree <= os->dnodecount); assert(chunk->nextfree <= DNODES_PER_CHUNK); @@ -149,8 +150,8 @@ _objset_write(zfs_opt_t *zfs, zfs_objset_t *os, struct dnode_cursor *c, * Write the object set itself. The saved block pointer will be copied * into the referencing DSL dataset or the uberblocks. */ - vdev_pwrite_data(zfs, DMU_OT_OBJSET, ZIO_CHECKSUM_FLETCHER_4, 0, 1, - os->phys, os->osblksz, os->osloc, &os->osbp); + vdev_pwrite_data(zfs, DMU_OT_OBJSET, ZIO_CHECKSUM_FLETCHER_4, 0, + os->dnodecount - 1, os->phys, os->osblksz, os->osloc, &os->osbp); } void From nobody Thu Oct 5 15:10:20 2023 X-Original-To: dev-commits-src-branches@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 4S1Zk44VRhz4vjlw; Thu, 5 Oct 2023 15:10: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1Zk43wvgz4XPB; Thu, 5 Oct 2023 15:10:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696518620; 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=+pEy6vfrWOp85dRTWmHyMdDPEOkl4RIGZfgu80GlUlU=; b=LwfeFjxcdOkvyIP0El6NTuHogGPyN8so8+mvFCvyA/Oh0gOVbTiUpEL96aNaevIooY3PXs aTkc220yzMXyasXvqveZipK3KZnT9XyXDpttqgQuZuMHe1wVAkGhipZ21geixTh9ot5pWq HvZKOovzksUft24PuB+w+Lpwm6fWu102OpKL0+/0S3W7xJTGCpW+JQN5WGHJV8CklWeQBF Pd9kgrA/EVCJE1IMuX4P8a47DnD7YHv15yfVHQzlWUXwAFH+kEdKdF6ome4urR/8I8RwSI 30gDQSIKJ7IlfLzjDEbg2IH51Upc9wxtwom2eilMbMArx09j9fOrBin89UXg5w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696518620; a=rsa-sha256; cv=none; b=fnCDXEeJg9zWgaH8s/pQRmRz8HS+wmzDp9fGhzpvPUdk14E8xbR4SBfBMcYiV45AIpUsTw /j0Te5UfE4t3snzNbv05RGowoDrGOihK5LKnnFh3l8trQD9PYqALCgM2+etnFpmWfpvtUX XAvqAImfy8Xex5ew7bH6AMMhqKEVpUSQzDJk+7X03ltbl1NTXnBLl/h1BZo/PSH8GPRGIo M1JEHb2XYh9a+6nzra/zHG925o6MWrD7G1ZLLzOj80SLl/MwHw6EH+xc442S1XSDQoULGj KvoeRvEzrAWlTmujtEYn9nv5wvEd6GqeKxS03Pzmq05sGwpfeSqJQzvSdQra5g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696518620; 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=+pEy6vfrWOp85dRTWmHyMdDPEOkl4RIGZfgu80GlUlU=; b=JAN4jZ5bDgjnNFGamvrCUwIvhD2WUiKe/QBxmpr5YQlh/PV9v40s1yIXgfDC37BIWaKi1w gjoEO0eH6nZCcTNteaWd4Yj+Uv8ufmxRWdz9PFfIKjEY+SWqOuPgrmvpr+ihJP2qyc7VO8 /lxhrIWsFwgvT1sYU+UvqnNYa+j2WsKcaQTs0qiCABnAQMy1FblW6QVkabl8i2nBoCrN0p sI0N1DnARB54hmzZDjBo3HrN/ZztiJH/Oe+bxhEOR9amtpI1PFR98A2MmVcZGzKtvwfOKs BO4vIYIR5NmhAibnT6vSIzzNDC18p2hZcqGleJ3OGSbRy3XkIeBEo7+x98nb6g== 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 4S1Zk43277z1PcX; Thu, 5 Oct 2023 15:10:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395FAKWr071476; Thu, 5 Oct 2023 15:10:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395FAKiJ071473; Thu, 5 Oct 2023 15:10:20 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:10:20 GMT Message-Id: <202310051510.395FAKiJ071473@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 5e78399dda05 - releng/14.0 - makefs/zfs: Remove a nonsensical comment List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 5e78399dda052dfa8c62b3e8b678d29196ca7a0c Auto-Submitted: auto-generated The branch releng/14.0 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=5e78399dda052dfa8c62b3e8b678d29196ca7a0c commit 5e78399dda052dfa8c62b3e8b678d29196ca7a0c Author: Mark Johnston AuthorDate: 2023-09-27 22:21:37 +0000 Commit: Mark Johnston CommitDate: 2023-10-05 14:01:26 +0000 makefs/zfs: Remove a nonsensical comment When populating files, makefs needs to copy their contents into userspace in order to compute a checksum, so copy_file_range(2) is out of the question. Though, it could possibly be used when building other types of filesystems. Approved by: re (gjb) MFC after: 1 week Sponsored by: The FreeBSD Foundation (cherry picked from commit 60c95af88f6a63fb7c2c86c6ff9c18743f6bbf0d) (cherry picked from commit 0074d0551ded1652155a23c6a8d04043c8ede1fd) --- usr.sbin/makefs/zfs/fs.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/usr.sbin/makefs/zfs/fs.c b/usr.sbin/makefs/zfs/fs.c index a4968d5f91e8..0d85ea8eb9d8 100644 --- a/usr.sbin/makefs/zfs/fs.c +++ b/usr.sbin/makefs/zfs/fs.c @@ -551,8 +551,6 @@ fs_populate_file(fsnode *cur, struct fs_populate_arg *arg) /* * Fill up our buffer, handling partial reads. - * - * It might be profitable to use copy_file_range(2) here. */ sofar = 0; target = MIN(size - foff, (off_t)bufsz); From nobody Thu Oct 5 15:10:21 2023 X-Original-To: dev-commits-src-branches@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 4S1Zk55TTyz4vjs5; Thu, 5 Oct 2023 15:10: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1Zk54f7Vz4XlW; Thu, 5 Oct 2023 15:10:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696518621; 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=BtbmO8tdhK1XfnivjCef804L9XtBogN+uJlYmlQY3Ds=; b=KPmHF0yz2lsyqazQCxwjGd3cWTrrwn8nqK3TtURJzEW3WrOEFpQGPUECUAzu8dAzozcrCs EgvhHWA5Iz35tMrSyi7MiA+BezXdbFVCoBX2AncWOvPq/h3p3EKazPfhx2i3xqcr0UG4pr 2hHUI4LGfhnJf64ulC4F90ijYQRIBTBdShumkCXh316DkbzpdeFyErC8FoAIPjFpCR/HNX j2bfrG3WWqz2B16Ne7UgwZaCmsTFpt35QQoqnun7XXzKF8/StLwQdPy+rlZ1U3QOj35/vT ie8R3BGorTJaLEpId+FnERSbev7i/zEsiZ9FD4QaI/OhRIj/IWiVQUY4hIAq6A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696518621; a=rsa-sha256; cv=none; b=mFO+08C4lkeRREdIgmH21oebY6Wy9igdbNZWVRVIowp2xPIXoyYpxkFefzDAcmY85TwMy3 hxttyDXSUVezsmux4fdNaS03UMN/g4eSDfBzEV2vxWKnKtIJRPtmubxmPz+FYgvATAlpnq Gx7man44tuMzJO6rWB1Golc1tZ2KtDDi4M3w0ViabrzfQA3i3fFl1orxK+2EQFHLA0IbqK UQr+l5cm5KB2MzOFasZDmT3zT6javnS/i4trMdLr3G62KlszjOa4NJmOYj/lCi7iwq/iVq YAVCvWJ4g3RL/jOUIAC+Vo8qbCiymSCENM3SLOWsTDM3h+BeRBv9v32hdRhl+A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696518621; 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=BtbmO8tdhK1XfnivjCef804L9XtBogN+uJlYmlQY3Ds=; b=dVKHFbiFlwJgZmUo39riLKj3W6wk5qz5sDA2vCcHlvxR/jpZHPDnqPFQib+25+OOTsrcEz kst4/bOEm0U6qzntMZawycfcro5hsITdVrHS/000TSP4zFBoOqXriwgjXhwmw9Z8cAvEwi k21Ab+LcSDH8dRpZYsvAyWvFJzdH7i9khhSfNzorYEsMNwNooEWiRWZAa7l1JPHrEb1GyQ zENjvLof+veG0aNYMEGgjIjxr+AHtyiuVS2sEbqsPzazW5sj3ZQ075kVB9YU3cDi/ohTfi dtot/BlmH1+kIwz9b9tGAn/GYG9HF6ajs9vdLCcnpB5I4kkr9XsY5eUjyqWjAw== 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 4S1Zk53YMyz1PcY; Thu, 5 Oct 2023 15:10:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395FALRe071545; Thu, 5 Oct 2023 15:10:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395FALsq071541; Thu, 5 Oct 2023 15:10:21 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:10:21 GMT Message-Id: <202310051510.395FALsq071541@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 3042b1d8159a - releng/14.0 - makefs/zfs: Ensure that the last block of a file has the right size List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 3042b1d8159a44faa2bac8c28810ec05025ebfbb Auto-Submitted: auto-generated The branch releng/14.0 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=3042b1d8159a44faa2bac8c28810ec05025ebfbb commit 3042b1d8159a44faa2bac8c28810ec05025ebfbb Author: Mark Johnston AuthorDate: 2023-09-28 20:16:17 +0000 Commit: Mark Johnston CommitDate: 2023-10-05 14:01:29 +0000 makefs/zfs: Ensure that the last block of a file has the right size When copying a file's contents into the pool, a loop copies blocks of the maximum size (128KB), allocating space from the vdev for each block. The space allocator rounds up to the nearest block size, but for files larger than the maximum size, this can result in the last block having a smaller logical size than the rest of the blocks belonging to that dnode. This violates some ZFS invariants when appending to that file. Modify fs_populate_file() to use the same block size for the final block. Approved by: re (gjb) Reported by: cperciva MFC after: 1 week Sponsored by: The FreeBSD Foundation (cherry picked from commit ef20cd33d3287ebead0d30f2e177fc57a97dc2d5) (cherry picked from commit 5175923ef4acb6faff370177fb60700721f13f92) --- usr.sbin/makefs/zfs/fs.c | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/usr.sbin/makefs/zfs/fs.c b/usr.sbin/makefs/zfs/fs.c index 0d85ea8eb9d8..b0a4c639f256 100644 --- a/usr.sbin/makefs/zfs/fs.c +++ b/usr.sbin/makefs/zfs/fs.c @@ -515,7 +515,7 @@ fs_populate_file(fsnode *cur, struct fs_populate_arg *arg) uint64_t dnid; ssize_t n; size_t bufsz; - off_t size, target; + off_t nbytes, reqbytes, size; int fd; assert(cur->type == S_IFREG); @@ -546,29 +546,30 @@ fs_populate_file(fsnode *cur, struct fs_populate_arg *arg) bufsz = sizeof(zfs->filebuf); size = cur->inode->st.st_size; c = dnode_cursor_init(zfs, arg->fs->os, dnode, size, 0); - for (off_t foff = 0; foff < size; foff += target) { + for (off_t foff = 0; foff < size; foff += nbytes) { off_t loc, sofar; /* * Fill up our buffer, handling partial reads. */ sofar = 0; - target = MIN(size - foff, (off_t)bufsz); + nbytes = MIN(size - foff, (off_t)bufsz); do { - n = read(fd, buf + sofar, target); + n = read(fd, buf + sofar, nbytes); if (n < 0) err(1, "reading from '%s'", cur->name); if (n == 0) errx(1, "unexpected EOF reading '%s'", cur->name); sofar += n; - } while (sofar < target); + } while (sofar < nbytes); - if (target < (off_t)bufsz) - memset(buf + target, 0, bufsz - target); + if (nbytes < (off_t)bufsz) + memset(buf + nbytes, 0, bufsz - nbytes); - loc = objset_space_alloc(zfs, arg->fs->os, &target); - vdev_pwrite_dnode_indir(zfs, dnode, 0, 1, buf, target, loc, + reqbytes = foff == 0 ? nbytes : MAXBLOCKSIZE; + loc = objset_space_alloc(zfs, arg->fs->os, &reqbytes); + vdev_pwrite_dnode_indir(zfs, dnode, 0, 1, buf, reqbytes, loc, dnode_cursor_next(zfs, c, foff)); } eclose(fd); From nobody Thu Oct 5 15:53:44 2023 X-Original-To: dev-commits-src-branches@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 4S1bh837Sdz4vrNj; Thu, 5 Oct 2023 15:53: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1bh82VHVz3Kn1; Thu, 5 Oct 2023 15:53:44 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521224; 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=r1lnMj3u3MjG+uBWoeeSr4FpzJOw02nKRl5Qc4bwSpY=; b=ROME49/hraRgM6ph0nkErYCghcVZrJ7Z22rUe4mvh3X0jHzUgy7TCqzYXCO7Hiiw2cFc2V jthDVhIbZmhAPYUYJ3ktzRQMfabr/CHhEyXIaFFxXVVkzYyqbkXwVy6wOy0vH6wB2s8/Ox JwS0kcJUvBPZ+wJR43syTsKeqVIE82NENCsFwrgzoejU+r0zi7egFyra/OUReJHpymsfbA WaPUqwnjahi2DBSmoThPrguGZAAw90S/iZU7Gt5CmAN/d+iYtcwFY2lNX+iIUl3kdZF/UX VQfu2R5i/m/4ULI7bsGZs7YEx8zw9BsKctd883CNyYjYYfmL/LhC8Qr4uuyp1w== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696521224; a=rsa-sha256; cv=none; b=bWe7ll08JJmSynOoMbiJ7WTdH3JhpYtuI/+qRtg1I25VQWAR3XafIVHPtfzmv2Y3wxEXNa lNst+Hy4D/Mwj/D8HNSRe/Tl5pCc7p5UAmHPyknyXf0MOPNC43YH8BR2UOh0M/l7pRVTKX 9au5/usnXD5c0eayPvOvVqMouPZKi80lLUenV3+U2WQVKKCtxcR0Y/5VaEjZ6ABduixCwG YzWtJWXVzrYI2GPNyDoGqjtubMS0SEW9aJdgk9FLVDEksTnVLLOSaFeiMxQl8FCSvWVLhE Ulnqu9GTwkAgJGtxXQGxuo/JCHlTb12KLhWLhX6MBgeAx7s1XuSuihQpwgS3pQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521224; 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=r1lnMj3u3MjG+uBWoeeSr4FpzJOw02nKRl5Qc4bwSpY=; b=o6SStZ1UYKSPLP7+22l/i6eRz8U3SMgyRLGETnP07jA6rvvJ07nx21/N2zK+iegp9BRxht 0jbhcxuQ5drQHiwUxx8HSjcZAvZkoYpQYcHlbCrmqZRQuYNEq0f/Lbdu1LMgUMMV4sxSMY dqk/Eqqp+4jnWiFggb9SApuIhJEjjZWFH8fZcf0zYW34nhCG46rx5nFKaQv0dLvNh+zaRB OaUNUKl/bW+qinUaQE/bP0VSyHUhaLKfGMOIvrSZE2jE2sXZDSUIP72Ji6dv/Hk5rnbEW7 RqJS085YtgXvjgRFF7LxvU+KGX+jFkBr6JfTGaYuoY9C9uypS2ZSLw4gXwdEnA== 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 4S1bh81Xhsz1Q89; Thu, 5 Oct 2023 15:53:44 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395Fripd046271; Thu, 5 Oct 2023 15:53:44 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395FriGk046268; Thu, 5 Oct 2023 15:53:44 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:53:44 GMT Message-Id: <202310051553.395FriGk046268@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: 4357ae1174f3 - releng/14.0 - libfetch: don't rely on ca_root_nss for certificate validation List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 4357ae1174f37fa2c10f7de7c05536f23e7439c4 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=4357ae1174f37fa2c10f7de7c05536f23e7439c4 commit 4357ae1174f37fa2c10f7de7c05536f23e7439c4 Author: Michael Osipov AuthorDate: 2023-10-03 05:53:20 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2023-10-05 15:52:43 +0000 libfetch: don't rely on ca_root_nss for certificate validation Before certctl(8), there was no system trust store, and libfetch relied on the CA certificate bundle from the ca_root_nss port to verify peers. We now have a system trust store and a reliable mechanism for manipulating it (to explicitly add, remove, or revoke certificates), but if ca_root_nss is installed, libfetch will still prefer that to the system trust store. With this change, unless explicitly overridden, libfetch will rely on OpenSSL to pick up the default system trust store. PR: 256902 MFC after: 3 days Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D42059 Approved by: re (gjb) (cherry picked from commit 09f5c1e118bb4eca77b83a0d08f559b20f60aa59) (cherry picked from commit fb058a9a40a5adc82721ed822fb4fba213446a7b) --- lib/libfetch/common.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/lib/libfetch/common.c b/lib/libfetch/common.c index fd2091791620..dfa742577585 100644 --- a/lib/libfetch/common.c +++ b/lib/libfetch/common.c @@ -1055,8 +1055,6 @@ fetch_ssl_setup_transport_layer(SSL_CTX *ctx, int verbose) /* * Configure peer verification based on environment. */ -#define LOCAL_CERT_FILE _PATH_LOCALBASE "/etc/ssl/cert.pem" -#define BASE_CERT_FILE "/etc/ssl/cert.pem" static int fetch_ssl_setup_peer_verification(SSL_CTX *ctx, int verbose) { @@ -1066,12 +1064,6 @@ fetch_ssl_setup_peer_verification(SSL_CTX *ctx, int verbose) if (getenv("SSL_NO_VERIFY_PEER") == NULL) { ca_cert_file = getenv("SSL_CA_CERT_FILE"); - if (ca_cert_file == NULL && - access(LOCAL_CERT_FILE, R_OK) == 0) - ca_cert_file = LOCAL_CERT_FILE; - if (ca_cert_file == NULL && - access(BASE_CERT_FILE, R_OK) == 0) - ca_cert_file = BASE_CERT_FILE; ca_cert_path = getenv("SSL_CA_CERT_PATH"); if (verbose) { fetch_info("Peer verification enabled"); From nobody Thu Oct 5 15:54:31 2023 X-Original-To: dev-commits-src-branches@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 4S1bj33KtTz4vryf; Thu, 5 Oct 2023 15:54: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1bj32tNsz3LKJ; Thu, 5 Oct 2023 15:54:31 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521271; 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=jY8yNmz2CejtlLAqLY7ivPxQcTnAqCODzKNSqbvZn9g=; b=qdSHOqykG+UWNLmg9tT4NQEq38HXDpaAzJTNPELdYOoIKu+ci7o7uYMDZds06XUW0UFnL+ bGERAlTjcoJ+s0HP/7SSR8KA5Wp4QYa9TT1+I3IzddEmuNOuk8K21gD2MvF/aIaIigF/Gb fhQ3wtX2Ct6lQxC1XNIS9Xsq8TKaHIDjNIR63e73PEPajqhUF/hpsWgs8QJ08GOussz4xP ctvs8BhsZfCz+daMVw/aCpikKFVHyeIKnVeOjLNs1LATqoKx0p4WwCFJIjWhLXiPd+T4Hj EmaeeTSbJrQFjIIllZ14zx45BqlPM0ytVK5urfiGRNX0OTUGgM6pYMrKQiWg4A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696521271; a=rsa-sha256; cv=none; b=w/3e4p9fT9nSs4TkoGu2h5zhy2Rj50AHqd0eLWDymt8lRr0BEMeDrCnSaU3tcSUJvaokyd 7PZQCwzjaql6p2VVs3HvGS29XDK7lJmOKUbo7ty937wqpj/vagQhI4Anz+R4rrJdPrd3Qe Aqz/sYM9dnxTHf+yuZzB0EzNJ5vRa9uhVUKH1MPur8ZA0iLrPUbV944rUgxUhW7dNSsop+ 6yYku0IM7pkjC43je0I5F/MrH1fY7N0CFJfofq9Yc9DujbD2td7feSBTrPLLvL43nOvkgA YbsD0FIXSny+sNgfuWkBYe3jZXr8CoehQGk1EoNaM4dPwURNhZFVprx0NqOKNg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521271; 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=jY8yNmz2CejtlLAqLY7ivPxQcTnAqCODzKNSqbvZn9g=; b=kLS/JUx1+di0udygpnBQoyqzDI+5Lnmg1CUwxkLT1Q6kE3dv0zPsDrQZZMqh7Yj7HLWDd1 AnbVOmoQ2YE/nIviltdkNgW0fvjDjNawbdXYEP78FBI/K3p7yPPgCsKgnORjvL9nFty1pA eYwkKZIOueZGBuL1Q4IWw3cPpvA1apxhXWBFXx8TuDso8eIdCC/J4hgiUjWes4b69d0Rke 0ptQx6r4M1dmgY4EMW7pCqK8FEENOdHbKURf5RNpnnR7cfcnN1xPQaLLLtFDUpg3h4HtVl mGiYNnzgL+KUmOGVya9ejd7RY79kSGFd0r9PfEFxXyE0PcoXDJudgI1gasqqXA== 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 4S1bj31pZRz1Prl; Thu, 5 Oct 2023 15:54:31 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395FsVar046568; Thu, 5 Oct 2023 15:54:31 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395FsViO046565; Thu, 5 Oct 2023 15:54:31 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:54:31 GMT Message-Id: <202310051554.395FsViO046565@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: e76b9cc26d68 - releng/14.0 - release/ec2: Remove references to portsnap List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: e76b9cc26d68fa0d398571c0142acc1a54bcb1a8 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=e76b9cc26d68fa0d398571c0142acc1a54bcb1a8 commit e76b9cc26d68fa0d398571c0142acc1a54bcb1a8 Author: Mark Johnston AuthorDate: 2023-09-27 22:02:36 +0000 Commit: Colin Percival CommitDate: 2023-10-05 15:54:02 +0000 release/ec2: Remove references to portsnap We no longer install a default portsnap.conf, so the sed invocation just generates an error. Reviewed by: cperciva Approved by: re (gjb) Differential Revision: https://reviews.freebsd.org/D42003 (cherry picked from commit 63aa2e91342ead0495eada5667f413f0cf8eb56a) (cherry picked from commit 1cc968931bef915dd700b5eaefc8e6bd13fdb8a0) --- release/tools/ec2.conf | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/release/tools/ec2.conf b/release/tools/ec2.conf index 71f9f5c330cb..d033739adc26 100644 --- a/release/tools/ec2.conf +++ b/release/tools/ec2.conf @@ -126,11 +126,9 @@ EOF 's/^#KbdInteractiveAuthentication yes/KbdInteractiveAuthentication no/' \ ${DESTDIR}/etc/ssh/sshd_config - # Use FreeBSD Update and Portsnap mirrors hosted in AWS + # Use FreeBSD Update mirrors hosted in AWS sed -i '' -e 's/update.FreeBSD.org/aws.update.FreeBSD.org/' \ ${DESTDIR}/etc/freebsd-update.conf - sed -i '' -e 's/portsnap.FreeBSD.org/aws.portsnap.FreeBSD.org/' \ - ${DESTDIR}/etc/portsnap.conf # Use the NTP service provided by Amazon sed -i '' -e 's/^pool/#pool/' \ From nobody Thu Oct 5 15:54:32 2023 X-Original-To: dev-commits-src-branches@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 4S1bj43cLdz4vrn5; Thu, 5 Oct 2023 15:54:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1bj431q3z3LWT; Thu, 5 Oct 2023 15:54:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521272; 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=nve0cm/eqo183xAr46wzmY00uqxTOLK/Akaa9hg2Z0Y=; b=EkaGKWUqgd89iIjulgX8JBEhZDs9XteFkVKfLUH7DBUryhYq408+1p4eWllyrv89Ie1qsZ nqx+RHZx2QMafKKm625Ur21799VIETmZbGaUK614Jcu7j8na30mCgyyi4N6R15PagYcpH3 mJfaEpmBiTqfvKyJncvSefHlQfTgHYCX4YMEfr+R6SzeYROD7Pns64KCGC5nRZ9Znupo4s L4cvWbMnnOxrFf1hEzFD9OAOFlIKH+NimRmtrfEQVhybE/E1oI1bfAEy1FlZI+cYRpa0mo dYrFGxlBNC4PkVVG//edzlJcixNGCnIuYnHjyX0pMphkmIjbE/zuY6XFs+1BZA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696521272; a=rsa-sha256; cv=none; b=bBAftkeArskALDdUdRwpt+VgLzjHMZlMMkRLHIzcL4rPpLdPNvS8slyIPKJc5wcBzm7vxN NdPIlzmM/uVHeXm6pC/mkM5F45YFvZ82PoLgL+o1whQUZoEGMwYJVw+uEl6vvn6BoStiwN +/7i8VUVwnPPFvdlPNPu7NqpblLF6LC6x/7XDey3M866Mt3QVzsd8T4kC18HB2Q96o19sw gcUcBNFBvj1GvH4aG/fOJuUgW8dYvIt6mnOZiw6cczo1UFlVVTgeYxV0VUIEOuLIXQxOzt KZTuhLIqPfIZuP9SII/4GIDya5GpJJR74QFQ7ARnDAWycCL5lnKK8LoJdxNc0w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521272; 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=nve0cm/eqo183xAr46wzmY00uqxTOLK/Akaa9hg2Z0Y=; b=nuQtDLV8lV1nRUb+qIXNK8u9k/Hq961mWhsJUM2sScDkyI2tbyht1LV/tn64hTZ9XtyF5U ewASoui4+cBX/zIzKGI6y6nuXwV/saNhiYJiG3g1WSsOG0b5tpJSd0Q3fewZkju2uLlOst FO/8Nc2CJuNYZ2En1/9qW3stlEBJIQ2UL01/zpnvrXHWNn0Axp+oXZa5du7H00eFC47ZSu Y0snvDQzK9an8/2hOx+z4yNBoWckbFOX0L5pA2cAY/zoYEY13DSpMHxM072sbiTJM1a27j +vmAWMNXBUjXdNhTFPO0ivdtMQm1C5j4R0lVi+ckbRp0KEi1x40BA/NqqrEI2Q== 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 4S1bj427Tsz1QPF; Thu, 5 Oct 2023 15:54:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395FsWkb046613; Thu, 5 Oct 2023 15:54:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395FsWEe046610; Thu, 5 Oct 2023 15:54:32 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:54:32 GMT Message-Id: <202310051554.395FsWEe046610@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: 84d45b29dd3f - releng/14.0 - release/Makefile.vm: Garbage collect unused bits List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 84d45b29dd3f588308c63a52fd1e92b03f50b002 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=84d45b29dd3f588308c63a52fd1e92b03f50b002 commit 84d45b29dd3f588308c63a52fd1e92b03f50b002 Author: Colin Percival AuthorDate: 2023-09-09 00:49:35 +0000 Commit: Colin Percival CommitDate: 2023-10-05 15:54:03 +0000 release/Makefile.vm: Garbage collect unused bits The cw*-package targets were introduced in February 2015 as part of adding support for building GCE images; but GCE support was reworked in June 2015 and the cw*-package targets were in fact never used. Remove them. The *_DISK variables were introduced in February 2015 as part of adding the cloudware-install target; this was removed in May 2016 as the cloudware images are published via the respective cloud systems and not published as disk images via the FreeBSD FTP site. As such, the *_DISK variables are not unused; remove them. Approved by: re (gjb) Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D41789 (cherry picked from commit fcbeeb5ff456b2f21d19d4fc6221774b512e30b7) (cherry picked from commit b9013d75c8531e1eaa993321a22eb7714af10f68) --- release/Makefile.vm | 23 +---------------------- 1 file changed, 1 insertion(+), 22 deletions(-) diff --git a/release/Makefile.vm b/release/Makefile.vm index fb00804a81ec..4041ae14e2f3 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -26,35 +26,27 @@ CLOUDWARE?= BASIC-CI \ AZURE_FORMAT= vhdf AZURE_FSLIST= ufs AZURE_DESC= Microsoft Azure platform image -AZURE_DISK= ${OSRELEASE}.${AZURE_FORMAT} BASIC-CI_FORMAT= raw BASIC-CI_FSLIST= ufs BASIC-CI_DESC= Image for CI -BASIC-CI_DISK= ${OSRELEASE}.${BASIC-CI_FORMAT} EC2_FORMAT= raw EC2_FSLIST= ufs zfs EC2_DESC= Amazon EC2 image -EC2_DISK= ${OSRELEASE}.${EC2_FORMAT} GCE_FORMAT= raw GCE_FSLIST= ufs GCE_DESC= Google Compute Engine image -GCE_DISK= disk.${GCE_FORMAT} OCI_FORMAT= qcow2 OCI_FSLIST= ufs OCI_DESC= Oracle Cloud Infrastructure image -OCI_DISK= ${OSRELEASE}.${OCI_FORMAT} OPENSTACK_FORMAT=qcow2 OPENSTACK_FSLIST= ufs OPENSTACK_DESC= OpenStack platform image -OPENSTACK_DISK= ${OSRELEASE}.${OPENSTACK_FORMAT} VAGRANT-VIRTUALBOX_FORMAT= vmdk VAGRANT-VIRTUALBOX_FSLIST= ufs VAGRANT-VIRTUALBOX_DESC= Vagrant Image for VirtualBox -VAGRANT-VIRTUALBOX_DISK= ${OSRELEASE}.vbox.${VAGRANT_FORMAT} VAGRANT-VMWARE_FORMAT= vmdk VAGRANT-VMWARE_FSLIST= ufs VAGRANT-VMWARE_DESC= Vagrant Image for VMWare -VAGRANT-VMWARE_DISK= ${OSRELEASE}.vmware.${VAGRANT_FORMAT} .for _V in TYPE BRANCH REVISION . if !defined(${_V}) || empty(${_V}) @@ -90,9 +82,7 @@ CLOUDTARGETS+= cw-${_CW:tl}-${_FS} CLEANDIRS+= cw-${_CW:tl}-${_FS} CLEANFILES+= ${_CW:tl}.${_FS}.img \ ${_CW:tl}.${_FS}.${${_CW:tu}_FORMAT} \ - ${_CW:tl}.${_FS}.${${_CW:tu}_FORMAT}.raw \ - cw${_CW:tl}-package -CLOUDPACKAGE+= cw${_CW:tl}-package + ${_CW:tl}.${_FS}.${${_CW:tu}_FORMAT}.raw ${_CW:tu}${_FS:tu}IMAGE= ${_CW:tl}.${_FS}.${${_CW:tu}_FORMAT} cw-${_CW:tl}-${_FS}: emulator-portinstall @@ -114,17 +104,6 @@ CLEANFILES+= ${_CW:tl}.${${_CW:tu}_FORMAT} ${_CW:tu}IMAGE= ${_CW:tl}.${${_CW:tu}_FORMAT} cw-${_CW:tl}: cw-${_CW:tl}-${VMFS} ln -f ${${_CW:tu}${VMFS:tu}IMAGE} ${${_CW:tu}IMAGE} - -cw${_CW:tl}-package: - @# Special target to handle packaging cloud images in the formats - @# specific to each hosting provider. -.if exists(${.CURDIR}/tools/${_CW:tl}-package.sh) - env TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} \ - ${.CURDIR}/tools/${_CW:tl}-package.sh \ - -D ${DESTDIR} -I ${${_CW}_DISK} -S ${WORLDDIR} -.endif - touch ${.TARGET} - . endfor .endif From nobody Thu Oct 5 15:54:33 2023 X-Original-To: dev-commits-src-branches@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 4S1bj54TRXz4vs6L; Thu, 5 Oct 2023 15:54:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1bj542nJz3LfK; Thu, 5 Oct 2023 15:54:33 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521273; 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=VdyopBprf7E8Q/QO/yIjiRWJo8ddrCjPlKz4jT7Uhg4=; b=p2sl29GMNTn0lMrot9M/kZHyUcu1bxvWa1TV7hHfcevNJ5uFSZ5b1k1VegZ0jfseMeKhm9 gxt5ygCiDU3bVKa8M+Q78hT7nk1nXI1BR+tXpS6zbqD+aMGVcfpAqDASfg8UQd9O7FyKjv VWRT+GqKe+mwsiNfWFeI6Wg5KI+DUKB47Qku4x168mvr0uJJYr/KC2dcQhOVA7qUeslQgq bok81nNZOdRnLez9/cQt0Zvb5H+lfoZHb635txDMSoSfu2y/oLGprYVRpv6DnNMrA3zR88 8e3pYMe1oE793+5cWPgtZ892F/YwxEgyLvtzuD2KErmiieL1UkPV37a918KCfw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696521273; a=rsa-sha256; cv=none; b=xIrW4F+jnGX+U+hibP3NSodi0Gw87TMPdPxErCDzx0KSFlRTESCWGV2cBPgdSPRbzEmGNu FoQMUgiwandN0Qrp4gnc2BAVaxT2Ilg5tyYqsoi5b/ypLlbEtOhpUWL+3iS4y9dixeFH3o 2n8jOaibgFXr89kqN+eACClAWNvtzHZrBZK2qYO5JiaiDJTUGJga29mc0F7g3inSqBHn8M 2gHW22otGvnEZ8RE5oeESXXH/QtIJC3yVYmbx00UH6EPnjrM69Z/D0HIJJivmnrpSgIl+6 cf1s8ghDV6h/Y9Rz8teA/rtdG6Zj2rnd5RGmiaVvN3TFqFpYWqkVDymqUv1pbw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521273; 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=VdyopBprf7E8Q/QO/yIjiRWJo8ddrCjPlKz4jT7Uhg4=; b=UlJOVReoGG87J2w2z9fAzlBdG5FFMx8xhIcqS2oGiLHELgbGiBXu7H4/BX6thHqvFBEwxl ESGA/vbt2yka0qLOG8+X3eUmy+9it5Hgea5Snk7mD28pp9jsRfpY8e8HWUA5mQ+ngtuB4T MPeYsttIJKWQgmJeW574V2f8i/rJ2UN8VXpUXNkUupJ7M8vI4dbeEv9q6+SBTb3QggnrDm AwGfnBApJr1nrlRKXMap1gEgeF2nbVO9FPEIogdHPzfDRuNQXtpzCDaERMiwbVI77XizHP xa6n1CixPzQX9CC09pPvJqMqAeXX9MPpAK3RA9gN76OCiuNC5sxYGjWb6xYG0w== 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 4S1bj534ZFz1QPG; Thu, 5 Oct 2023 15:54:33 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395FsXA4046662; Thu, 5 Oct 2023 15:54:33 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395FsX4G046659; Thu, 5 Oct 2023 15:54:33 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:54:33 GMT Message-Id: <202310051554.395FsX4G046659@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: d371e6ef0624 - releng/14.0 - release/Makefile.vm: Add support for CW flavours List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: d371e6ef06242dcb63219d6163d279c7cff847bc Auto-Submitted: auto-generated The branch releng/14.0 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=d371e6ef06242dcb63219d6163d279c7cff847bc commit d371e6ef06242dcb63219d6163d279c7cff847bc Author: Colin Percival AuthorDate: 2023-09-09 00:51:08 +0000 Commit: Colin Percival CommitDate: 2023-10-05 15:54:03 +0000 release/Makefile.vm: Add support for CW flavours There are two "Vagrant" images right now: "Vagrant Image for VirtualBox" and "Vagrant Image for VMWare". Rather than listing these separately in a CLOUDWARE list, place "VAGRANT" into a CLOUDWARE_TYPES list and then use a VAGRANT_FLAVOURS variable to identify the two versions. Add make logic to allow defaults (in this case, image format and filesystem) to be specified once for VAGRANT and inherited by both flavours. This will make future work to add flavoured EC2 images simpler. Approved by: re (gjb) Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D41790 (cherry picked from commit e6eeac9b71795252b12a6b94e7a06633a9ff6e4e) (cherry picked from commit fec4f6a7c377f576c78dabe16bc632ecf20058b4) --- release/Makefile.vm | 26 +++++++++++++++++++------- 1 file changed, 19 insertions(+), 7 deletions(-) diff --git a/release/Makefile.vm b/release/Makefile.vm index 4041ae14e2f3..e7ff86c28df3 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -17,12 +17,11 @@ VMDK_DESC= VMWare, VirtualBox disk image QCOW2_DESC= Qemu, KVM disk image RAW_DESC= Unformatted raw disk image -CLOUDWARE?= BASIC-CI \ +CLOUDWARE_TYPES?= BASIC-CI \ EC2 \ GCE \ OCI \ - VAGRANT-VIRTUALBOX \ - VAGRANT-VMWARE + VAGRANT AZURE_FORMAT= vhdf AZURE_FSLIST= ufs AZURE_DESC= Microsoft Azure platform image @@ -41,13 +40,26 @@ OCI_DESC= Oracle Cloud Infrastructure image OPENSTACK_FORMAT=qcow2 OPENSTACK_FSLIST= ufs OPENSTACK_DESC= OpenStack platform image -VAGRANT-VIRTUALBOX_FORMAT= vmdk -VAGRANT-VIRTUALBOX_FSLIST= ufs +VAGRANT_FORMAT= vmdk +VAGRANT_FSLIST= ufs +VAGRANT_FLAVOURS= VIRTUALBOX VMWARE VAGRANT-VIRTUALBOX_DESC= Vagrant Image for VirtualBox -VAGRANT-VMWARE_FORMAT= vmdk -VAGRANT-VMWARE_FSLIST= ufs VAGRANT-VMWARE_DESC= Vagrant Image for VMWare +.for _CWT in ${CLOUDWARE_TYPES} +. if defined(${_CWT}_FLAVOURS) +. for _CWF in ${${_CWT}_FLAVOURS} +CLOUDWARE_GEN+= ${_CWT}-${_CWF} +${_CWT}-${_CWF}_FORMAT?= ${${_CWT}_FORMAT} +${_CWT}-${_CWF}_FSLIST?= ${${_CWT}_FSLIST} +${_CWT}-${_CWF}_DESC?= ${${_CWT}_DESC} +. endfor +. else +CLOUDWARE_GEN+= ${_CWT} +. endif +.endfor +CLOUDWARE?= ${CLOUDWARE_GEN} + .for _V in TYPE BRANCH REVISION . if !defined(${_V}) || empty(${_V}) ${_V}!= eval $$(awk '/^${_V}=/{print}' ${.CURDIR}/../sys/conf/newvers.sh); echo $$${_V} From nobody Thu Oct 5 15:54:34 2023 X-Original-To: dev-commits-src-branches@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 4S1bj675jfz4vs8Y; Thu, 5 Oct 2023 15:54: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1bj666KMz3Lhv; Thu, 5 Oct 2023 15:54:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521274; 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=7IYMppSIl4VdMOuyXi0UNH05N3F3Q8eWCD7X+ZTm1gA=; b=h6EC/FdAH4DcK/8zUJ6XD0lFzbzOHUrY3U/+810Sy9c2gTCkB2LT0EZTXknygSmLiu9qBH HxhzDtQmyxOESSKbmgdG4pqC1QoOKis/m6W0XgEXA+i08uNEF6PdbCg/Go9Z8Sc5QhHdni VWSV47auOVw9Gdj0o/ssRnWKce0uQ9lMiJ8NMuaprh6Fv1vR00xlvmevdbIxxmaHKn+XtB DTfIQpbO+HVpNKuXEKjhLBYw6+Ex5rLqeV7DNZvW5EHnksH7Bs6cvUTddjccToe2sETQVy iz5sRMHrhoahMUHxPQS4QHTcT9HOkN0M/t7Iofc5hSdBvDgOJtPfi0Nib6bJCA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696521274; a=rsa-sha256; cv=none; b=k/HmlFudCt9XJbslu0NyBvvhkU9CUXgpKQhlrb9NmALR+Lkz35KO3y04BaSqUn+SZGTCn7 kj15fCwV4OozcKPzIcj2TOj9NvSQ7yVvKDk1sMtpdIhCkX6+aQv/pY2TZNjZGGQ9aMJUFo DqUl3LkgwP/J5clPrHgX+14CuEfQdGILDpx+RdmkdkoUfNAtxsPg69H4XReHt5/2x4tqjb JddeKOwRuDi0rOI9a7FJ9syHM0+svRlj6HSerCvVlAC+z3qvX0vh64nOIz3QcYSfwJW3DM EIG5jUwdhBe9ZcSi7MNKbpWBEfxGiRI/TxiZfKdKXQ97oys80lbfNaVVychVog== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521274; 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=7IYMppSIl4VdMOuyXi0UNH05N3F3Q8eWCD7X+ZTm1gA=; b=sZ0ZR2oomR1bJTyjapiyCamXqfUSwnsI1n9p6JZ7G7mTMIVciKrLoVBaiubMTAf7r68pFT pD2gE03twYCs+DJSO1U5v6oxJUnFaTsajZWnuldyaSD2BrNpPA/XEl+BEIjUP0YoSn467e dH1UgA+DI+1AYlANdpWGzVGAzg7j48GjTu/gOUPncyFH3ArAuZha2HtioAMlrqajRR/rvQ J1nwV7rJHIxGC0z1OuYWPgJJF0q4Vz/wV8z1QW92fpx/vwuy7fBeKCGbDmxA8qoLdXBL0G qCo5sxpkrKqf0CX0qCOQ/npIhAEvjmkLmF6wru2JJBfIOU9tqZS/MyoDcJ6jSA== 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 4S1bj64zmFz1Qfp; Thu, 5 Oct 2023 15:54:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395FsYp5046710; Thu, 5 Oct 2023 15:54:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395FsYcb046707; Thu, 5 Oct 2023 15:54:34 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:54:34 GMT Message-Id: <202310051554.395FsYcb046707@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: c34cce0a2bae - releng/14.0 - EC2: Flavour existing AMIs as "base" List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: c34cce0a2bae98ca1fcd1bba6c462f99e733d36b Auto-Submitted: auto-generated The branch releng/14.0 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=c34cce0a2bae98ca1fcd1bba6c462f99e733d36b commit c34cce0a2bae98ca1fcd1bba6c462f99e733d36b Author: Colin Percival AuthorDate: 2023-09-09 00:51:57 +0000 Commit: Colin Percival CommitDate: 2023-10-05 15:54:04 +0000 EC2: Flavour existing AMIs as "base" Using the recently-added "cloudware flavours" mechanism, turn the existing EC2 AMIs into a new "base" flavour. The only user-visible change is that AMI names now include the word "base". Approved by: re (gjb) Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D41791 (cherry picked from commit 7494fb6b7d809257d4eb9eff06ce226143f27add) (cherry picked from commit a18905a9bfccc962f67b8a6067e7cbd4eb2bba17) --- release/Makefile.ec2 | 16 +++++++++------- release/Makefile.vm | 1 + release/tools/{ec2.conf => ec2-base.conf} | 0 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/release/Makefile.ec2 b/release/Makefile.ec2 index b3f32d0e3efb..c674c967ff57 100644 --- a/release/Makefile.ec2 +++ b/release/Makefile.ec2 @@ -51,11 +51,12 @@ cw-ec2-portinstall: @touch ${.TARGET} .for _FS in ${EC2_FSLIST} +.for _FL in ${EC2_FLAVOURS:tl} .if defined(SSMPREFIX) && !empty(SSMPREFIX) -SSMOPTS_${_FS}= --ssm-name ${SSMPREFIX}/${TARGET_ARCH:S/aarch64/arm64/}/base/${_FS}/${REVISION}/${BRANCH} +SSMOPTS_${_FL}_${_FS}= --ssm-name ${SSMPREFIX}/${TARGET_ARCH:S/aarch64/arm64/}/${_FL}/${_FS}/${REVISION}/${BRANCH} .endif -EC2AMILIST+= ec2ami-${_FS} -ec2ami-${_FS}: cw-ec2-${_FS} ${CW_EC2_PORTINSTALL} +EC2AMILIST+= ec2ami-${_FL}-${_FS} +ec2ami-${_FL}-${_FS}: cw-ec2-${_FL}-${_FS} ${CW_EC2_PORTINSTALL} .if !defined(AWSKEYFILE) || !exists(${AWSKEYFILE}) @echo "--------------------------------------------------------------" @echo ">>> AWSKEYFILE must point at AWS keys for EC2 AMI creation" @@ -75,14 +76,15 @@ ec2ami-${_FS}: cw-ec2-${_FS} ${CW_EC2_PORTINSTALL} @false .endif /usr/local/bin/bsdec2-image-upload ${PUBLISH} ${PUBLICSNAP} \ - ${EC2ARCH} ${SSMOPTS_${_FS}} ${BOOTMODEOPT} --sriov --ena \ - ${.OBJDIR}/${EC2${_FS:tu}IMAGE} \ - "${TYPE} ${REVISION}-${BRANCH}-${TARGET}${AMINAMESUFFIX} ${AMIBOOTMETHOD} ${_FS:tu}" \ + ${EC2ARCH} ${SSMOPTS_${_FL}_${_FS}} ${BOOTMODEOPT} --sriov --ena \ + ${.OBJDIR}/${EC2-${_FL:tu}${_FS:tu}IMAGE} \ + "${TYPE} ${REVISION}-${BRANCH}-${TARGET}${AMINAMESUFFIX} ${AMIBOOTMETHOD} ${_FL} ${_FS:tu}" \ "${TYPE}/${TARGET} ${GITBRANCH}@${GITREV}" \ ${AWSREGION} ${AWSBUCKET} ${AWSKEYFILE} \ ${EC2SNSTOPIC} ${EC2SNSREL} ${EC2SNSVERS} @touch ${.TARGET} .endfor +.endfor -ec2ami: ec2ami-${VMFS} +ec2ami: ec2ami-base-${VMFS} ec2amis: ${EC2AMILIST} diff --git a/release/Makefile.vm b/release/Makefile.vm index e7ff86c28df3..8828b99599e7 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -31,6 +31,7 @@ BASIC-CI_DESC= Image for CI EC2_FORMAT= raw EC2_FSLIST= ufs zfs EC2_DESC= Amazon EC2 image +EC2_FLAVOURS= BASE GCE_FORMAT= raw GCE_FSLIST= ufs GCE_DESC= Google Compute Engine image diff --git a/release/tools/ec2.conf b/release/tools/ec2-base.conf similarity index 100% rename from release/tools/ec2.conf rename to release/tools/ec2-base.conf From nobody Thu Oct 5 15:54:35 2023 X-Original-To: dev-commits-src-branches@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 4S1bj80St4z4vs8d; Thu, 5 Oct 2023 15:54:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1bj75xb2z3Lp7; Thu, 5 Oct 2023 15:54:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521275; 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=/OF5BaPu4oFkow2QfULCArUCMuJO6YTes5KZaF+A9ZQ=; b=ECna4/I/Sasp0ncU7IN77tUZ7GOnAl/4KkFtGW5T+azfk0HQWbwg66LuMbvKELUIDXuKLW TrtCDBi3a/wyBpD0p9kWFM97W87LmH0ehSJ+qcHKkOf9TTj3M/nH8yk/dq/14UjxdcriDj 2d0XRDlMcblEFLFEh09mp/UvAPDoZ7KFLE3eofQBuQw7HfcRBCkhlb2ZS2klpj1euEraU8 5aY5H6/5JJpHESoYGxf/Z/d392amCc3vOAqoMWSsmiSCzszGsa488b+q1tYwcHzqvUHT+t kQb5ZvopFLs8DrcSOdZmuIzlUq6fMClEjQed20M/JWNf/VFM3d8oI/Jjmyweog== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696521275; a=rsa-sha256; cv=none; b=r2Q+5qVR/JNIkA5q1UKzkP54M685DPuQBib7h05I+MtjulZ8RiD2toHbl0vFD5bREkPWgs SKoo/j/G6hKsr0GkgrD/02Mq/+g24an9OpUIECxl6fbop0ZGmL/xge8k5qADmi/MW+YCIk BQ44L+JGyJQGc85gqnI9AwjKZ0oN/lqR/nc+NLF258O4BVVI/BWJI78FgsLXSzfEwJVJtz vH7/kwKFt6xHuE0zJTi2cko71tGlaSGzclU8e2gTdqaSdNyhqUB28J2udQUBqEy6e4fb5n zPDHBLytsdK2HPqPgtF/H/LhdBsgs4W0yqkNDO4sV+CGY55z5sLQgyKrgVOogw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521275; 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=/OF5BaPu4oFkow2QfULCArUCMuJO6YTes5KZaF+A9ZQ=; b=M8euVWdXoISraeitMkROju6XSr01Okfl3WRH85f/F00GCXSQrrI9Ybaj6OpvRtFXXIMXXA 4Pu/G60PrvbhTlC9ivLD6Muh9RVpak6z/WF85uQLSkoi527R0jkKH2KoGX14eXAuAhXk/1 GZ1gghI0hSQZ1pmol/4C0KTEhgoAqqs59LSdzh1mJdpr0rWJs3aLTGgtBWkbSTefl1kfUj uAMC1jJMG7e0Xelam8m7h7dPOD/gd5ZcTNKPIbKYE+dAF8aOZXMBs6TDDz92c8hbSnaUWi VjfZ0i7r1O9qhzS2VdwSLLiowty5Vf8+tlElRAgkNoWwh4/04Q9w9OVoJnRg+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 4S1bj752ZZz1QrK; Thu, 5 Oct 2023 15:54:35 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395FsZ8O046763; Thu, 5 Oct 2023 15:54:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395FsZMR046760; Thu, 5 Oct 2023 15:54:35 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:54:35 GMT Message-Id: <202310051554.395FsZMR046760@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: a02a57f65b20 - releng/14.0 - EC2: Split off reusable configuration bits List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: a02a57f65b200aa4a4cb6474d6f389e5d918d8f2 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=a02a57f65b200aa4a4cb6474d6f389e5d918d8f2 commit a02a57f65b200aa4a4cb6474d6f389e5d918d8f2 Author: Colin Percival AuthorDate: 2023-09-09 00:54:11 +0000 Commit: Colin Percival CommitDate: 2023-10-05 15:54:04 +0000 EC2: Split off reusable configuration bits Split ec2-base.conf into ec2-base.conf and a reusable ec2.conf, similar to how Vagrant flavours share a common vagrant.conf. Approved by: re (gjb) Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D41792 (cherry picked from commit fada6e2389fb62ff621a98fab7319e426da58b0b) (cherry picked from commit f4576ea0d5bcc26d8ffdf033cab36c651a5f0885) --- release/tools/ec2-base.conf | 161 ++++++-------------------------------------- release/tools/ec2.conf | 111 ++++++++++++++++++++++++++++++ 2 files changed, 130 insertions(+), 142 deletions(-) diff --git a/release/tools/ec2-base.conf b/release/tools/ec2-base.conf index d033739adc26..f4c46fe285cd 100644 --- a/release/tools/ec2-base.conf +++ b/release/tools/ec2-base.conf @@ -1,78 +1,36 @@ #!/bin/sh -# -# -# Packages to install into the image we're creating. This is a deliberately -# minimalist set, providing only the packages necessary to bootstrap further -# package installation as specified via EC2 user-data. -export VM_EXTRA_PACKAGES="${VM_EXTRA_PACKAGES} ec2-scripts \ - firstboot-freebsd-update firstboot-pkgs isc-dhcp44-client \ - ebsnvme-id" - -# Include the amazon-ssm-agent package in amd64 images, since some users want -# to be able to use it on systems which are not connected to the Internet. -# (It is not enabled by default, however.) This package does not exist for -# aarch64, so we have to be selective about when we install it. -if [ "${TARGET_ARCH}" = "amd64" ]; then - export VM_EXTRA_PACKAGES="${VM_EXTRA_PACKAGES} amazon-ssm-agent" -fi - -# Set to a list of third-party software to enable in rc.conf(5). -export VM_RC_LIST="ec2_configinit ec2_fetchkey ec2_loghostkey firstboot_freebsd_update firstboot_pkgs ntpd dev_aws_disk ec2_ephemeral_swap" +. ${WORLDDIR}/release/tools/ec2.conf -# Build with a 4.9 GB partition; the growfs rc.d script will expand -# the partition to fill the root disk after the EC2 instance is launched. -# Note that if this is set to G, we will end up with an GB disk -# image since VMSIZE is the size of the filesystem partition, not the disk -# which it resides within. -export VMSIZE=5000m +# Packages to install into the image we're creating. In addition to packages +# present on all EC2 AMIs, we install: +# * ec2-scripts, which provides a range of EC2ification startup scripts, +# * firstboot-freebsd-update, to install security updates at first boot, +# * firstboot-pkgs, to install packages at first boot, and +# * isc-dhcp44-client, used for IPv6 network setup. +export VM_EXTRA_PACKAGES="${VM_EXTRA_PACKAGES} ec2-scripts \ + firstboot-freebsd-update firstboot-pkgs isc-dhcp44-client" -# No swap space; the ec2_ephemeralswap rc.d script will allocate swap -# space on EC2 ephemeral disks. (If they exist -- the T2 low-cost instances -# and the C4 compute-optimized instances don't have ephemeral disks. But -# it would be silly to bloat the image and increase costs for every instance -# just for those two families, especially since instances ranging in size -# from 1 GB of RAM to 60 GB of RAM would need different sizes of swap space -# anyway.) -export NOSWAP=YES +# Services to enable in rc.conf(5). +export VM_RC_LIST="${VM_RC_LIST} ec2_configinit ec2_ephemeral_swap \ + ec2_fetchkey ec2_loghostkey firstboot_freebsd_update firstboot_pkgs \ + growfs sshd" vm_extra_pre_umount() { - # The firstboot_pkgs rc.d script will download the repository - # catalogue and install or update pkg when the instance first - # launches, so these files would just be replaced anyway; removing - # them from the image allows it to boot faster. - mount -t devfs devfs ${DESTDIR}/dev - chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \ - /usr/sbin/pkg delete -f -y pkg - umount ${DESTDIR}/dev - rm ${DESTDIR}/var/db/pkg/repo-*.sqlite - - # The size of the EC2 root disk can be configured at instance launch - # time; expand our filesystem to fill the disk. - echo 'growfs_enable="YES"' >> ${DESTDIR}/etc/rc.conf - - # EC2 instances use DHCP to get their network configuration. IPv6 - # requires accept_rtadv. - echo 'ifconfig_DEFAULT="SYNCDHCP accept_rtadv"' >> ${DESTDIR}/etc/rc.conf - - # Unless the system has been configured via EC2 user-data, the user - # will need to SSH in to do anything. - echo 'sshd_enable="YES"' >> ${DESTDIR}/etc/rc.conf - # The AWS CLI tools are generally useful, and small enough that they # will download quickly; but users will often override this setting # via EC2 user-data. echo 'firstboot_pkgs_list="devel/py-awscli"' >> ${DESTDIR}/etc/rc.conf + # EC2 instances use DHCP to get their network configuration. IPv6 + # requires accept_rtadv. + echo 'ifconfig_DEFAULT="SYNCDHCP accept_rtadv"' >> ${DESTDIR}/etc/rc.conf + # Enable IPv6 on all interfaces, and spawn DHCPv6 via rtsold echo 'ipv6_activate_all_interfaces="YES"' >> ${DESTDIR}/etc/rc.conf echo 'rtsold_enable="YES"' >> ${DESTDIR}/etc/rc.conf echo 'rtsold_flags="-M /usr/local/libexec/rtsold-M -a"' >> ${DESTDIR}/etc/rc.conf - # Turn off IPv6 Duplicate Address Detection; the EC2 networking - # configuration makes it unnecessary. - echo 'net.inet6.ip6.dad_count=0' >> ${DESTDIR}/etc/sysctl.conf - # Provide a script which rtsold can use to launch DHCPv6 mkdir -p ${DESTDIR}/usr/local/libexec cat > ${DESTDIR}/usr/local/libexec/rtsold-M <<'EOF' @@ -82,94 +40,13 @@ vm_extra_pre_umount() { EOF chmod 755 ${DESTDIR}/usr/local/libexec/rtsold-M - # The EC2 console is output-only, so while printing a backtrace can - # be useful, there's no point dropping into a debugger or waiting - # for a keypress. - echo 'debug.trace_on_panic=1' >> ${DESTDIR}/boot/loader.conf - echo 'debug.debugger_on_panic=0' >> ${DESTDIR}/boot/loader.conf - echo 'kern.panic_reboot_wait_time=0' >> ${DESTDIR}/boot/loader.conf - - # The console is not interactive, so we might as well boot quickly. - echo 'autoboot_delay="-1"' >> ${DESTDIR}/boot/loader.conf - echo 'beastie_disable="YES"' >> ${DESTDIR}/boot/loader.conf - - # Tell gptboot not to wait 3 seconds for a keypress which won't - # arrive either. - printf -- "-n\n" > ${DESTDIR}/boot.config - - # The emulated keyboard attached to EC2 instances is inaccessible to - # users, and there is no mouse attached at all; disable to keyboard - # and the keyboard controller (to which the mouse would attach, if - # one existed) in order to save time in device probing. - echo 'hint.atkbd.0.disabled=1' >> ${DESTDIR}/boot/loader.conf - echo 'hint.atkbdc.0.disabled=1' >> ${DESTDIR}/boot/loader.conf - - # EC2 has two consoles: An emulated serial port ("system log"), - # which has been present since 2006; and a VGA console ("instance - # screenshot") which was introduced in 2016. - echo 'boot_multicons="YES"' >> ${DESTDIR}/boot/loader.conf - - # Some older EC2 hardware used a version of Xen with a bug in its - # emulated serial port. It is not clear if EC2 still has any such - # nodes, but apply the workaround just in case. - echo 'hw.broken_txfifo="1"' >> ${DESTDIR}/boot/loader.conf - - # Load the kernel module for the Amazon "Elastic Network Adapter" - echo 'if_ena_load="YES"' >> ${DESTDIR}/boot/loader.conf - - # Use the "nda" driver for accessing NVMe disks rather than the - # historical "nvd" driver. - echo 'hw.nvme.use_nvd="0"' >> ${DESTDIR}/boot/loader.conf - - # Disable KbdInteractiveAuthentication according to EC2 requirements. - sed -i '' -e \ - 's/^#KbdInteractiveAuthentication yes/KbdInteractiveAuthentication no/' \ - ${DESTDIR}/etc/ssh/sshd_config - - # Use FreeBSD Update mirrors hosted in AWS - sed -i '' -e 's/update.FreeBSD.org/aws.update.FreeBSD.org/' \ - ${DESTDIR}/etc/freebsd-update.conf - - # Use the NTP service provided by Amazon - sed -i '' -e 's/^pool/#pool/' \ - -e '1,/^#server/s/^#server.*/server 169.254.169.123 iburst/' \ - ${DESTDIR}/etc/ntp.conf - - # Provide a map for accessing Elastic File System mounts - cat > ${DESTDIR}/etc/autofs/special_efs <<'EOF' -#!/bin/sh - -if [ $# -eq 0 ]; then - # No way to know which EFS filesystems exist and are - # accessible to this EC2 instance. - exit 0 -fi - -# Provide instructions on how to mount the requested filesystem. -FS=$1 -REGION=`fetch -qo- http://169.254.169.254/latest/meta-data/placement/availability-zone | sed -e 's/[a-z]$//'` -echo "-nfsv4,minorversion=1,oneopenown ${FS}.efs.${REGION}.amazonaws.com:/" -EOF - chmod 755 ${DESTDIR}/etc/autofs/special_efs - - # The first time the AMI boots, the installed "first boot" scripts - # should be allowed to run: - # * ec2_configinit (download and process EC2 user-data) - # * ec2_fetchkey (arrange for SSH using the EC2-provided public key) - # * growfs (expand the filesystem to fill the provided disk) - # * firstboot_freebsd_update (install critical updates) - # * firstboot_pkgs (install packages) - touch ${DESTDIR}/firstboot - # Any EC2 ephemeral disks seen when the system first boots will # be "new" disks; there is no "previous boot" when they might have # been seen and used already. touch ${DESTDIR}/var/db/ec2_ephemeral_diskseen - if ! [ -z "${QEMUSTATIC}" ]; then - rm -f ${DESTDIR}/${EMULATOR} - fi - rm -f ${DESTDIR}/etc/resolv.conf + # Configuration common to all EC2 AMIs + ec2_common return 0 } diff --git a/release/tools/ec2.conf b/release/tools/ec2.conf new file mode 100644 index 000000000000..a233bf5981c1 --- /dev/null +++ b/release/tools/ec2.conf @@ -0,0 +1,111 @@ +#!/bin/sh + +# Packages which should be installed onto all EC2 AMIs: +# * ebsnvme-id, which is very minimal and provides important EBS-specific +# functionality, +# * amazon-ssm-agent (not enabled by default, but some users need to use +# it on systems not connected to the internet). +export VM_EXTRA_PACKAGES="${VM_EXTRA_PACKAGES} ebsnvme-id amazon-ssm-agent" + +# Services which should be enabled by default in rc.conf(5). +export VM_RC_LIST="dev_aws_disk ntpd" + +# Build with a 4.9 GB partition; the growfs rc.d script will expand +# the partition to fill the root disk after the EC2 instance is launched. +# Note that if this is set to G, we will end up with an GB disk +# image since VMSIZE is the size of the filesystem partition, not the disk +# which it resides within. +export VMSIZE=5000m + +# No swap space; it doesn't make sense to provision any as part of the disk +# image when we could be launching onto a system with anywhere between 0.5 +# and 4096 GB of RAM. +export NOSWAP=YES + +ec2_common() { + # Delete the pkg package and the repo database; they will likely be + # long out of date before the EC2 instance is launched. + mount -t devfs devfs ${DESTDIR}/dev + chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \ + /usr/sbin/pkg delete -f -y pkg + umount ${DESTDIR}/dev + rm ${DESTDIR}/var/db/pkg/repo-*.sqlite + + # Turn off IPv6 Duplicate Address Detection; the EC2 networking + # configuration makes it unnecessary. + echo 'net.inet6.ip6.dad_count=0' >> ${DESTDIR}/etc/sysctl.conf + + # Booting quickly is more important than giving users a chance to + # access the boot loader via the serial port. + echo 'autoboot_delay="-1"' >> ${DESTDIR}/boot/loader.conf + echo 'beastie_disable="YES"' >> ${DESTDIR}/boot/loader.conf + + # Tell gptboot not to wait 3 seconds for a keypress which will + # never arrive. + printf -- "-n\n" > ${DESTDIR}/boot.config + + # The emulated keyboard attached to EC2 instances is inaccessible to + # users, and there is no mouse attached at all; disable to keyboard + # and the keyboard controller (to which the mouse would attach, if + # one existed) in order to save time in device probing. + echo 'hint.atkbd.0.disabled=1' >> ${DESTDIR}/boot/loader.conf + echo 'hint.atkbdc.0.disabled=1' >> ${DESTDIR}/boot/loader.conf + + # EC2 has two consoles: An emulated serial port ("system log"), + # which has been present since 2006; and a VGA console ("instance + # screenshot") which was introduced in 2016. + echo 'boot_multicons="YES"' >> ${DESTDIR}/boot/loader.conf + + # Some older EC2 hardware used a version of Xen with a bug in its + # emulated serial port. It is not clear if EC2 still has any such + # nodes, but apply the workaround just in case. + echo 'hw.broken_txfifo="1"' >> ${DESTDIR}/boot/loader.conf + + # Load the kernel module for the Amazon "Elastic Network Adapter" + echo 'if_ena_load="YES"' >> ${DESTDIR}/boot/loader.conf + + # Use the "nda" driver for accessing NVMe disks rather than the + # historical "nvd" driver. + echo 'hw.nvme.use_nvd="0"' >> ${DESTDIR}/boot/loader.conf + + # Disable KbdInteractiveAuthentication according to EC2 requirements. + sed -i '' -e \ + 's/^#KbdInteractiveAuthentication yes/KbdInteractiveAuthentication no/' \ + ${DESTDIR}/etc/ssh/sshd_config + + # Use FreeBSD Update mirrors hosted in AWS + sed -i '' -e 's/update.FreeBSD.org/aws.update.FreeBSD.org/' \ + ${DESTDIR}/etc/freebsd-update.conf + + # Use the NTP service provided by Amazon + sed -i '' -e 's/^pool/#pool/' \ + -e '1,/^#server/s/^#server.*/server 169.254.169.123 iburst/' \ + ${DESTDIR}/etc/ntp.conf + + # Provide a map for accessing Elastic File System mounts + cat > ${DESTDIR}/etc/autofs/special_efs <<'EOF' +#!/bin/sh + +if [ $# -eq 0 ]; then + # No way to know which EFS filesystems exist and are + # accessible to this EC2 instance. + exit 0 +fi + +# Provide instructions on how to mount the requested filesystem. +FS=$1 +REGION=`fetch -qo- http://169.254.169.254/latest/meta-data/placement/availability-zone | sed -e 's/[a-z]$//'` +echo "-nfsv4,minorversion=1,oneopenown ${FS}.efs.${REGION}.amazonaws.com:/" +EOF + chmod 755 ${DESTDIR}/etc/autofs/special_efs + + # The first time the AMI boots, run "first boot" scripts. + touch ${DESTDIR}/firstboot + + if ! [ -z "${QEMUSTATIC}" ]; then + rm -f ${DESTDIR}/${EMULATOR} + fi + rm -f ${DESTDIR}/etc/resolv.conf + + return 0 +} From nobody Thu Oct 5 15:54:36 2023 X-Original-To: dev-commits-src-branches@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 4S1bj91GZ2z4vs6f; Thu, 5 Oct 2023 15:54: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1bj90LRJz3Lx9; Thu, 5 Oct 2023 15:54:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521277; 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=XYA9MoCwefY1QO7OhgbLvze5egX85oFUnkbWC6ppYOk=; b=h8yzQSHiisrFnQ00lFCaXbvUjzX6uL51lXb3NWfybGhrafcAr3cx3fv8oLH+py06s3jXqd 59X0cormRFA35Ren6wNm9Q/IW3g2RWPKx8rw3NVVR98umo8mrpv0+FAp1uBSLyqi1aG4UJ OLjAdqHEjT313SA9yzHTuGBniMgPcN5ryLuwSyLwosvfnFb35gfPIcZ/Z/OsV/4PzG0Z5v oTH3yJYOb0kC1c5Ek4BaeDlZsGk4RHTJNylG9mDsdAySAq8X1xmpolFk4IwofFvFzvd6hu mpxcVJz1FbGr5dM9ii0S2s+CMUoGJDjSMFEGK3MYTac7icci1S26pdqaHz+yhw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696521277; a=rsa-sha256; cv=none; b=hQnJZjp9I/gxjhcD4LMWXX56ffgx2oYq2yHtJ6HBBUPYowOB2AjtGd0c7fS3CTvlCoQiGA 2bpYk9xeGEOOZ3V1gYsCalsH/e9JArKDxgWBaRd10pnXxVYVR29xkNCtajn5LNhNre/5TM /vKGDvoJOB9w2A437pha/C7NbSsBgSpng+mAb8NodCZvLW+0fJGjUme5Na1GFlO9lzdZgV XOZG245N4Bfd+JZYFgcD+330fq+/5S3B4jttfazEEK3Dc0OriELrONPfbWp+oWUSKUdAWE YkzTr/vHCVHWi7OaFD2Ggp1CJG2g4K9ZdQVEeQDDh1xpha1SFN7oYmTglcOGkw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521277; 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=XYA9MoCwefY1QO7OhgbLvze5egX85oFUnkbWC6ppYOk=; b=McvykfMR+5Dc3rtE/HODrVqazQuemPVfhM3fwM6f98XK7T1CvBMECuqKQMMfydSir9MK62 fT/dNcDNo4hVpH/0PoBczvjo5Pak9tBZ4k8Yytw4ks3LerEPz6EH6D9tofSgneiAotQQmH Zm/3n8V07/CyQqSgM6b71G+Z+ohwi936YCyK3lTZX1p0H49l8/F+JCCuI2+nFDZCtJcSQn fEa2iijaDcW+C38YGVJPExL9RhJk5fd2vcWdcINHAy1MnUyfqfMS2KLTEebyLTaYiQIRaW 6MhwdWihQWm0O28I035ZELXIJ+bs5ExlACXKqIWMd8Z3c11KmD3Ob4cN0mM8QQ== 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 4S1bj86P4Pz1Qck; Thu, 5 Oct 2023 15:54:36 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395Fsamr046808; Thu, 5 Oct 2023 15:54:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395FsatF046805; Thu, 5 Oct 2023 15:54:36 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:54:36 GMT Message-Id: <202310051554.395FsatF046805@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Colin Percival Subject: git: bdd892341813 - releng/14.0 - EC2: Add experimental cloud-init images List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/releng/14.0 X-Git-Reftype: branch X-Git-Commit: bdd89234181337347ea6a81677875fc676325380 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=bdd89234181337347ea6a81677875fc676325380 commit bdd89234181337347ea6a81677875fc676325380 Author: Colin Percival AuthorDate: 2023-09-09 00:55:16 +0000 Commit: Colin Percival CommitDate: 2023-10-05 15:54:04 +0000 EC2: Add experimental cloud-init images Known issues: 1. The ec2-user user is created with a homedir of /usr/home/ec2-user instead of /home/ec2-user; this appears to be a bug in cloud-init's FreeBSD support. 2. Cloud-init configures IPv4 networking but not IPv6 networking. Approved by: re (gjb) Relnotes: yes Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D41793 (cherry picked from commit 1f4ce7a39f0f4b0621ff55d228014ccddb366d37) (cherry picked from commit d9243c1ab3cd8e744aaf54177232cdbffa07392d) --- release/Makefile.vm | 5 +++-- release/tools/ec2-cloud-init.conf | 31 +++++++++++++++++++++++++++++++ 2 files changed, 34 insertions(+), 2 deletions(-) diff --git a/release/Makefile.vm b/release/Makefile.vm index 8828b99599e7..09e31e3c0b6f 100644 --- a/release/Makefile.vm +++ b/release/Makefile.vm @@ -30,8 +30,9 @@ BASIC-CI_FSLIST= ufs BASIC-CI_DESC= Image for CI EC2_FORMAT= raw EC2_FSLIST= ufs zfs -EC2_DESC= Amazon EC2 image -EC2_FLAVOURS= BASE +EC2_FLAVOURS= BASE CLOUD-INIT +EC2-BASE_DESC= Amazon EC2 image +EC2-CLOUD-INIT_DESC= Amazon EC2 Cloud-Init image GCE_FORMAT= raw GCE_FSLIST= ufs GCE_DESC= Google Compute Engine image diff --git a/release/tools/ec2-cloud-init.conf b/release/tools/ec2-cloud-init.conf new file mode 100644 index 000000000000..2dd4df390fa3 --- /dev/null +++ b/release/tools/ec2-cloud-init.conf @@ -0,0 +1,31 @@ +#!/bin/sh + +. ${WORLDDIR}/release/tools/ec2.conf + +# Packages to install into the image we're creating. In addition to packages +# present on all EC2 AMIs, we install cloud-init. +export VM_EXTRA_PACKAGES="${VM_EXTRA_PACKAGES} net/cloud-init" + +# Services to enable in rc.conf(5). +export VM_RC_LIST="${VM_RC_LIST} cloudinit sshd" + +vm_extra_pre_umount() { + # Configuration common to all EC2 AMIs + ec2_common + + # Configure cloud-init + cat <<-'EOF' > ${DESTDIR}/usr/local/etc/cloud/cloud.cfg.d/98_ec2.cfg + disable_root: true + system_info: + distro: freebsd + default_user: + name: ec2-user + lock_passwd: True + groups: [wheel] + shell: /bin/sh + # Currently broken, cloud-init hard-codes to /usr/home/* + homedir: /home/ec2-user + EOF + + return 0 +} From nobody Thu Oct 5 15:56:04 2023 X-Original-To: dev-commits-src-branches@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 4S1bks1VC5z4vs7M; Thu, 5 Oct 2023 15:56: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1bks0xKgz3NC2; Thu, 5 Oct 2023 15:56:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521365; 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=KhSu87BABk2HuzXshRMaCvkeekorLq7wwIsZqH+TPuM=; b=f2A7IRnFT6xqDyWkRoRbAy5vKqRTnu0wm02EdpYDVgtZbafBWgYO6E40JTx9ntHtXHtxsE BCQqmzHNlA5eCUfH5xOmfgx/nlVn+UlGWh9wCFoBBwYsgZF4huEvwrp0xI+Kpdbkr6NDau vkcNbzsW9yYH5w+/74CUl3AaoFIfpQG1EWQMZXPX5H+d9HXdgWBpSkKICLlN1aAqdrgPh+ AQGVzu6PUTiKMae3EPJdQxKoNSwReAm4MSkZF9ubxfWwt5K15PQKDqRaUWbrxHRhh9iIMO j3leQgo3XZCw2oYLRHDu/R3Io8bkP/u7XAHfdWIazZGM0JQqi3ZGR9OobQgq8g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696521365; a=rsa-sha256; cv=none; b=ex/FUm9PG4j8S/AkYGzHv69Ie5LfIbOkB0nCcULnF3YjYshgtF4e52u9CkMwx+cFIKDewp GULyNSTpsA9vzejgFRDqjIQFX1Mmmxo3NCrvY3IXnn1++nPeFlquAj2CIE4bDIfmTl9mWB xfYDgAofyJvz2SSWnUK5Dt5QpJnTgZ5+QBDjZCnqi1J1D9PpKAkzXNB96qN9Cc+kA2rtx3 9zyGzg0MVxX8gWC0UI33jmLXlQy1e0xOPKrIJuMHXVJ6eiDwpJxcc8VIcnZOju0yIfM+uU khfoVFx8ha3QZHuqJqQU/hQhH6+GMqc2rbMhJ5vfVHofP/B2GXBWhMJf9uJj7g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521365; 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=KhSu87BABk2HuzXshRMaCvkeekorLq7wwIsZqH+TPuM=; b=BC/SIyFdQnRUEcYxapWfKTEuJCFhoWyg6b1gcO0ekCLzFxmynSVe1zIlXVSjr52Y1L6cqq 5U1a8sS/tYzVKfhTBanUSggVR5EdkoshP/nl4vM+5Fp6WZw6Qe8n4pRgMZTDaxLBKYoU0T Ekn+rA29CEV5Z/wbZYoyPOZ/wfpUkQblhOx6iVwWLXv1dE9PTVoUxOreQrLBBWYWrjHn+p BmecoThu9itpF6LO+FgAQ9WHkaHU43Avb+NSKhdXzJCIPJ/lctcB51b0Z2rnK0ZSuEp89F OcloK5uMEAXt08X4jUlqvG1/PGOS4rZA7kuNX0f3uCW79QJ1mGfa7tGBy6OmWQ== 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 4S1bkr75Y4z1QQy; Thu, 5 Oct 2023 15:56:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395Fu474047249; Thu, 5 Oct 2023 15:56:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395Fu48F047246; Thu, 5 Oct 2023 15:56:04 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:56:04 GMT Message-Id: <202310051556.395Fu48F047246@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: 681fbce51d33 - stable/13 - libc: Rewrite quick_exit() and at_quick_exit() using C11 atomics. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/13 X-Git-Reftype: branch X-Git-Commit: 681fbce51d337febf945a9f66592711f56cf3f51 Auto-Submitted: auto-generated The branch stable/13 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=681fbce51d337febf945a9f66592711f56cf3f51 commit 681fbce51d337febf945a9f66592711f56cf3f51 Author: Dag-Erling Smørgrav AuthorDate: 2023-09-26 20:06:27 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2023-10-05 15:55:29 +0000 libc: Rewrite quick_exit() and at_quick_exit() using C11 atomics. Compiler memory barriers do not prevent the CPU from executing the code out of order. Switch to C11 atomics. This also lets us get rid of the mutex; instead, loop until the compare_exchange succeeds. While here, change the return value of at_quick_exit() on failure to the more traditional -1, matching atexit(). Sponsored by: Klara, Inc. Reviewed by: Olivier Certner, kevans, kib Differential Revision: https://reviews.freebsd.org/D41936 (cherry picked from commit 1dc3abb052430279e47c8922d22b30922adcf0f6) libc: Add a rudimentary test for quick_exit(3). Sponsored by: Klara, Inc. Reviewed by: kib Differential Revision: https://reviews.freebsd.org/D41937 (cherry picked from commit c7dd4601aeebbc1bbe131cbe6747476c124b47fe) --- lib/libc/stdlib/quick_exit.c | 40 +++++++--------- lib/libc/tests/stdlib/Makefile | 1 + lib/libc/tests/stdlib/quick_exit_test.c | 81 +++++++++++++++++++++++++++++++++ 3 files changed, 98 insertions(+), 24 deletions(-) diff --git a/lib/libc/stdlib/quick_exit.c b/lib/libc/stdlib/quick_exit.c index 05db690cb6e7..4dee7b20bd2b 100644 --- a/lib/libc/stdlib/quick_exit.c +++ b/lib/libc/stdlib/quick_exit.c @@ -2,6 +2,7 @@ * SPDX-License-Identifier: BSD-2-Clause * * Copyright (c) 2011 David Chisnall + * Copyright (c) 2023 Klara, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -27,44 +28,35 @@ */ #include -#include + +#include #include -#include /** - * Linked list of quick exit handlers. This is simpler than the atexit() - * version, because it is not required to support C++ destructors or - * DSO-specific cleanups. + * Linked list of quick exit handlers. These will be invoked in reverse + * order of insertion when quick_exit() is called. This is simpler than + * the atexit() version, because it is not required to support C++ + * destructors or DSO-specific cleanups. */ struct quick_exit_handler { struct quick_exit_handler *next; void (*cleanup)(void); }; -/** - * Lock protecting the handlers list. - */ -static pthread_mutex_t atexit_mutex = PTHREAD_MUTEX_INITIALIZER; -/** - * Stack of cleanup handlers. These will be invoked in reverse order when - */ -static struct quick_exit_handler *handlers; +static _Atomic(struct quick_exit_handler *) handlers; int at_quick_exit(void (*func)(void)) { struct quick_exit_handler *h; - - h = malloc(sizeof(*h)); - if (NULL == h) - return (1); + if ((h = calloc(1, sizeof(*h))) == NULL) { + return (-1); + } h->cleanup = func; - pthread_mutex_lock(&atexit_mutex); - h->next = handlers; - __compiler_membar(); - handlers = h; - pthread_mutex_unlock(&atexit_mutex); + while (!atomic_compare_exchange_strong(&handlers, &h->next, h)) { + /* nothing */ ; + } return (0); } @@ -77,8 +69,8 @@ quick_exit(int status) * XXX: The C++ spec requires us to call std::terminate if there is an * exception here. */ - for (h = handlers; NULL != h; h = h->next) { - __compiler_membar(); + for (h = atomic_load_explicit(&handlers, memory_order_acquire); + h != NULL; h = h->next) { h->cleanup(); } _Exit(status); diff --git a/lib/libc/tests/stdlib/Makefile b/lib/libc/tests/stdlib/Makefile index 772c470e8865..aa2fa7683cb7 100644 --- a/lib/libc/tests/stdlib/Makefile +++ b/lib/libc/tests/stdlib/Makefile @@ -10,6 +10,7 @@ ATF_TESTS_C+= qsort_b_test .endif ATF_TESTS_C+= qsort_r_test ATF_TESTS_C+= qsort_s_test +ATF_TESTS_C+= quick_exit_test ATF_TESTS_C+= set_constraint_handler_s_test ATF_TESTS_C+= strfmon_test ATF_TESTS_C+= tsearch_test diff --git a/lib/libc/tests/stdlib/quick_exit_test.c b/lib/libc/tests/stdlib/quick_exit_test.c new file mode 100644 index 000000000000..9feed8a6fa63 --- /dev/null +++ b/lib/libc/tests/stdlib/quick_exit_test.c @@ -0,0 +1,81 @@ +/*- + * Copyright (c) 2023 Klara, Inc. + * + * SPDX-License-Identifier: BSD-2-Clause + */ + +#include + +#include +#include +#include + +#include + +static void func_a(void) +{ + if (write(STDOUT_FILENO, "a", 1) != 1) + _Exit(1); +} + +static void func_b(void) +{ + if (write(STDOUT_FILENO, "b", 1) != 1) + _Exit(1); +} + +static void func_c(void) +{ + if (write(STDOUT_FILENO, "c", 1) != 1) + _Exit(1); +} + +static void child(void) +{ + // this will be received by the parent + printf("hello, "); + fflush(stdout); + // this won't, because quick_exit() does not flush + printf("world"); + // these will be called in reverse order, producing "abc" + if (at_quick_exit(func_c) != 0 || + at_quick_exit(func_b) != 0 || + at_quick_exit(func_a) != 0) + _Exit(1); + quick_exit(0); +} + +ATF_TC_WITHOUT_HEAD(quick_exit); +ATF_TC_BODY(quick_exit, tc) +{ + char buf[100] = ""; + ssize_t len; + int p[2], wstatus = 0; + pid_t pid; + + ATF_REQUIRE(pipe(p) == 0); + pid = fork(); + if (pid == 0) { + if (dup2(p[1], STDOUT_FILENO) < 0) + _Exit(1); + (void)close(p[1]); + (void)close(p[0]); + child(); + _Exit(1); + } + ATF_REQUIRE_MSG(pid > 0, + "expect fork() to succeed"); + ATF_CHECK_EQ_MSG(pid, waitpid(pid, &wstatus, 0), + "expect to collect child process"); + ATF_CHECK_EQ_MSG(0, wstatus, + "expect child to exit cleanly"); + ATF_CHECK_MSG((len = read(p[0], buf, sizeof(buf))) > 0, + "expect to receive output from child"); + ATF_CHECK_STREQ("hello, abc", buf); +} + +ATF_TP_ADD_TCS(tp) +{ + ATF_TP_ADD_TC(tp, quick_exit); + return (atf_no_error()); +} From nobody Thu Oct 5 15:56:06 2023 X-Original-To: dev-commits-src-branches@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 4S1bkt4Ntjz4vs09; Thu, 5 Oct 2023 15:56: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1bkt2hR0z3NVk; Thu, 5 Oct 2023 15:56:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521366; 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=c6LtYUpSOPQO2IJZ+n8T0us1oQ1PWrsGhhXiKmslT94=; b=uQbIWcBUEATNAz/RbbheQeXtD+EzAbfWuwjjd+WbTKKEB+tn3Ho8XY44VsDvK3ehYeL6fY P5RQrIaSXgaw4UOxR/jtCLjyOc+2Yknne5jprvu+R4QGzC4RyRFAIDEapbyQo6BWnijTma /Qq1U4mT7wxmGSwsQojCJrcoFLwvlyZh76By3xcRcl5xpa52+2Zrel1Qv/GI4snRlM+hkK mfQ+fmHs5r2yVHhxyBJz77KoL2Pu0HFC1QTnaphLrS5/D++q79+v17P+vcvPBZ8ovK7lFn 9AJZ29GeyGhuqCsqNxFdyGI8GqvoGpapqd79t8rRC9msPVrJtrCs1yhTuDp+UQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696521366; a=rsa-sha256; cv=none; b=gQeORLG2tUUvE/Wf/oohRUsdvulrYapRLj5M2QQblnROd7oVn1xPMbYGbff5J5HM3hRqSY eJNeBIplAeXGHC11GBMk9MJlrbxv8GgIIXdG08lexM3xp0WFB9PWnSOqzKkYFDXhwxa1e/ Bj1r1T4352O8O+D+tlOSJ9QPVs1FGpYIUzczK2clIHB7fF8lpzKOay7Nn9p7mmZNCA1YJ9 ChFXeLAq2h5lwIVsJRAy4gBoodDPFBqmWguFqrpF71PPlFrtojZx8JEbDJHNkEhBfZPgFu 0RDJ/fGu272g+cOj39B9/t8rHDGy9gbC+MMgrfS3yYpIsMjC2wcFT8IpyUCmMw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521366; 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=c6LtYUpSOPQO2IJZ+n8T0us1oQ1PWrsGhhXiKmslT94=; b=sNhGgquq6pIXegbueuZlvbaf82FPupUTeyTOX5FrM+lXuBey1MPrOakwEURrHR5aZmSVyM lQGsPghmzBofO77kDkmuA/Kf7tjZEK7uQAyb8/UfoIPF9uPDYIq42cl4RA/olfh8xUvrVw B4GNHMSAj4UWSEE4Xb4YDEvNENwemvubYtuIozvmgZtyc877rgh5faLDdae3w5IcY3kBXL pnndDNYDS787VrLmojzhDstyjx7WRjh/+v7kL603oDstZT/uRJVWkBhLGaJdZYuWuBaxuZ UlHEyRDXnUQFyoAuKkqsyOzfeH+pMU26u9ga7j1JAPGeWIBOS2xj8Y3qtaSEqQ== 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 4S1bkt1Nczz1QpR; Thu, 5 Oct 2023 15:56:06 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395Fu6fA047294; Thu, 5 Oct 2023 15:56:06 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395Fu62U047291; Thu, 5 Oct 2023 15:56:06 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:56:06 GMT Message-Id: <202310051556.395Fu62U047291@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: db95aeb922c9 - stable/13 - split: Further option parsing improvements. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/13 X-Git-Reftype: branch X-Git-Commit: db95aeb922c9ca20d0914a6ee449064e6d507fe8 Auto-Submitted: auto-generated The branch stable/13 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=db95aeb922c9ca20d0914a6ee449064e6d507fe8 commit db95aeb922c9ca20d0914a6ee449064e6d507fe8 Author: Dag-Erling Smørgrav AuthorDate: 2023-09-28 16:29:52 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2023-10-05 15:55:30 +0000 split: Further option parsing improvements. * Whenever possible, use strtonum() to parse numeric arguments. * Improve usefulness and consistency of error messages. * While here, fix some type and style issues. Sponsored by: Klara, Inc. Reviewed by: christos, kevans Differential Revision: https://reviews.freebsd.org/D42010 (cherry picked from commit d7399551b02861b910b15c7b7a78a2835644aa45) split: Improve GNU compatibility. * Like GNU split, turn autoextend back on if given -a0. * Add a test case that verifies that -a turns autoextend off. * Add a test case that verifies that -a0 turns autoextend back on. Sponsored by: Klara, Inc. Reviewed by: christos, kevans Differential Revision: https://reviews.freebsd.org/D42011 (cherry picked from commit d9d69a6f6fc1f8d80df9ce6493e8ab9388781615) --- usr.bin/split/split.c | 89 ++++++++++++++++++++++----------------- usr.bin/split/tests/split_test.sh | 19 +++++++++ 2 files changed, 70 insertions(+), 38 deletions(-) diff --git a/usr.bin/split/split.c b/usr.bin/split/split.c index af1ed69c9482..e246a0d4adfc 100644 --- a/usr.bin/split/split.c +++ b/usr.bin/split/split.c @@ -63,7 +63,7 @@ static const char sccsid[] = "@(#)split.c 8.2 (Berkeley) 4/16/94"; #define DEFLINE 1000 /* Default num lines per file. */ static off_t bytecnt; /* Byte count to split on. */ -static off_t chunks = 0; /* Chunks count to split into. */ +static long chunks; /* Chunks count to split into. */ static bool clobber = true; /* Whether to overwrite existing output files. */ static long numlines; /* Line count to split on. */ static int file_open; /* If a file open. */ @@ -73,7 +73,7 @@ static regex_t rgx; static int pflag; static bool dflag; static long sufflen = 2; /* File name suffix length. */ -static int autosfx = 1; /* Whether to auto-extend the suffix length. */ +static bool autosfx = true; /* Whether to auto-extend the suffix length. */ static void newfile(void); static void split1(void); @@ -84,8 +84,8 @@ static void usage(void) __dead2; int main(int argc, char **argv) { - const char *p; - char *ep; + char errbuf[64]; + const char *p, *errstr; int ch, error; setlocale(LC_ALL, ""); @@ -106,20 +106,27 @@ main(int argc, char **argv) while (numlines >= 0 && *p >= '0' && *p <= '9') numlines = numlines * 10 + *p++ - '0'; if (numlines <= 0 || *p != '\0') - errx(EX_USAGE, "%c%s: illegal line count", ch, - optarg ? optarg : ""); + errx(EX_USAGE, "%c%s: line count is invalid", + ch, optarg ? optarg : ""); break; case 'a': /* Suffix length */ - if ((sufflen = strtol(optarg, &ep, 10)) <= 0 || *ep) - errx(EX_USAGE, - "%s: illegal suffix length", optarg); - autosfx = 0; + sufflen = strtonum(optarg, 0, INT_MAX, &errstr); + if (errstr != NULL) { + errx(EX_USAGE, "%s: suffix length is %s", + optarg, errstr); + } + if (sufflen == 0) { + sufflen = 2; + autosfx = true; + } else { + autosfx = false; + } break; case 'b': /* Byte count. */ - errno = 0; - error = expand_number(optarg, &bytecnt); - if (error == -1) - errx(EX_USAGE, "%s: offset too large", optarg); + if (expand_number(optarg, &bytecnt) != 0) { + errx(EX_USAGE, "%s: byte count is invalid", + optarg); + } break; case 'c': /* Continue, don't overwrite output files. */ clobber = false; @@ -130,22 +137,27 @@ main(int argc, char **argv) case 'l': /* Line count. */ if (numlines != 0) usage(); - if ((numlines = strtol(optarg, &ep, 10)) <= 0 || *ep) - errx(EX_USAGE, - "%s: illegal line count", optarg); + numlines = strtonum(optarg, 1, LONG_MAX, &errstr); + if (errstr != NULL) { + errx(EX_USAGE, "%s: line count is %s", + optarg, errstr); + } break; case 'n': /* Chunks. */ - if (!isdigit((unsigned char)optarg[0]) || - (chunks = (size_t)strtoul(optarg, &ep, 10)) == 0 || - *ep != '\0') { - errx(EX_USAGE, "%s: illegal number of chunks", - optarg); + chunks = strtonum(optarg, 1, LONG_MAX, &errstr); + if (errstr != NULL) { + errx(EX_USAGE, "%s: number of chunks is %s", + optarg, errstr); } break; case 'p': /* pattern matching. */ - if (regcomp(&rgx, optarg, REG_EXTENDED|REG_NOSUB) != 0) - errx(EX_USAGE, "%s: illegal regexp", optarg); + error = regcomp(&rgx, optarg, REG_EXTENDED|REG_NOSUB); + if (error != 0) { + regerror(error, &rgx, errbuf, sizeof(errbuf)); + errx(EX_USAGE, "%s: regex is invalid: %s", + optarg, errbuf); + } pflag = 1; break; default: @@ -163,9 +175,10 @@ main(int argc, char **argv) --argc; } if (argc > 0) { /* File name prefix. */ - if (strlcpy(fname, *argv, sizeof(fname)) >= sizeof(fname)) - errx(EX_USAGE, "file name prefix is too long: %s", + if (strlcpy(fname, *argv, sizeof(fname)) >= sizeof(fname)) { + errx(EX_USAGE, "%s: file name prefix is too long", *argv); + } ++argv; --argc; } @@ -182,16 +195,16 @@ main(int argc, char **argv) else if (bytecnt != 0 || chunks != 0) usage(); - if (bytecnt && chunks) + if (bytecnt != 0 && chunks != 0) usage(); if (ifd == -1) /* Stdin by default. */ ifd = 0; - if (bytecnt) { + if (bytecnt != 0) { split1(); exit (0); - } else if (chunks) { + } else if (chunks != 0) { split3(); exit (0); } @@ -225,7 +238,7 @@ split1(void) /* NOTREACHED */ default: if (!file_open) { - if (!chunks || (nfiles < chunks)) { + if (chunks == 0 || nfiles < chunks) { newfile(); nfiles++; } @@ -236,24 +249,24 @@ split1(void) err(EX_IOERR, "write"); len -= dist; for (C = bfr + dist; len >= bytecnt; - len -= bytecnt, C += bytecnt) { - if (!chunks || (nfiles < chunks)) { - newfile(); + len -= bytecnt, C += bytecnt) { + if (chunks == 0 || nfiles < chunks) { + newfile(); nfiles++; } - if (write(ofd, - C, bytecnt) != bytecnt) + if (write(ofd, C, bytecnt) != bytecnt) err(EX_IOERR, "write"); } if (len != 0) { - if (!chunks || (nfiles < chunks)) { - newfile(); + if (chunks == 0 || nfiles < chunks) { + newfile(); nfiles++; } if (write(ofd, C, len) != len) err(EX_IOERR, "write"); - } else + } else { file_open = 0; + } bcnt = len; } else { bcnt += len; diff --git a/usr.bin/split/tests/split_test.sh b/usr.bin/split/tests/split_test.sh index c9b87c01618c..48065719055a 100755 --- a/usr.bin/split/tests/split_test.sh +++ b/usr.bin/split/tests/split_test.sh @@ -209,6 +209,23 @@ autoextend_body() atf_check -o inline:"$((26*25+1))\n" cat xzaaa } +atf_test_case noautoextend +noautoextend_body() +{ + seq $((26*26)) >input + atf_check split -a2 -l1 input + atf_check -o inline:"$((26*26))\n" cat xzz +} + +atf_test_case reautoextend +reautoextend_body() +{ + seq $((26*25+1)) >input + atf_check split -a2 -a0 -l1 input + atf_check -o inline:"$((26*25))\n" cat xyz + atf_check -o inline:"$((26*25+1))\n" cat xzaaa +} + atf_test_case continue continue_body() { @@ -249,6 +266,8 @@ atf_init_test_cases() atf_add_test_case larger_suffix_length atf_add_test_case pattern atf_add_test_case autoextend + atf_add_test_case noautoextend + atf_add_test_case reautoextend atf_add_test_case continue atf_add_test_case undocumented_kludge atf_add_test_case duplicate_linecount From nobody Thu Oct 5 15:56:07 2023 X-Original-To: dev-commits-src-branches@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 4S1bkv3ZhMz4vs55; Thu, 5 Oct 2023 15:56: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1bkv30sFz3NNQ; Thu, 5 Oct 2023 15:56:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521367; 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=gnX6xRX0nmY8teL90GWAD7lYKkJc90iVkUZbIBBr1xI=; b=DM16WoNhPlw71uIcYCVdgHquWEfgiyN5EoTPkbJ1122tDhvqqvmfQLxxNh+C9wNtufTrFj Nt2EI/lL38OEgdI8vcXC1cGwQyJdH21cMsAGi3rG3aIRs/3pzR4aW/1MQdqqTAyj3ksLKx Jeu1sQ17UpKfBLseMcjtE+7SHNIjGLMfps4hZOPTyr5XCiy8t0Ntb6iiz2x3Uu2N7QqSfi yMmXZ/ykScZN19qP4hN8RiKCwBNKmF7Hp5RW914mg8B7t8rj8nxI13571F0KZcPsbUNU4L d6Fxy9k9RDj/KILudqtYmq44IQJO315NEt6lb36yieXfvkI8rEX/+3B8zQ16SQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696521367; a=rsa-sha256; cv=none; b=Ml5ajtHZt4/l3qlAu9mRPmuXZbqPS54P6+XmxHkTBqsLzwglk2MZA+OQRlDq+/GXwK5iHE YKVfUucFvERzyaEwYIr6j5DAH7RD+Mh5wsx3pLmqooUTTbRijzL04aOq9kh/t4A3UZcOIf xipj4TJ2AfcXjcuHWvZ1XYRF8s/fhTrem/4Pwj65UxHGwAcjXJWgutJlv6r0Zoa5OChebz KitxID43PojiKkn9Lo6AVZe0heoEVETtRM37qeqrPLanWDaj2ERNd99qyQHTBULHRksowW XS0ndr/dVEFEp1UMGG5bvSGBPPrB0/8f27wHvXgWIxfUf4rqoJ7Sob0B5gZKiA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521367; 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=gnX6xRX0nmY8teL90GWAD7lYKkJc90iVkUZbIBBr1xI=; b=jfLJk1jqMhaI0/whr6dscPNxa5wmCZf9o61ww7kidxi40hYv11jOY6zSQnFA5vrjn2hkkW xBWbivXmoauv3gjZpW2uTJknjanWNpnuC+ah7kxjPqzRhb5b/PKIsWLO/WRdVsEf5PZ68H F2YxZhvzPjggH2t1+D1fRUImeVrWD7MhmuoqwxbwCykIB8wFhHLSouPX5npRI0uxG/Fp/q ZezjewZghsCrtoX/IauH//Z23Q6fgfm6Mn+ec8mhIlk4gULjDokWXfoj0G7hgOpLE5JnKK mI6ZLmSLDkCIud7nZp16sV31MvSO0afnD7pgrllwM3trve8ujCADCgVurIHV5w== 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 4S1bkv1rYpz1QrQ; Thu, 5 Oct 2023 15:56:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395Fu7Iq047355; Thu, 5 Oct 2023 15:56:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395Fu7eF047352; Thu, 5 Oct 2023 15:56:07 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:56:07 GMT Message-Id: <202310051556.395Fu7eF047352@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: baf69f6c9973 - stable/13 - libfetch: don't rely on ca_root_nss for certificate validation List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/13 X-Git-Reftype: branch X-Git-Commit: baf69f6c997392cde9ae75d3ebc25a8201c7cc99 Auto-Submitted: auto-generated The branch stable/13 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=baf69f6c997392cde9ae75d3ebc25a8201c7cc99 commit baf69f6c997392cde9ae75d3ebc25a8201c7cc99 Author: Michael Osipov AuthorDate: 2023-10-03 05:53:20 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2023-10-05 15:55:33 +0000 libfetch: don't rely on ca_root_nss for certificate validation Before certctl(8), there was no system trust store, and libfetch relied on the CA certificate bundle from the ca_root_nss port to verify peers. We now have a system trust store and a reliable mechanism for manipulating it (to explicitly add, remove, or revoke certificates), but if ca_root_nss is installed, libfetch will still prefer that to the system trust store. With this change, unless explicitly overridden, libfetch will rely on OpenSSL to pick up the default system trust store. PR: 256902 MFC after: 3 days Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D42059 (cherry picked from commit 09f5c1e118bb4eca77b83a0d08f559b20f60aa59) --- lib/libfetch/common.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/lib/libfetch/common.c b/lib/libfetch/common.c index c01710832791..69b507109bc4 100644 --- a/lib/libfetch/common.c +++ b/lib/libfetch/common.c @@ -1071,8 +1071,6 @@ fetch_ssl_setup_transport_layer(SSL_CTX *ctx, int verbose) /* * Configure peer verification based on environment. */ -#define LOCAL_CERT_FILE _PATH_LOCALBASE "/etc/ssl/cert.pem" -#define BASE_CERT_FILE "/etc/ssl/cert.pem" static int fetch_ssl_setup_peer_verification(SSL_CTX *ctx, int verbose) { @@ -1082,12 +1080,6 @@ fetch_ssl_setup_peer_verification(SSL_CTX *ctx, int verbose) if (getenv("SSL_NO_VERIFY_PEER") == NULL) { ca_cert_file = getenv("SSL_CA_CERT_FILE"); - if (ca_cert_file == NULL && - access(LOCAL_CERT_FILE, R_OK) == 0) - ca_cert_file = LOCAL_CERT_FILE; - if (ca_cert_file == NULL && - access(BASE_CERT_FILE, R_OK) == 0) - ca_cert_file = BASE_CERT_FILE; ca_cert_path = getenv("SSL_CA_CERT_PATH"); if (verbose) { fetch_info("Peer verification enabled"); From nobody Thu Oct 5 15:59:39 2023 X-Original-To: dev-commits-src-branches@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 4S1bpz5BZVz4vsn9; Thu, 5 Oct 2023 15:59: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1bpz4b1fz3PRs; Thu, 5 Oct 2023 15:59:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521579; 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=CQ+ERgHqxOrACocBbiLi/xYDdcOoWxSzqK8ABcbpfOk=; b=Y94d146QePvqYp+ySHr9Cp9cXbhMX334tYPk3yQwKzJfm9EYXYoOvUiZHH8NUVEIjEQvoh qUDFhUs8hFu1asOwrPIXr8yIfZhf1LRUhPiTzJKl7KkOQcNf6VAiIU6TEa0+5MG+QAKNK+ 0rUy6OvfiB5vZuKgnryH/F4kC9iALUyrf5vuEdU6FDDBhBXvFzHR8GiRhX4A4Tm9HZomcQ cIqQGAD7iqVJ0osozEBPUoP6cfmynZikgPxVqgOWY+Awvg6aocCxy1QaMHyAn7MKi1Z5Y0 KJYDCjqu7CvU1v1dKjGk2uOfo8HfzkR2S65Zh6VYVk/H5YBHTjVNELO0zr7bZA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696521579; a=rsa-sha256; cv=none; b=Uyxk9WXJie9YpqSz+b3rVrnKiD8QIwRJs4SnYJt0JlvCkqHnE4Ij9Rl/LgP5jvmaPfnAZQ WQUxQ/HQ+FsYnXHjCGwXE+ovqtJ7+0hWvMsYhOu4YbXCdURstzbDUzbNmYEiXezuoX3Mb+ XBT1Con7lJGzPEwEIL1/QcAPMZKFYmtZ6Z2iN3EysyC8Ui9V6eaEM4jhA2bfIhQXxSr9WK 4rNrv5tigKs6wC+kTvtP54fw14UHmrwH5CuFiWwjNZvC6zAvWMYvdmSzZIG474QJ3KXskJ sRwxgAO+MSZbw5Bh1mDMlQYMAUDz9MH7YBSYUGW+Cu8hlX6OewDBY0KV/rXNhQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696521579; 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=CQ+ERgHqxOrACocBbiLi/xYDdcOoWxSzqK8ABcbpfOk=; b=SivxHnDhNqAyAf8AeoIGEDCw3OjNxT4mwZcJSR2i/HYhaSrddgX9IOjP25f6UJo5crvXlc y+xRy/yqbomVF4HjqEHzXVwZSOJBBq1flpu5lKHytzoB3ISkSShQbYxu4x5aU+ACefrOf8 ysV2ZwaE+mgZm1tzD2bzFTX9EslXF4uJ2TffieqfQmQjL+HEZoep8DBHqg50W5iaVUqDPm 7rv1HM54HEsdV5Qr3sZssEaHcu7fnnPgwxRPx+QWi48vLWCLQ6iJhdJGmT/30aPyRxFL26 ztYzOVvgyf6SpbD3Cq6aLeUXFHVzywqIHhGqz6rdd2AlS9BwUvecWr/bWlAMnA== 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 4S1bpz3fP7z1QpV; Thu, 5 Oct 2023 15:59:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395Fxdak047999; Thu, 5 Oct 2023 15:59:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395FxdVW047996; Thu, 5 Oct 2023 15:59:39 GMT (envelope-from git) Date: Thu, 5 Oct 2023 15:59:39 GMT Message-Id: <202310051559.395FxdVW047996@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: 8d939b7d9845 - stable/12 - libfetch: don't rely on ca_root_nss for certificate validation List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/12 X-Git-Reftype: branch X-Git-Commit: 8d939b7d98452c0357e49b090d5a685ea8a0e69a Auto-Submitted: auto-generated The branch stable/12 has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=8d939b7d98452c0357e49b090d5a685ea8a0e69a commit 8d939b7d98452c0357e49b090d5a685ea8a0e69a Author: Michael Osipov AuthorDate: 2023-10-03 05:53:20 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2023-10-05 15:58:59 +0000 libfetch: don't rely on ca_root_nss for certificate validation Before certctl(8), there was no system trust store, and libfetch relied on the CA certificate bundle from the ca_root_nss port to verify peers. We now have a system trust store and a reliable mechanism for manipulating it (to explicitly add, remove, or revoke certificates), but if ca_root_nss is installed, libfetch will still prefer that to the system trust store. With this change, unless explicitly overridden, libfetch will rely on OpenSSL to pick up the default system trust store. PR: 256902 MFC after: 3 days Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D42059 (cherry picked from commit 09f5c1e118bb4eca77b83a0d08f559b20f60aa59) --- lib/libfetch/common.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/lib/libfetch/common.c b/lib/libfetch/common.c index 80a63123abdb..8b3b69ff3351 100644 --- a/lib/libfetch/common.c +++ b/lib/libfetch/common.c @@ -786,8 +786,6 @@ fetch_ssl_setup_transport_layer(SSL_CTX *ctx, int verbose) /* * Configure peer verification based on environment. */ -#define LOCAL_CERT_FILE "/usr/local/etc/ssl/cert.pem" -#define BASE_CERT_FILE "/etc/ssl/cert.pem" static int fetch_ssl_setup_peer_verification(SSL_CTX *ctx, int verbose) { @@ -797,12 +795,6 @@ fetch_ssl_setup_peer_verification(SSL_CTX *ctx, int verbose) if (getenv("SSL_NO_VERIFY_PEER") == NULL) { ca_cert_file = getenv("SSL_CA_CERT_FILE"); - if (ca_cert_file == NULL && - access(LOCAL_CERT_FILE, R_OK) == 0) - ca_cert_file = LOCAL_CERT_FILE; - if (ca_cert_file == NULL && - access(BASE_CERT_FILE, R_OK) == 0) - ca_cert_file = BASE_CERT_FILE; ca_cert_path = getenv("SSL_CA_CERT_PATH"); if (verbose) { fetch_info("Peer verification enabled"); From nobody Thu Oct 5 17:34:45 2023 X-Original-To: dev-commits-src-branches@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 4S1dwk0Zmhz4w8s8; Thu, 5 Oct 2023 17:34: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1dwk050tz3gf7; Thu, 5 Oct 2023 17:34:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696527286; 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=fx5Ny1FODsaiJ8ClGdvGVTh8EwYyTA0jx7Y0ULPcpVA=; b=IGp98MUozYJ1W/R7Zrjxu/wKTfGRaydJO7JLjEiP3w/Kp/OKYdKbT7UEtSUE2Fxv0+e9bc mH+0GIglK6SdPYC3VvDW4IhuDfwDztxwu1usvS79CRtn7IDAbk7yOcJEeRjBnnLfc6fmrf E+c2R2I340+xnCPeUtNQaCmwwnNOfHK8YtzzaK8OFzEYisVH3Wof3Qh8Xn5wJCYL2omQbQ X2BMbVwkni+grbU/pvTUAtrb56QIWmq7pImU6f2Yyp/eQYg2w0eg0V5bZ08agESxh0pEEp QUfy1dujDV2Rt/FbvQlGe29SKdlbUaAlz4ECkAigbDtaDuXBGRTvYyB15IOB1g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696527286; a=rsa-sha256; cv=none; b=MtrDEBHF25nMBZ31DS4PDNv4Pv/gEqROkA3qSnY8o+fEj0BAYkK5Dhhrd61/P0fil/oV/w jf5Hqv5BIr5o1ZUKb0B+X2cqb1RWaHAwE1e1jQysMYyvyDx69MKlTsTtgpFk1P08F0XbNO 8J+bpc0CRH5WyOO1sMZ0C7RfV7dG+7ASuaHv7bG1H7DF9hwD6maTahOPhxRfa/qdzDpZuy oeIlbiB5HgPtaApTtHRfxx9G3N9plczj4L+GlOaRdQ2TDGLIw0xqh5sch1UXIKAbHapyqI lAyTGDlLwMz6Brn2IVD5fYGsitkEH806fHKuQzmtKw/E2Jd5lDzK+31BzRw8qw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696527286; 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=fx5Ny1FODsaiJ8ClGdvGVTh8EwYyTA0jx7Y0ULPcpVA=; b=QEGuChvgj4Aejg7wpXSvFFYJSJV6BV0RNkzNfJ8JXir18X8EcjgXq1kaaRFqQO3pSsK/Nt QoeP2/XVRd17PU9Vu+ymfnaOrzR4q5NWt6XRD5C9IE8yB/t1XRDSsMQ/8whxuCtp6BS41U qAkWv2AYZOezOPWp1R0ivhgyyE3TyyigEQCH4bgb/V8bRmyOD5SYcWUYnz2CnW7cwQOz7S U/GqCvjYSTWAn3AryGlTPkMtlNUvq2HH6l+dmRBTfqYbwqn5o5ohy75m4WRaC3CRd1obdM ecqEwS0DnqOx4CGCrRh15/aCSJnPM7ZRABxCnwqag8JGPoTcKPLd9iveiv/0pg== 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 4S1dwj68Ykzmq; Thu, 5 Oct 2023 17:34:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395HYjo4014515; Thu, 5 Oct 2023 17:34:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395HYjV7014512; Thu, 5 Oct 2023 17:34:45 GMT (envelope-from git) Date: Thu, 5 Oct 2023 17:34:45 GMT Message-Id: <202310051734.395HYjV7014512@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alan Somers Subject: git: 2d05cbe00272 - stable/13 - fusefs: fix some bugs updating atime during close List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: asomers X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 2d05cbe002726a28e11060a601d1877784f6d587 Auto-Submitted: auto-generated The branch stable/13 has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=2d05cbe002726a28e11060a601d1877784f6d587 commit 2d05cbe002726a28e11060a601d1877784f6d587 Author: Alan Somers AuthorDate: 2023-09-20 21:37:31 +0000 Commit: Alan Somers CommitDate: 2023-10-05 16:16:11 +0000 fusefs: fix some bugs updating atime during close When using cached attributes, we must update a file's atime during close, if it has been read since the last attribute refresh. But, * Don't update atime if we lack write permissions to the file or if the file system is readonly. * If the daemon fails our atime update request for any reason, don't report this as a failure for VOP_CLOSE. PR: 270749 Reported by: Jamie Landeg-Jones Sponsored by: Axcient Reviewed by: pfg Differential Revision: https://reviews.freebsd.org/D41925 (cherry picked from commit fb619c94c679e939496fe0cf94b8d2cba95e6e63) fusefs: fix unused variables from fb619c94c67 PR: 270749 Reported by: cy Sponsored by: Axcient (cherry picked from commit e5236d25f2c0709acf3547e6af45f4bb4eec4f02) --- sys/fs/fuse/fuse_vnops.c | 27 ++++++++-- tests/sys/fs/fusefs/access.cc | 2 +- tests/sys/fs/fusefs/default_permissions.cc | 41 ++++++++++++++- tests/sys/fs/fusefs/read.cc | 83 ++++++++++++++++++++++++++++++ 4 files changed, 147 insertions(+), 6 deletions(-) diff --git a/sys/fs/fuse/fuse_vnops.c b/sys/fs/fuse/fuse_vnops.c index 5cd67d9af5a3..8fa60ff95d4c 100644 --- a/sys/fs/fuse/fuse_vnops.c +++ b/sys/fs/fuse/fuse_vnops.c @@ -780,6 +780,7 @@ static int fuse_vnop_close(struct vop_close_args *ap) { struct vnode *vp = ap->a_vp; + struct mount *mp = vnode_mount(vp); struct ucred *cred = ap->a_cred; int fflag = ap->a_fflag; struct thread *td = ap->a_td; @@ -795,12 +796,30 @@ fuse_vnop_close(struct vop_close_args *ap) return 0; err = fuse_flush(vp, cred, pid, fflag); - if (err == 0 && (fvdat->flag & FN_ATIMECHANGE)) { + if (err == 0 && (fvdat->flag & FN_ATIMECHANGE) && !vfs_isrdonly(mp)) { struct vattr vap; + struct fuse_data *data; + int dataflags; + int access_e = 0; - VATTR_NULL(&vap); - vap.va_atime = fvdat->cached_attrs.va_atime; - err = fuse_internal_setattr(vp, &vap, td, NULL); + data = fuse_get_mpdata(mp); + dataflags = data->dataflags; + if (dataflags & FSESS_DEFAULT_PERMISSIONS) { + struct vattr va; + + fuse_internal_getattr(vp, &va, cred, td); + access_e = vaccess(vp->v_type, va.va_mode, va.va_uid, + va.va_gid, VWRITE, cred); + } + if (access_e == 0) { + VATTR_NULL(&vap); + vap.va_atime = fvdat->cached_attrs.va_atime; + /* + * Ignore errors setting when setting atime. That + * should not cause close(2) to fail. + */ + fuse_internal_setattr(vp, &vap, td, NULL); + } } /* TODO: close the file handle, if we're sure it's no longer used */ if ((fvdat->flag & FN_SIZECHANGE) != 0) { diff --git a/tests/sys/fs/fusefs/access.cc b/tests/sys/fs/fusefs/access.cc index 3d6cddb9417b..5762269fac7b 100644 --- a/tests/sys/fs/fusefs/access.cc +++ b/tests/sys/fs/fusefs/access.cc @@ -55,7 +55,7 @@ void expect_lookup(const char *relpath, uint64_t ino) } /* - * Expect tha FUSE_ACCESS will never be called for the given inode, with any + * Expect that FUSE_ACCESS will never be called for the given inode, with any * bits in the supplied access_mask set */ void expect_noaccess(uint64_t ino, mode_t access_mask) diff --git a/tests/sys/fs/fusefs/default_permissions.cc b/tests/sys/fs/fusefs/default_permissions.cc index 8527b0c6deb5..ff25d37f5b4d 100644 --- a/tests/sys/fs/fusefs/default_permissions.cc +++ b/tests/sys/fs/fusefs/default_permissions.cc @@ -30,7 +30,7 @@ /* * Tests for the "default_permissions" mount option. They must be in their own - * file so they can be run as an unprivileged user + * file so they can be run as an unprivileged user. */ extern "C" { @@ -162,6 +162,7 @@ class CopyFileRange: public DefaultPermissions {}; class Lookup: public DefaultPermissions {}; class Open: public DefaultPermissions {}; class PosixFallocate: public DefaultPermissions {}; +class Read: public DefaultPermissions {}; class Setattr: public DefaultPermissions {}; class Unlink: public DefaultPermissions {}; class Utimensat: public DefaultPermissions {}; @@ -1140,6 +1141,44 @@ TEST_F(Rename, ok_to_remove_src_because_of_stickiness) ASSERT_EQ(0, rename(FULLSRC, FULLDST)) << strerror(errno); } +// Don't update atime during close after read, if we lack permissions to write +// that file. +TEST_F(Read, atime_during_close) +{ + const char FULLPATH[] = "mountpoint/some_file.txt"; + const char RELPATH[] = "some_file.txt"; + uint64_t ino = 42; + int fd; + ssize_t bufsize = 100; + uint8_t buf[bufsize]; + const char *CONTENTS = "abcdefgh"; + ssize_t fsize = sizeof(CONTENTS); + + expect_getattr(FUSE_ROOT_ID, S_IFDIR | 0755, UINT64_MAX, 1); + FuseTest::expect_lookup(RELPATH, ino, S_IFREG | 0755, fsize, + 1, UINT64_MAX, 0, 0); + expect_open(ino, 0, 1); + expect_read(ino, 0, fsize, fsize, CONTENTS); + EXPECT_CALL(*m_mock, process( + ResultOf([&](auto in) { + return (in.header.opcode == FUSE_SETATTR); + }, Eq(true)), + _) + ).Times(0); + expect_flush(ino, 1, ReturnErrno(0)); + expect_release(ino, FuseTest::FH); + + fd = open(FULLPATH, O_RDONLY); + ASSERT_LE(0, fd) << strerror(errno); + + /* Ensure atime will be different than during lookup */ + nap(); + + ASSERT_EQ(fsize, read(fd, buf, bufsize)) << strerror(errno); + + close(fd); +} + TEST_F(Setattr, ok) { const char FULLPATH[] = "mountpoint/some_file.txt"; diff --git a/tests/sys/fs/fusefs/read.cc b/tests/sys/fs/fusefs/read.cc index 3b2a04fe0a52..5beb59e9f3be 100644 --- a/tests/sys/fs/fusefs/read.cc +++ b/tests/sys/fs/fusefs/read.cc @@ -57,6 +57,14 @@ void expect_lookup(const char *relpath, uint64_t ino, uint64_t size) } }; +class RofsRead: public Read { +public: +virtual void SetUp() { + m_ro = true; + Read::SetUp(); +} +}; + class Read_7_8: public FuseTest { public: virtual void SetUp() { @@ -454,6 +462,47 @@ TEST_F(Read, atime_during_close) close(fd); } +/* + * When not using -o default_permissions, the daemon may make its own decisions + * regarding access permissions, and these may be unpredictable. If it rejects + * our attempt to set atime, that should not cause close(2) to fail. + */ +TEST_F(Read, atime_during_close_eacces) +{ + const char FULLPATH[] = "mountpoint/some_file.txt"; + const char RELPATH[] = "some_file.txt"; + const char *CONTENTS = "abcdefgh"; + uint64_t ino = 42; + int fd; + ssize_t bufsize = strlen(CONTENTS); + uint8_t buf[bufsize]; + + expect_lookup(RELPATH, ino, bufsize); + expect_open(ino, 0, 1); + expect_read(ino, 0, bufsize, bufsize, CONTENTS); + EXPECT_CALL(*m_mock, process( + ResultOf([&](auto in) { + uint32_t valid = FATTR_ATIME; + return (in.header.opcode == FUSE_SETATTR && + in.header.nodeid == ino && + in.body.setattr.valid == valid); + }, Eq(true)), + _) + ).WillOnce(Invoke(ReturnErrno(EACCES))); + expect_flush(ino, 1, ReturnErrno(0)); + expect_release(ino, FuseTest::FH); + + fd = open(FULLPATH, O_RDONLY); + ASSERT_LE(0, fd) << strerror(errno); + + /* Ensure atime will be different than during lookup */ + nap(); + + ASSERT_EQ(bufsize, read(fd, buf, bufsize)) << strerror(errno); + + ASSERT_EQ(0, close(fd)); +} + /* A cached atime should be flushed during FUSE_SETATTR */ TEST_F(Read, atime_during_setattr) { @@ -1321,6 +1370,40 @@ INSTANTIATE_TEST_CASE_P(RA, ReadAhead, tuple(true, 1), tuple(true, 2))); +/* With read-only mounts, fuse should never update atime during close */ +TEST_F(RofsRead, atime_during_close) +{ + const char FULLPATH[] = "mountpoint/some_file.txt"; + const char RELPATH[] = "some_file.txt"; + const char *CONTENTS = "abcdefgh"; + uint64_t ino = 42; + int fd; + ssize_t bufsize = strlen(CONTENTS); + uint8_t buf[bufsize]; + + expect_lookup(RELPATH, ino, bufsize); + expect_open(ino, 0, 1); + expect_read(ino, 0, bufsize, bufsize, CONTENTS); + EXPECT_CALL(*m_mock, process( + ResultOf([&](auto in) { + return (in.header.opcode == FUSE_SETATTR); + }, Eq(true)), + _) + ).Times(0); + expect_flush(ino, 1, ReturnErrno(0)); + expect_release(ino, FuseTest::FH); + + fd = open(FULLPATH, O_RDONLY); + ASSERT_LE(0, fd) << strerror(errno); + + /* Ensure atime will be different than during lookup */ + nap(); + + ASSERT_EQ(bufsize, read(fd, buf, bufsize)) << strerror(errno); + + close(fd); +} + /* fuse_init_out.time_gran controls the granularity of timestamps */ TEST_P(TimeGran, atime_during_setattr) { From nobody Thu Oct 5 17:37:21 2023 X-Original-To: dev-commits-src-branches@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 4S1dzk2Bssz4w95p; Thu, 5 Oct 2023 17:37:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1dzk1jRdz4CYN; Thu, 5 Oct 2023 17:37:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696527442; 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=k0OwbQx3KeWM9EIVj8U9llZR7zaKJmmPkGyYa+vCSbo=; b=PNkSg2y1CrPi+cX9UaKqH470+fYSpgUwiifmnjs30o209GOnTghB0lce3cAMK7JPSdSr4Z hnI04SKPJZ2Z9/g4Y43VmFFxEVg2prD6BTZKShZbwuSPkErLhZdUs+1arcbpZZaNfbvoj8 Z3NLyUU9HQ7Ws9ylE5CbijrAIo/dKQJnoMjkAEN6A+sRMa4kOsJYKTjFBjjU8WMB9hEmHL dQcooHv9ohf4qxDzDXtkADWli4r3wFme2lUPdDZpC9r398Txn/Nm6CuL/rT4E1XFgQ1wKR ZKq+/bwQa2tiPnNyHcmi96HaKx2B+Vkfs92aduFl2yzydhTjEw9TNwJWIBHKAw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696527442; a=rsa-sha256; cv=none; b=cDaZRKrfl3e91pjnHhBmuDC+BQjL0FGvdFR6jZb1rrH63eS0UptKnfSNh9o6F9smydo7VN PciJv6xy+1RYBQodXKwh6LGZs4nTdtYfNsPqLakoQAhPKYlQ2FERNYyd23BjVIersXsA/g Dd5DGHO5zb3jEmPq951iPxmB9S7hAXihfEu+FiSNCjTevZNpJMipeCLjuHUay7fE/0YNhX vnUjRBHsEVPE6/eDgAk6oEVvCcHPbDTxh9+wPL+ClQvZ0lPtOINOWFeBnsWJsWofzDTi3S QVY2FmpiFEqZXjrllLv2EZebpTgoylOigIYuBEkDWCEEZh3xwzlVqZ39Nc3HcA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696527442; 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=k0OwbQx3KeWM9EIVj8U9llZR7zaKJmmPkGyYa+vCSbo=; b=pXjOEFiKz8MsqhWji56lPdUhGauV+YnTN+LGSHbbihgDX+CRDVi8wZUboPlNg7f1PihHPG 5lTDxjVHWbjL7mviWcdNFjzKkdGen6pMdzyjQLBEzhgWFfdhqpd0bYxFw6Mk51hVvJRBvY KMJG76OueT4SgOPit3FW+P6urD60ULaabtU84wOeaR5Xl+7qGWiNAPT21tISvkW6zO+xzS x7W51tnLP7v/htjZ6jpBxPIxtaEFmHrmOkQH6Ai2Dq+MmWsasU1/rftaANJRsvRnv2DHD0 48tU8+pLzEfLwy/NvAZ+PtL+GdHUGW9rG460cqg/Jy0rjwuWmlg4OFcemJ3ruw== 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 4S1dzk0fgGzZf; Thu, 5 Oct 2023 17:37:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395HbLrO015024; Thu, 5 Oct 2023 17:37:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395HbLJZ015021; Thu, 5 Oct 2023 17:37:21 GMT (envelope-from git) Date: Thu, 5 Oct 2023 17:37:21 GMT Message-Id: <202310051737.395HbLJZ015021@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alan Somers Subject: git: 51426ad9c75b - stable/13 - mprutil: "fix user reply buffer (64)..." warnings List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: asomers X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 51426ad9c75b21424a05208a0c3d122beb08ddd7 Auto-Submitted: auto-generated The branch stable/13 has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=51426ad9c75b21424a05208a0c3d122beb08ddd7 commit 51426ad9c75b21424a05208a0c3d122beb08ddd7 Author: Alan Somers AuthorDate: 2023-02-22 22:06:43 +0000 Commit: Alan Somers CommitDate: 2023-10-05 17:35:27 +0000 mprutil: "fix user reply buffer (64)..." warnings Depending on the card's firmware version, it may return different length responses for MPI2_FUNCTION_IOC_FACTS. But the first part of the response contains the length of the rest, so query it first to get the length and then use that to size the buffer for the full response. Also, correctly zero-initialize MPI2_IOC_FACTS_REQUEST. It only worked by luck before. PR: 264848 Reported by: Julien Cigar Sponsored by: Axcient Reviewed by: scottl, imp Differential Revision: https://reviews.freebsd.org/D38739 (cherry picked from commit 7d154c4dc64e61af7ca536c4e9927fa07c675a83) --- sys/dev/mpr/mpr.c | 2 +- sys/dev/mpr/mpr_user.c | 4 ++-- sys/dev/mps/mps.c | 2 +- sys/dev/mps/mps_user.c | 4 ++-- usr.sbin/mpsutil/mps_cmd.c | 40 +++++++++++++++++++++++++++------------- 5 files changed, 33 insertions(+), 19 deletions(-) diff --git a/sys/dev/mpr/mpr.c b/sys/dev/mpr/mpr.c index 6d41b77b1182..161914748e56 100644 --- a/sys/dev/mpr/mpr.c +++ b/sys/dev/mpr/mpr.c @@ -1871,7 +1871,7 @@ mpr_setup_sysctl(struct mpr_softc *sc) SYSCTL_ADD_STRING(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), OID_AUTO, "msg_version", CTLFLAG_RD, sc->msg_version, - strlen(sc->msg_version), "message interface version"); + strlen(sc->msg_version), "message interface version (deprecated)"); SYSCTL_ADD_INT(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), OID_AUTO, "io_cmds_active", CTLFLAG_RD, diff --git a/sys/dev/mpr/mpr_user.c b/sys/dev/mpr/mpr_user.c index d9dc3d2377a2..f2847ae36d66 100644 --- a/sys/dev/mpr/mpr_user.c +++ b/sys/dev/mpr/mpr_user.c @@ -852,7 +852,7 @@ mpr_user_pass_thru(struct mpr_softc *sc, mpr_pass_thru_t *data) rpl = (MPI2_DEFAULT_REPLY *)cm->cm_reply; sz = rpl->MsgLength * 4; - if (sz > data->ReplySize) { + if (bootverbose && sz > data->ReplySize) { mpr_printf(sc, "%s: user reply buffer (%d) " "smaller than returned buffer (%d)\n", __func__, data->ReplySize, sz); @@ -1077,7 +1077,7 @@ mpr_user_pass_thru(struct mpr_softc *sc, mpr_pass_thru_t *data) rpl = (MPI2_DEFAULT_REPLY *)cm->cm_reply; sz = rpl->MsgLength * 4; - if (sz > data->ReplySize) { + if (bootverbose && sz > data->ReplySize) { mpr_printf(sc, "%s: user reply buffer (%d) smaller " "than returned buffer (%d)\n", __func__, data->ReplySize, sz); diff --git a/sys/dev/mps/mps.c b/sys/dev/mps/mps.c index a312e95df771..10aea28db9ee 100644 --- a/sys/dev/mps/mps.c +++ b/sys/dev/mps/mps.c @@ -1716,7 +1716,7 @@ mps_setup_sysctl(struct mps_softc *sc) SYSCTL_ADD_STRING(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), OID_AUTO, "msg_version", CTLFLAG_RD, sc->msg_version, - strlen(sc->msg_version), "message interface version"); + strlen(sc->msg_version), "message interface version (deprecated)"); SYSCTL_ADD_INT(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), OID_AUTO, "io_cmds_active", CTLFLAG_RD, diff --git a/sys/dev/mps/mps_user.c b/sys/dev/mps/mps_user.c index a1ee620c713a..49dc0f05619c 100644 --- a/sys/dev/mps/mps_user.c +++ b/sys/dev/mps/mps_user.c @@ -863,7 +863,7 @@ mps_user_pass_thru(struct mps_softc *sc, mps_pass_thru_t *data) rpl = (MPI2_DEFAULT_REPLY *)cm->cm_reply; sz = rpl->MsgLength * 4; - if (sz > data->ReplySize) { + if (bootverbose && sz > data->ReplySize) { mps_printf(sc, "%s: user reply buffer (%d) " "smaller than returned buffer (%d)\n", __func__, data->ReplySize, sz); @@ -1017,7 +1017,7 @@ mps_user_pass_thru(struct mps_softc *sc, mps_pass_thru_t *data) rpl = (MPI2_DEFAULT_REPLY *)cm->cm_reply; sz = rpl->MsgLength * 4; - if (sz > data->ReplySize) { + if (bootverbose && sz > data->ReplySize) { mps_printf(sc, "%s: user reply buffer (%d) smaller " "than returned buffer (%d)\n", __func__, data->ReplySize, sz); diff --git a/usr.sbin/mpsutil/mps_cmd.c b/usr.sbin/mpsutil/mps_cmd.c index 448e4cea602f..2101bbba73b0 100644 --- a/usr.sbin/mpsutil/mps_cmd.c +++ b/usr.sbin/mpsutil/mps_cmd.c @@ -721,25 +721,39 @@ mps_pass_command(int fd, void *req, uint32_t req_len, void *reply, return (0); } +/* Return the length in bytes of the device's MPI2_IOC_FACTS reply */ +static size_t +mps_get_ioc_factslen(int fd) +{ + MPI2_IOC_FACTS_REQUEST req; + const size_t factslen = 4; + char factsbuf[4] = {0}; + MPI2_IOC_FACTS_REPLY *facts = (MPI2_IOC_FACTS_REPLY*)factsbuf; + int error; + + bzero(&req, sizeof(req)); + req.Function = MPI2_FUNCTION_IOC_FACTS; + error = mps_pass_command(fd, &req, sizeof(MPI2_IOC_FACTS_REQUEST), + factsbuf, factslen, NULL, 0, NULL, 0, 10); + + if (error) + return (0); + + /* The card's response is measured in dwords */ + return (facts->MsgLength * 4); +} + MPI2_IOC_FACTS_REPLY * mps_get_iocfacts(int fd) { MPI2_IOC_FACTS_REPLY *facts; MPI2_IOC_FACTS_REQUEST req; - char msgver[8], sysctlname[128]; - size_t len, factslen; + size_t factslen; int error; - snprintf(sysctlname, sizeof(sysctlname), "dev.%s.%d.msg_version", - is_mps ? "mps" : "mpr", mps_unit); - - factslen = sizeof(MPI2_IOC_FACTS_REPLY); - len = sizeof(msgver); - error = sysctlbyname(sysctlname, msgver, &len, NULL, 0); - if (error == 0) { - if (strncmp(msgver, "2.6", sizeof(msgver)) == 0) - factslen += 4; - } + factslen = mps_get_ioc_factslen(fd); + if (factslen == 0) + return (NULL); facts = malloc(factslen); if (facts == NULL) { @@ -747,7 +761,7 @@ mps_get_iocfacts(int fd) return (NULL); } - bzero(&req, factslen); + bzero(&req, sizeof(req)); req.Function = MPI2_FUNCTION_IOC_FACTS; #if 1 From nobody Thu Oct 5 20:36:55 2023 X-Original-To: dev-commits-src-branches@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 4S1jyv5CLKz4wf00; Thu, 5 Oct 2023 20:36: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1jyv4jbRz4Xjv; Thu, 5 Oct 2023 20:36:55 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696538215; 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=M9stKKMbcia1RrAsowRtNiixaih1X0pG/ya/89qkL+I=; b=gRpCCrtFA8FS3JXEF1PELfaYtHiVex3Bavn6whYvylpCJOu3LitjMzHC7tU4UWCsJZ1uli 5aPPDigJ5toFZOMQzVK9D4DwDe5RSSLsvFtDDy3jEKjyv76AFEc5obyOWq7JFfBXv8fLqV maw1gBqwFVNtr5N4DCYvMDSFFxshlkGaAB5iqsQJeDx8lZ+oFeMyNgJ5Wy3xJ18VcDTGkc CYKPhlTDgZhY06u/LvH+5QJQV0QksZzmbVebeyoZbt2+BSABsO++W3981X3/rBbth/MjFI NJ7G7hIB8QJDF2vr9lITd8biSqCXz1d0XC48cbpafV0JDK6BQ1Eazxuo6q8n4Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696538215; a=rsa-sha256; cv=none; b=uCvpCrwO4GNCt9/u8UXW9W/DKPOO382uPO2XKcBgXgLbBCdhk4QpbJJHlr0KRc1WhVqflr ZfYl5QlMfmRbAS0sp1HR6p3MdqfxJaYiFU8p+fJY5o6rU0bX9LhT2fyRrkMmYHDHtg80+D bZh7izVBRhKnJn783Nc4X6cVcvtZFhM5Q6WTo7VenkwtGlRTPz3FKYxrNYitGrjscelg4g yqqkA8BfitEnGIkYiqev8rSCvQhncUgWkZHNt7Hm8CqvrAdE6Cq5NrQMEnLjTM1tXl6hUc X5cgRDWhBb726TOQo9vze4zNThvJ/ZF8Yy/zZklvrMNV+4WHlvmxwbZGXO5THA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696538215; 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=M9stKKMbcia1RrAsowRtNiixaih1X0pG/ya/89qkL+I=; b=NYtP75CJTWiTdxLvD8e3PdGHF8RUfc8R9muwjhOfEFSWH630vdou7mdz484awAl+ZU6g9o WrmuSLZ42k6lEBEUBpKkqCUHbw6tzTowKh2CypyFQW0VHRdnNa6DpD3Mj/EZvdQcrM8vbe lcksvkLvkZP1GxOc0dA6TO7O3s7yU8Hj8ldEiw7JNSSdaJ1YCXijc8WT8grpbP08RBVZEE VGBUGuII0c7W0VA8BddFX+TBA2vlN25GWUAnmKOnWY0iVP74qdR8Z5jk4JnbEYj9X7HX2/ 4l0PC3ReoiwpVUiegai600Ce7kZo10ZNWMTFxQaUwbRp/L0d8k9n7uu3m4fFVA== 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 4S1jyv3mBhz4gm; Thu, 5 Oct 2023 20:36:55 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395Kat4N013855; Thu, 5 Oct 2023 20:36:55 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395KatmI013852; Thu, 5 Oct 2023 20:36:55 GMT (envelope-from git) Date: Thu, 5 Oct 2023 20:36:55 GMT Message-Id: <202310052036.395KatmI013852@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alan Somers Subject: git: 73765a5fa7d0 - stable/12 - Advertise the MPI Message Version that's contained in the IOCFacts message in the sysctl block for the driver. mpsutil/mprutil needs this so it can know how big of a buffer to allocate when requesting the IOCFacts from the controller. This eliminates the kernel console messages about wrong allocation sizes. List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: asomers X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: 73765a5fa7d0daa72387d41661c36922f7860bcb Auto-Submitted: auto-generated The branch stable/12 has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=73765a5fa7d0daa72387d41661c36922f7860bcb commit 73765a5fa7d0daa72387d41661c36922f7860bcb Author: Scott Long AuthorDate: 2020-02-07 12:15:39 +0000 Commit: Alan Somers CommitDate: 2023-10-05 20:36:00 +0000 Advertise the MPI Message Version that's contained in the IOCFacts message in the sysctl block for the driver. mpsutil/mprutil needs this so it can know how big of a buffer to allocate when requesting the IOCFacts from the controller. This eliminates the kernel console messages about wrong allocation sizes. Reported by: imp (cherry picked from commit 69e85eb8ae4919e0806bc2957cbc4a33f9138b54) mprutil: "fix user reply buffer (64)..." warnings Depending on the card's firmware version, it may return different length responses for MPI2_FUNCTION_IOC_FACTS. But the first part of the response contains the length of the rest, so query it first to get the length and then use that to size the buffer for the full response. Also, correctly zero-initialize MPI2_IOC_FACTS_REQUEST. It only worked by luck before. PR: 264848 Reported by: Julien Cigar Sponsored by: Axcient Reviewed by: scottl, imp Differential Revision: https://reviews.freebsd.org/D38739 (cherry picked from commit 7d154c4dc64e61af7ca536c4e9927fa07c675a83) --- sys/dev/mpr/mpr.c | 14 ++++++++++++-- sys/dev/mpr/mpr_user.c | 6 +++--- sys/dev/mpr/mprvar.h | 1 + sys/dev/mps/mps.c | 14 ++++++++++++-- sys/dev/mps/mps_user.c | 6 +++--- sys/dev/mps/mpsvar.h | 1 + usr.sbin/mpsutil/mps_cmd.c | 35 +++++++++++++++++++++++++++++++---- 7 files changed, 63 insertions(+), 14 deletions(-) diff --git a/sys/dev/mpr/mpr.c b/sys/dev/mpr/mpr.c index 562d629c7afa..b36e10d103d3 100644 --- a/sys/dev/mpr/mpr.c +++ b/sys/dev/mpr/mpr.c @@ -521,6 +521,12 @@ mpr_iocfacts_allocate(struct mpr_softc *sc, uint8_t attaching) sc->facts->FWVersion.Struct.Unit, sc->facts->FWVersion.Struct.Dev); + snprintf(sc->msg_version, sizeof(sc->msg_version), "%d.%d", + (sc->facts->MsgVersion & MPI2_IOCFACTS_MSGVERSION_MAJOR_MASK) >> + MPI2_IOCFACTS_MSGVERSION_MAJOR_SHIFT, + (sc->facts->MsgVersion & MPI2_IOCFACTS_MSGVERSION_MINOR_MASK) >> + MPI2_IOCFACTS_MSGVERSION_MINOR_SHIFT); + mpr_dprint(sc, MPR_INFO, "Firmware: %s, Driver: %s\n", sc->fw_version, MPR_DRIVER_VERSION); mpr_dprint(sc, MPR_INFO, @@ -1904,13 +1910,17 @@ mpr_setup_sysctl(struct mpr_softc *sc) "Total number of event frames allocated"); SYSCTL_ADD_STRING(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), - OID_AUTO, "firmware_version", CTLFLAG_RW, sc->fw_version, + OID_AUTO, "firmware_version", CTLFLAG_RD, sc->fw_version, strlen(sc->fw_version), "firmware version"); SYSCTL_ADD_STRING(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), - OID_AUTO, "driver_version", CTLFLAG_RW, MPR_DRIVER_VERSION, + OID_AUTO, "driver_version", CTLFLAG_RD, MPR_DRIVER_VERSION, strlen(MPR_DRIVER_VERSION), "driver version"); + SYSCTL_ADD_STRING(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), + OID_AUTO, "msg_version", CTLFLAG_RD, sc->msg_version, + strlen(sc->msg_version), "message interface version (deprecated)"); + SYSCTL_ADD_INT(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), OID_AUTO, "io_cmds_active", CTLFLAG_RD, &sc->io_cmds_active, 0, "number of currently active commands"); diff --git a/sys/dev/mpr/mpr_user.c b/sys/dev/mpr/mpr_user.c index 53b3f94ea152..62111b91af0b 100644 --- a/sys/dev/mpr/mpr_user.c +++ b/sys/dev/mpr/mpr_user.c @@ -855,8 +855,8 @@ mpr_user_pass_thru(struct mpr_softc *sc, mpr_pass_thru_t *data) if ((cm != NULL) && (cm->cm_reply != NULL)) { rpl = (MPI2_DEFAULT_REPLY *)cm->cm_reply; sz = rpl->MsgLength * 4; - - if (sz > data->ReplySize) { + + if (bootverbose && sz > data->ReplySize) { mpr_printf(sc, "%s: user reply buffer (%d) " "smaller than returned buffer (%d)\n", __func__, data->ReplySize, sz); @@ -1081,7 +1081,7 @@ mpr_user_pass_thru(struct mpr_softc *sc, mpr_pass_thru_t *data) rpl = (MPI2_DEFAULT_REPLY *)cm->cm_reply; sz = rpl->MsgLength * 4; - if (sz > data->ReplySize) { + if (bootverbose && sz > data->ReplySize) { mpr_printf(sc, "%s: user reply buffer (%d) smaller " "than returned buffer (%d)\n", __func__, data->ReplySize, sz); diff --git a/sys/dev/mpr/mprvar.h b/sys/dev/mpr/mprvar.h index 8eb9379d8cff..bda6e9c7da17 100644 --- a/sys/dev/mpr/mprvar.h +++ b/sys/dev/mpr/mprvar.h @@ -369,6 +369,7 @@ struct mpr_softc { struct sysctl_ctx_list sysctl_ctx; struct sysctl_oid *sysctl_tree; char fw_version[16]; + char msg_version[8]; struct mpr_command *commands; struct mpr_chain *chains; struct mpr_prp_page *prps; diff --git a/sys/dev/mps/mps.c b/sys/dev/mps/mps.c index 1fb7cf09eae8..7bb7d97cb538 100644 --- a/sys/dev/mps/mps.c +++ b/sys/dev/mps/mps.c @@ -498,6 +498,12 @@ mps_iocfacts_allocate(struct mps_softc *sc, uint8_t attaching) sc->facts->FWVersion.Struct.Unit, sc->facts->FWVersion.Struct.Dev); + snprintf(sc->msg_version, sizeof(sc->msg_version), "%d.%d", + (sc->facts->MsgVersion & MPI2_IOCFACTS_MSGVERSION_MAJOR_MASK) >> + MPI2_IOCFACTS_MSGVERSION_MAJOR_SHIFT, + (sc->facts->MsgVersion & MPI2_IOCFACTS_MSGVERSION_MINOR_MASK) >> + MPI2_IOCFACTS_MSGVERSION_MINOR_SHIFT); + mps_dprint(sc, MPS_INFO, "Firmware: %s, Driver: %s\n", sc->fw_version, MPS_DRIVER_VERSION); mps_dprint(sc, MPS_INFO, "IOCCapabilities: %b\n", @@ -1738,13 +1744,17 @@ mps_setup_sysctl(struct mps_softc *sc) "Total number of event frames allocated"); SYSCTL_ADD_STRING(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), - OID_AUTO, "firmware_version", CTLFLAG_RW, sc->fw_version, + OID_AUTO, "firmware_version", CTLFLAG_RD, sc->fw_version, strlen(sc->fw_version), "firmware version"); SYSCTL_ADD_STRING(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), - OID_AUTO, "driver_version", CTLFLAG_RW, MPS_DRIVER_VERSION, + OID_AUTO, "driver_version", CTLFLAG_RD, MPS_DRIVER_VERSION, strlen(MPS_DRIVER_VERSION), "driver version"); + SYSCTL_ADD_STRING(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), + OID_AUTO, "msg_version", CTLFLAG_RD, sc->msg_version, + strlen(sc->msg_version), "message interface version (deprecated)"); + SYSCTL_ADD_INT(sysctl_ctx, SYSCTL_CHILDREN(sysctl_tree), OID_AUTO, "io_cmds_active", CTLFLAG_RD, &sc->io_cmds_active, 0, "number of currently active commands"); diff --git a/sys/dev/mps/mps_user.c b/sys/dev/mps/mps_user.c index e7e376288961..a065112bf138 100644 --- a/sys/dev/mps/mps_user.c +++ b/sys/dev/mps/mps_user.c @@ -866,8 +866,8 @@ mps_user_pass_thru(struct mps_softc *sc, mps_pass_thru_t *data) if ((cm != NULL) && (cm->cm_reply != NULL)) { rpl = (MPI2_DEFAULT_REPLY *)cm->cm_reply; sz = rpl->MsgLength * 4; - - if (sz > data->ReplySize) { + + if (bootverbose && sz > data->ReplySize) { mps_printf(sc, "%s: user reply buffer (%d) " "smaller than returned buffer (%d)\n", __func__, data->ReplySize, sz); @@ -1021,7 +1021,7 @@ mps_user_pass_thru(struct mps_softc *sc, mps_pass_thru_t *data) rpl = (MPI2_DEFAULT_REPLY *)cm->cm_reply; sz = rpl->MsgLength * 4; - if (sz > data->ReplySize) { + if (bootverbose && sz > data->ReplySize) { mps_printf(sc, "%s: user reply buffer (%d) smaller " "than returned buffer (%d)\n", __func__, data->ReplySize, sz); diff --git a/sys/dev/mps/mpsvar.h b/sys/dev/mps/mpsvar.h index bb0087bf0346..2326084fee3d 100644 --- a/sys/dev/mps/mpsvar.h +++ b/sys/dev/mps/mpsvar.h @@ -327,6 +327,7 @@ struct mps_softc { struct sysctl_ctx_list sysctl_ctx; struct sysctl_oid *sysctl_tree; char fw_version[16]; + char msg_version[8]; struct mps_command *commands; struct mps_chain *chains; struct callout periodic; diff --git a/usr.sbin/mpsutil/mps_cmd.c b/usr.sbin/mpsutil/mps_cmd.c index 51a0e77822d9..8d7432651495 100644 --- a/usr.sbin/mpsutil/mps_cmd.c +++ b/usr.sbin/mpsutil/mps_cmd.c @@ -727,28 +727,55 @@ mps_pass_command(int fd, void *req, uint32_t req_len, void *reply, return (0); } +/* Return the length in bytes of the device's MPI2_IOC_FACTS reply */ +static size_t +mps_get_ioc_factslen(int fd) +{ + MPI2_IOC_FACTS_REQUEST req; + const size_t factslen = 4; + char factsbuf[4] = {0}; + MPI2_IOC_FACTS_REPLY *facts = (MPI2_IOC_FACTS_REPLY*)factsbuf; + int error; + + bzero(&req, sizeof(req)); + req.Function = MPI2_FUNCTION_IOC_FACTS; + error = mps_pass_command(fd, &req, sizeof(MPI2_IOC_FACTS_REQUEST), + factsbuf, factslen, NULL, 0, NULL, 0, 10); + + if (error) + return (0); + + /* The card's response is measured in dwords */ + return (facts->MsgLength * 4); +} + MPI2_IOC_FACTS_REPLY * mps_get_iocfacts(int fd) { MPI2_IOC_FACTS_REPLY *facts; MPI2_IOC_FACTS_REQUEST req; + size_t factslen; int error; - facts = malloc(sizeof(MPI2_IOC_FACTS_REPLY)); + factslen = mps_get_ioc_factslen(fd); + if (factslen == 0) + return (NULL); + + facts = malloc(factslen); if (facts == NULL) { errno = ENOMEM; return (NULL); } - bzero(&req, sizeof(MPI2_IOC_FACTS_REQUEST)); + bzero(&req, sizeof(req)); req.Function = MPI2_FUNCTION_IOC_FACTS; #if 1 error = mps_pass_command(fd, &req, sizeof(MPI2_IOC_FACTS_REQUEST), - facts, sizeof(MPI2_IOC_FACTS_REPLY), NULL, 0, NULL, 0, 10); + facts, factslen, NULL, 0, NULL, 0, 10); #else error = mps_user_command(fd, &req, sizeof(MPI2_IOC_FACTS_REQUEST), - facts, sizeof(MPI2_IOC_FACTS_REPLY), NULL, 0, 0); + facts, factslen, NULL, 0, 0); #endif if (error) { free(facts); From nobody Thu Oct 5 22:05:12 2023 X-Original-To: dev-commits-src-branches@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 4S1lwm3DY2z4vwdW; Thu, 5 Oct 2023 22:05:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1lwm2kfPz3GGx; Thu, 5 Oct 2023 22:05:12 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696543512; 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=Fdh59te33r8HTHQevfhZHVRDPktPS5vMr5nDRPC9sa4=; b=wdtY2gx5nCv4eMdMQ2bxri5br12aUPnMjXfmUKVuUj8fJ6/6Lasc6heWvSTGJZ7lpqPYIF IohPoikWa8vB3koH4XYbvxeMEj1zblVVZBoDOVF99FCCDeOZWISzPGokmDcoyWsyuTsYW6 tVz8usrIPcqcpRRYAWCG4wyOOqSzQI6mtKozCXO0y52cREzhipiZJytvsBaxQERq/iy6gP Wr156fRPPS9iNbWupuDiE+ZpWHilHwMmci/5+2oREcvlgcUAwYnVgrz7tlZmaHG+ckrBOX Qm4fyt8jRSrFoyLS+Y/Q4v1WSJE1kz4yI1slov+nNdMHcE2j8vlCJXwePioYHw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696543512; a=rsa-sha256; cv=none; b=hRemQe4E4dlaE+hAK+m2GlWT3t4KtAhYQtGzSdWWUC2A2IE6DlBB5OgUA7q9g6h3Lix7oi dIVfuI9lt5B7JX3wi62hmVWUVeL8+4u7ET6CzuRpxsUTFVyM1ehic2ISqQCkT8DXPUOPWF yT598CyfRuSzRQf9RZtcUopb/5tWOggQXXrpC8rES2yGrQp18tl5zJ6htInE2JOcEO7vrD qlXEm279t5E/qagzZ5L/JffmG6x4y68wiTECa2RIMa6MlCA3Q2BnFKz4xr6up92Mz9EPOV 1kkxa72qWj8zkI9HzekqXmCWEsdhXyxWjd/c8yONtqMo0YB91N3t1Ip5ZR/0Vg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696543512; 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=Fdh59te33r8HTHQevfhZHVRDPktPS5vMr5nDRPC9sa4=; b=nH7AV8AuWOysG0wwn+qr9g38457yQnJus1ztiksD87pJ6y5djOUotikzcqQRv/XsE/VdRt 7vZHyxacUWQvQizOoJXi0IhTH+oO0zs4FrHxWi1SrTw+MMl1K4DPZVeDCI6aN8/I6v+a3S 7Q0w1huAaaclmFVVy7mLuZ/kWhDuP8DCNSoBhzpNqFQYZcKd9wclLZOJrK2F6aEjOXHxy6 olX8pApDjiAc4107PnYuxtsJsavZwhzLOMZCN80iqdLX634rf109H+EIdhLt6Sq1VaDV/2 W6eCN4PErVlMW+nMe+tZ/8zpEhXO1WRDiJp6KH+PGUpS3Efp2UADj1/OmtfNig== 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 4S1lwm1nHwz7MQ; Thu, 5 Oct 2023 22:05:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 395M5CgJ063436; Thu, 5 Oct 2023 22:05:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 395M5Cqs063433; Thu, 5 Oct 2023 22:05:12 GMT (envelope-from git) Date: Thu, 5 Oct 2023 22:05:12 GMT Message-Id: <202310052205.395M5Cqs063433@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Guzik Subject: git: 7a360746c877 - stable/14 - vfs cache: s/vfs.cache_fast_lookup/vfs.cache.param.fast_lookup List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mjg X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 7a360746c877e00c994c60004ccd87253091dbba Auto-Submitted: auto-generated The branch stable/14 has been updated by mjg: URL: https://cgit.FreeBSD.org/src/commit/?id=7a360746c877e00c994c60004ccd87253091dbba commit 7a360746c877e00c994c60004ccd87253091dbba Author: Mateusz Guzik AuthorDate: 2023-10-03 13:34:32 +0000 Commit: Mateusz Guzik CommitDate: 2023-10-05 22:05:00 +0000 vfs cache: s/vfs.cache_fast_lookup/vfs.cache.param.fast_lookup (cherry picked from commit 38a375c472d295df41adf73c5ddd50543f9d877c) --- sys/kern/vfs_cache.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/kern/vfs_cache.c b/sys/kern/vfs_cache.c index 12b9f2d74641..7e059d374c31 100644 --- a/sys/kern/vfs_cache.c +++ b/sys/kern/vfs_cache.c @@ -4036,7 +4036,7 @@ syscal_vfs_cache_fast_lookup(SYSCTL_HANDLER_ARGS) cache_fast_lookup_enabled_recalc(); return (error); } -SYSCTL_PROC(_vfs, OID_AUTO, cache_fast_lookup, CTLTYPE_INT|CTLFLAG_RW|CTLFLAG_MPSAFE, +SYSCTL_PROC(_vfs_cache_param, OID_AUTO, fast_lookup, CTLTYPE_INT|CTLFLAG_RW|CTLFLAG_MPSAFE, &cache_fast_lookup, 0, syscal_vfs_cache_fast_lookup, "IU", ""); /* From nobody Fri Oct 6 00:00:43 2023 X-Original-To: dev-commits-src-branches@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 4S1pV34MpVz4wHG2; Fri, 6 Oct 2023 00:00: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S1pV33qNLz3Tlx; Fri, 6 Oct 2023 00:00:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696550443; 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=SoAFPtrLsGzOvIyH7SsZ2QoipUiZ3kd9FkM1JGJpFPA=; b=dR1tUVbmBsQmFgXLjRz5CWCATgsZtza9o5ECk3NZBVtNu4ihEslU5IkeBM3eOX+85VQGw8 khFTxm3omrtdRLV3mROBXlH0osshueMoUHR7dOLYLEHl3P1ATt1EMnHlG+NUvvNxYoz2XU exPq0KHD9cC9u4+CE38MB3KNKv6rg9nOFISrCOU+6/n32uiKXsw9hXshTf8/jS4ix3gNDi XlnJdk915/k4sLvFB7Re3DF9VN25b0yGoluU+h8B3YtpAKDhsugh/D0f10yq98G9HU7Nsg XrUg0JVdGYovk4JeFd764o1FdDpVI2lkSw88nQoqCo2kSIM4lIn/84WdTUowXQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696550443; a=rsa-sha256; cv=none; b=l76TG/C6fJ9Q7A/8mAKJwmXzeEzpIiZOTmJx/Hr2LZaMkcX+4fy3APwc30U7EGLIs1SNeV aHh2Z5eroeXve+C9sQPvjwJRUvGOX3WxA31JRWEGh7yiZABMk9+KC0IBRwZq3RetvdyQe/ V11uuBboNNeOI2RHgLgucj4OYfcIpZ1N+mLkM0EqzQxPk5T47waVKLfILuXvlXAucgSoA4 nQi9k3M/vzV5kAw0RKA1TyC1fOPqLsSDD71HH+ZmR0ThKHf4t3fxITr3UWMQBRllnU+R17 yBTREjbwo66FpSziFAcC00toG/gLqftdy6Atd9XwZbdXhLi5xnW2cVZT18Dg6g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696550443; 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=SoAFPtrLsGzOvIyH7SsZ2QoipUiZ3kd9FkM1JGJpFPA=; b=nbuveYy5dqNw5yHLrKdhHFcTA6YsekHfDfjBGi/2d6/3dPpYfeniadTRjUPzrLZX/5vPQK 00AwtMe6pGTXfj1iyG1mwWrrh1313d+OAu9Lj18LweiTZrxQ/wja/p//bs3MX04srF02Uu pt9s/M77nMeP9t8bmEMHDKyYADj9eOAzFU/ffbV7GSI78eTSuRhT1v7tkrhvWiXX8ta1oI 1e6RwwQYYDydEqXqeI6qp13Rv/EoKl+6tFs1CGSYcVrUcYsXyi9OebwC0js33LZ//agUb3 ggv3JtArjwbVc2omBYD+uXutl/8WlnteTJsdJcZDBaKBnhDtyhw76OtakaTPnw== 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 4S1pV32pQQzBMl; Fri, 6 Oct 2023 00:00:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39600hLM056437; Fri, 6 Oct 2023 00:00:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39600hME056434; Fri, 6 Oct 2023 00:00:43 GMT (envelope-from git) Date: Fri, 6 Oct 2023 00:00:43 GMT Message-Id: <202310060000.39600hME056434@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Glen Barber Subject: git: 243550d32f42 - releng/14.0 - release: update releng/14.0 to BETA5 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: gjb X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.0 X-Git-Reftype: branch X-Git-Commit: 243550d32f4231d4407cd57220d36e42153d97f0 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by gjb: URL: https://cgit.FreeBSD.org/src/commit/?id=243550d32f4231d4407cd57220d36e42153d97f0 commit 243550d32f4231d4407cd57220d36e42153d97f0 Author: Glen Barber AuthorDate: 2023-10-06 00:00:16 +0000 Commit: Glen Barber CommitDate: 2023-10-06 00:00:16 +0000 release: update releng/14.0 to BETA5 Approved by: re (implicit) Sponsored by: GoFundMe https://www.gofundme.com/f/gjbbsd Sponsored by: PayPal https://paypal.me/gjbbsd --- sys/conf/newvers.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/conf/newvers.sh b/sys/conf/newvers.sh index 58dc89079e90..41c4da97d022 100644 --- a/sys/conf/newvers.sh +++ b/sys/conf/newvers.sh @@ -53,7 +53,7 @@ TYPE="FreeBSD" REVISION="14.0" -BRANCH="BETA4" +BRANCH="BETA5" if [ -n "${BRANCH_OVERRIDE}" ]; then BRANCH=${BRANCH_OVERRIDE} fi From nobody Fri Oct 6 07:55:27 2023 X-Original-To: dev-commits-src-branches@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 4S211q6VMyz4wKWR; Fri, 6 Oct 2023 07:55: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S211q60Gxz3RcL; Fri, 6 Oct 2023 07:55:27 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696578927; 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=zytb/AKN1BFq9bBFMedaod9wilrq0VzLQZX8gPIqn/U=; b=RaQVzDZNppqp1haSaGHDm/c9NmRTt461mnqZ0UMW3KbgWUarHKEnGLuJXiC6Y7Ixqbu5Qj uefBkgpmeHs815WNour2rfdpFXI9tpyerqqLGhtQNZFZIns94dSWqW+cSfgmR9wk0qbNSd Kx8uu7UkYwgcsFLnDdKoabw475ylMwWBWQucUUnVpvpdCMuonC+BAyB/6i3fKrSfGFqrv4 BK0nUFy6JY/rdGIuyFusozGFOYeDU3g8gfd3i4xoLHN0+wd9HwCqlXoeernRwbGuhSDkah HDn9XmLJQblpflB6T9oL355IluVYVZVn5Xx+6IDHjBkvaGWh8Fkbq1W+ry7UCg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696578927; a=rsa-sha256; cv=none; b=EtAVeEvZNk+3CoH2Qnue8uguYLWK16GOAs0VvfR49i+ZleqQn28EOpy/o90mU1ai0Y+oPR uh2C8WGmZ8+5vzKhnVVp8A+MKFxpKrucdLedNKRS34rtngulus57vd38ExAJwHyFdinDcB OzkjlLun05diQkHCDEBT0zsqM3qWJaGoj/cYYn7fe0LbuDNtaT7r3X3VpqclR6DoNxenfY m9A2bT41pP7dueoJNl7iT+p2ceyJmRETuJ8Bal4/mlkvVlBq3usIfOFAfkmuUcNoMvztvf RJzrFGmcbhoFqlDJsYJ2g/iHgCKc2A37VoCSViwsbxSAsP48b3Nr6AyTt6nUkg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696578927; 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=zytb/AKN1BFq9bBFMedaod9wilrq0VzLQZX8gPIqn/U=; b=mR14zkrZYfPXfIae3fmlLlXzLKMGhPvoL0kCGM+EUdvxEfV8rMal2mFRyVAXuXG+cCUw7q qYZQKaOlvtXEo8M915COCNUM1ek7Mevhht2J5PUHG20zZMVcbAh5d+bGYSiGsebDbRnSY5 sGWVIC4dPbG0+9vn9eqHV7OJCevrJbSvRM5bP0DPoupSUnml7TF+A3ghfLL91UqDQGvDWS htBVNyCKgyk8y80Uu8UFgdCRwI+mrHO+l7QuQEUVmTVcrWWWL0HWEtHv4257QUa9wGd8n3 WXud5VUhy3eTq+sVNw/j+kyDfxUTGGOd4dGC+I6Kkte+VzVb3aaSHseZ1FFr6w== 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 4S211q52y2zg9s; Fri, 6 Oct 2023 07:55:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3967tR4D041769; Fri, 6 Oct 2023 07:55:27 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3967tRoX041766; Fri, 6 Oct 2023 07:55:27 GMT (envelope-from git) Date: Fri, 6 Oct 2023 07:55:27 GMT Message-Id: <202310060755.3967tRoX041766@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 1e853a1196fc - stable/14 - sbuf.9: Add LIBRARY section List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 1e853a1196fcabe890aafdf1a22616d392e28974 Auto-Submitted: auto-generated The branch stable/14 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=1e853a1196fcabe890aafdf1a22616d392e28974 commit 1e853a1196fcabe890aafdf1a22616d392e28974 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2023-10-03 17:07:15 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-06 07:55:14 +0000 sbuf.9: Add LIBRARY section Sponsored by: Klara, Inc. MFC after: 3 days (cherry picked from commit 5a82fc7859f746d95811e43b3a117b8eea297749) --- share/man/man9/sbuf.9 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/share/man/man9/sbuf.9 b/share/man/man9/sbuf.9 index 5ab045118f51..d4ffa050a893 100644 --- a/share/man/man9/sbuf.9 +++ b/share/man/man9/sbuf.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 26, 2020 +.Dd October 3, 2023 .Dt SBUF 9 .Os .Sh NAME @@ -60,6 +60,8 @@ .Nm sbuf_printf_drain , .Nm sbuf_putbuf .Nd safe string composition +.Sh LIBRARY +.Lb libsbuf .Sh SYNOPSIS .In sys/types.h .In sys/sbuf.h From nobody Fri Oct 6 07:55:34 2023 X-Original-To: dev-commits-src-branches@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 4S211y5Wn6z4wKLt; Fri, 6 Oct 2023 07:55: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S211y4Kbbz3RxP; Fri, 6 Oct 2023 07:55:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696578934; 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=h31yuekMRbz4OiaJErxdTVryhV3fejzQSVf0gFaVSq4=; b=OBevaNMiPS3MPH+rqe2K6Rkb9T/5gsw2h5leptSrS8UoBDHoLmiYFa3WCvkdh1INp17jiS QMkUF2WmencJFi+2E0rMCqRQofbPa5pqZ5MbSUTeRnKMH6LdGbiUY0+u4zNwoafft1r7kL aYzhS6/IUQv70vyAT3vPXzjjHNmsqK5IG5W0OBwo37LQ4gXFuiHKxnNW5FIgH+KkCLMiOy ddpFU0D5CPVOvhv75UdWec4GueKXFsUDN5llGV+8N5OkNDkSYgviHkChgWcKG6cNt0I4VY yOMGHXawiLzdW6KrBS/gbk8/R9tDB4AS5yfx1WaU2zOxetZhUJYXM94iHwnnUw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696578934; a=rsa-sha256; cv=none; b=ww/7i+q2Gck8ltlqml+pCWqyjd7Go9/5pZMlwkq/TlFEbGZ7/DcwYwVC1JtAbYCfEy/P+L P9lEsBMMP1HpDZ2xlsvUw9LFDs0l4BudBqxFKbv4jVBRpxjek36jVcDlSrpmHbEOm1F8xl Aed8ht9LbmgUg+j56cl+BKkhuTheHiIORwKQyYs0p3GiObIWGJDJr4rNU6LWw4Mv+JbZnz GdNiAlYAOffWQDhks2sdtFIHAi4FKUh8ZCCIIJY0gsByXqWTLcD90ABn6AUxgnBZ54woNG QzZ35lEF9ZSMnab7yfaDlSojSC4wlOVILmdPXbGbTgecdKH3GtCC/m9zh+T+rw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696578934; 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=h31yuekMRbz4OiaJErxdTVryhV3fejzQSVf0gFaVSq4=; b=n3a7jYlP3hbR0rA5iN+tBe0BttthlYyVkAeLnjGhtC3TpF7UeFvSweqRz6MjE9q0viWtBJ IxRJkAh/D2y16D/DFqG6DtCmTiB+z7xRfF6/CvQxVMX8/TkX6JVzYds4LsKrbnyobMv7K9 p7KR5WoVuKFjVDS2npSCPUA2VWmBksdo9t1NO/u2O2tExmFfP9DjgKI1l68ZIEXOUNT7Kp EElXcHfMO0ZWqzwLCC4ZlAAiY1Oibi+SRJLcyV8e0L52uR1TZNZRtoEdqcNEKUz5LA0Lkr Inoxbg1e6qaAb9QtEdj3ur9KzHTDleuJVsmF5ReG6HlktfJ3g0+MYXYZDZTxEw== 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 4S211y3R1Lzfnq; Fri, 6 Oct 2023 07:55:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3967tY2k041906; Fri, 6 Oct 2023 07:55:34 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3967tYu5041903; Fri, 6 Oct 2023 07:55:34 GMT (envelope-from git) Date: Fri, 6 Oct 2023 07:55:34 GMT Message-Id: <202310060755.3967tYu5041903@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 1369c31e7808 - stable/13 - sbuf.9: Add LIBRARY section List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 1369c31e78082f70cb4a95429c866df397eb9d8b Auto-Submitted: auto-generated The branch stable/13 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=1369c31e78082f70cb4a95429c866df397eb9d8b commit 1369c31e78082f70cb4a95429c866df397eb9d8b Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2023-10-03 17:07:15 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2023-10-06 07:55:28 +0000 sbuf.9: Add LIBRARY section Sponsored by: Klara, Inc. MFC after: 3 days (cherry picked from commit 5a82fc7859f746d95811e43b3a117b8eea297749) --- share/man/man9/sbuf.9 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/share/man/man9/sbuf.9 b/share/man/man9/sbuf.9 index 499b9b194d35..77640fb7fd26 100644 --- a/share/man/man9/sbuf.9 +++ b/share/man/man9/sbuf.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 26, 2020 +.Dd October 3, 2023 .Dt SBUF 9 .Os .Sh NAME @@ -60,6 +60,8 @@ .Nm sbuf_printf_drain , .Nm sbuf_putbuf .Nd safe string composition +.Sh LIBRARY +.Lb libsbuf .Sh SYNOPSIS .In sys/types.h .In sys/sbuf.h From nobody Fri Oct 6 14:25:02 2023 X-Original-To: dev-commits-src-branches@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 4S29gL684nz4wgbH; Fri, 6 Oct 2023 14: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gL5gXHz3QWp; Fri, 6 Oct 2023 14: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=1696602302; 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=ydchxDGLVTdouxGgENzP8fR50JLDXGaCtyRvjl/quz8=; b=nZmG9RfUbMZzokhtiyk2YlMQs60qW2oODoRTO+dCldr4LGLB5mkTMzxzoUAqPr8TyCeupK Bpuotbc0S8olIM9/T73HTjofaMKizWKR4SDkEAg3dHcQpz8SxjE6z8r8iPs0zKnpIJItnr E97E39yj/84BM45jSpA6O055xugaNVrivg0RX1+3olsq8vHA4bYgfRpbh7WNX9AcFe8wuc rObaflh6xA6yxZYABFczumFkq+KQXk4j8me0NzG2OzAYe+E+GjkCLeox5bS8z5y2entPuh YSRzpW2QrdN1akf/iz9ZEfWKhAzOwOrMb42j/w36VCGVJ9AILtwB6fquIrX77g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602302; a=rsa-sha256; cv=none; b=HxZ8sV/Sq6s4Z0JM4q1L4M7RzPSNBVw8TMt63FftkldAretu+ic8WxvIOsx11v6YPYxP0A 8QSCHtVKW9FLei89ByS7vkOYkC02IOWlrtrIWqDlaYD7xfgSsrWpppeCwGoqz9jV3jwPQJ ePZ5FI4oLcU/43ClWOvDJku6nLRCWXB4ZZVuhCrBcsVNjsMWP7bM31tkF+g0unysd5U82y 1OmTx5j0r9FEyp8AR/ai0UV9/v6i1ypugDCTcQJbQ0XcDMhYmjRoq23D85uglePkzSBN3/ iokrT/ZtaWcCayFu+S+UmXJJXVU4MkVz61tzBCSUcrB/CTee6Gqz++mw6kptYw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602302; 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=ydchxDGLVTdouxGgENzP8fR50JLDXGaCtyRvjl/quz8=; b=ycWgU89+dF9RNIEbO6gem1BcDqRISiSiqETUTz4X40ak/9s4YLXX+jQgLqJ29w3mj+FfVM 2hYdEvOTeqj29Bu+ctKXwGww9bRErPmu8o3iQCYscMXbJc9+hc8VXPgxByKtn6/2gn6rFi lwBQZLpw3LPPgLXNRWqpyuYCb+1XE62U1dUJ9ujf3zAklVaH+gj7EbjjA6zdPGph+GjCvd jpbG+Z58qQiZAxDBzM/dCqpNVyN/HxRDGOpW7lVwoeKDK2y9i+YMVxmKYNUFxD94Piqafp 3hCBTmxynXw0K5IsFam4a71yVMJEWYJlA1d0F6kG7xzxW93dHqQLHTCTT+H+sw== 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 4S29gL4StkzrXF; Fri, 6 Oct 2023 14:25:02 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EP2B0092901; Fri, 6 Oct 2023 14:25:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EP2N9092896; Fri, 6 Oct 2023 14:25:02 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:02 GMT Message-Id: <202310061425.396EP2N9092896@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 2709483a725e - stable/14 - linuxkpi: fix iteration in __sg_alloc_table_from_pages List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 2709483a725e1da2d443d9e391bfaa0f223099be Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=2709483a725e1da2d443d9e391bfaa0f223099be commit 2709483a725e1da2d443d9e391bfaa0f223099be Author: Austin Shafer AuthorDate: 2023-09-06 14:08:05 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:39 +0000 linuxkpi: fix iteration in __sg_alloc_table_from_pages Commit 3f686532c9b4 tried to fix an issue with not properly starting at the first page in the sg list to prevent a panic. This worked but with the side effect of incrementing "s" during the final iteration causing it to be NULL since the list had ended. In cases non-DEBUG kernels this causes a panic with drm-5.15, since "s" is NULL when we later pass it to sg_mark_end(). This change decouples the iteration sg from the return value so that it is never incremented past the final page in the chain. Reviewed by: manu Differential Revision: https://reviews.freebsd.org/D41574 (cherry picked from commit 09b0401e91a92bcb58ea1873857b42f8211f660f) --- sys/compat/linuxkpi/common/include/linux/scatterlist.h | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/scatterlist.h b/sys/compat/linuxkpi/common/include/linux/scatterlist.h index 0e4cc90e57a5..e462d5c649f1 100644 --- a/sys/compat/linuxkpi/common/include/linux/scatterlist.h +++ b/sys/compat/linuxkpi/common/include/linux/scatterlist.h @@ -343,7 +343,7 @@ __sg_alloc_table_from_pages(struct sg_table *sgt, { unsigned int i, segs, cur, len; int rc; - struct scatterlist *s; + struct scatterlist *s, *sg_iter; #if defined(LINUXKPI_VERSION) && LINUXKPI_VERSION >= 51300 if (prv != NULL) { @@ -377,10 +377,18 @@ __sg_alloc_table_from_pages(struct sg_table *sgt, #endif cur = 0; - for (i = 0, s = sgt->sgl; i < sgt->orig_nents; i++) { + for_each_sg(sgt->sgl, sg_iter, sgt->orig_nents, i) { unsigned long seg_size; unsigned int j; + /* + * We need to make sure that when we exit this loop "s" has the + * last sg in the chain so we can call sg_mark_end() on it. + * Only set this inside the loop since sg_iter will be iterated + * until it is NULL. + */ + s = sg_iter; + len = 0; for (j = cur + 1; j < count; ++j) { len += PAGE_SIZE; @@ -394,8 +402,6 @@ __sg_alloc_table_from_pages(struct sg_table *sgt, size -= seg_size; off = 0; cur = j; - - s = sg_next(s); } KASSERT(s != NULL, ("s is NULL after loop in __sg_alloc_table_from_pages()")); From nobody Fri Oct 6 14:25:03 2023 X-Original-To: dev-commits-src-branches@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 4S29gN0DxJz4wghG; Fri, 6 Oct 2023 14:25: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gM6qgTz3QVQ; Fri, 6 Oct 2023 14:25:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602304; 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=xSWChhgW8dk0YKKiJfaLFA0ifSPsEtbFij/sUsEUeUQ=; b=qr0Uv00+rFVzfWhjnr3aFRulW9Syozm7QGfY41K/iY18r12rGwZelA06DOwIvXZaQVIk/E rTTGVGMwzFs0/7uJI8ptFVDAD7E93Puyx4slMmditXLHQKsMcvLn99KKlIGeA1n4lIPPZQ 4svU9WEyurTct6ADc58KdUDO7Eu/d9nAPPC8h9rLIy8Wt2aZDO7DTyA2hCf/LVMhcVgDWj Som1W2XnfARv+HbHAKPKrGbgkid+a4yx7/1/IC2Gn72+r6W5hT/Wnh+pNl7+2/BLRn9ipt RnxRjoI9BvrTVeYXkX1R6loiWFhXJBGeqY6vLSycRqRNYnOifT9CbDUSi3rOMg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602304; a=rsa-sha256; cv=none; b=ZHj22s6SuNaqFwAcSxr4SNPK9rlbsWDBTPyZqU4aqLLygAEQ13VkinK6pUmny0RZ0Vt0Wk uzPJVtRvjQem7GZ3aq9fnd8P1sHXFjaunqkXsTFfyxHE5JfwFHKDNlt0XzFKUHIwy/w/B8 qR0QAhMdCmaDQWW/90XzUfo4kxF4NdhVlq+5kzV3kiiEO2IKqngfFclybPIXyGFmgYDKtx BPdMh7o9s73THn9SnmQx2wTpDOv5DhfVz/dCltXxSE823sU3B0HeChCKQxncPRkQVx/fl6 JUBj6P/HN+/CDUikDWm+kA3kBvBwV3IF8UQbBBExcn6IrrdnRqm2TA/cATlHEg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602304; 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=xSWChhgW8dk0YKKiJfaLFA0ifSPsEtbFij/sUsEUeUQ=; b=FWlOmUR4q1z93ogfqbcysIq5vHj6X7nrFOjKU2HuWH/ehdp2Tp4jEtMMIaEpQ7zaKq21pY zRLFMhhtf+q1S7We4QQODL5oanfT7T8SGpKdOKIskeizaqIF7ZzkSffb4YTK6+Ojsr5jDO 84idj9sefQa3OuJvvmBnrGkl1KMIbjsCDT4aoDMCqA3ZG2WY3de3M0XnxCnImtrX9wlX9Z RQleY9T9UNUyzZg5s52cCAKcMJMH9CdykbHpsl7kP1KdeTwq3ODgUCk5rLlnr7UlooNdeR m4xiaMGWlN9kWi7JtuTrDJ+5zGbTy1Y4KP8UMhazTl2Q6vGDODGbib6d220QOg== 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 4S29gM5GzQzrXG; Fri, 6 Oct 2023 14:25:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EP3cj092955; Fri, 6 Oct 2023 14:25:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EP3Fj092952; Fri, 6 Oct 2023 14:25:03 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:03 GMT Message-Id: <202310061425.396EP3Fj092952@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 8bda9f9c56a9 - stable/14 - netlink: fix accessing freed memory List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 8bda9f9c56a997d851e8fc2c20b5e37f072ecb4a Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=8bda9f9c56a997d851e8fc2c20b5e37f072ecb4a commit 8bda9f9c56a997d851e8fc2c20b5e37f072ecb4a Author: Bjoern A. Zeeb AuthorDate: 2023-09-30 15:11:57 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:39 +0000 netlink: fix accessing freed memory The check for if_addrlen in dump_iface() is not sufficient to determine if we still have a valid if_addr. Rather than directly accessing if_addr check the STAILQ (for the first entry). This avoids panics when destroying cloned interfaces as experienced with net80211 wlan ones. Sponsored by: The FreeBSD Foundation Reviewed by: jhibbits (earlier version), kp Differential Revision: https://reviews.freebsd.org/D42027 (cherry picked from commit 7d48224073ce14f0dd3db2d4e96876ac928b52f2) --- sys/netlink/route/iface.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/sys/netlink/route/iface.c b/sys/netlink/route/iface.c index e1939c7681de..b6e120933f83 100644 --- a/sys/netlink/route/iface.c +++ b/sys/netlink/route/iface.c @@ -292,6 +292,7 @@ static bool dump_iface(struct nl_writer *nw, if_t ifp, const struct nlmsghdr *hdr, int if_flags_mask) { + struct epoch_tracker et; struct ifinfomsg *ifinfo; NL_LOG(LOG_DEBUG3, "dumping interface %s data", if_name(ifp)); @@ -321,11 +322,15 @@ dump_iface(struct nl_writer *nw, if_t ifp, const struct nlmsghdr *hdr, nlattr_add_u8(nw, IFLA_PROTO_DOWN, val); nlattr_add_u8(nw, IFLA_LINKMODE, val); */ - if (if_getaddrlen(ifp) != 0) { - struct ifaddr *ifa = if_getifaddr(ifp); + if (if_getaddrlen(ifp) != 0) { + struct ifaddr *ifa; - dump_sa(nw, IFLA_ADDRESS, ifa->ifa_addr); - } + NET_EPOCH_ENTER(et); + ifa = CK_STAILQ_FIRST(&ifp->if_addrhead); + if (ifa != NULL) + dump_sa(nw, IFLA_ADDRESS, ifa->ifa_addr); + NET_EPOCH_EXIT(et); + } if ((if_getbroadcastaddr(ifp) != NULL)) { nlattr_add(nw, IFLA_BROADCAST, if_getaddrlen(ifp), From nobody Fri Oct 6 14:25:04 2023 X-Original-To: dev-commits-src-branches@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 4S29gP0gmvz4wghL; Fri, 6 Oct 2023 14:25: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gN6wWdz3QPY; Fri, 6 Oct 2023 14:25:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602305; 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=MrN0YZQn8zl8lYddQlaNUDOP6tDd+Xi6dWuPmBdLweU=; b=OoL7VelrpKd+GwqUtCyjIRWLgsqST1KLqtlXd6ke1IHOBArnOrSsILxcS8x/EUn6RseXER hs16ThmFz6eBUpGenfNyf04gSmnXOF6mGxN7RAc9TUDLuBbuHn0A4j7112WjHjDekukLVq L9A+h5PUsdVffvB83lInTFQN5uY42Q74NYJBOyf1OARTIndkRCR6ZfGtPxiMdVWi1jdTyB Q5NHcP8PO8Lv8MUdIkJcKvdiuo/cysrXq4HMWnD/022K2AnjVMjmiVBFPjwlyRGK+aWZqc hBacAlgwDRy26aHtfjHvvwpQ3ZWnwnUPpuWkc5KeJCHnab7OkTmzy5S2aApwPA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602305; a=rsa-sha256; cv=none; b=Wvb03c6Zj/Lumd4EDno3ldzWin7ZayFycwsvcgpw1uPtgAR50o6KbGK1ZD2IpkW+si6m3Y 8JbFwCSZbK40H3+vi69tvjsZWUJsiMuP3JcKQkYJSO4NmTwu5kOp/oDwDza/w6oMwlJOsP oI0x9vFS6PBwThTcyi+1zqGWFUCcJoW9PtBKvcrLbxwVr+a27vt1RJInmf2D7E71tnwhBP J1n9xIZtlplaFTJ+P4iQUJTCIKHXeZkIjZkfzaf06emwAfILMG8xEhn+8zauvDvWtX3wP9 Yxw1erqdfeEP+JrCnYIPnDk1LEWPxwxZz38CcytEPDxBqtJ9NIHUp7Ee9aMnaw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602305; 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=MrN0YZQn8zl8lYddQlaNUDOP6tDd+Xi6dWuPmBdLweU=; b=XcOXU1KsTrUMBO7klGvquKQz+rq5fkzc5kaXQxVQAlMDMLqPbQqzl7EIqu3hcYHcHM8e6s a4Pr1AwyZaueg5n38VW6sRwyTWXSdv7G+Z9q0AT2rxR+h8vly9ksXmQmvlCDM9460orf6X WTq6yyhwfnNUqJmZEtWV4y+zCxqfOTYGa8WAgpbscbdJE7kCpCIVAh2mgweRStMnmmm9xh /c+P886xoLGYtR3vMy3OtAUr9fEX+V+i0r6Ae5jIsyxeyZYiuwOU5uSE699+JHt+PjUSm3 Q3MTr6yuWRcWIwKPq69x4/BigEx4KOAwesXugn90riubIuvuRy8nrw7kZts7GQ== 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 4S29gN60JWzrXH; Fri, 6 Oct 2023 14:25:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EP45j093012; Fri, 6 Oct 2023 14:25:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EP4J3093009; Fri, 6 Oct 2023 14:25:04 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:04 GMT Message-Id: <202310061425.396EP4J3093009@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: b6fbec77eb97 - stable/14 - iwlwifi / rtw88: temporary disconnect from build for updates List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: b6fbec77eb977538ab4c353789fdb255e01e0a8e Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=b6fbec77eb977538ab4c353789fdb255e01e0a8e commit b6fbec77eb977538ab4c353789fdb255e01e0a8e Author: Bjoern A. Zeeb AuthorDate: 2023-09-05 17:34:35 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:39 +0000 iwlwifi / rtw88: temporary disconnect from build for updates Disconnect iwlwifi/rtw88 from the build for a few commits which, due to incompatible LinuxKPI 802.11 changes would break the build for a revision. It will be re-enabled "instantly". Sponsored by: The FreeBSD Foundation (cherry picked from commit 712468443df1130db8f893a5e2ce5c6a8dbf5cde) (cherry picked from commit b75d1ce6c10652fc4bfbf509deeae0e05c3d1356) --- sys/modules/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/modules/Makefile b/sys/modules/Makefile index 4b98c7ed6e0d..66d7c895a460 100644 --- a/sys/modules/Makefile +++ b/sys/modules/Makefile @@ -561,12 +561,12 @@ _mlx5ib= mlx5ib ${MACHINE_CPUARCH} == "i386" _ena= ena _gve= gve -_iwlwifi= iwlwifi +#_iwlwifi= iwlwifi .if ${MK_SOURCELESS_UCODE} != "no" _iwlwififw= iwlwififw .endif _ossl= ossl -_rtw88= rtw88 +#_rtw88= rtw88 .if ${MK_SOURCELESS_UCODE} != "no" _rtw88fw= rtw88fw .endif From nobody Fri Oct 6 14:25:05 2023 X-Original-To: dev-commits-src-branches@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 4S29gQ1c6Vz4wgXk; Fri, 6 Oct 2023 14:25: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gQ0lCFz3Qjl; Fri, 6 Oct 2023 14:25:06 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602306; 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=CBHqk4Ygmz+8eWBoDNBxeYttEc1Ifw0eS2+5bQGo5mw=; b=QETzjdJ4UrDGmpAaFuDx0FH5yHKV8OuKhdt2KeZpR82B40APlgsLdMCupPzbg1i2Lwib3C u1l5iKwg5q6Xdxex06YuyCRTgnHf+amYUVuH4y7kgsRREKD4DaCsbIn16CkSkdS71coyWw TrMA3eqj5pObbbnP65D98xrd4JiIDC2CfrfulVxIt1ilkLW25VaOp80LhBmIhFAn4dM4v/ D+C02HQ4TjE5qK5hMAdG884rZeKu4ARLqjNCwumwfe8Zf9ItKhRL5LyKvXkOnP6Tc3XS35 5WYixd3ZqEbPVH4tm3Z1JFzqcNm5eTuP7rrNoRfqgXG8nmQm0Pv0r6Y9oq8uEw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602306; a=rsa-sha256; cv=none; b=mDfqox6qLgn6dU7JaE8b2lTJgbFpHiVl27YDSpoOqjHIVbaE02NHgxCfA4lRQeAPsuuOmI JW8ZgnxuzYhgLk8p6NtmNdmOPy+SyYGOSLnFViOMn72RQQEGZ9R/4r/uCBznJkepn4Dg+M I5QTVFbMpFlIYlv2rlq8R4QgPe3emeZ80+l0tIwhzAA9yti36BuubIsnOobKixjd9ZwjSA S06Usiow36BtjL9ec23/IYVCdobyrBh9eaBJRwYeh1yJTsJJBjlkgqw926NYSJpAoTXVR2 kdMQg+Oe2CE+/ykyHDheFHZ8mnffzpL+USzoPnTy8UC9o1xNEnkZXn1P0x9D5Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602306; 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=CBHqk4Ygmz+8eWBoDNBxeYttEc1Ifw0eS2+5bQGo5mw=; b=vMAxrn++daYBO/BarpBMcqyrg7WNPFz/+prD4mcmPUMKnAHz5w51vNBkCq4WWbsxlrZHCl hyK5ZLZOF4xJTi35uhHsRYOlQNMWx4R5zyOgwiAF14tICi4WwX7uJWnVE1CmoAvRtO0z0w nmw1u6k20c/88XaOkBZ+YvB/05Y1XE0P8+SxyLWDWlYFnIDaPap0/72gbCuK2jtgdfwOVQ Ye4TJnrt56AM/cqJwzcXh/JDT0NFbotNxFKN1MwiwFxNR2xKSutXL3bWa2IbltnjnuEzmh USq5sh3vSCNSee4qF7jeLcBu5BKloN0UUhxDGy3pm7ON9KfD4phTW7lhMtglow== 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 4S29gP6nfzzrw4; Fri, 6 Oct 2023 14:25:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EP59X093073; Fri, 6 Oct 2023 14:25:05 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EP5rt093070; Fri, 6 Oct 2023 14:25:05 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:05 GMT Message-Id: <202310061425.396EP5rt093070@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 82782cffead3 - stable/14 - LinuxKPI: 802.11: prepare for iwlwifi driver updates List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 82782cffead3c757a94a10fe02b202a4dd3b1a04 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=82782cffead3c757a94a10fe02b202a4dd3b1a04 commit 82782cffead3c757a94a10fe02b202a4dd3b1a04 Author: Bjoern A. Zeeb AuthorDate: 2023-09-05 18:02:02 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:39 +0000 LinuxKPI: 802.11: prepare for iwlwifi driver updates Update ieee80211_request_smps() to the new number of arguments in LinuxKPI (which was already prepared) and update the one call in the older iwlwifi driver version. This will allow iwlwifi as-is now and rtw88 to compile in case someone else wants to work on the latter in parallel to predominant efforts on the former. Unconditionally enable the other changes for newer drivers, as needed by iwlwifi (and others). Sponsored by: The FreeBSD Foundation (cherry picked from commit 815b7436a7c6302365b6514194d27d41cb736227) (cherry picked from commit 3e1f5cc9a81a6065ddc371eea5755b4e207d72f8) --- sys/compat/linuxkpi/common/include/net/mac80211.h | 29 +++-------------------- sys/contrib/dev/iwlwifi/mvm/utils.c | 2 +- 2 files changed, 4 insertions(+), 27 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/net/mac80211.h b/sys/compat/linuxkpi/common/include/net/mac80211.h index cacf9d652fd0..20371812198a 100644 --- a/sys/compat/linuxkpi/common/include/net/mac80211.h +++ b/sys/compat/linuxkpi/common/include/net/mac80211.h @@ -703,12 +703,6 @@ struct ieee80211_sta { struct ieee80211_link_sta deflink; struct ieee80211_link_sta *link[IEEE80211_MLD_MAX_NUM_LINKS]; /* rcu? */ -#ifndef __FOR_LATER_DRV_UPDATE - uint16_t max_rc_amsdu_len; - uint16_t max_amsdu_len; - uint16_t max_tid_amsdu_len[IEEE80211_NUM_TIDS]; -#endif - /* Must stay last. */ uint8_t drv_priv[0] __aligned(CACHE_LINE_SIZE); }; @@ -1421,7 +1415,6 @@ ieee80211_is_back_req(__le16 fc) } static __inline bool -#ifdef __FOR_LATER_DRV_UPDATE ieee80211_is_bufferable_mmpdu(struct sk_buff *skb) { struct ieee80211_mgmt *mgmt; @@ -1429,10 +1422,6 @@ ieee80211_is_bufferable_mmpdu(struct sk_buff *skb) mgmt = (struct ieee80211_mgmt *)skb->data; fc = mgmt->frame_control; -#else -ieee80211_is_bufferable_mmpdu(__le16 fc) -{ -#endif /* 11.2.2 Bufferable MMPDUs, 80211-2020. */ /* XXX we do not care about IBSS yet. */ @@ -2022,10 +2011,7 @@ ieee80211_ie_split(const u8 *ies, size_t ies_len, } static __inline void -ieee80211_request_smps(struct ieee80211_vif *vif, -#ifdef __FOR_LATER_DRV_UPDATE - u_int link_id, -#endif +ieee80211_request_smps(struct ieee80211_vif *vif, u_int link_id, enum ieee80211_smps_mode smps) { static const char *smps_mode_name[] = { @@ -2222,10 +2208,7 @@ ieee80211_tx_dequeue(struct ieee80211_hw *hw, struct ieee80211_txq *txq) static __inline void ieee80211_update_mu_groups(struct ieee80211_vif *vif, -#ifdef __FOR_LATER_DRV_UPDATE - u_int _i, -#endif - uint8_t *ms, uint8_t *up) + u_int _i, uint8_t *ms, uint8_t *up) { TODO(); } @@ -2345,14 +2328,8 @@ ieee80211_proberesp_get(struct ieee80211_hw *hw, struct ieee80211_vif *vif) static __inline struct sk_buff * ieee80211_nullfunc_get(struct ieee80211_hw *hw, struct ieee80211_vif *vif, -#ifdef __FOR_LATER_DRV_UPDATE - int linkid, -#endif - bool qos) + int linkid, bool qos) { -#ifndef __FOR_LATER_DRV_UPDATE - int linkid = 0; -#endif /* Only STA needs this. Otherwise return NULL and panic bad drivers. */ if (vif->type != NL80211_IFTYPE_STATION) diff --git a/sys/contrib/dev/iwlwifi/mvm/utils.c b/sys/contrib/dev/iwlwifi/mvm/utils.c index 075ada8ba356..5370cec8140a 100644 --- a/sys/contrib/dev/iwlwifi/mvm/utils.c +++ b/sys/contrib/dev/iwlwifi/mvm/utils.c @@ -307,7 +307,7 @@ void iwl_mvm_update_smps(struct iwl_mvm *mvm, struct ieee80211_vif *vif, smps_mode = IEEE80211_SMPS_DYNAMIC; } - ieee80211_request_smps(vif, smps_mode); + ieee80211_request_smps(vif, 0, smps_mode); } static bool iwl_wait_stats_complete(struct iwl_notif_wait_data *notif_wait, From nobody Fri Oct 6 14:25:07 2023 X-Original-To: dev-commits-src-branches@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 4S29gR4SCTz4wgTH; Fri, 6 Oct 2023 14:25: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gR1ppJz3Qbx; Fri, 6 Oct 2023 14:25:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602307; 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=t37mM1hiWaV3umPWzG40WyXsACotvp+l/mPM22AF02E=; b=KG9myCS/NyYhIXbGvxdNTjxAcwMS9paPyNuLhRp3XdHLcSU8Vr//j7joroTm+3jDypr6CQ qdczAaeJdYiZYJxDO8+aTzOzPQzttM8xW2Typ5WX2pVRZKMmif7b30dr8JWmeBqb2cXCg0 nyw4emqYuBJWZynY4THuocmSIWmua4s6/VlQQ00gjHhnwazH8xhTX15mvznlm0fDdGH4NW KIYnGzAlC86C++Oz+7vLtoRj7msRPOHiiuHOnpfwksWEDbTDHIahA7zba2shIE8Fr1bAn/ axTW2Okx7qmOk/UtECZb3c6o+/3jkFiVHkLQmLp8rv3fmg+hA04JlOeHcKp0kg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602307; a=rsa-sha256; cv=none; b=qHSfHmnoGs2cjY8pWEDnv+IedGIBHL+xyTFpdbbOBmDNUIl9Fw+g/8ckr1siigOdlgkvVL rujHuXKk09BYZbPY/F96zJp/0pajBt62AOBmSjSAhCnlWSTjm5ILLDnFwgRb2Lhf1rO4qe 4997FdrrHc+se3zNCSpKCS8LO6Lj2h/TNA7zHB+a6H77q4WgZO5k9VhjdVpx9gLsAEIRDX TodJPLkj5AtE2PJurDE7FYFuaC1MtvkM8CcekttkFPbSARGboc69AvpmFFrQf25zmSUAcI XttHU8ucGhg89fs3suDnZ1JevDLy2B8+g3mRfApdH5rJGUlwjy8T3yQv97Rrng== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602307; 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=t37mM1hiWaV3umPWzG40WyXsACotvp+l/mPM22AF02E=; b=SDLRNrzkGZtHaPH5MtP/3G3CvLSXVyrT3y9dsAXnmDwcaPolUeuuoWX5vZjTcjZfdxEdJF w5kLEfF8Xr6MqSaQ2x3kaCW41ZxKD6+Kz/FAH/OLNNghzbd/OuIdPfWtCYiOlFVRJS2Jap pvzYe3KKNGzTnyla+/VcmyV4m/D0wxRghBOEIbBTcg2HteftjCUYOYridZS3wVoz6eNDwX uLe9Lzy/nR75BTxszsfSobhI3XefOwHmHeCr0ufAokLe3EAGqhsiGvsOa5V8+6ZKOyMXIX X52NQzLm3o/GxeY6NgE8egTUn/X9TOOPcIxDQMxVGYOKAHwI2yW49l/V9MbSgg== 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 4S29gR0wYQzrkD; Fri, 6 Oct 2023 14:25:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EP7Mc093128; Fri, 6 Oct 2023 14:25:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EP7Tf093125; Fri, 6 Oct 2023 14:25:07 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:07 GMT Message-Id: <202310061425.396EP7Tf093125@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: be5f1d2e7138 - stable/14 - LinuxKPI: 802.11: pass non-0/NULL arguments to MO functions List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: be5f1d2e7138eb680db400813af54d9f33d9b252 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=be5f1d2e7138eb680db400813af54d9f33d9b252 commit be5f1d2e7138eb680db400813af54d9f33d9b252 Author: Bjoern A. Zeeb AuthorDate: 2023-09-16 13:10:57 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:39 +0000 LinuxKPI: 802.11: pass non-0/NULL arguments to MO functions In [1] we updated the KPI for various mac80211 ops functions to deal with MLD code. Newer iwlwifi driver and firmware supports these functions so we need to pass non-dummy (0, NULL) arguments to them. Start extending the internel MO functions by these arguments and pass down values from LinuxKPI 802.11 code. It is assumed that further work will be needed to have all the right fields available to at least work in the lgeacy way of a single link. Sponsored by: The FreeBSD Foundation Improves: 549198b1ab95 (update mac80211 KPI) [1] (cherry picked from commit 6854154638a2c04ab59da43aedbe2c0ee8ef71a5) --- sys/compat/linuxkpi/common/src/linux_80211.c | 11 ++++++----- sys/compat/linuxkpi/common/src/linux_80211.h | 6 +++--- sys/compat/linuxkpi/common/src/linux_80211_macops.c | 21 ++++++++++++--------- 3 files changed, 21 insertions(+), 17 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 978a82ad2ceb..37e1de0b76ad 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -991,7 +991,8 @@ lkpi_sta_scan_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, int } /* Assign vif chanctx. */ if (error == 0) - error = lkpi_80211_mo_assign_vif_chanctx(hw, vif, conf); + error = lkpi_80211_mo_assign_vif_chanctx(hw, vif, + &vif->bss_conf, conf); if (error == EOPNOTSUPP) error = 0; if (error != 0) { @@ -1172,7 +1173,7 @@ lkpi_sta_auth_to_scan(struct ieee80211vap *vap, enum ieee80211_state nstate, int conf = vif->chanctx_conf; /* Remove vif context. */ - lkpi_80211_mo_unassign_vif_chanctx(hw, vif, &vif->chanctx_conf); + lkpi_80211_mo_unassign_vif_chanctx(hw, vif, &vif->bss_conf, &vif->chanctx_conf); /* NB: vif->chanctx_conf is NULL now. */ /* Remove chan ctx. */ @@ -1447,7 +1448,7 @@ _lkpi_sta_assoc_to_down(struct ieee80211vap *vap, enum ieee80211_state nstate, i conf = vif->chanctx_conf; /* Remove vif context. */ - lkpi_80211_mo_unassign_vif_chanctx(hw, vif, &vif->chanctx_conf); + lkpi_80211_mo_unassign_vif_chanctx(hw, vif, &vif->bss_conf, &vif->chanctx_conf); /* NB: vif->chanctx_conf is NULL now. */ /* Remove chan ctx. */ @@ -1909,7 +1910,7 @@ lkpi_sta_run_to_init(struct ieee80211vap *vap, enum ieee80211_state nstate, int conf = vif->chanctx_conf; /* Remove vif context. */ - lkpi_80211_mo_unassign_vif_chanctx(hw, vif, &vif->chanctx_conf); + lkpi_80211_mo_unassign_vif_chanctx(hw, vif, &vif->bss_conf, &vif->chanctx_conf); /* NB: vif->chanctx_conf is NULL now. */ /* Remove chan ctx. */ @@ -2200,7 +2201,7 @@ lkpi_wme_update(struct lkpi_hw *lhw, struct ieee80211vap *vap, bool planned) txqp.cw_max = wmep->wmep_logcwmax; txqp.txop = wmep->wmep_txopLimit; txqp.aifs = wmep->wmep_aifsn; - error = lkpi_80211_mo_conf_tx(hw, vif, ac, &txqp); + error = lkpi_80211_mo_conf_tx(hw, vif, /* link_id */0, ac, &txqp); if (error != 0) ic_printf(ic, "%s: conf_tx ac %u failed %d\n", __func__, ac, error); diff --git a/sys/compat/linuxkpi/common/src/linux_80211.h b/sys/compat/linuxkpi/common/src/linux_80211.h index 42b4192bac63..22a5f5a6377c 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.h +++ b/sys/compat/linuxkpi/common/src/linux_80211.h @@ -276,9 +276,9 @@ int lkpi_80211_mo_sta_state(struct ieee80211_hw *, struct ieee80211_vif *, struct lkpi_sta *, enum ieee80211_sta_state); int lkpi_80211_mo_config(struct ieee80211_hw *, uint32_t); int lkpi_80211_mo_assign_vif_chanctx(struct ieee80211_hw *, struct ieee80211_vif *, - struct ieee80211_chanctx_conf *); + struct ieee80211_bss_conf *, struct ieee80211_chanctx_conf *); void lkpi_80211_mo_unassign_vif_chanctx(struct ieee80211_hw *, struct ieee80211_vif *, - struct ieee80211_chanctx_conf **); + struct ieee80211_bss_conf *, struct ieee80211_chanctx_conf **); int lkpi_80211_mo_add_chanctx(struct ieee80211_hw *, struct ieee80211_chanctx_conf *); void lkpi_80211_mo_change_chanctx(struct ieee80211_hw *, struct ieee80211_chanctx_conf *, uint32_t); @@ -287,7 +287,7 @@ void lkpi_80211_mo_remove_chanctx(struct ieee80211_hw *, void lkpi_80211_mo_bss_info_changed(struct ieee80211_hw *, struct ieee80211_vif *, struct ieee80211_bss_conf *, uint64_t); int lkpi_80211_mo_conf_tx(struct ieee80211_hw *, struct ieee80211_vif *, - uint16_t, const struct ieee80211_tx_queue_params *); + uint32_t, uint16_t, const struct ieee80211_tx_queue_params *); void lkpi_80211_mo_flush(struct ieee80211_hw *, struct ieee80211_vif *, uint32_t, bool); void lkpi_80211_mo_mgd_prepare_tx(struct ieee80211_hw *, struct ieee80211_vif *, diff --git a/sys/compat/linuxkpi/common/src/linux_80211_macops.c b/sys/compat/linuxkpi/common/src/linux_80211_macops.c index c386c096add7..8444c3b3f245 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211_macops.c +++ b/sys/compat/linuxkpi/common/src/linux_80211_macops.c @@ -444,7 +444,7 @@ out: int lkpi_80211_mo_assign_vif_chanctx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, - struct ieee80211_chanctx_conf *chanctx_conf) + struct ieee80211_bss_conf *conf, struct ieee80211_chanctx_conf *chanctx_conf) { struct lkpi_hw *lhw; int error; @@ -455,8 +455,9 @@ lkpi_80211_mo_assign_vif_chanctx(struct ieee80211_hw *hw, struct ieee80211_vif * goto out; } - LKPI_80211_TRACE_MO("hw %p vif %p chanctx_conf %p", hw, vif, chanctx_conf); - error = lhw->ops->assign_vif_chanctx(hw, vif, NULL, chanctx_conf); + LKPI_80211_TRACE_MO("hw %p vif %p bss_conf %p chanctx_conf %p", + hw, vif, conf, chanctx_conf); + error = lhw->ops->assign_vif_chanctx(hw, vif, conf, chanctx_conf); if (error == 0) vif->chanctx_conf = chanctx_conf; @@ -466,7 +467,7 @@ out: void lkpi_80211_mo_unassign_vif_chanctx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, - struct ieee80211_chanctx_conf **chanctx_conf) + struct ieee80211_bss_conf *conf, struct ieee80211_chanctx_conf **chanctx_conf) { struct lkpi_hw *lhw; @@ -477,8 +478,9 @@ lkpi_80211_mo_unassign_vif_chanctx(struct ieee80211_hw *hw, struct ieee80211_vif if (*chanctx_conf == NULL) return; - LKPI_80211_TRACE_MO("hw %p vif %p chanctx_conf %p", hw, vif, *chanctx_conf); - lhw->ops->unassign_vif_chanctx(hw, vif, NULL, *chanctx_conf); + LKPI_80211_TRACE_MO("hw %p vif %p bss_conf %p chanctx_conf %p", + hw, vif, conf, *chanctx_conf); + lhw->ops->unassign_vif_chanctx(hw, vif, conf, *chanctx_conf); *chanctx_conf = NULL; } @@ -548,7 +550,7 @@ lkpi_80211_mo_bss_info_changed(struct ieee80211_hw *hw, struct ieee80211_vif *vi int lkpi_80211_mo_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, - uint16_t ac, const struct ieee80211_tx_queue_params *txqp) + uint32_t link_id, uint16_t ac, const struct ieee80211_tx_queue_params *txqp) { struct lkpi_hw *lhw; int error; @@ -559,8 +561,9 @@ lkpi_80211_mo_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, goto out; } - LKPI_80211_TRACE_MO("hw %p vif %p ac %u txpq %p", hw, vif, ac, txqp); - error = lhw->ops->conf_tx(hw, vif, 0, ac, txqp); + LKPI_80211_TRACE_MO("hw %p vif %p link_id %u ac %u txpq %p", + hw, vif, link_id, ac, txqp); + error = lhw->ops->conf_tx(hw, vif, link_id, ac, txqp); out: return (error); From nobody Fri Oct 6 14:25:08 2023 X-Original-To: dev-commits-src-branches@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 4S29gS3V6Qz4wgXp; Fri, 6 Oct 2023 14:25:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gS2ssnz3QhW; Fri, 6 Oct 2023 14:25:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602308; 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=U8jvU6Wr6op+uhR2376a/y32WEE5wjtIG0CBm8zwwSA=; b=NefxwSaD9BbqYgjbt9AqMUIl+8WZ5qJMziKmxdENWe3of8H/CUaP+D3hI30dSg/Es+G06H 4wwi9WN40joCoARB0/GFj9j+yGprLuMrkIpz9leyGd+FSw6c2ssqTqjxzUp7AxF6UT+ZS7 mKakMZax7XSaUWk/8gQ/ZHpSLLs/1O9et4otiIBdj3t+78lUtKRuJOknwRXooA7Rks3/cV GKm7OMQYLpmzxOsZhbksnVZRGhWmOvEzAPXaadWRkRSvb0FqDLatd2OIjTuBZr+ChGv6nG Xj4aLAmatgC9nKaP1o+GWFTY6LCfI7n+8h+6hUKgpKvQr97MC6uBvKb4AHmSRA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602308; a=rsa-sha256; cv=none; b=T4ulEiZVeLanqq1glQoVYIpH+MYnZzOfoasxPSXH3vHeMmWzE718cNPPTiW/6YIueunb8+ j062Es0YYbhji6GlxRGM290h9ED7LBKBFKgr7IcN/HiglZ04zl/LpkacGdIb49xhmAbT8V hiOE38I4hxYvEzUNJU5OzOTN/b6L4J0SHqXddd9RA8ASs3lID/MKC4fUvIx8CxvMr9i2Uc XdIkykyxp1n9SXbqKiM6ptxevd6q5Z7lwWAYo4BDZFpLU1eFBD5h8Dc8YFk3B5/yWJuPnq zoF2hrWLygkxnSAldHn926C9QRdOfoZfOCAGa22Z8e6Q5XPx5fj+xgygxnLBsg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602308; 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=U8jvU6Wr6op+uhR2376a/y32WEE5wjtIG0CBm8zwwSA=; b=tew2AXD3yHwbpi1szM0RRlK5fgDMh8M/AlihT0hfDJJtr07s04DmpzeAaEZS05LSJt9F91 DjB9Kx9dbMMUrq9vp4jxcbK5noEophZ22867HYLa48y7xPkH2DQTlGzzj7mUEv6s8pwmJM YHM3Ea7AG+ycPPn/RxBMYw08pBdTpuR2NwSRzX4F40Os6w+dErjNUBr1ULWhhO8RPxjJXR sAYbMMwzPkcSP1O23iH3RpHey8WY2lyB+2VGJYmXenEcy6w+VR2yd5+psnwiAoJKXgo8Yo COFqG2/lwIc7yWARCNyLj7odIvZwjNwvncw/osBfcIlWMmt9it8sudCL5Sn+xw== 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 4S29gS1wfJzrNn; Fri, 6 Oct 2023 14:25:08 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EP8oQ093182; Fri, 6 Oct 2023 14:25:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EP8pf093179; Fri, 6 Oct 2023 14:25:08 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:08 GMT Message-Id: <202310061425.396EP8pf093179@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: ad79da1b1ad3 - stable/14 - LinuxKPI: 802.11: mac80211 ops: distinguish between {bss,link}_info_changed List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: ad79da1b1ad323a00329c1c80fe9b90eb1e434b2 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=ad79da1b1ad323a00329c1c80fe9b90eb1e434b2 commit ad79da1b1ad323a00329c1c80fe9b90eb1e434b2 Author: Bjoern A. Zeeb AuthorDate: 2023-09-21 11:58:17 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:39 +0000 LinuxKPI: 802.11: mac80211 ops: distinguish between {bss,link}_info_changed With MLO and multi-link setups if avail we want to call link_info_changed whereas for legacy drivers we still need to call bss_info_changed. While we currently do not (yet) support multi-link configurations we still need to drive the correct commands to satisfy firmware requirements. Sponsored by: The FreeBSD Foundation (cherry picked from commit 727f88f2617acaff4ada0f3dda6ca23c6679310d) --- sys/compat/linuxkpi/common/src/linux_80211_macops.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211_macops.c b/sys/compat/linuxkpi/common/src/linux_80211_macops.c index 8444c3b3f245..b3b53d23f62e 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211_macops.c +++ b/sys/compat/linuxkpi/common/src/linux_80211_macops.c @@ -540,14 +540,17 @@ lkpi_80211_mo_bss_info_changed(struct ieee80211_hw *hw, struct ieee80211_vif *vi struct lkpi_hw *lhw; lhw = HW_TO_LHW(hw); - if (lhw->ops->bss_info_changed == NULL) + if (lhw->ops->link_info_changed == NULL && + lhw->ops->bss_info_changed == NULL) return; LKPI_80211_TRACE_MO("hw %p vif %p conf %p changed %#jx", hw, vif, conf, (uintmax_t)changed); - lhw->ops->bss_info_changed(hw, vif, conf, changed); + if (lhw->ops->link_info_changed != NULL) + lhw->ops->link_info_changed(hw, vif, conf, changed); + else + lhw->ops->bss_info_changed(hw, vif, conf, changed); } - int lkpi_80211_mo_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, uint32_t link_id, uint16_t ac, const struct ieee80211_tx_queue_params *txqp) From nobody Fri Oct 6 14:25:09 2023 X-Original-To: dev-commits-src-branches@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 4S29gT4J5xz4wgXs; Fri, 6 Oct 2023 14:25: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gT3hpSz3Qvx; Fri, 6 Oct 2023 14:25:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602309; 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=vPBj+eo4dRsiDzdiivaXOmjAlIUTO5+C9GiBdLyqmYw=; b=pFXK3rYKq0+sjqJsLRiteNO6hillcKXe1YW99OP8byWHI0fJlFIz7ghdZL30y1ZOlaUoBa x9wO1KYk4l83/4VH6OazlJq28fxwK+blIjZ47gxEnu/80kjo2INlyE1EcFp/0uGzycWeGW 8WKLOI3q+ZZxzm4TTeQWiz3xk1ufDZJcjlSZ0c4ZGw/SgC5FnDAfCsn9TRA+f4FrXDzhu7 /aeH5im3qA5AzaR5W5tZ5YMynggf6HGztVIUA39V0Dced8w/65n6O43q6ruV4cIWJISlJX /peTJ3EHX6cqdR46Sg1Xb7QqFM3c9E+g9HN63WFzzXGGlltnLK1iP0N9IyzPyg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602309; a=rsa-sha256; cv=none; b=F69FekPlt0RUyTjCLMw786DPq2IqKHaz11WxHSReGQIkzxrDlrzHcE626B+kiq+UOEO1tt c5gJW6gMbzrDaszLVMYyU/cGqaZHOP/I8ZGIBbHy2W8DdIrnAItKknj30e06RsLq9pKtRi bK51T95wp2KFvm64jLCMhUs+0A0EmatRhK3PNoYGTemi4XPZoJ9LVUEGcHvGXzLF6oBE9D AlChNQgMGgdB4aOr99kVUSNQZaubZERpwvaF2/7AAhSKGF7WlJVi06hYUghY8+c/KsZ32o sJx/RqcmTcPXYRzR3BLuJQ7gnKA3Y1YNCVNdHat2tdEiysn4sb/wD0/VKB0qcw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602309; 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=vPBj+eo4dRsiDzdiivaXOmjAlIUTO5+C9GiBdLyqmYw=; b=OVaOgug/KZLoDaxeSaJPO48Zxni+9qUypa/NQHau6C9e6Ec3YSvwl5EmuZ+tq1xlceHyzz ka7zuXAazomPNHL1iRMhH3LMJXxsmToxuZO0018R4Dxdl5dTH/FpPDWcth0CQjMQAD+LUc ZaEhLUtEVZAV+CkyfeozONZQH4SZ92daniCxyA2wca9sCAxgN4+Qdi5Q4khW7Ym5/qAMiW tMs8GcVcbxI2ueR/9ZSdKASsfUoXNlAfZ62TCbtOglhEhmJWlV7/dZIWF01QPgRFulViVE 1nKjAmtDgPLqLjcYCxnOEutwgkXRAE5JgWvGawMD0stCGB8dp0AxLUro159ImQ== 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 4S29gT2ldczrw5; Fri, 6 Oct 2023 14:25:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EP9aU093236; Fri, 6 Oct 2023 14:25:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EP9xP093233; Fri, 6 Oct 2023 14:25:09 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:09 GMT Message-Id: <202310061425.396EP9xP093233@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 8614ae463a1e - stable/14 - LinuxKPI: 802.11: adjust code to new structure layout List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 8614ae463a1e913ff97039655a08316556839b4c Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=8614ae463a1e913ff97039655a08316556839b4c commit 8614ae463a1e913ff97039655a08316556839b4c Author: Bjoern A. Zeeb AuthorDate: 2023-09-21 12:19:54 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:39 +0000 LinuxKPI: 802.11: adjust code to new structure layout With past commits new structures were added. Now switch over some bss_conf fields into vif->cfg where they got moved to and remove the old fields. This allows drivers to find the expected values in the now expected places and work better. Sponsored by: The FreeBSD Foundation (cherry picked from commit 616e13301bcf274b007f84ef99ea857a55bef46d) --- sys/compat/linuxkpi/common/include/net/mac80211.h | 9 ++--- sys/compat/linuxkpi/common/src/linux_80211.c | 44 +++++++++++------------ 2 files changed, 24 insertions(+), 29 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/net/mac80211.h b/sys/compat/linuxkpi/common/include/net/mac80211.h index 20371812198a..7e6fb1bce16e 100644 --- a/sys/compat/linuxkpi/common/include/net/mac80211.h +++ b/sys/compat/linuxkpi/common/include/net/mac80211.h @@ -280,19 +280,13 @@ struct ieee80211_bss_conf { bool eht_su_beamformer; bool eht_mu_beamformer; - size_t ssid_len; - uint8_t ssid[IEEE80211_NWID_LEN]; - uint16_t aid; uint16_t ht_operation_mode; int arp_addr_cnt; uint16_t eht_puncturing; uint8_t dtim_period; uint8_t sync_dtim_count; - bool assoc; - bool idle; bool qos; - bool ps; bool twt_broadcast; bool use_cts_prot; bool use_short_preamble; @@ -991,6 +985,8 @@ struct ieee80211_ops { void (*config_iface_filter)(struct ieee80211_hw *, struct ieee80211_vif *, unsigned int, unsigned int); void (*bss_info_changed)(struct ieee80211_hw *, struct ieee80211_vif *, struct ieee80211_bss_conf *, u64); + void (*link_info_changed)(struct ieee80211_hw *, struct ieee80211_vif *, struct ieee80211_bss_conf *, u64); + int (*set_rts_threshold)(struct ieee80211_hw *, u32); void (*event_callback)(struct ieee80211_hw *, struct ieee80211_vif *, const struct ieee80211_event *); int (*get_survey)(struct ieee80211_hw *, int, struct survey_info *); @@ -1038,7 +1034,6 @@ struct ieee80211_ops { int (*set_hw_timestamp)(struct ieee80211_hw *, struct ieee80211_vif *, struct cfg80211_set_hw_timestamp *); - void (*link_info_changed)(struct ieee80211_hw *, struct ieee80211_vif *, struct ieee80211_bss_conf *, u64); void (*vif_cfg_changed)(struct ieee80211_hw *, struct ieee80211_vif *, u64); int (*change_vif_links)(struct ieee80211_hw *, struct ieee80211_vif *, u16, u16, struct ieee80211_bss_conf *[IEEE80211_MLD_MAX_NUM_LINKS]); diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 37e1de0b76ad..ac43b1248536 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -744,7 +744,7 @@ lkpi_update_dtim_tsf(struct ieee80211_vif *vif, struct ieee80211_node *ni, "dtim_period %u sync_dtim_count %u sync_tsf %ju " "sync_device_ts %u bss_changed %#08x\n", __func__, __LINE__, _f, _l, - vif->bss_conf.assoc, vif->bss_conf.aid, + vif->cfg.assoc, vif->cfg.aid, vif->bss_conf.beacon_int, vif->bss_conf.dtim_period, vif->bss_conf.sync_dtim_count, (uintmax_t)vif->bss_conf.sync_tsf, @@ -775,7 +775,7 @@ lkpi_update_dtim_tsf(struct ieee80211_vif *vif, struct ieee80211_node *ni, "dtim_period %u sync_dtim_count %u sync_tsf %ju " "sync_device_ts %u bss_changed %#08x\n", __func__, __LINE__, _f, _l, - vif->bss_conf.assoc, vif->bss_conf.aid, + vif->cfg.assoc, vif->cfg.aid, vif->bss_conf.beacon_int, vif->bss_conf.dtim_period, vif->bss_conf.sync_dtim_count, (uintmax_t)vif->bss_conf.sync_tsf, @@ -846,7 +846,7 @@ lkpi_disassoc(struct ieee80211_sta *sta, struct ieee80211_vif *vif, struct lkpi_hw *lhw) { sta->aid = 0; - if (vif->bss_conf.assoc) { + if (vif->cfg.assoc) { struct ieee80211_hw *hw; enum ieee80211_bss_changed changed; @@ -854,8 +854,8 @@ lkpi_disassoc(struct ieee80211_sta *sta, struct ieee80211_vif *vif, lkpi_update_mcast_filter(lhw->ic, true); changed = 0; - vif->bss_conf.assoc = false; - vif->bss_conf.aid = 0; + vif->cfg.assoc = false; + vif->cfg.aid = 0; changed |= BSS_CHANGED_ASSOC; /* * This will remove the sta from firmware for iwlwifi. @@ -1009,12 +1009,12 @@ lkpi_sta_scan_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, int bss_changed |= BSS_CHANGED_BSSID; vif->bss_conf.txpower = ni->ni_txpower; bss_changed |= BSS_CHANGED_TXPOWER; - vif->bss_conf.idle = false; + vif->cfg.idle = false; bss_changed |= BSS_CHANGED_IDLE; /* Should almost assert it is this. */ - vif->bss_conf.assoc = false; - vif->bss_conf.aid = 0; + vif->cfg.assoc = false; + vif->cfg.aid = 0; bss_changed |= lkpi_update_dtim_tsf(vif, ni, vap, __func__, __LINE__); @@ -1433,8 +1433,8 @@ _lkpi_sta_assoc_to_down(struct ieee80211vap *vap, enum ieee80211_state nstate, i bss_changed = 0; vif->bss_conf.qos = 0; bss_changed |= BSS_CHANGED_QOS; - vif->bss_conf.ssid_len = 0; - memset(vif->bss_conf.ssid, '\0', sizeof(vif->bss_conf.ssid)); + vif->cfg.ssid_len = 0; + memset(vif->cfg.ssid, '\0', sizeof(vif->cfg.ssid)); bss_changed |= BSS_CHANGED_BSSID; lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, bss_changed); @@ -1549,14 +1549,14 @@ lkpi_sta_assoc_to_run(struct ieee80211vap *vap, enum ieee80211_state nstate, int #ifdef LKPI_80211_WME bss_changed |= lkpi_wme_update(lhw, vap, true); #endif - if (!vif->bss_conf.assoc || vif->bss_conf.aid != IEEE80211_NODE_AID(ni)) { - vif->bss_conf.assoc = true; - vif->bss_conf.aid = IEEE80211_NODE_AID(ni); + if (!vif->cfg.assoc || vif->cfg.aid != IEEE80211_NODE_AID(ni)) { + vif->cfg.assoc = true; + vif->cfg.aid = IEEE80211_NODE_AID(ni); bss_changed |= BSS_CHANGED_ASSOC; } /* We set SSID but this is not BSSID! */ - vif->bss_conf.ssid_len = ni->ni_esslen; - memcpy(vif->bss_conf.ssid, ni->ni_essid, ni->ni_esslen); + vif->cfg.ssid_len = ni->ni_esslen; + memcpy(vif->cfg.ssid, ni->ni_essid, ni->ni_esslen); if ((vap->iv_flags & IEEE80211_F_SHPREAMBLE) != vif->bss_conf.use_short_preamble) { vif->bss_conf.use_short_preamble ^= 1; @@ -1895,8 +1895,8 @@ lkpi_sta_run_to_init(struct ieee80211vap *vap, enum ieee80211_state nstate, int bss_changed = 0; vif->bss_conf.qos = 0; bss_changed |= BSS_CHANGED_QOS; - vif->bss_conf.ssid_len = 0; - memset(vif->bss_conf.ssid, '\0', sizeof(vif->bss_conf.ssid)); + vif->cfg.ssid_len = 0; + memset(vif->cfg.ssid, '\0', sizeof(vif->cfg.ssid)); bss_changed |= BSS_CHANGED_BSSID; lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, bss_changed); @@ -2276,16 +2276,16 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ], #if 1 vif->chanctx_conf = NULL; vif->bss_conf.vif = vif; - vif->bss_conf.idle = true; - vif->bss_conf.ps = false; vif->bss_conf.chandef.width = NL80211_CHAN_WIDTH_20_NOHT; vif->bss_conf.use_short_preamble = false; /* vap->iv_flags IEEE80211_F_SHPREAMBLE */ vif->bss_conf.use_short_slot = false; /* vap->iv_flags IEEE80211_F_SHSLOT */ vif->bss_conf.qos = false; vif->bss_conf.use_cts_prot = false; /* vap->iv_protmode */ vif->bss_conf.ht_operation_mode = IEEE80211_HT_OP_MODE_PROTECTION_NONE; - vif->bss_conf.assoc = false; - vif->bss_conf.aid = 0; + vif->cfg.aid = 0; + vif->cfg.assoc = false; + vif->cfg.idle = true; + vif->cfg.ps = false; /* * We need to initialize it to something as the bss_info_changed call * will try to copy from it in iwlwifi and NULL is a panic. @@ -4712,7 +4712,7 @@ linuxkpi_ieee80211_pspoll_get(struct ieee80211_hw *hw, psp = skb_put_zero(skb, sizeof(*psp)); psp->i_fc[0] = IEEE80211_FC0_VERSION_0; psp->i_fc[0] |= IEEE80211_FC0_SUBTYPE_PS_POLL | IEEE80211_FC0_TYPE_CTL; - v = htole16(vif->bss_conf.aid | 1<<15 | 1<<16); + v = htole16(vif->cfg.aid | 1<<15 | 1<<16); memcpy(&psp->i_aid, &v, sizeof(v)); IEEE80211_ADDR_COPY(psp->i_bssid, vap->iv_bss->ni_macaddr); IEEE80211_ADDR_COPY(psp->i_ta, vif->addr); From nobody Fri Oct 6 14:25:10 2023 X-Original-To: dev-commits-src-branches@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 4S29gV5XYnz4wgkM; Fri, 6 Oct 2023 14:25: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gV4srWz3R6l; Fri, 6 Oct 2023 14:25:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602310; 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=QJWoYEfDLO+JH2Z13vnqZI3dJhyqKkXTlrL2LEEDMKs=; b=TS4skLsGfuAkY+/KnIDGUlMqnF5PVtw/WPhCII9xEt1tvvYHhP4/5N1LUvmS2Hq3REv4fW uZZb5539yCxbeMEcDOJKH/a4oKoY+xYh/nOjhGHwNPC9cIg1cUfNEYY3EfF6VGprY6mJOa iqi98hoqOmCp/UiUysZlQEtH2o6IYqGCMh7tfNy7k+I2/1h+4pkE3RXZVEpolDEKZ34xIe vX3LUFpVcyOS+/dUT1+mmB56NXr9DshOKbDFcpOfWaA+bLDTlpnmy0/ZkX5qxo9v6le/bs DjSO2qqGs1ZbkBCz4GsunAXZUidFKAYxN+G4Wdz5tc8zWqeA1GDc8x+duW5vhQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602310; a=rsa-sha256; cv=none; b=VjBXjkS670oXJNnMnPCOOIqI3J1ZlKUsaTmGqyON9pTLgn6At1mRJPCSFGyGFknkKQGSF8 wKNSvNpPuuSoYi0GeRt356/seVgR68x5relYzKL1Re0hENoXk14R4FJ7cWKCCZsCj7UBQh yAb+JsG4QoR/EZw6SCmj6rva4quxjSdRLcPtcPI+fUhBBsyQXYAfCBpNMr2U4ESQOuV1wM 5O8hIl4tE1SQh5v99k8W5IYYnXfmguIKUnxNiFflG8veAxI61cX8BzCSRDDjQzHGxpLbTZ lwq9vx3KMBnuU29BCztqAIEUxnSkKyk+5P/qXHxIUu+Ruk6oyN07iOsXggUZdQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602310; 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=QJWoYEfDLO+JH2Z13vnqZI3dJhyqKkXTlrL2LEEDMKs=; b=w/EjOceNpM/kcwZ3uEZDUj+aizCVR5ZmJpJY06AXi6pARNT3Dtc4fcPtSyC/oJWZ4gfknm XVxfgIX+81/irwtZFuH2ZuBkArB0GJJCgmC2/tl0Gau20ykBQ+Ywu21dkIp3cT0YS42jgH WOXXg/kraOgKjl863BYutSECH2PexwNv/Tan35Zyku7APOwLSwW3Mzbc5RN5jHdIrenVpC ti8/xWNp7GDGNX/dsT9lyz4WdTLbReUlg44HZULhmVs44my0SKyEGf47W3hPRabluYwDBZ 2gQdK0DjGM2jRSLUzmKGQ0WdFOA2Z+jX+OqJB3AstlFRusJNtz5kddVM7Ai3cg== 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 4S29gV3ysVzrkF; Fri, 6 Oct 2023 14:25:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EPAEO093290; Fri, 6 Oct 2023 14:25:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EPAFg093287; Fri, 6 Oct 2023 14:25:10 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:10 GMT Message-Id: <202310061425.396EPAFg093287@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 753730087671 - stable/14 - LinuxKPI: 802.11: change ic_parent() to not call mo_stop()/mo_start() List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 753730087671551425554a28d64c898997f9bbdd Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=753730087671551425554a28d64c898997f9bbdd commit 753730087671551425554a28d64c898997f9bbdd Author: Bjoern A. Zeeb AuthorDate: 2023-09-21 12:25:20 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:40 +0000 LinuxKPI: 802.11: change ic_parent() to not call mo_stop()/mo_start() Driven by net80211 we may call mac80211 ops stop() and start() mostly when toggling a first VAP. While this is FreeBSD behaviour the firmware based LinuxKPI drivers seem to possibly clear state in the case of stop() triggering further errors down the line. We call mo_start() when starting the VAP and mo_stop() when destroying it now only. In the future (e.g., in multi-VAP setups) we may need to re-address some of this so keep the code under #ifdef. Sponsored by: The FreeBSD Foundation (cherry picked from commit 8d58a0578635dc7dd1025ab08b0479f2b383e1a4) --- sys/compat/linuxkpi/common/src/linux_80211.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index ac43b1248536..04ee75eb2c68 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -2468,24 +2468,32 @@ static void lkpi_ic_parent(struct ieee80211com *ic) { struct lkpi_hw *lhw; +#ifdef HW_START_STOP struct ieee80211_hw *hw; int error; +#endif bool start_all; IMPROVE(); lhw = ic->ic_softc; +#ifdef HW_START_STOP hw = LHW_TO_HW(lhw); +#endif start_all = false; /* IEEE80211_UNLOCK(ic); */ LKPI_80211_LHW_LOCK(lhw); if (ic->ic_nrunning > 0) { +#ifdef HW_START_STOP error = lkpi_80211_mo_start(hw); if (error == 0) +#endif start_all = true; } else { +#ifdef HW_START_STOP lkpi_80211_mo_stop(hw); +#endif } LKPI_80211_LHW_UNLOCK(lhw); /* IEEE80211_LOCK(ic); */ From nobody Fri Oct 6 14:25:11 2023 X-Original-To: dev-commits-src-branches@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 4S29gX0ZZRz4wgkP; Fri, 6 Oct 2023 14:25:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gW5fzKz3R59; Fri, 6 Oct 2023 14:25:11 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602311; 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=0GGoBhBfzcqCeu+IcK/3M5yZ4sWREeTwFcsqodL6Ux4=; b=QNU0ODyEIMpUJiBwoDvSQ8EIHAjoNiEg+3K+qiNyGEY5QTG93BW1VHjPjfBsqayHhttr6w uqpn8eP9G1EtsKpcbY43h+ZT+OBPpxkItHkKQan+Xanc5O9GCV+vJbQZGcvAnIUl7cPIAd FvXwmclV1haT+Okx8ljmg65egjC8yd64Goo6xi70vAd46TIqwgVKePIGAV2gDyFRvLmVP6 13Jo5gOGc6yhyKP+iv2nYnXY0IFpF9ckQxYmMVTkdqQmqoaKkKMnn7Nnt2HSCqtADX5QrT KnWiXnNsJ3zEsALHmbLJoA/vuiNUaKs/2uQ0pd4h+ke9nFwlYZY8nMmT/EgaBg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602311; a=rsa-sha256; cv=none; b=j1BjdSqKJbzWZV19FDYTvEpDDwmd6n5vo3TEYaj3NvI9td2yHrjTjKa2jQ7nEmNnPQmEF0 c8pXNaP+h10uPLEqwxGUatkH5CysBQgRtSl2RM6Gl9sTNMm+W9QHHQpNtET2GAeSrFhjP7 zy0jsIFAVkYQ2H2xfI4Au0tzjYdRjy2rSiun6rIRteEn7UeVaLVhlk5ys5HAGo2iJssXO9 BMeFrcM/R+5rqljmkEOMrH2GMqSj0Pwrd24LBL4klZCb7kOfL4lNUPQwYrIuO/wdqBkaDt cHryyNbQMXdTkbN20SI7nVm9h9mfIZj2n88IfmcjZyJGrr3Sl4Bfgn4QqlV8Yw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602311; 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=0GGoBhBfzcqCeu+IcK/3M5yZ4sWREeTwFcsqodL6Ux4=; b=qndGNay7+LVeHVqPWVDTvPmgK45eQ/xaluyt7BAB2JZEwIAJlJSGvGItiPvtvdstpGbNp/ sOImQr+pf18pCW+FxmouLBkJQBR1hUfqVg+Jy0rhwqrovlohHn56y6Bd+L+XdOl6UK+ob1 XKlky689epj5R/dOI9ySON8W8FRkBOduYzGWymeX12UNAlj+8oE3TABr37K1zrwqUWXnmv lOCSGxs5QlPgsVkKK9WxUKKPPKUCPl2oOHZb9vZS9yUS49BGh4VmM27jLvkKrjlMCR7qUZ +MUEhAKvQ6W29d3lcDoEbLc+SG/FA1SabuDbR7z9dClULoBznke6ozA0bjC12g== 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 4S29gW4dClzrtW; Fri, 6 Oct 2023 14:25:11 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EPBH1093344; Fri, 6 Oct 2023 14:25:11 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EPB5p093341; Fri, 6 Oct 2023 14:25:11 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:11 GMT Message-Id: <202310061425.396EPB5p093341@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 68e1e25baf2e - stable/14 - LinuxKPI: 802.11: inialize tx queue params List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 68e1e25baf2e5576011ed532d5a30e70997d488c Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=68e1e25baf2e5576011ed532d5a30e70997d488c commit 68e1e25baf2e5576011ed532d5a30e70997d488c Author: Bjoern A. Zeeb AuthorDate: 2023-09-21 12:36:38 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:40 +0000 LinuxKPI: 802.11: inialize tx queue params When adding a VAP (vif) initialize its tx queue parameters calling mo_conf_tx(). I could not spot net80211 providing some of the values needed before having a node so currrently we use hard-coded values with a comment with a reference on how to properly calculate the values in the future (e.g., in case of 11b or other cases). Sponsored by: The FreeBSD Foundation (cherry picked from commit a6042e17c8999c4965bd4d762c4564b322f1ae7b) --- sys/compat/linuxkpi/common/src/linux_80211.c | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 04ee75eb2c68..1e7ae261779c 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -2245,9 +2245,11 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ], struct lkpi_vif *lvif; struct ieee80211vap *vap; struct ieee80211_vif *vif; + struct ieee80211_tx_queue_params txqp; enum ieee80211_bss_changed changed; size_t len; int error, i; + uint16_t ac; if (!TAILQ_EMPTY(&ic->ic_vaps)) /* 1 so far. Add once this works. */ return (NULL); @@ -2346,7 +2348,24 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ], changed = 0; lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, changed); - /* conf_tx setup; default WME? */ + /* Configure tx queues (conf_tx), default WME & send BSS_CHANGED_QOS. */ + IMPROVE("Hardcoded values; to fix see 802.11-2016, 9.4.2.29 EDCA Parameter Set element"); + LKPI_80211_LHW_LOCK(lhw); + for (ac = 0; ac < IEEE80211_NUM_ACS; ac++) { + + bzero(&txqp, sizeof(txqp)); + txqp.cw_min = 15; + txqp.cw_max = 1023; + txqp.txop = 0; + txqp.aifs = 2; + error = lkpi_80211_mo_conf_tx(hw, vif, /* link_id */0, ac, &txqp); + if (error != 0) + ic_printf(ic, "%s: conf_tx ac %u failed %d\n", + __func__, ac, error); + } + LKPI_80211_LHW_UNLOCK(lhw); + changed = BSS_CHANGED_QOS; + lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, changed); /* Force MC init. */ lkpi_update_mcast_filter(ic, true); From nobody Fri Oct 6 14:25:12 2023 X-Original-To: dev-commits-src-branches@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 4S29gY2m4Sz4wgbX; Fri, 6 Oct 2023 14:25:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gX6MSwz3R5L; Fri, 6 Oct 2023 14:25:12 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602312; 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=x09Sg9dKobnqmC77H4RU4TQw5f657jdgy8kin2YjG24=; b=R5LOazrZB0VwEj264KEIzL6ule/mxrinTAUUHc5v+D2sl0t4IrfIbSXopeagnqKyWA8Yxv iWA1x2ZFk1011nmDTPjvkO0Gy5jpLy66Eb+vzV/1pCLQGwyrm9SUFCPofzbgur4s8yR7j0 3460w1a3Ns1LibeyYYjY2ArDq9LxyjBVrgkb93XgnDAuArMV8t4U55suG99LQ0K3xnuQ6M bWiOeb63HYfl22veIGMqHiXRtVddHYOovqVm/9qn4gdoE3H9l6bvKPtdGQnnsH8Q2yxzst CoLGMhQbVLvAVIN8FJw2BorXHnZ34eNF8GP8EqStaOOPgsa03AzMwhvRxLmUuA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602312; a=rsa-sha256; cv=none; b=DVvDuhAOQxXOIsls4TMUagEM2Y1wi/l/6azyzmR8VRC3v0A+54P5uowCzD/60qr2tGEG/D bOKVuP7m0edXALs8ZDjGoZi3nzH+Gv7nZ1aTKcLjeNK9x/A7GKfEo9NaMeXJQ0qth/o2AF v33O6u1n0Td9OyajgIRPcdhUoTWinGf5bJ8TFowTmv7bJumuXGGKL1A4CHscbezpX8aVaa srI2aTV5VErd0qb5u1y1faoKE67zZFYB6hHLhl2SPk5TXJNkLsW7Ogky72bwu47qGh/MVc Lh4Qfb8HOWCsM6ShrJE9r174BhB3PkFBNBHEZ5QTQFbvxm+/wwALtfs7McY9yQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602312; 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=x09Sg9dKobnqmC77H4RU4TQw5f657jdgy8kin2YjG24=; b=fUARtzsA72yqLIbTpwUu8q9+Nz/VhY9pq1HpXnGJ753hc3A79DurZ0dbGyIlhlvmu0HOsc UwQFMBIbIQNCxosp263o+drAQCkMg8Xeft0M5FmbwP6I8+BlmAncNRqcUBAX7Gslat8wQ4 Q0O5lypY/yeMWOPK4ZARuFaIeT+W/Uhk91tq32HhdkTdVSBqgx7i36dluifnKfQ0s4AEy9 mi2cAZIAilqOPOJWqSyBVxKK1USv6yS0HxHRE4G+hw6Dcl8VOuGUlQ1N7Pe065hdFJsEIy ngPC0cFElYZUZgxLuXo0rKc1tTmk07WKUZFhvX2bQvAFKdt7UntkeozLPOvWNQ== 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 4S29gX5TgDzr9S; Fri, 6 Oct 2023 14:25:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EPCwx093404; Fri, 6 Oct 2023 14:25:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EPCu6093401; Fri, 6 Oct 2023 14:25:12 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:12 GMT Message-Id: <202310061425.396EPCu6093401@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: c18ead9cb26d - stable/14 - LinuxKPI: 802.11: setup a default link[0] and adjust related needs List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: c18ead9cb26d4199dbea8cc032420ae2164928ad Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=c18ead9cb26d4199dbea8cc032420ae2164928ad commit c18ead9cb26d4199dbea8cc032420ae2164928ad Author: Bjoern A. Zeeb AuthorDate: 2023-09-21 12:49:15 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:40 +0000 LinuxKPI: 802.11: setup a default link[0] and adjust related needs Setup more link_conf/deflink fields for vif/sta as are needed to allow us to work with the KPI bits in a non-MLO configuration. In lkpi_sta_scan_to_auth() set the bss_conf values before calling into the driver for chanctx setup/updates as certain values (e.g., beacon_int) need to be set before; we still call the MO function for the updates after to keep the expected workflow. Deal with the (to be dealt with otherwise later) net80211 ni swaps and update the addresses on the deflink as well as otherwise firmware will hit asserts or things will not work (e.g. indicating the peer is us). Sponsored by: The FreeBSD Foundation (cherry picked from commit 6ffb7bd469b26f2ff6cc62cedca6ffe884076196) --- sys/compat/linuxkpi/common/src/linux_80211.c | 63 ++++++++++++++++++---------- 1 file changed, 41 insertions(+), 22 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 1e7ae261779c..1fee5f6809fd 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -107,9 +107,6 @@ SYSCTL_INT(_compat_linuxkpi_80211, OID_AUTO, debug, CTLFLAG_RWTUN, #define PREP_TX_INFO_DURATION 0 /* Let the driver do its thing. */ #endif -/* c.f. ieee80211_ioctl.c */ -static const uint8_t zerobssid[IEEE80211_ADDR_LEN]; - /* This is DSAP | SSAP | CTRL | ProtoID/OrgCode{3}. */ const uint8_t rfc1042_header[6] = { 0xaa, 0xaa, 0x03, 0x00, 0x00, 0x00 }; @@ -270,9 +267,17 @@ lkpi_lsta_alloc(struct ieee80211vap *vap, const uint8_t mac[IEEE80211_ADDR_LEN], sta->deflink.supp_rates[band] |= BIT(i); } } + sta->deflink.smps_mode = IEEE80211_SMPS_OFF; IMPROVE("ht, vht, he, ... bandwidth, smps_mode, .."); /* bandwidth = IEEE80211_STA_RX_... */ + /* Link configuration. */ + IEEE80211_ADDR_COPY(sta->deflink.addr, sta->addr); + sta->link[0] = &sta->deflink; + for (i = 1; i < nitems(sta->link); i++) { + IMPROVE("more links; only link[0] = deflink currently."); + } + /* Deferred TX path. */ mtx_init(&lsta->txq_mtx, "lsta_txq", NULL, MTX_DEF); TASK_INIT(&lsta->txq_task, 0, lkpi_80211_txq_task, lsta); @@ -970,6 +975,23 @@ lkpi_sta_scan_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, int conf->min_def.center_freq2 = 0; IMPROVE("currently 20_NOHT only"); + /* Set bss info (bss_info_changed). */ + bss_changed = 0; + vif->bss_conf.bssid = ni->ni_bssid; + bss_changed |= BSS_CHANGED_BSSID; + vif->bss_conf.txpower = ni->ni_txpower; + bss_changed |= BSS_CHANGED_TXPOWER; + vif->cfg.idle = false; + bss_changed |= BSS_CHANGED_IDLE; + + /* vif->bss_conf.basic_rates ? Where exactly? */ + + /* Should almost assert it is this. */ + vif->cfg.assoc = false; + vif->cfg.aid = 0; + + bss_changed |= lkpi_update_dtim_tsf(vif, ni, vap, __func__, __LINE__); + error = 0; if (vif->chanctx_conf != NULL) { changed = IEEE80211_CHANCTX_CHANGE_MIN_WIDTH; @@ -989,6 +1011,9 @@ lkpi_sta_scan_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, int } else { goto out; } + + vif->bss_conf.chanctx_conf = conf; + /* Assign vif chanctx. */ if (error == 0) error = lkpi_80211_mo_assign_vif_chanctx(hw, vif, @@ -1003,21 +1028,6 @@ lkpi_sta_scan_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, int } IMPROVE("update radiotap chan fields too"); - /* Set bss info (bss_info_changed). */ - bss_changed = 0; - vif->bss_conf.bssid = ni->ni_bssid; - bss_changed |= BSS_CHANGED_BSSID; - vif->bss_conf.txpower = ni->ni_txpower; - bss_changed |= BSS_CHANGED_TXPOWER; - vif->cfg.idle = false; - bss_changed |= BSS_CHANGED_IDLE; - - /* Should almost assert it is this. */ - vif->cfg.assoc = false; - vif->cfg.aid = 0; - - bss_changed |= lkpi_update_dtim_tsf(vif, ni, vap, __func__, __LINE__); - /* RATES */ IMPROVE("bss info: not all needs to come now and rates are missing"); lkpi_80211_mo_bss_info_changed(hw, vif, &vif->bss_conf, bss_changed); @@ -2132,12 +2142,14 @@ lkpi_iv_update_bss(struct ieee80211vap *vap, struct ieee80211_node *ni) lsta->ni = ni; sta = LSTA_TO_STA(lsta); IEEE80211_ADDR_COPY(sta->addr, lsta->ni->ni_macaddr); + IEEE80211_ADDR_COPY(sta->deflink.addr, sta->addr); } lsta = obss->ni_drv_data; if (lsta != NULL) { lsta->ni = obss; sta = LSTA_TO_STA(lsta); IEEE80211_ADDR_COPY(sta->addr, lsta->ni->ni_macaddr); + IEEE80211_ADDR_COPY(sta->deflink.addr, sta->addr); } out: @@ -2278,6 +2290,9 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ], #if 1 vif->chanctx_conf = NULL; vif->bss_conf.vif = vif; + /* vap->iv_myaddr is not set until net80211::vap_setup or vap_attach. */ + IEEE80211_ADDR_COPY(vif->bss_conf.addr, mac); + vif->bss_conf.link_id = 0; /* Non-MLO operation. */ vif->bss_conf.chandef.width = NL80211_CHAN_WIDTH_20_NOHT; vif->bss_conf.use_short_preamble = false; /* vap->iv_flags IEEE80211_F_SHPREAMBLE */ vif->bss_conf.use_short_slot = false; /* vap->iv_flags IEEE80211_F_SHSLOT */ @@ -2288,15 +2303,13 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ], vif->cfg.assoc = false; vif->cfg.idle = true; vif->cfg.ps = false; + IMPROVE("Check other fields and then figure out whats is left elsewhere of them"); /* * We need to initialize it to something as the bss_info_changed call * will try to copy from it in iwlwifi and NULL is a panic. * We will set the proper one in scan_to_auth() before being assoc. - * NB: the logic there with using an array as bssid_override and checking - * for non-NULL later is flawed but in their workflow does not seem to - * matter. */ - vif->bss_conf.bssid = zerobssid; + vif->bss_conf.bssid = ieee80211broadcastaddr; #endif #if 0 vif->bss_conf.dtim_period = 0; /* IEEE80211_DTIM_DEFAULT ; must stay 0. */ @@ -2307,6 +2320,12 @@ lkpi_ic_vap_create(struct ieee80211com *ic, const char name[IFNAMSIZ], vif->bss_conf.beacon_int = 16; #endif + /* Link Config */ + vif->link_conf[0] = &vif->bss_conf; + for (i = 0; i < nitems(vif->link_conf); i++) { + IMPROVE("more than 1 link one day"); + } + /* Setup queue defaults; driver may override in (*add_interface). */ for (i = 0; i < IEEE80211_NUM_ACS; i++) { if (ieee80211_hw_check(hw, QUEUE_CONTROL)) From nobody Fri Oct 6 14:25:13 2023 X-Original-To: dev-commits-src-branches@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 4S29gZ3yhtz4wgmf; Fri, 6 Oct 2023 14:25:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gZ08lsz3R0k; Fri, 6 Oct 2023 14:25:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602314; 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=TQcfG+BFaSiNUNmuACcbsZMmCOMmnuQvSdT738nLQgs=; b=eLkdvV1Ka+9LdZN2/KAHvH+BHYuOCHWq1+snlqPGnBWumX9WpIjqv7OskBNwo9r3Xp7jz2 eg3a3NvFkP3a/RJeVCCd9b76WmdUTcL3PhjEcKsDAfDXZMxyGgrPM5sllDO1tIvJsf9Fen yUbTsT32Q213LW1Qqs1gAYGd7oHUv3UmGx/SZc+9NKGnU8L/ZisnHnf7pHmjbssE6UlFle sgHtJNDZfZfDvcKcthNRwP7fbwm0K3GUhuKrCZ9XLXanYvSKKFPS9EB6MtHaRSVjHpYsug PDx/yhWOml5SaadlI4YQ/w+LCXpHUdrPgvaTVauLiwy9UsrOW9t5GksGSnjhtw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602314; a=rsa-sha256; cv=none; b=NGedsffTfeH1H3DsSeCLYobqK58XKKXDT44wzf3E9R7j0sKCcbrdtdG2fKcJfffe9BDMMD xSBAcQ1K/LT8+kwYSSNgfb+wkCdzVm42bKSsaBYbgbNQNUOvPd6E7wXTf5vMJP0k7uJNbz sqz2fngM/2xeDuY5xELLqMWq8Yxt9aVCFD1kE+qGZWzhXJfiFF7IR8jks4asEFlpPHsBy5 cUYE8vB7gcY2ISCOWc5AlO0jGzAIkSPFlI35wWDncAuF4EdIRU0Td4qAqQErlLReuIxTHs 2Q7Ag8FmOhLNDW3ZkJkiwhwvdAPfZF3Zb1RNYb1ZoRbycFBDgdvdeRYYCtx2pg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602314; 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=TQcfG+BFaSiNUNmuACcbsZMmCOMmnuQvSdT738nLQgs=; b=wLlP6ycJt30LrTLMhCe4sTQ2QAHDsFPJeQfT7OdBj9RYcCORWg7qZzp7i5AAtMiyw/STYq rPO+hKMR7mD8WLBIGuxdlLuGdD7Te4q/+EsZPx2v9j4H/MiNhAarW/8A8rWmL25tXzBc8h rYSH7T5AULaIswZWnX6uZ6p2sMVlqj0+++XVMN2cBCbYLTq+yRIBBCkf5bOXKzGhFhOK/Q 9IFZ4TASymco2OGkzUrYz97K/3VwD8RomoZnTGXKLIKOQC6b0adT6o7uKLMC/9tFw2+QF7 KT4u/IwYcdAKsNt3DvDSm93AYIhBimy9ZgNnR/iiHHxPWiNmC6EQfI1Ouk/Jgg== 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 4S29gY6NCbzrXJ; Fri, 6 Oct 2023 14:25:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EPDo0093459; Fri, 6 Oct 2023 14:25:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EPDoG093456; Fri, 6 Oct 2023 14:25:13 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:13 GMT Message-Id: <202310061425.396EPDoG093456@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: b6628a233e8e - stable/14 - LinuxKPI: 802.11: move ieee80211_chanctx_conf into lkpi private struct List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: b6628a233e8e6407a504172a562ba14a66c7e7da Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=b6628a233e8e6407a504172a562ba14a66c7e7da commit b6628a233e8e6407a504172a562ba14a66c7e7da Author: Bjoern A. Zeeb AuthorDate: 2023-09-25 16:57:23 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:40 +0000 LinuxKPI: 802.11: move ieee80211_chanctx_conf into lkpi private struct Factor out ieee80211_chanctx_conf into struct lkpi_chanctx in order to keep local state as well. In first instance that is added_to_drv only. For now we stay single-chanctx only but this paves the path to make it a list. Use the new information to implement ieee80211_iter_chan_contexts_atomic(). Sponsored by: The FreeBSD Foundation (cherry picked from commit c5e257985085bd987b1dddffd0455c2230df2d1d) --- sys/compat/linuxkpi/common/src/linux_80211.c | 46 +++++++++++++++++++--- sys/compat/linuxkpi/common/src/linux_80211.h | 9 +++++ .../linuxkpi/common/src/linux_80211_macops.c | 8 ++++ 3 files changed, 57 insertions(+), 6 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 1fee5f6809fd..d2f67230a812 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -922,6 +922,7 @@ static int lkpi_sta_scan_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, int arg) { struct linuxkpi_ieee80211_channel *chan; + struct lkpi_chanctx *lchanctx; struct ieee80211_chanctx_conf *conf; struct lkpi_hw *lhw; struct ieee80211_hw *hw; @@ -953,11 +954,13 @@ lkpi_sta_scan_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, int /* Add chanctx (or if exists, change it). */ if (vif->chanctx_conf != NULL) { conf = vif->chanctx_conf; + lchanctx = CHANCTX_CONF_TO_LCHANCTX(conf); IMPROVE("diff changes for changed, working on live copy, rcu"); } else { /* Keep separate alloc as in Linux this is rcu managed? */ - conf = malloc(sizeof(*conf) + hw->chanctx_data_size, + lchanctx = malloc(sizeof(*lchanctx) + hw->chanctx_data_size, M_LKPI80211, M_WAITOK | M_ZERO); + conf = &lchanctx->conf; } conf->rx_chains_dynamic = 1; @@ -1022,7 +1025,8 @@ lkpi_sta_scan_to_auth(struct ieee80211vap *vap, enum ieee80211_state nstate, int error = 0; if (error != 0) { lkpi_80211_mo_remove_chanctx(hw, conf); - free(conf, M_LKPI80211); + lchanctx = CHANCTX_CONF_TO_LCHANCTX(conf); + free(lchanctx, M_LKPI80211); goto out; } } @@ -1179,6 +1183,7 @@ lkpi_sta_auth_to_scan(struct ieee80211vap *vap, enum ieee80211_state nstate, int /* Take the chan ctx down. */ if (vif->chanctx_conf != NULL) { + struct lkpi_chanctx *lchanctx; struct ieee80211_chanctx_conf *conf; conf = vif->chanctx_conf; @@ -1188,7 +1193,8 @@ lkpi_sta_auth_to_scan(struct ieee80211vap *vap, enum ieee80211_state nstate, int /* Remove chan ctx. */ lkpi_80211_mo_remove_chanctx(hw, conf); - free(conf, M_LKPI80211); + lchanctx = CHANCTX_CONF_TO_LCHANCTX(conf); + free(lchanctx, M_LKPI80211); } out: @@ -1454,6 +1460,7 @@ _lkpi_sta_assoc_to_down(struct ieee80211vap *vap, enum ieee80211_state nstate, i /* Take the chan ctx down. */ if (vif->chanctx_conf != NULL) { + struct lkpi_chanctx *lchanctx; struct ieee80211_chanctx_conf *conf; conf = vif->chanctx_conf; @@ -1463,7 +1470,8 @@ _lkpi_sta_assoc_to_down(struct ieee80211vap *vap, enum ieee80211_state nstate, i /* Remove chan ctx. */ lkpi_80211_mo_remove_chanctx(hw, conf); - free(conf, M_LKPI80211); + lchanctx = CHANCTX_CONF_TO_LCHANCTX(conf); + free(lchanctx, M_LKPI80211); } error = EALREADY; @@ -1916,6 +1924,7 @@ lkpi_sta_run_to_init(struct ieee80211vap *vap, enum ieee80211_state nstate, int /* Take the chan ctx down. */ if (vif->chanctx_conf != NULL) { + struct lkpi_chanctx *lchanctx; struct ieee80211_chanctx_conf *conf; conf = vif->chanctx_conf; @@ -1925,7 +1934,8 @@ lkpi_sta_run_to_init(struct ieee80211vap *vap, enum ieee80211_state nstate, int /* Remove chan ctx. */ lkpi_80211_mo_remove_chanctx(hw, conf); - free(conf, M_LKPI80211); + lchanctx = CHANCTX_CONF_TO_LCHANCTX(conf); + free(lchanctx, M_LKPI80211); } error = EALREADY; @@ -3968,8 +3978,32 @@ linuxkpi_ieee80211_iterate_chan_contexts(struct ieee80211_hw *hw, void *), void *arg) { + struct lkpi_hw *lhw; + struct lkpi_vif *lvif; + struct ieee80211_vif *vif; + struct lkpi_chanctx *lchanctx; - UNIMPLEMENTED; + KASSERT(hw != NULL && iterfunc != NULL, + ("%s: hw %p iterfunc %p arg %p\n", __func__, hw, iterfunc, arg)); + + lhw = HW_TO_LHW(hw); + + IMPROVE("lchanctx should be its own list somewhere"); + + LKPI_80211_LHW_LVIF_LOCK(lhw); + TAILQ_FOREACH(lvif, &lhw->lvif_head, lvif_entry) { + + vif = LVIF_TO_VIF(lvif); + if (vif->chanctx_conf == NULL) + continue; + + lchanctx = CHANCTX_CONF_TO_LCHANCTX(vif->chanctx_conf); + if (!lchanctx->added_to_drv) + continue; + + iterfunc(hw, &lchanctx->conf, arg); + } + LKPI_80211_LHW_LVIF_UNLOCK(lhw); } void diff --git a/sys/compat/linuxkpi/common/src/linux_80211.h b/sys/compat/linuxkpi/common/src/linux_80211.h index 22a5f5a6377c..93c1e2873206 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.h +++ b/sys/compat/linuxkpi/common/src/linux_80211.h @@ -210,6 +210,15 @@ struct lkpi_hw { /* name it mac80211_sc? */ #define LHW_TO_HW(_lhw) (&(_lhw)->hw) #define HW_TO_LHW(_hw) container_of(_hw, struct lkpi_hw, hw) +struct lkpi_chanctx { + bool added_to_drv; /* Managed by MO */ + struct ieee80211_chanctx_conf conf __aligned(CACHE_LINE_SIZE); +}; +#define LCHANCTX_TO_CHANCTX_CONF(_lchanctx) \ + (&(_lchanctx)->conf) +#define CHANCTX_CONF_TO_LCHANCTX(_conf) \ + container_of(_conf, struct lkpi_chanctx, conf) + struct lkpi_wiphy { const struct cfg80211_ops *ops; diff --git a/sys/compat/linuxkpi/common/src/linux_80211_macops.c b/sys/compat/linuxkpi/common/src/linux_80211_macops.c index b3b53d23f62e..8f75b1bdf8b1 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211_macops.c +++ b/sys/compat/linuxkpi/common/src/linux_80211_macops.c @@ -490,6 +490,7 @@ lkpi_80211_mo_add_chanctx(struct ieee80211_hw *hw, struct ieee80211_chanctx_conf *chanctx_conf) { struct lkpi_hw *lhw; + struct lkpi_chanctx *lchanctx; int error; lhw = HW_TO_LHW(hw); @@ -500,6 +501,10 @@ lkpi_80211_mo_add_chanctx(struct ieee80211_hw *hw, LKPI_80211_TRACE_MO("hw %p chanctx_conf %p", hw, chanctx_conf); error = lhw->ops->add_chanctx(hw, chanctx_conf); + if (error == 0) { + lchanctx = CHANCTX_CONF_TO_LCHANCTX(chanctx_conf); + lchanctx->added_to_drv = true; + } out: return (error); @@ -524,6 +529,7 @@ lkpi_80211_mo_remove_chanctx(struct ieee80211_hw *hw, struct ieee80211_chanctx_conf *chanctx_conf) { struct lkpi_hw *lhw; + struct lkpi_chanctx *lchanctx; lhw = HW_TO_LHW(hw); if (lhw->ops->remove_chanctx == NULL) @@ -531,6 +537,8 @@ lkpi_80211_mo_remove_chanctx(struct ieee80211_hw *hw, LKPI_80211_TRACE_MO("hw %p chanctx_conf %p", hw, chanctx_conf); lhw->ops->remove_chanctx(hw, chanctx_conf); + lchanctx = CHANCTX_CONF_TO_LCHANCTX(chanctx_conf); + lchanctx->added_to_drv = false; } void From nobody Fri Oct 6 14:25:14 2023 X-Original-To: dev-commits-src-branches@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 4S29gb3yRVz4wgWH; Fri, 6 Oct 2023 14:25: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gb1D72z3R10; Fri, 6 Oct 2023 14:25:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602315; 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=xvCHp0SFl5eCXdwdbZtQJJqvrg2lEbneH4EkX3jGB28=; b=j59w7T/+H+e7It3QZrDLaNx+eupvxIqtrS6MLVPgAJAV3pqfofNSPSZf7Zkenv5FmzQFBC spDj9oqPLxHoK3OB/x+q2qtdIoGEk9n+8beFazGXNgIqs2LryibhAM0w6dsHIZXNx+WZCm WFL045LQXHhc8MDSLopFw9pehlsdecYEAA2xUoReWxy1cGu5+EFCAGW008tXi5jVCACGIk A6Z+Tz4GHT6KriL1UMNDP6OK/bggDZWfMvm19dsKKY1HCzOr9IhrEW9JYY4ej2buZhy83C w6edcEmdNybjjslLVBBefcVPbqSB1BSdm7CHuDBwbn8sEW2UPOMD3J9yLiWaxg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602315; a=rsa-sha256; cv=none; b=EAV4rqdBhdS8Vr3xpYaDOfMnk9fkUJ340JiPzbDeQ79VWv0Zmi7w1JErtgA82QWpj/9roP 60c7iklGbipqRxzTbohV3PStfLUkfPst2fGqoONuey3tZjy17ZuseKfSoPIrF3EKdLxk12 qXGo7xF4UnaAP4hmqn9SzvkKrfVw3W+nkYo8Bv8Ycylw75xzFOq60gl9DNt+yaJLMsCC1D eOIBVawIbEXIcDa3VTYX8pIH+puDthBqkXABSaa76pW8Q7+X6QDEsqrtxgyBu9aH8D4dzj +Tvcmr9v2ZdqTdeuxY7ntORL6c2nStxlyr/nD55UdqCT6T3UuuaPOZOsZafnxQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602315; 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=xvCHp0SFl5eCXdwdbZtQJJqvrg2lEbneH4EkX3jGB28=; b=Z9e1SZQbfg/seW7FPQaHv4zJnDm0PNbO8aoq7+tY+Ef4vl+e3MVkQLP1W3ve+iN2gcN2Ad jM/URBn1MSS7sCKLBQ5n7G6beYh0OaQ+g5kq2Hdc+nSlj1imr6PVPowmK2e2glZInXpqGW 85WJu7/0U2vvcWQ06Zw/Z0j4LwXNH4TDLEm39I/4nTX4qabybDxeD/BLCNg4N6+0n7qmZD T1JLIvwr9vOWoIlFFZRt9VoFlojpbGCzJqO8GhnwqWfCeWVuCKuAdP3T1A1EmCyHIDPGqh u5HBp2SX1dmmsKryaXFvsWUO+hkSGAnHx3thpSrkWsvq/rLfQthTbVYA4Tr34Q== 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 4S29gb0LHbzrXK; Fri, 6 Oct 2023 14:25:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EPE00093507; Fri, 6 Oct 2023 14:25:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EPE7D093504; Fri, 6 Oct 2023 14:25:14 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:14 GMT Message-Id: <202310061425.396EPE7D093504@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 4e26de26431b - stable/14 - LinuxKPI: 802.11: fix problem removing sta List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 4e26de26431be8b830ef9d2d2397490b68437ddd Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=4e26de26431be8b830ef9d2d2397490b68437ddd commit 4e26de26431be8b830ef9d2d2397490b68437ddd Author: Bjoern A. Zeeb AuthorDate: 2023-09-30 07:59:48 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:40 +0000 LinuxKPI: 802.11: fix problem removing sta Move the call to lkpi_disassoc() before the state change to IEEE80211_STA_NOTEXIST which will remove the sta (from firmware). Based on a comment it seems that originally we had to do it the other way round. iwlwifi(4) has a check and will silently not remove the sta from the firmware when vif->cfg.assoc is still set (see iwl_mvm_sta_del()). This leads to the LinuxKPI 802.11 code thinking the sta is gone as downward state changes by the mac80211 op (*sta_state)() may not fail. Once we try to assoc with a newly added station later, iwlwifi firmware will run into an assert having two ap_sta set on the same vif. We can observe that problem in iwlwifi(4) having __le32 sta_id = 1 instead of sta_id = 0 in iwl_mvm_sta_cfg_cmd{} on the HCMD. This should fix one of the most seen problems with iwlwifi(4), e.g., when running service netif restart wlan0 or service wpa_supplicant restart wlan0. Sponsored by: The FreeBSD Foundation (cherry picked from commit 16e688b2a403a3dbc05de3b9f8a3132838613790) --- sys/compat/linuxkpi/common/src/linux_80211.c | 37 ++++++++++++++-------------- 1 file changed, 18 insertions(+), 19 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index d2f67230a812..9f5f5bef7f27 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -1426,6 +1426,15 @@ _lkpi_sta_assoc_to_down(struct ieee80211vap *vap, enum ieee80211_state nstate, i lkpi_lsta_dump(lsta, ni, __func__, __LINE__); + /* Update bss info (bss_info_changed) (assoc, aid, ..). */ + /* + * We need to do this now, before sta changes to IEEE80211_STA_NOTEXIST + * as otherwise drivers (iwlwifi at least) will silently not remove + * the sta from the firmware and when we will add a new one trigger + * a fw assert. + */ + lkpi_disassoc(sta, vif, lhw); + /* Adjust sta and change state (from NONE) to NOTEXIST. */ KASSERT(lsta != NULL, ("%s: ni %p lsta is NULL\n", __func__, ni)); KASSERT(lsta->state == IEEE80211_STA_NONE, ("%s: lsta %p state not " @@ -1435,15 +1444,8 @@ _lkpi_sta_assoc_to_down(struct ieee80211vap *vap, enum ieee80211_state nstate, i IMPROVE("do we need to undo the chan ctx?"); goto out; } -#if 0 - lsta->added_to_drv = false; /* mo manages. */ -#endif - lkpi_lsta_dump(lsta, ni, __func__, __LINE__); - - /* Update bss info (bss_info_changed) (assoc, aid, ..). */ - /* We need to do this now, can only do after sta is IEEE80211_STA_NOTEXIST. */ - lkpi_disassoc(sta, vif, lhw); + lkpi_lsta_dump(lsta, ni, __func__, __LINE__); /* sta no longer save to use. */ IMPROVE("Any bss_info changes to announce?"); bss_changed = 0; @@ -1887,6 +1889,13 @@ lkpi_sta_run_to_init(struct ieee80211vap *vap, enum ieee80211_state nstate, int lkpi_lsta_dump(lsta, ni, __func__, __LINE__); + /* Update bss info (bss_info_changed) (assoc, aid, ..). */ + /* + * One would expect this to happen when going off AUTHORIZED. + * See comment there; removes the sta from fw. + */ + lkpi_disassoc(sta, vif, lhw); + /* Adjust sta and change state (from NONE) to NOTEXIST. */ KASSERT(lsta != NULL, ("%s: ni %p lsta is NULL\n", __func__, ni)); KASSERT(lsta->state == IEEE80211_STA_NONE, ("%s: lsta %p state not " @@ -1896,18 +1905,8 @@ lkpi_sta_run_to_init(struct ieee80211vap *vap, enum ieee80211_state nstate, int IMPROVE("do we need to undo the chan ctx?"); goto out; } -#if 0 - lsta->added_to_drv = false; /* mo manages. */ -#endif - lkpi_lsta_dump(lsta, ni, __func__, __LINE__); - - /* Update bss info (bss_info_changed) (assoc, aid, ..). */ - /* - * One would expect this to happen when going off AUTHORIZED. - * See comment there; removes the sta from fw. - */ - lkpi_disassoc(sta, vif, lhw); + lkpi_lsta_dump(lsta, ni, __func__, __LINE__); /* sta no longer save to use. */ IMPROVE("Any bss_info changes to announce?"); bss_changed = 0; From nobody Fri Oct 6 14:25:16 2023 X-Original-To: dev-commits-src-branches@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 4S29gc4pVGz4wgmk; Fri, 6 Oct 2023 14:25: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gc2b5Zz3R64; Fri, 6 Oct 2023 14:25:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602316; 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=FUjqq2MSeSnj3nFjD0Eia0Evkxc2PWJH+xeHB01TSeQ=; b=Q10hoZwHcBGnnv8EYV1BiylJOL7LDcvGUNNZcvMlItlBAeaqof25kuYJ8G9Fwq03tKJAtt JgWKD9oFGDlgpB7L4N1xMH3hc/1NEBBj9zckzW5WcrwDi0M45lFJB08UjE3O7xAmeZjKmX R6GJDT2PcF/519duo1Ef+2JaWDkBXAFrspVoS9AxnJq73bxxL4NooEhy/iYSqdV8c61j2h 8vd4/P5ADnq+oxydKAykM4iWoyzFb2AOYeuNM/rKVG7MNueF9U3hanENrNF7TV0vWYFRSd 2XnsuH59FDx6l9c0nUTsoR2Dxjcg5rIvQF9XBG2lN4Xy4Y6MR43sqc02bONqGw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602316; a=rsa-sha256; cv=none; b=I7n826b+dZIsPbYL57X4oOPKN5rCdHixPReBxh5DkcXAYMmKGIPWB/1HlpV8zxj/g7YjAz 5SjhDe9YUJsTZ2zn0TmVxlOQyoNOrfbDZkFARD+TEStotTqJOCqGPTnaYB3NLGpHOsoDBN 8GWlETxXp7WyQKfRZN1lucDNS4ztgtaOMpjW7+C85lTfOjG0MJWnFBpLDQFIj2SdqsIXzc T/7xBFV3Sh314n3DyT6C/TglTmdQCibW5MeOecWEGl3zBH0N0uM4jBP6kZ86nBb7x69l+y TYKC7LV4xC4vzV2wl7d02iSXPOxTyPNxYyY911fjfWm/V/rJw2L82KQ+tJK3dQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602316; 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=FUjqq2MSeSnj3nFjD0Eia0Evkxc2PWJH+xeHB01TSeQ=; b=v+njGHbURStTHD+lU2odlvsaHD8mUbZ5MgUXIYitSY4Y0bL6BWnDwGZeCi9p1x08f+xfev bgqQoU5p9ygdrrvTdpeM76GF+eSNYmS7rvXAn8KWSAoKU8XRpRVw43ePmxaB12hVYOcM21 53ORk+mbcPPAAf7/6QCahBuLyoBJ/KyYGcdf46gE6NxzWKkiu0IcOJlgfzBgDjYExZ38Zc djAfSd81qn1MiF1W/wS3K+91UDi+7VONtk1W7TjiRqqFPFP38h5DxSdihQyhNDbtjKKXZ5 zEVf9534HzfmWsFljLAg7V1dZhPNd3GaCWDehBc10SZdwKuQ/iibLaHvejSPeA== 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 4S29gc1hQmzr9T; Fri, 6 Oct 2023 14:25:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EPGLs093560; Fri, 6 Oct 2023 14:25:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EPG8L093557; Fri, 6 Oct 2023 14:25:16 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:16 GMT Message-Id: <202310061425.396EPG8L093557@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 5b9404565fef - stable/14 - LinuxKPI: 802.11: hide txq debugging behind checks List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 5b9404565fef6cf4f01210343c8074b9407cb268 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=5b9404565fef6cf4f01210343c8074b9407cb268 commit 5b9404565fef6cf4f01210343c8074b9407cb268 Author: Bjoern A. Zeeb AuthorDate: 2023-10-04 20:30:00 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:40 +0000 LinuxKPI: 802.11: hide txq debugging behind checks Two txq debug messages were left unconditionally. Hide them behind ifdef/if() condition checks for selective debugging only. Sponsored by: The FreeBSD Foundation (cherry picked from commit 0d2cb6a6ecde3b271ede59d77801cb43a8804688) --- sys/compat/linuxkpi/common/src/linux_80211.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 9f5f5bef7f27..4a296e2f0fad 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -4911,15 +4911,18 @@ linuxkpi_ieee80211_stop_queue(struct ieee80211_hw *hw, int qnum) for (ac = 0; ac < ac_count; ac++) { IMPROVE_TXQ("LOCKING"); if (qnum == vif->hw_queue[ac]) { +#ifdef LINUXKPI_DEBUG_80211 /* * For now log this to better understand * how this is supposed to work. */ - if (lvif->hw_queue_stopped[ac]) + if (lvif->hw_queue_stopped[ac] && + (linuxkpi_debug_80211 & D80211_IMPROVE_TXQ) != 0) ic_printf(lhw->ic, "%s:%d: lhw %p hw %p " "lvif %p vif %p ac %d qnum %d already " "stopped\n", __func__, __LINE__, lhw, hw, lvif, vif, ac, qnum); +#endif lvif->hw_queue_stopped[ac] = true; } } @@ -4966,15 +4969,18 @@ lkpi_ieee80211_wake_queues(struct ieee80211_hw *hw, int hwq) /* XXX-BZ what about software scan? */ +#ifdef LINUXKPI_DEBUG_80211 /* * For now log this to better understand * how this is supposed to work. */ - if (!lvif->hw_queue_stopped[ac]) + if (!lvif->hw_queue_stopped[ac] && + (linuxkpi_debug_80211 & D80211_IMPROVE_TXQ) != 0) ic_printf(lhw->ic, "%s:%d: lhw %p hw %p " "lvif %p vif %p ac %d hw_q not stopped\n", __func__, __LINE__, lhw, hw, lvif, vif, ac); +#endif lvif->hw_queue_stopped[ac] = false; LKPI_80211_LVIF_LOCK(lvif); From nobody Fri Oct 6 14:25:17 2023 X-Original-To: dev-commits-src-branches@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 4S29gf0vDDz4wgkV; Fri, 6 Oct 2023 14:25: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gd6Rdpz3RDC; Fri, 6 Oct 2023 14:25:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602317; 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=FO7hc++UY3WPJUyS9iq+f1C9VNaExI0Xlukx07uqp0g=; b=lpaMpMoMFcfExr3bdSF3d+DM84izXzzaDgf8tkOJ7QGH/XAk34W6KBHQ4KCCekNj63c86L auMIZaX2k+ldt95QAST8qg9t3yLX2GEDEQf362Yrlhrrk8geR3YraFlAtIzYgCyruN+lnb vJ0wM5G1mCg/w25uuw6NP0of9mAP/Y6vzsdibkGQ2JMvgQRRJtaq8dG9Cv4ljsgAt90/eO 6O74hbrmP2d5yJRAdr/LKIuBnmi/+v91anmBg3Dsnra5jAGh7jx2MKVFLLp10s/IukCYFO 1O5pvutqtA0TUdAhPdkMzUpBlnqziMja8U0UfA6opwxbO79RIczqIYRLC/cVcg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602317; a=rsa-sha256; cv=none; b=k8Gq0RGPFLYSGwU0ys5trxCtpSFSH1iTcCKM2/txIY0L+6govMX7kCaNp5UYOVnQW7jz1Y MO5D+g6b6ZG1Ma5LCW3od7X0MHmlUABVDf4SAZhZjz2dL0dbkmd0sFf75tYZc16Y5DiED7 2fiExGN+IExeldasbi4I4d/Ek5LWXPIg2jKdgGmNgNAzGABo0aghg6JTZ5TXgcG6qcX8Ob laYdQ+BIqgUU6lILYJSo4Cr62tCjBf9Ui65xinb+nh7i4RmU5uYI0TVgNLhgDl+hysvYZh MCQyrbAt9EAQkfsokKXJLKN/fZeZnhsDlC6ZOZFXoFe5Ed97KV1x+wd4cqdlqQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602317; 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=FO7hc++UY3WPJUyS9iq+f1C9VNaExI0Xlukx07uqp0g=; b=pshfhNQYx7MZXEMy+JJ2gJS4fGrREWOpPDODFu1jw19964coU21brrU/khWp62rvbV9jV3 Xid9ClXMGpHNmIoezbwsZQMUxsPuvU8QhtYYde5nUDeW/DGlI5jSv1QsfTG1vSrLo8ruDL bFK/G3z+cTHg0m6BNUJ0LEFaQb3MtdLAoJOayR/20Q1cqiJ4V+odX2fMeZrbzWmDSLagX0 qnm3whK7ua1wzJxXntkvuIAWaRuuykEWgxGyyzNtTQInvSWdM1Nr3jFvAXVAwwmLw8TH+e BpicBI8XCyEilcFsvGimARuR6Gx3/jR+rBZETdO6kaGHMNxcw61Df4xnFMHXtQ== 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 4S29gd5VB0zrtX; Fri, 6 Oct 2023 14:25:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EPHO6093613; Fri, 6 Oct 2023 14:25:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EPHIV093609; Fri, 6 Oct 2023 14:25:17 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:17 GMT Message-Id: <202310061425.396EPHIV093609@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 12d5f2e7196f - stable/14 - iwlwifi: update driver from upstream List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 12d5f2e7196fc4a68833c154c74de814f770d468 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=12d5f2e7196fc4a68833c154c74de814f770d468 commit 12d5f2e7196fc4a68833c154c74de814f770d468 Author: Bjoern A. Zeeb AuthorDate: 2023-05-16 21:56:20 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:40 +0000 iwlwifi: update driver from upstream This is a combined versions of updates of the iwlwifi driver based on wireless-testing (wt-2023-05-11) 711dca0ca3d77414f8f346e564e9c8640147f40d (after v6.4-rc1). (wt-2023-06-09) 7bd20e011626ccc3ad53e57873452b1716fcfaaa (after v6.4-rc5). (wt-2023-07-24) 62e409149b62a285e89018e49b2e115757fb9022 (after v6.5-rc3). Sponsored by: The FreeBSD Foundation (cherry picked from commit 9af1bba44e1ce9b0296ae56760b564d67ab7a1cf) --- sys/contrib/dev/iwlwifi/cfg/22000.c | 617 +----- sys/contrib/dev/iwlwifi/cfg/7000.c | 22 +- sys/contrib/dev/iwlwifi/cfg/8000.c | 10 +- sys/contrib/dev/iwlwifi/cfg/9000.c | 10 +- sys/contrib/dev/iwlwifi/cfg/ax210.c | 301 +++ sys/contrib/dev/iwlwifi/cfg/bz.c | 183 ++ sys/contrib/dev/iwlwifi/cfg/sc.c | 166 ++ sys/contrib/dev/iwlwifi/fw/acpi.c | 172 +- sys/contrib/dev/iwlwifi/fw/acpi.h | 41 +- sys/contrib/dev/iwlwifi/fw/api/binding.h | 14 +- sys/contrib/dev/iwlwifi/fw/api/commands.h | 47 +- sys/contrib/dev/iwlwifi/fw/api/config.h | 15 +- sys/contrib/dev/iwlwifi/fw/api/context.h | 13 +- sys/contrib/dev/iwlwifi/fw/api/d3.h | 98 +- sys/contrib/dev/iwlwifi/fw/api/datapath.h | 287 ++- sys/contrib/dev/iwlwifi/fw/api/dbg-tlv.h | 4 +- sys/contrib/dev/iwlwifi/fw/api/debug.h | 100 +- sys/contrib/dev/iwlwifi/fw/api/filter.h | 2 +- sys/contrib/dev/iwlwifi/fw/api/location.h | 16 +- sys/contrib/dev/iwlwifi/fw/api/mac-cfg.h | 465 ++++- sys/contrib/dev/iwlwifi/fw/api/mac.h | 30 +- sys/contrib/dev/iwlwifi/fw/api/nvm-reg.h | 46 +- sys/contrib/dev/iwlwifi/fw/api/offload.h | 20 +- sys/contrib/dev/iwlwifi/fw/api/phy-ctxt.h | 39 +- sys/contrib/dev/iwlwifi/fw/api/phy.h | 10 +- sys/contrib/dev/iwlwifi/fw/api/power.h | 2 +- sys/contrib/dev/iwlwifi/fw/api/rs.h | 39 +- sys/contrib/dev/iwlwifi/fw/api/rx.h | 215 ++- sys/contrib/dev/iwlwifi/fw/api/scan.h | 66 +- sys/contrib/dev/iwlwifi/fw/api/sta.h | 2 +- sys/contrib/dev/iwlwifi/fw/api/tdls.h | 2 +- sys/contrib/dev/iwlwifi/fw/api/time-event.h | 7 +- sys/contrib/dev/iwlwifi/fw/api/tx.h | 23 +- sys/contrib/dev/iwlwifi/fw/dbg.c | 129 +- sys/contrib/dev/iwlwifi/fw/dbg.h | 18 +- sys/contrib/dev/iwlwifi/fw/debugfs.c | 39 +- sys/contrib/dev/iwlwifi/fw/dump.c | 87 +- sys/contrib/dev/iwlwifi/fw/error-dump.h | 19 +- sys/contrib/dev/iwlwifi/fw/file.h | 23 +- sys/contrib/dev/iwlwifi/fw/img.h | 5 +- sys/contrib/dev/iwlwifi/fw/pnvm.c | 233 ++- sys/contrib/dev/iwlwifi/fw/pnvm.h | 27 +- sys/contrib/dev/iwlwifi/fw/rs.c | 6 +- sys/contrib/dev/iwlwifi/fw/runtime.h | 11 +- sys/contrib/dev/iwlwifi/fw/uefi.c | 331 ++-- sys/contrib/dev/iwlwifi/fw/uefi.h | 58 +- sys/contrib/dev/iwlwifi/iwl-config.h | 55 +- sys/contrib/dev/iwlwifi/iwl-context-info-gen3.h | 53 +- sys/contrib/dev/iwlwifi/iwl-context-info.h | 5 +- sys/contrib/dev/iwlwifi/iwl-csr.h | 5 + sys/contrib/dev/iwlwifi/iwl-dbg-tlv.c | 99 +- sys/contrib/dev/iwlwifi/iwl-debug.c | 3 +- sys/contrib/dev/iwlwifi/iwl-drv.c | 105 +- sys/contrib/dev/iwlwifi/iwl-drv.h | 6 +- sys/contrib/dev/iwlwifi/iwl-eeprom-parse.h | 8 +- sys/contrib/dev/iwlwifi/iwl-fh.h | 4 +- sys/contrib/dev/iwlwifi/iwl-io.c | 4 +- sys/contrib/dev/iwlwifi/iwl-modparams.h | 1 + sys/contrib/dev/iwlwifi/iwl-nvm-parse.c | 393 +++- sys/contrib/dev/iwlwifi/iwl-nvm-parse.h | 4 +- sys/contrib/dev/iwlwifi/iwl-prph.h | 20 +- sys/contrib/dev/iwlwifi/iwl-trans.c | 6 +- sys/contrib/dev/iwlwifi/iwl-trans.h | 138 +- sys/contrib/dev/iwlwifi/mei/iwl-mei.h | 23 +- sys/contrib/dev/iwlwifi/mvm/binding.c | 23 +- sys/contrib/dev/iwlwifi/mvm/coex.c | 112 +- sys/contrib/dev/iwlwifi/mvm/constants.h | 6 +- sys/contrib/dev/iwlwifi/mvm/d3.c | 1148 ++++++++---- sys/contrib/dev/iwlwifi/mvm/debugfs-vif.c | 31 +- sys/contrib/dev/iwlwifi/mvm/debugfs.c | 468 ++++- sys/contrib/dev/iwlwifi/mvm/ftm-initiator.c | 98 +- sys/contrib/dev/iwlwifi/mvm/ftm-responder.c | 44 +- sys/contrib/dev/iwlwifi/mvm/fw.c | 383 ++-- sys/contrib/dev/iwlwifi/mvm/link.c | 285 +++ sys/contrib/dev/iwlwifi/mvm/mac-ctxt.c | 686 ++++--- sys/contrib/dev/iwlwifi/mvm/mac80211.c | 2288 +++++++++++++++-------- sys/contrib/dev/iwlwifi/mvm/mld-key.c | 376 ++++ sys/contrib/dev/iwlwifi/mvm/mld-mac.c | 321 ++++ sys/contrib/dev/iwlwifi/mvm/mld-mac80211.c | 1215 ++++++++++++ sys/contrib/dev/iwlwifi/mvm/mld-sta.c | 1181 ++++++++++++ sys/contrib/dev/iwlwifi/mvm/mvm.h | 669 ++++++- sys/contrib/dev/iwlwifi/mvm/nvm.c | 73 +- sys/contrib/dev/iwlwifi/mvm/offloading.c | 10 +- sys/contrib/dev/iwlwifi/mvm/ops.c | 131 +- sys/contrib/dev/iwlwifi/mvm/phy-ctxt.c | 73 +- sys/contrib/dev/iwlwifi/mvm/power.c | 104 +- sys/contrib/dev/iwlwifi/mvm/ptp.c | 326 ++++ sys/contrib/dev/iwlwifi/mvm/quota.c | 15 +- sys/contrib/dev/iwlwifi/mvm/rfi.c | 16 +- sys/contrib/dev/iwlwifi/mvm/rs-fw.c | 366 +++- sys/contrib/dev/iwlwifi/mvm/rs.c | 6 +- sys/contrib/dev/iwlwifi/mvm/rs.h | 14 +- sys/contrib/dev/iwlwifi/mvm/rx.c | 94 +- sys/contrib/dev/iwlwifi/mvm/rxmq.c | 1204 ++++++++---- sys/contrib/dev/iwlwifi/mvm/scan.c | 313 +++- sys/contrib/dev/iwlwifi/mvm/sf.c | 66 +- sys/contrib/dev/iwlwifi/mvm/sta.c | 844 +++++---- sys/contrib/dev/iwlwifi/mvm/sta.h | 154 +- sys/contrib/dev/iwlwifi/mvm/tdls.c | 12 +- sys/contrib/dev/iwlwifi/mvm/time-event.c | 33 +- sys/contrib/dev/iwlwifi/mvm/time-sync.c | 173 ++ sys/contrib/dev/iwlwifi/mvm/time-sync.h | 30 + sys/contrib/dev/iwlwifi/mvm/tt.c | 79 +- sys/contrib/dev/iwlwifi/mvm/tx.c | 342 ++-- sys/contrib/dev/iwlwifi/mvm/utils.c | 115 +- sys/contrib/dev/iwlwifi/pcie/ctxt-info-gen3.c | 278 ++- sys/contrib/dev/iwlwifi/pcie/ctxt-info.c | 8 +- sys/contrib/dev/iwlwifi/pcie/drv.c | 711 +++---- sys/contrib/dev/iwlwifi/pcie/internal.h | 13 +- sys/contrib/dev/iwlwifi/pcie/rx.c | 52 +- sys/contrib/dev/iwlwifi/pcie/trans-gen2.c | 89 +- sys/contrib/dev/iwlwifi/pcie/trans.c | 225 ++- sys/contrib/dev/iwlwifi/pcie/tx.c | 7 +- sys/contrib/dev/iwlwifi/queue/tx.c | 32 +- sys/contrib/dev/iwlwifi/queue/tx.h | 8 +- sys/modules/iwlwifi/Makefile | 4 + 116 files changed, 15387 insertions(+), 4969 deletions(-) diff --git a/sys/contrib/dev/iwlwifi/cfg/22000.c b/sys/contrib/dev/iwlwifi/cfg/22000.c index 192ecc480f90..d594694206b3 100644 --- a/sys/contrib/dev/iwlwifi/cfg/22000.c +++ b/sys/contrib/dev/iwlwifi/cfg/22000.c @@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause /* * Copyright (C) 2015-2017 Intel Deutschland GmbH - * Copyright (C) 2018-2022 Intel Corporation + * Copyright (C) 2018-2023 Intel Corporation */ #include #include @@ -10,10 +10,10 @@ #include "fw/api/txq.h" /* Highest firmware API version supported */ -#define IWL_22000_UCODE_API_MAX 73 +#define IWL_22000_UCODE_API_MAX 77 /* Lowest firmware API version supported */ -#define IWL_22000_UCODE_API_MIN 39 +#define IWL_22000_UCODE_API_MIN 50 /* NVM versions */ #define IWL_22000_NVM_VERSION 0x0a1d @@ -26,111 +26,26 @@ #define IWL_22000_SMEM_OFFSET 0x400000 #define IWL_22000_SMEM_LEN 0xD0000 -#define IWL_QU_B_HR_B_FW_PRE "iwlwifi-Qu-b0-hr-b0-" -#define IWL_QNJ_B_HR_B_FW_PRE "iwlwifi-QuQnj-b0-hr-b0-" -#define IWL_QU_C_HR_B_FW_PRE "iwlwifi-Qu-c0-hr-b0-" -#define IWL_QU_B_JF_B_FW_PRE "iwlwifi-Qu-b0-jf-b0-" -#define IWL_QU_C_JF_B_FW_PRE "iwlwifi-Qu-c0-jf-b0-" -#define IWL_QUZ_A_HR_B_FW_PRE "iwlwifi-QuZ-a0-hr-b0-" -#define IWL_QUZ_A_JF_B_FW_PRE "iwlwifi-QuZ-a0-jf-b0-" -#define IWL_QNJ_B_JF_B_FW_PRE "iwlwifi-QuQnj-b0-jf-b0-" -#define IWL_CC_A_FW_PRE "iwlwifi-cc-a0-" -#define IWL_SO_A_JF_B_FW_PRE "iwlwifi-so-a0-jf-b0-" -#define IWL_SO_A_HR_B_FW_PRE "iwlwifi-so-a0-hr-b0-" -#define IWL_SO_A_GF_A_FW_PRE "iwlwifi-so-a0-gf-a0-" -#define IWL_TY_A_GF_A_FW_PRE "iwlwifi-ty-a0-gf-a0-" -#define IWL_SO_A_GF4_A_FW_PRE "iwlwifi-so-a0-gf4-a0-" -#define IWL_SO_A_MR_A_FW_PRE "iwlwifi-so-a0-mr-a0-" -#define IWL_SNJ_A_GF4_A_FW_PRE "iwlwifi-SoSnj-a0-gf4-a0-" -#define IWL_SNJ_A_GF_A_FW_PRE "iwlwifi-SoSnj-a0-gf-a0-" -#define IWL_SNJ_A_HR_B_FW_PRE "iwlwifi-SoSnj-a0-hr-b0-" -#define IWL_SNJ_A_JF_B_FW_PRE "iwlwifi-SoSnj-a0-jf-b0-" -#define IWL_MA_A_HR_B_FW_PRE "iwlwifi-ma-a0-hr-b0-" -#define IWL_MA_A_GF_A_FW_PRE "iwlwifi-ma-a0-gf-a0-" -#define IWL_MA_A_GF4_A_FW_PRE "iwlwifi-ma-a0-gf4-a0-" -#define IWL_MA_A_MR_A_FW_PRE "iwlwifi-ma-a0-mr-a0-" -#define IWL_MA_A_FM_A_FW_PRE "iwlwifi-ma-a0-fm-a0-" -#define IWL_SNJ_A_MR_A_FW_PRE "iwlwifi-SoSnj-a0-mr-a0-" -#define IWL_BZ_A_HR_B_FW_PRE "iwlwifi-bz-a0-hr-b0-" -#define IWL_BZ_A_GF_A_FW_PRE "iwlwifi-bz-a0-gf-a0-" -#define IWL_BZ_A_GF4_A_FW_PRE "iwlwifi-bz-a0-gf4-a0-" -#define IWL_BZ_A_MR_A_FW_PRE "iwlwifi-bz-a0-mr-a0-" -#define IWL_BZ_A_FM_A_FW_PRE "iwlwifi-bz-a0-fm-a0-" -#define IWL_GL_A_FM_A_FW_PRE "iwlwifi-gl-a0-fm-a0-" -#define IWL_BZ_Z_GF_A_FW_PRE "iwlwifi-bz-z0-gf-a0-" -#define IWL_BNJ_A_FM_A_FW_PRE "iwlwifi-BzBnj-a0-fm-a0-" -#define IWL_BNJ_A_FM4_A_FW_PRE "iwlwifi-BzBnj-a0-fm4-a0-" -#define IWL_BNJ_A_GF_A_FW_PRE "iwlwifi-BzBnj-a0-gf-a0-" -#define IWL_BNJ_A_GF4_A_FW_PRE "iwlwifi-BzBnj-a0-gf4-a0-" -#define IWL_BNJ_A_HR_B_FW_PRE "iwlwifi-BzBnj-a0-hr-b0-" - +#define IWL_QU_B_HR_B_FW_PRE "iwlwifi-Qu-b0-hr-b0" +#define IWL_QU_C_HR_B_FW_PRE "iwlwifi-Qu-c0-hr-b0" +#define IWL_QU_B_JF_B_FW_PRE "iwlwifi-Qu-b0-jf-b0" +#define IWL_QU_C_JF_B_FW_PRE "iwlwifi-Qu-c0-jf-b0" +#define IWL_QUZ_A_HR_B_FW_PRE "iwlwifi-QuZ-a0-hr-b0" +#define IWL_QUZ_A_JF_B_FW_PRE "iwlwifi-QuZ-a0-jf-b0" +#define IWL_CC_A_FW_PRE "iwlwifi-cc-a0" #define IWL_QU_B_HR_B_MODULE_FIRMWARE(api) \ - IWL_QU_B_HR_B_FW_PRE __stringify(api) ".ucode" -#define IWL_QNJ_B_HR_B_MODULE_FIRMWARE(api) \ - IWL_QNJ_B_HR_B_FW_PRE __stringify(api) ".ucode" + IWL_QU_B_HR_B_FW_PRE "-" __stringify(api) ".ucode" #define IWL_QUZ_A_HR_B_MODULE_FIRMWARE(api) \ - IWL_QUZ_A_HR_B_FW_PRE __stringify(api) ".ucode" + IWL_QUZ_A_HR_B_FW_PRE "-" __stringify(api) ".ucode" #define IWL_QUZ_A_JF_B_MODULE_FIRMWARE(api) \ - IWL_QUZ_A_JF_B_FW_PRE __stringify(api) ".ucode" + IWL_QUZ_A_JF_B_FW_PRE "-" __stringify(api) ".ucode" #define IWL_QU_C_HR_B_MODULE_FIRMWARE(api) \ - IWL_QU_C_HR_B_FW_PRE __stringify(api) ".ucode" + IWL_QU_C_HR_B_FW_PRE "-" __stringify(api) ".ucode" #define IWL_QU_B_JF_B_MODULE_FIRMWARE(api) \ - IWL_QU_B_JF_B_FW_PRE __stringify(api) ".ucode" -#define IWL_QNJ_B_JF_B_MODULE_FIRMWARE(api) \ - IWL_QNJ_B_JF_B_FW_PRE __stringify(api) ".ucode" + IWL_QU_B_JF_B_FW_PRE "-" __stringify(api) ".ucode" #define IWL_CC_A_MODULE_FIRMWARE(api) \ - IWL_CC_A_FW_PRE __stringify(api) ".ucode" -#define IWL_SO_A_JF_B_MODULE_FIRMWARE(api) \ - IWL_SO_A_JF_B_FW_PRE __stringify(api) ".ucode" -#define IWL_SO_A_HR_B_MODULE_FIRMWARE(api) \ - IWL_SO_A_HR_B_FW_PRE __stringify(api) ".ucode" -#define IWL_SO_A_GF_A_MODULE_FIRMWARE(api) \ - IWL_SO_A_GF_A_FW_PRE __stringify(api) ".ucode" -#define IWL_TY_A_GF_A_MODULE_FIRMWARE(api) \ - IWL_TY_A_GF_A_FW_PRE __stringify(api) ".ucode" -#define IWL_SNJ_A_GF4_A_MODULE_FIRMWARE(api) \ - IWL_SNJ_A_GF4_A_FW_PRE __stringify(api) ".ucode" -#define IWL_SNJ_A_GF_A_MODULE_FIRMWARE(api) \ - IWL_SNJ_A_GF_A_FW_PRE __stringify(api) ".ucode" -#define IWL_SNJ_A_HR_B_MODULE_FIRMWARE(api) \ - IWL_SNJ_A_HR_B_FW_PRE __stringify(api) ".ucode" -#define IWL_SNJ_A_JF_B_MODULE_FIRMWARE(api) \ - IWL_SNJ_A_JF_B_FW_PRE __stringify(api) ".ucode" -#define IWL_MA_A_HR_B_FW_MODULE_FIRMWARE(api) \ - IWL_MA_A_HR_B_FW_PRE __stringify(api) ".ucode" -#define IWL_MA_A_GF_A_FW_MODULE_FIRMWARE(api) \ - IWL_MA_A_GF_A_FW_PRE __stringify(api) ".ucode" -#define IWL_MA_A_GF4_A_FW_MODULE_FIRMWARE(api) \ - IWL_MA_A_GF4_A_FW_PRE __stringify(api) ".ucode" -#define IWL_MA_A_MR_A_FW_MODULE_FIRMWARE(api) \ - IWL_MA_A_MR_A_FW_PRE __stringify(api) ".ucode" -#define IWL_MA_A_FM_A_FW_MODULE_FIRMWARE(api) \ - IWL_MA_A_FM_A_FW_PRE __stringify(api) ".ucode" -#define IWL_SNJ_A_MR_A_MODULE_FIRMWARE(api) \ - IWL_SNJ_A_MR_A_FW_PRE __stringify(api) ".ucode" -#define IWL_BZ_A_HR_B_MODULE_FIRMWARE(api) \ - IWL_BZ_A_HR_B_FW_PRE __stringify(api) ".ucode" -#define IWL_BZ_A_GF_A_MODULE_FIRMWARE(api) \ - IWL_BZ_A_GF_A_FW_PRE __stringify(api) ".ucode" -#define IWL_BZ_A_GF4_A_MODULE_FIRMWARE(api) \ - IWL_BZ_A_GF4_A_FW_PRE __stringify(api) ".ucode" -#define IWL_BZ_A_MR_A_MODULE_FIRMWARE(api) \ - IWL_BZ_A_MR_A_FW_PRE __stringify(api) ".ucode" -#define IWL_BZ_A_FM_A_MODULE_FIRMWARE(api) \ - IWL_BZ_A_FM_A_FW_PRE __stringify(api) ".ucode" -#define IWL_GL_A_FM_A_MODULE_FIRMWARE(api) \ - IWL_GL_A_FM_A_FW_PRE __stringify(api) ".ucode" -#define IWL_BNJ_A_FM_A_MODULE_FIRMWARE(api) \ - IWL_BNJ_A_FM_A_FW_PRE __stringify(api) ".ucode" -#define IWL_BNJ_A_FM4_A_MODULE_FIRMWARE(api) \ - IWL_BNJ_A_FM4_A_FW_PRE __stringify(api) ".ucode" -#define IWL_BNJ_A_GF_A_MODULE_FIRMWARE(api) \ - IWL_BNJ_A_GF_A_FW_PRE __stringify(api) ".ucode" -#define IWL_BNJ_A_GF4_A_MODULE_FIRMWARE(api) \ - IWL_BNJ_A_GF4_A_FW_PRE __stringify(api) ".ucode" -#define IWL_BNJ_A_HR_B_MODULE_FIRMWARE(api) \ - IWL_BNJ_A_HR_B_FW_PRE __stringify(api) ".ucode" + IWL_CC_A_FW_PRE "-" __stringify(api) ".ucode" static const struct iwl_base_params iwl_22000_base_params = { .eeprom_size = OTP_LOW_IMAGE_SIZE_32K, @@ -144,19 +59,7 @@ static const struct iwl_base_params iwl_22000_base_params = { .pcie_l1_allowed = true, }; -static const struct iwl_base_params iwl_ax210_base_params = { - .eeprom_size = OTP_LOW_IMAGE_SIZE_32K, - .num_of_queues = 512, - .max_tfd_queue_size = 65536, - .shadow_ram_support = true, - .led_compensation = 57, - .wd_timeout = IWL_LONG_WD_TIMEOUT, - .max_event_log_size = 512, - .shadow_reg_enable = true, - .pcie_l1_allowed = true, -}; - -static const struct iwl_ht_params iwl_22000_ht_params = { +const struct iwl_ht_params iwl_22000_ht_params = { .stbc = true, .ldpc = true, .ht40_bands = BIT(NL80211_BAND_2GHZ) | BIT(NL80211_BAND_5GHZ) | @@ -164,7 +67,6 @@ static const struct iwl_ht_params iwl_22000_ht_params = { }; #define IWL_DEVICE_22000_COMMON \ - .ucode_api_max = IWL_22000_UCODE_API_MAX, \ .ucode_api_min = IWL_22000_UCODE_API_MIN, \ .led_mode = IWL_LED_RF_STATE, \ .nvm_hw_section_num = 10, \ @@ -182,7 +84,6 @@ static const struct iwl_ht_params iwl_22000_ht_params = { .mac_addr_from_csr = 0x380, \ .ht_params = &iwl_22000_ht_params, \ .nvm_ver = IWL_22000_NVM_VERSION, \ - .trans.use_tfh = true, \ .trans.rf_id = true, \ .trans.gen2 = true, \ .nvm_type = IWL_NVM_EXT, \ @@ -203,6 +104,7 @@ static const struct iwl_ht_params iwl_22000_ht_params = { #define IWL_DEVICE_22500 \ IWL_DEVICE_22000_COMMON, \ + .ucode_api_max = IWL_22000_UCODE_API_MAX, \ .trans.device_family = IWL_DEVICE_FAMILY_22000, \ .trans.base_params = &iwl_22000_base_params, \ .gp2_reg_addr = 0xa02c68, \ @@ -217,108 +119,8 @@ static const struct iwl_ht_params iwl_22000_ht_params = { }, \ } -#define IWL_DEVICE_AX210 \ - IWL_DEVICE_22000_COMMON, \ - .trans.umac_prph_offset = 0x300000, \ - .trans.device_family = IWL_DEVICE_FAMILY_AX210, \ - .trans.base_params = &iwl_ax210_base_params, \ - .min_txq_size = 128, \ - .gp2_reg_addr = 0xd02c68, \ - .min_ba_txq_size = IWL_DEFAULT_QUEUE_SIZE_HE, \ - .mon_dram_regs = { \ - .write_ptr = { \ - .addr = DBGC_CUR_DBGBUF_STATUS, \ - .mask = DBGC_CUR_DBGBUF_STATUS_OFFSET_MSK, \ - }, \ - .cycle_cnt = { \ - .addr = DBGC_DBGBUF_WRAP_AROUND, \ - .mask = 0xffffffff, \ - }, \ - .cur_frag = { \ - .addr = DBGC_CUR_DBGBUF_STATUS, \ - .mask = DBGC_CUR_DBGBUF_STATUS_IDX_MSK, \ - }, \ - } - -#define IWL_DEVICE_BZ_COMMON \ - .ucode_api_max = IWL_22000_UCODE_API_MAX, \ - .ucode_api_min = IWL_22000_UCODE_API_MIN, \ - .led_mode = IWL_LED_RF_STATE, \ - .nvm_hw_section_num = 10, \ - .non_shared_ant = ANT_B, \ - .dccm_offset = IWL_22000_DCCM_OFFSET, \ - .dccm_len = IWL_22000_DCCM_LEN, \ - .dccm2_offset = IWL_22000_DCCM2_OFFSET, \ - .dccm2_len = IWL_22000_DCCM2_LEN, \ - .smem_offset = IWL_22000_SMEM_OFFSET, \ - .smem_len = IWL_22000_SMEM_LEN, \ - .features = IWL_TX_CSUM_NETIF_FLAGS_BZ | NETIF_F_RXCSUM, \ - .apmg_not_supported = true, \ - .trans.mq_rx_supported = true, \ - .vht_mu_mimo_supported = true, \ - .mac_addr_from_csr = 0x30, \ - .ht_params = &iwl_22000_ht_params, \ - .nvm_ver = IWL_22000_NVM_VERSION, \ - .trans.use_tfh = true, \ - .trans.rf_id = true, \ - .trans.gen2 = true, \ - .nvm_type = IWL_NVM_EXT, \ - .dbgc_supported = true, \ - .min_umac_error_event_table = 0x400000, \ - .d3_debug_data_base_addr = 0x401000, \ - .d3_debug_data_length = 60 * 1024, \ - .mon_smem_regs = { \ - .write_ptr = { \ - .addr = LDBG_M2S_BUF_WPTR, \ - .mask = LDBG_M2S_BUF_WPTR_VAL_MSK, \ - }, \ - .cycle_cnt = { \ - .addr = LDBG_M2S_BUF_WRAP_CNT, \ - .mask = LDBG_M2S_BUF_WRAP_CNT_VAL_MSK, \ - }, \ - } - -#define IWL_DEVICE_BZ \ - IWL_DEVICE_BZ_COMMON, \ - .trans.umac_prph_offset = 0x300000, \ - .trans.device_family = IWL_DEVICE_FAMILY_BZ, \ - .trans.base_params = &iwl_ax210_base_params, \ - .min_txq_size = 128, \ - .gp2_reg_addr = 0xd02c68, \ - .min_ba_txq_size = IWL_DEFAULT_QUEUE_SIZE_EHT, \ - .mon_dram_regs = { \ - .write_ptr = { \ - .addr = DBGC_CUR_DBGBUF_STATUS, \ - .mask = DBGC_CUR_DBGBUF_STATUS_OFFSET_MSK, \ - }, \ - .cycle_cnt = { \ - .addr = DBGC_DBGBUF_WRAP_AROUND, \ - .mask = 0xffffffff, \ - }, \ - .cur_frag = { \ - .addr = DBGC_CUR_DBGBUF_STATUS, \ - .mask = DBGC_CUR_DBGBUF_STATUS_IDX_MSK, \ - }, \ - }, \ - .mon_dbgi_regs = { \ - .write_ptr = { \ - .addr = DBGI_SRAM_FIFO_POINTERS, \ - .mask = DBGI_SRAM_FIFO_POINTERS_WR_PTR_MSK, \ - }, \ - } - -const struct iwl_cfg_trans_params iwl_qnj_trans_cfg = { - .mq_rx_supported = true, - .use_tfh = true, - .rf_id = true, - .gen2 = true, - .device_family = IWL_DEVICE_FAMILY_22000, - .base_params = &iwl_22000_base_params, -}; - const struct iwl_cfg_trans_params iwl_qu_trans_cfg = { .mq_rx_supported = true, - .use_tfh = true, .rf_id = true, .gen2 = true, .device_family = IWL_DEVICE_FAMILY_22000, @@ -330,7 +132,6 @@ const struct iwl_cfg_trans_params iwl_qu_trans_cfg = { const struct iwl_cfg_trans_params iwl_qu_medium_latency_trans_cfg = { .mq_rx_supported = true, - .use_tfh = true, .rf_id = true, .gen2 = true, .device_family = IWL_DEVICE_FAMILY_22000, @@ -342,7 +143,6 @@ const struct iwl_cfg_trans_params iwl_qu_medium_latency_trans_cfg = { const struct iwl_cfg_trans_params iwl_qu_long_latency_trans_cfg = { .mq_rx_supported = true, - .use_tfh = true, .rf_id = true, .gen2 = true, .device_family = IWL_DEVICE_FAMILY_22000, @@ -353,59 +153,6 @@ const struct iwl_cfg_trans_params iwl_qu_long_latency_trans_cfg = { .ltr_delay = IWL_CFG_TRANS_LTR_DELAY_2500US, }; -const struct iwl_cfg_trans_params iwl_snj_trans_cfg = { - .mq_rx_supported = true, - .use_tfh = true, - .rf_id = true, - .gen2 = true, - .device_family = IWL_DEVICE_FAMILY_AX210, - .base_params = &iwl_ax210_base_params, - .umac_prph_offset = 0x300000, -}; - -const struct iwl_cfg_trans_params iwl_so_trans_cfg = { - .mq_rx_supported = true, - .use_tfh = true, - .rf_id = true, - .gen2 = true, - .device_family = IWL_DEVICE_FAMILY_AX210, - .base_params = &iwl_ax210_base_params, - .umac_prph_offset = 0x300000, - .integrated = true, - /* TODO: the following values need to be checked */ - .xtal_latency = 500, - .ltr_delay = IWL_CFG_TRANS_LTR_DELAY_200US, -}; - -const struct iwl_cfg_trans_params iwl_so_long_latency_trans_cfg = { - .mq_rx_supported = true, - .use_tfh = true, - .rf_id = true, - .gen2 = true, - .device_family = IWL_DEVICE_FAMILY_AX210, - .base_params = &iwl_ax210_base_params, - .umac_prph_offset = 0x300000, - .integrated = true, - .low_latency_xtal = true, - .xtal_latency = 12000, - .ltr_delay = IWL_CFG_TRANS_LTR_DELAY_2500US, -}; - -const struct iwl_cfg_trans_params iwl_so_long_latency_imr_trans_cfg = { - .mq_rx_supported = true, - .use_tfh = true, - .rf_id = true, - .gen2 = true, - .device_family = IWL_DEVICE_FAMILY_AX210, - .base_params = &iwl_ax210_base_params, - .umac_prph_offset = 0x300000, - .integrated = true, - .low_latency_xtal = true, - .xtal_latency = 12000, - .ltr_delay = IWL_CFG_TRANS_LTR_DELAY_2500US, - .imr_enabled = true, -}; - /* * If the device doesn't support HE, no need to have that many buffers. * 22000 devices can split multiple frames into a single RB, so fewer are @@ -415,7 +162,6 @@ const struct iwl_cfg_trans_params iwl_so_long_latency_imr_trans_cfg = { */ #define IWL_NUM_RBDS_NON_HE 512 #define IWL_NUM_RBDS_22000_HE 2048 -#define IWL_NUM_RBDS_AX210_HE 4096 /* * All JF radio modules are part of the 9000 series, but the MAC part @@ -446,63 +192,20 @@ const struct iwl_cfg iwl9560_quz_a0_jf_b0_cfg = { .num_rbds = IWL_NUM_RBDS_NON_HE, }; -const struct iwl_cfg iwl9560_qnj_b0_jf_b0_cfg = { - .fw_name_pre = IWL_QNJ_B_JF_B_FW_PRE, - IWL_DEVICE_22500, - /* - * This device doesn't support receiving BlockAck with a large bitmap - * so we need to restrict the size of transmitted aggregation to the - * HT size; mac80211 would otherwise pick the HE max (256) by default. - */ - .max_tx_agg_size = IEEE80211_MAX_AMPDU_BUF_HT, - .num_rbds = IWL_NUM_RBDS_NON_HE, -}; - const struct iwl_cfg_trans_params iwl_ax200_trans_cfg = { .device_family = IWL_DEVICE_FAMILY_22000, .base_params = &iwl_22000_base_params, .mq_rx_supported = true, - .use_tfh = true, .rf_id = true, .gen2 = true, .bisr_workaround = 1, }; -const struct iwl_cfg_trans_params iwl_ma_trans_cfg = { - .device_family = IWL_DEVICE_FAMILY_AX210, - .base_params = &iwl_ax210_base_params, - .mq_rx_supported = true, - .use_tfh = true, - .rf_id = true, - .gen2 = true, - .integrated = true, - .umac_prph_offset = 0x300000 -}; - -const struct iwl_cfg_trans_params iwl_bz_trans_cfg = { - .device_family = IWL_DEVICE_FAMILY_BZ, - .base_params = &iwl_ax210_base_params, - .mq_rx_supported = true, - .use_tfh = true, - .rf_id = true, - .gen2 = true, - .integrated = true, - .umac_prph_offset = 0x300000, - .xtal_latency = 12000, - .low_latency_xtal = true, - .ltr_delay = IWL_CFG_TRANS_LTR_DELAY_2500US, -}; - const char iwl_ax101_name[] = "Intel(R) Wi-Fi 6 AX101"; const char iwl_ax200_name[] = "Intel(R) Wi-Fi 6 AX200 160MHz"; const char iwl_ax201_name[] = "Intel(R) Wi-Fi 6 AX201 160MHz"; const char iwl_ax203_name[] = "Intel(R) Wi-Fi 6 AX203"; const char iwl_ax204_name[] = "Intel(R) Wi-Fi 6 AX204 160MHz"; -const char iwl_ax211_name[] = "Intel(R) Wi-Fi 6E AX211 160MHz"; -const char iwl_ax221_name[] = "Intel(R) Wi-Fi 6E AX221 160MHz"; -const char iwl_ax231_name[] = "Intel(R) Wi-Fi 6E AX231 160MHz"; -const char iwl_ax411_name[] = "Intel(R) Wi-Fi 6E AX411 160MHz"; -const char iwl_bz_name[] = "Intel(R) TBD Bz device"; const char iwl_ax200_killer_1650w_name[] = "Killer(R) Wi-Fi 6 AX1650w 160MHz Wireless Network Adapter (200D2W)"; @@ -512,18 +215,6 @@ const char iwl_ax201_killer_1650s_name[] = "Killer(R) Wi-Fi 6 AX1650s 160MHz Wireless Network Adapter (201D2W)"; const char iwl_ax201_killer_1650i_name[] = "Killer(R) Wi-Fi 6 AX1650i 160MHz Wireless Network Adapter (201NGW)"; -const char iwl_ax210_killer_1675w_name[] = - "Killer(R) Wi-Fi 6E AX1675w 160MHz Wireless Network Adapter (210D2W)"; -const char iwl_ax210_killer_1675x_name[] = - "Killer(R) Wi-Fi 6E AX1675x 160MHz Wireless Network Adapter (210NGW)"; -const char iwl_ax211_killer_1675s_name[] = - "Killer(R) Wi-Fi 6E AX1675s 160MHz Wireless Network Adapter (211NGW)"; -const char iwl_ax211_killer_1675i_name[] = - "Killer(R) Wi-Fi 6E AX1675i 160MHz Wireless Network Adapter (211NGW)"; -const char iwl_ax411_killer_1690s_name[] = - "Killer(R) Wi-Fi 6E AX1690s 160MHz Wireless Network Adapter (411D2W)"; -const char iwl_ax411_killer_1690i_name[] = - "Killer(R) Wi-Fi 6E AX1690i 160MHz Wireless Network Adapter (411NGW)"; const struct iwl_cfg iwl_qu_b0_hr1_b0 = { .fw_name_pre = IWL_QU_B_HR_B_FW_PRE, @@ -717,168 +408,6 @@ const struct iwl_cfg killer1650i_2ax_cfg_qu_c0_hr_b0 = { .num_rbds = IWL_NUM_RBDS_22000_HE, }; -const struct iwl_cfg iwl_qnj_b0_hr_b0_cfg = { - .fw_name_pre = IWL_QNJ_B_HR_B_FW_PRE, - IWL_DEVICE_22500, - /* - * This device doesn't support receiving BlockAck with a large bitmap - * so we need to restrict the size of transmitted aggregation to the - * HT size; mac80211 would otherwise pick the HE max (256) by default. - */ - .max_tx_agg_size = IEEE80211_MAX_AMPDU_BUF_HT, - .num_rbds = IWL_NUM_RBDS_22000_HE, -}; - -const struct iwl_cfg iwlax210_2ax_cfg_so_jf_b0 = { - .name = "Intel(R) Wireless-AC 9560 160MHz", - .fw_name_pre = IWL_SO_A_JF_B_FW_PRE, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_NON_HE, -}; - -const struct iwl_cfg iwlax211_2ax_cfg_so_gf_a0 = { - .name = iwl_ax211_name, - .fw_name_pre = IWL_SO_A_GF_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwlax211_2ax_cfg_so_gf_a0_long = { - .name = iwl_ax211_name, - .fw_name_pre = IWL_SO_A_GF_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, - .trans.xtal_latency = 12000, - .trans.low_latency_xtal = true, -}; - -const struct iwl_cfg iwlax210_2ax_cfg_ty_gf_a0 = { - .name = "Intel(R) Wi-Fi 6 AX210 160MHz", - .fw_name_pre = IWL_TY_A_GF_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwlax411_2ax_cfg_so_gf4_a0 = { - .name = iwl_ax411_name, - .fw_name_pre = IWL_SO_A_GF4_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwlax411_2ax_cfg_so_gf4_a0_long = { - .name = iwl_ax411_name, - .fw_name_pre = IWL_SO_A_GF4_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, - .trans.xtal_latency = 12000, - .trans.low_latency_xtal = true, -}; - -const struct iwl_cfg iwlax411_2ax_cfg_sosnj_gf4_a0 = { - .name = iwl_ax411_name, - .fw_name_pre = IWL_SNJ_A_GF4_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwlax211_cfg_snj_gf_a0 = { - .name = iwl_ax211_name, - .fw_name_pre = IWL_SNJ_A_GF_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_snj_hr_b0 = { - .fw_name_pre = IWL_SNJ_A_HR_B_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_snj_a0_jf_b0 = { - .fw_name_pre = IWL_SNJ_A_JF_B_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_ma_a0_hr_b0 = { - .fw_name_pre = IWL_MA_A_HR_B_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_ma_a0_gf_a0 = { - .fw_name_pre = IWL_MA_A_GF_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_ma_a0_gf4_a0 = { - .fw_name_pre = IWL_MA_A_GF4_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_ma_a0_mr_a0 = { - .fw_name_pre = IWL_MA_A_MR_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_ma_a0_ms_a0 = { - .fw_name_pre = IWL_MA_A_MR_A_FW_PRE, - .uhb_supported = false, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_so_a0_ms_a0 = { - .fw_name_pre = IWL_SO_A_MR_A_FW_PRE, - .uhb_supported = false, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_ma_a0_fm_a0 = { - .fw_name_pre = IWL_MA_A_FM_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_snj_a0_mr_a0 = { - .fw_name_pre = IWL_SNJ_A_MR_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_snj_a0_ms_a0 = { - .fw_name_pre = IWL_SNJ_A_MR_A_FW_PRE, - .uhb_supported = false, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_so_a0_hr_a0 = { - .fw_name_pre = IWL_SO_A_HR_B_FW_PRE, - IWL_DEVICE_AX210, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - const struct iwl_cfg iwl_cfg_quz_a0_hr_b0 = { .fw_name_pre = IWL_QUZ_A_HR_B_FW_PRE, IWL_DEVICE_22500, @@ -891,119 +420,9 @@ const struct iwl_cfg iwl_cfg_quz_a0_hr_b0 = { .num_rbds = IWL_NUM_RBDS_22000_HE, }; -const struct iwl_cfg iwl_cfg_bz_a0_hr_b0 = { - .fw_name_pre = IWL_BZ_A_HR_B_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_BZ, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_bz_a0_gf_a0 = { - .fw_name_pre = IWL_BZ_A_GF_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_BZ, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_bz_a0_gf4_a0 = { - .fw_name_pre = IWL_BZ_A_GF4_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_BZ, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_bz_a0_mr_a0 = { - .fw_name_pre = IWL_BZ_A_MR_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_BZ, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_bz_a0_fm_a0 = { - .fw_name_pre = IWL_BZ_A_FM_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_BZ, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_gl_a0_fm_a0 = { - .fw_name_pre = IWL_GL_A_FM_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_BZ, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_bz_z0_gf_a0 = { - .fw_name_pre = IWL_BZ_Z_GF_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_BZ, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_bnj_a0_fm_a0 = { - .fw_name_pre = IWL_BNJ_A_FM_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_BZ, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_bnj_a0_fm4_a0 = { - .fw_name_pre = IWL_BNJ_A_FM4_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_BZ, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_bnj_a0_gf_a0 = { - .fw_name_pre = IWL_BNJ_A_GF_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_BZ, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_bnj_a0_gf4_a0 = { - .fw_name_pre = IWL_BNJ_A_GF4_A_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_BZ, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; - -const struct iwl_cfg iwl_cfg_bnj_a0_hr_b0 = { - .fw_name_pre = IWL_BNJ_A_HR_B_FW_PRE, - .uhb_supported = true, - IWL_DEVICE_BZ, - .num_rbds = IWL_NUM_RBDS_AX210_HE, -}; MODULE_FIRMWARE(IWL_QU_B_HR_B_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_QNJ_B_HR_B_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); MODULE_FIRMWARE(IWL_QU_C_HR_B_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); MODULE_FIRMWARE(IWL_QU_B_JF_B_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); MODULE_FIRMWARE(IWL_QUZ_A_HR_B_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); MODULE_FIRMWARE(IWL_QUZ_A_JF_B_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_QNJ_B_JF_B_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); MODULE_FIRMWARE(IWL_CC_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_SO_A_JF_B_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_SO_A_HR_B_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_SO_A_GF_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_TY_A_GF_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_SNJ_A_GF4_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_SNJ_A_GF_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_SNJ_A_HR_B_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_SNJ_A_JF_B_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_MA_A_HR_B_FW_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_MA_A_GF_A_FW_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_MA_A_GF4_A_FW_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_MA_A_MR_A_FW_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_MA_A_FM_A_FW_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_SNJ_A_MR_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_BZ_A_HR_B_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_BZ_A_GF_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_BZ_A_GF4_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_BZ_A_MR_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_BZ_A_FM_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_GL_A_FM_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_BNJ_A_FM_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_BNJ_A_FM4_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_BNJ_A_GF_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_BNJ_A_GF4_A_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); -MODULE_FIRMWARE(IWL_BNJ_A_HR_B_MODULE_FIRMWARE(IWL_22000_UCODE_API_MAX)); diff --git a/sys/contrib/dev/iwlwifi/cfg/7000.c b/sys/contrib/dev/iwlwifi/cfg/7000.c index b24dc5523a52..4e2afdedf4c6 100644 --- a/sys/contrib/dev/iwlwifi/cfg/7000.c +++ b/sys/contrib/dev/iwlwifi/cfg/7000.c @@ -1,6 +1,6 @@ // SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause /* - * Copyright (C) 2012-2014, 2018-2020 Intel Corporation + * Copyright (C) 2012-2014, 2018-2020, 2023 Intel Corporation * Copyright (C) 2013-2014 Intel Mobile Communications GmbH * Copyright (C) 2015 Intel Deutschland GmbH */ @@ -34,20 +34,20 @@ #define IWL3160_DCCM_LEN 0x10000 #define IWL7265_DCCM_LEN 0x17A00 -#define IWL7260_FW_PRE "iwlwifi-7260-" -#define IWL7260_MODULE_FIRMWARE(api) IWL7260_FW_PRE __stringify(api) ".ucode" +#define IWL7260_FW_PRE "iwlwifi-7260" +#define IWL7260_MODULE_FIRMWARE(api) IWL7260_FW_PRE "-" __stringify(api) ".ucode" -#define IWL3160_FW_PRE "iwlwifi-3160-" -#define IWL3160_MODULE_FIRMWARE(api) IWL3160_FW_PRE __stringify(api) ".ucode" +#define IWL3160_FW_PRE "iwlwifi-3160" +#define IWL3160_MODULE_FIRMWARE(api) IWL3160_FW_PRE "-" __stringify(api) ".ucode" -#define IWL3168_FW_PRE "iwlwifi-3168-" -#define IWL3168_MODULE_FIRMWARE(api) IWL3168_FW_PRE __stringify(api) ".ucode" +#define IWL3168_FW_PRE "iwlwifi-3168" +#define IWL3168_MODULE_FIRMWARE(api) IWL3168_FW_PRE "-" __stringify(api) ".ucode" -#define IWL7265_FW_PRE "iwlwifi-7265-" -#define IWL7265_MODULE_FIRMWARE(api) IWL7265_FW_PRE __stringify(api) ".ucode" +#define IWL7265_FW_PRE "iwlwifi-7265" +#define IWL7265_MODULE_FIRMWARE(api) IWL7265_FW_PRE "-" __stringify(api) ".ucode" -#define IWL7265D_FW_PRE "iwlwifi-7265D-" -#define IWL7265D_MODULE_FIRMWARE(api) IWL7265D_FW_PRE __stringify(api) ".ucode" +#define IWL7265D_FW_PRE "iwlwifi-7265D" +#define IWL7265D_MODULE_FIRMWARE(api) IWL7265D_FW_PRE "-" __stringify(api) ".ucode" static const struct iwl_base_params iwl7000_base_params = { .eeprom_size = OTP_LOW_IMAGE_SIZE_16K, diff --git a/sys/contrib/dev/iwlwifi/cfg/8000.c b/sys/contrib/dev/iwlwifi/cfg/8000.c index a6454287d506..d09cf8d7dc01 100644 --- a/sys/contrib/dev/iwlwifi/cfg/8000.c +++ b/sys/contrib/dev/iwlwifi/cfg/8000.c @@ -1,6 +1,6 @@ // SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause /* - * Copyright (C) 2014, 2018-2020 Intel Corporation + * Copyright (C) 2014, 2018-2020, 2023 Intel Corporation * Copyright (C) 2014-2015 Intel Mobile Communications GmbH * Copyright (C) 2016 Intel Deutschland GmbH */ @@ -27,13 +27,13 @@ #define IWL8260_SMEM_OFFSET 0x400000 #define IWL8260_SMEM_LEN 0x68000 -#define IWL8000_FW_PRE "iwlwifi-8000C-" +#define IWL8000_FW_PRE "iwlwifi-8000C" #define IWL8000_MODULE_FIRMWARE(api) \ - IWL8000_FW_PRE __stringify(api) ".ucode" + IWL8000_FW_PRE "-" __stringify(api) ".ucode" -#define IWL8265_FW_PRE "iwlwifi-8265-" +#define IWL8265_FW_PRE "iwlwifi-8265" #define IWL8265_MODULE_FIRMWARE(api) \ - IWL8265_FW_PRE __stringify(api) ".ucode" + IWL8265_FW_PRE "-" __stringify(api) ".ucode" #define DEFAULT_NVM_FILE_FAMILY_8000C "nvmData-8000C" diff --git a/sys/contrib/dev/iwlwifi/cfg/9000.c b/sys/contrib/dev/iwlwifi/cfg/9000.c index 7a7ca06d46c1..0130d9a9b78b 100644 --- a/sys/contrib/dev/iwlwifi/cfg/9000.c +++ b/sys/contrib/dev/iwlwifi/cfg/9000.c @@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause /* * Copyright (C) 2015-2017 Intel Deutschland GmbH - * Copyright (C) 2018-2021 Intel Corporation + * Copyright (C) 2018-2021, 2023 Intel Corporation */ #include *** 31085 LINES SKIPPED *** From nobody Fri Oct 6 14:25:19 2023 X-Original-To: dev-commits-src-branches@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 4S29gh0H1jz4wgWS; Fri, 6 Oct 2023 14:25: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gg4l7wz3RSM; Fri, 6 Oct 2023 14:25:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602319; 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=ut8HXBNzq2S3Kmnhdl/fXIWoNJDk7I7vcGwNfXvFQIE=; b=yUlfzQlmiIK+TwLCfyUkgB/UEYk+czgXkznY05xqxMB8RuZIWy68SMpoGTS2Y2y026cffV BH5vKND3hHW1QIRQ18KK40dCGHNhohNmFEB/0mVkeLIuYzkkb6ByZ26KMyRtQw1qiJiL4s CP8y2iVso40roo84U7JFol2I7OTRN2vZ8yhGTDhkfPqsjuwnjQ6yQmqtNftjGCJ4kB+ohr r0D/fokwL9nymCnCoiosm0nKQFXMXWg4/wlg0nvVUO9ZEcYPZvI4J6ao0GcfBycZMrDSh9 N2XQpsYS8hR196jehaITiwdBZBG9W0SL2mDLkcZzgNIIj1eEGIMe2H1qe6WpMA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602319; a=rsa-sha256; cv=none; b=n5+glywbfH21f3wpGrmTKIdRftoDt+FOgzdCqf5aZlPjJ0nTCeaLtha8m4zgO/Orw56+I0 7FwbmbiAVye5GnvY29ZQbV7qfq21fL1S9AKv/JfBr5TL6bV1HPGdb5YEnHSd5pDwxf7NAA QDigseHumtRKuZTS5Q1Zg9AWXwF2xAhkfCALZtEc0eiyqj2r0QksenFTVWIEc04rh3mhDO 5MsCLE+9M47ouBjqR0yVGOHB0GGi+ygXAQ/hqLkpNyaj78dQbnQk4yKbl7zKI2pIj5vNSL SGsOSK68bOob87A/hFu3HpPgFsHr08Gc6zDjicRsQ0AwbsLr38SvRNOx99Q/MQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602319; 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=ut8HXBNzq2S3Kmnhdl/fXIWoNJDk7I7vcGwNfXvFQIE=; b=rn2XP15LOAggfoEYlPAdmW1kzXQg23b4j1tWf+kMxs/chlpkcd1Ilj18Xqp2r9W4GepTLd HhI/Zs0cblBqApidjmAKb4rb67F3C2GndYfdKAK0AHP9c0eHUgFRPeCeTaPo5vp5nBx46n tn8S6JZ1ILR/ZQaS5nF2oqYJyrnmsjoqhPIvLo3ipRVkOiUlignZFbQgYu+CiBFwOl989E T1dUIzeScP4yEpiRspV9dXpd0JcUD+sWnvJETZ3iX6vpDrm5euJlnyHCMSdBBTsKcipyD1 I+Mq7LgiKd1H2daKRQt1hL4/x8qJIl+IAOc0R1Sm3+yJFIo45RdhYIdG5bcUqA== 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 4S29gg3s1Jzrb3; Fri, 6 Oct 2023 14:25:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EPJER093676; Fri, 6 Oct 2023 14:25:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EPJRV093671; Fri, 6 Oct 2023 14:25:19 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:19 GMT Message-Id: <202310061425.396EPJRV093671@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: e504b5da3ef2 - stable/14 - iwlwifi firmware: update up-to -83 / updated -77 for others List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: e504b5da3ef2c24b4e09e7331e9628a8299540f6 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=e504b5da3ef2c24b4e09e7331e9628a8299540f6 commit e504b5da3ef2c24b4e09e7331e9628a8299540f6 Author: Bjoern A. Zeeb AuthorDate: 2023-06-11 00:45:37 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:41 +0000 iwlwifi firmware: update up-to -83 / updated -77 for others Firmware was obtained from linux-firmware at dfa11466cf000120d1551146fd5bf78c44941eda. Sponsored by: The FreeBSD Foundation (cherry picked from commit 027768a21217499dd85aba8608715a5bf66a7857) --- .../iwlwififw/iwlwifi-9000-pu-b0-jf-b0-46.ucode | Bin 1518788 -> 1518772 bytes .../iwlwififw/iwlwifi-9260-th-b0-jf-b0-46.ucode | Bin 1489548 -> 1489652 bytes ...hr-b0-73.ucode => iwlwifi-Qu-b0-hr-b0-77.ucode} | Bin 1369840 -> 1404704 bytes ...jf-b0-73.ucode => iwlwifi-Qu-b0-jf-b0-77.ucode} | Bin 1290220 -> 1322436 bytes ...hr-b0-73.ucode => iwlwifi-Qu-c0-hr-b0-77.ucode} | Bin 1369976 -> 1404720 bytes ...jf-b0-73.ucode => iwlwifi-Qu-c0-jf-b0-77.ucode} | Bin 1290100 -> 1322452 bytes ...r-b0-73.ucode => iwlwifi-QuZ-a0-hr-b0-77.ucode} | Bin 1369856 -> 1404840 bytes ...f-b0-73.ucode => iwlwifi-QuZ-a0-jf-b0-77.ucode} | Bin 1290084 -> 1321956 bytes ...lwifi-cc-a0-73.ucode => iwlwifi-cc-a0-77.ucode} | Bin 1333296 -> 1366144 bytes .../dev/iwlwififw/iwlwifi-so-a0-gf-a0-73.ucode | Bin 1563692 -> 0 bytes .../dev/iwlwififw/iwlwifi-so-a0-gf-a0-83.ucode | Bin 0 -> 1739988 bytes sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf-a0.pnvm | Bin 41808 -> 55580 bytes .../dev/iwlwififw/iwlwifi-so-a0-gf4-a0-73.ucode | Bin 1587800 -> 0 bytes .../dev/iwlwififw/iwlwifi-so-a0-gf4-a0-83.ucode | Bin 0 -> 1703968 bytes .../dev/iwlwififw/iwlwifi-so-a0-gf4-a0.pnvm | Bin 28064 -> 28064 bytes ...hr-b0-73.ucode => iwlwifi-so-a0-hr-b0-81.ucode} | Bin 1465208 -> 1539288 bytes ...jf-b0-73.ucode => iwlwifi-so-a0-jf-b0-77.ucode} | Bin 1409336 -> 1446036 bytes .../dev/iwlwififw/iwlwifi-ty-a0-gf-a0-73.ucode | Bin 1502900 -> 0 bytes .../dev/iwlwififw/iwlwifi-ty-a0-gf-a0-83.ucode | Bin 0 -> 1683076 bytes sys/contrib/dev/iwlwififw/iwlwifi-ty-a0-gf-a0.pnvm | Bin 41588 -> 55484 bytes .../iwlwififw/iwlwifi-Qu-b0-hr-b0-fw/Makefile | 2 +- .../iwlwififw/iwlwifi-Qu-b0-jf-b0-fw/Makefile | 2 +- .../iwlwififw/iwlwifi-Qu-c0-hr-b0-fw/Makefile | 2 +- .../iwlwififw/iwlwifi-Qu-c0-jf-b0-fw/Makefile | 2 +- .../iwlwififw/iwlwifi-QuZ-a0-hr-b0-fw/Makefile | 2 +- .../iwlwififw/iwlwifi-QuZ-a0-jf-b0-fw/Makefile | 2 +- sys/modules/iwlwififw/iwlwifi-cc-a0-fw/Makefile | 2 +- .../iwlwififw/iwlwifi-so-a0-gf-a0-fw/Makefile | 2 +- .../iwlwififw/iwlwifi-so-a0-gf-a0-pnvm/Makefile | 2 +- .../iwlwififw/iwlwifi-so-a0-gf4-a0-fw/Makefile | 2 +- .../iwlwififw/iwlwifi-so-a0-gf4-a0-pnvm/Makefile | 2 +- .../iwlwififw/iwlwifi-so-a0-hr-b0-fw/Makefile | 2 +- .../iwlwififw/iwlwifi-so-a0-jf-b0-fw/Makefile | 2 +- .../iwlwififw/iwlwifi-ty-a0-gf-a0-fw/Makefile | 2 +- .../iwlwififw/iwlwifi-ty-a0-gf-a0-pnvm/Makefile | 2 +- 35 files changed, 15 insertions(+), 15 deletions(-) diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-9000-pu-b0-jf-b0-46.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-9000-pu-b0-jf-b0-46.ucode index f9ea46dc928c..9af424f1ce06 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-9000-pu-b0-jf-b0-46.ucode and b/sys/contrib/dev/iwlwififw/iwlwifi-9000-pu-b0-jf-b0-46.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-9260-th-b0-jf-b0-46.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-9260-th-b0-jf-b0-46.ucode index fec9d0aba254..4c2b25e585cb 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-9260-th-b0-jf-b0-46.ucode and b/sys/contrib/dev/iwlwififw/iwlwifi-9260-th-b0-jf-b0-46.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-Qu-b0-hr-b0-73.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-Qu-b0-hr-b0-77.ucode similarity index 52% rename from sys/contrib/dev/iwlwififw/iwlwifi-Qu-b0-hr-b0-73.ucode rename to sys/contrib/dev/iwlwififw/iwlwifi-Qu-b0-hr-b0-77.ucode index 26abb3a850a4..de6cd8b98985 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-Qu-b0-hr-b0-73.ucode and b/sys/contrib/dev/iwlwififw/iwlwifi-Qu-b0-hr-b0-77.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-QuZ-a0-jf-b0-73.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-Qu-b0-jf-b0-77.ucode similarity index 52% rename from sys/contrib/dev/iwlwififw/iwlwifi-QuZ-a0-jf-b0-73.ucode rename to sys/contrib/dev/iwlwififw/iwlwifi-Qu-b0-jf-b0-77.ucode index 072064dde7b1..ad87490d470b 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-QuZ-a0-jf-b0-73.ucode and b/sys/contrib/dev/iwlwififw/iwlwifi-Qu-b0-jf-b0-77.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-QuZ-a0-hr-b0-73.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-Qu-c0-hr-b0-77.ucode similarity index 51% rename from sys/contrib/dev/iwlwififw/iwlwifi-QuZ-a0-hr-b0-73.ucode rename to sys/contrib/dev/iwlwififw/iwlwifi-Qu-c0-hr-b0-77.ucode index 16e42ff8889f..37e1c7af3f16 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-QuZ-a0-hr-b0-73.ucode and b/sys/contrib/dev/iwlwififw/iwlwifi-Qu-c0-hr-b0-77.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-Qu-c0-jf-b0-73.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-Qu-c0-jf-b0-77.ucode similarity index 52% rename from sys/contrib/dev/iwlwififw/iwlwifi-Qu-c0-jf-b0-73.ucode rename to sys/contrib/dev/iwlwififw/iwlwifi-Qu-c0-jf-b0-77.ucode index 4e88eb24ba76..bd0b2b249894 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-Qu-c0-jf-b0-73.ucode and b/sys/contrib/dev/iwlwififw/iwlwifi-Qu-c0-jf-b0-77.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-Qu-c0-hr-b0-73.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-QuZ-a0-hr-b0-77.ucode similarity index 52% rename from sys/contrib/dev/iwlwififw/iwlwifi-Qu-c0-hr-b0-73.ucode rename to sys/contrib/dev/iwlwififw/iwlwifi-QuZ-a0-hr-b0-77.ucode index c3a23c81643c..256997390af6 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-Qu-c0-hr-b0-73.ucode and b/sys/contrib/dev/iwlwififw/iwlwifi-QuZ-a0-hr-b0-77.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-Qu-b0-jf-b0-73.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-QuZ-a0-jf-b0-77.ucode similarity index 52% rename from sys/contrib/dev/iwlwififw/iwlwifi-Qu-b0-jf-b0-73.ucode rename to sys/contrib/dev/iwlwififw/iwlwifi-QuZ-a0-jf-b0-77.ucode index e1ecc31408e2..7c2a06a2dd2e 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-Qu-b0-jf-b0-73.ucode and b/sys/contrib/dev/iwlwififw/iwlwifi-QuZ-a0-jf-b0-77.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-cc-a0-73.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-cc-a0-77.ucode similarity index 51% rename from sys/contrib/dev/iwlwififw/iwlwifi-cc-a0-73.ucode rename to sys/contrib/dev/iwlwififw/iwlwifi-cc-a0-77.ucode index 9f7df7693322..d138e34af24d 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-cc-a0-73.ucode and b/sys/contrib/dev/iwlwififw/iwlwifi-cc-a0-77.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf-a0-73.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf-a0-73.ucode deleted file mode 100644 index 196a3bda21b7..000000000000 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf-a0-73.ucode and /dev/null differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf-a0-83.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf-a0-83.ucode new file mode 100644 index 000000000000..dbb15f487716 Binary files /dev/null and b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf-a0-83.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf-a0.pnvm b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf-a0.pnvm index b649de0118ef..9dad35a1f5f5 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf-a0.pnvm and b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf-a0.pnvm differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf4-a0-73.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf4-a0-73.ucode deleted file mode 100644 index c1595fd0baa8..000000000000 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf4-a0-73.ucode and /dev/null differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf4-a0-83.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf4-a0-83.ucode new file mode 100644 index 000000000000..1bc07d83ac07 Binary files /dev/null and b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf4-a0-83.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf4-a0.pnvm b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf4-a0.pnvm index 8658ebaa8fa8..86b9a7c63776 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf4-a0.pnvm and b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-gf4-a0.pnvm differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-hr-b0-73.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-hr-b0-81.ucode similarity index 50% rename from sys/contrib/dev/iwlwififw/iwlwifi-so-a0-hr-b0-73.ucode rename to sys/contrib/dev/iwlwififw/iwlwifi-so-a0-hr-b0-81.ucode index 2da5b4cdcae9..fc8558c6cc90 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-hr-b0-73.ucode and b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-hr-b0-81.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-jf-b0-73.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-jf-b0-77.ucode similarity index 54% rename from sys/contrib/dev/iwlwififw/iwlwifi-so-a0-jf-b0-73.ucode rename to sys/contrib/dev/iwlwififw/iwlwifi-so-a0-jf-b0-77.ucode index 4704c56f8456..3649a1c89238 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-jf-b0-73.ucode and b/sys/contrib/dev/iwlwififw/iwlwifi-so-a0-jf-b0-77.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-ty-a0-gf-a0-73.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-ty-a0-gf-a0-73.ucode deleted file mode 100644 index 1a6592408f1d..000000000000 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-ty-a0-gf-a0-73.ucode and /dev/null differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-ty-a0-gf-a0-83.ucode b/sys/contrib/dev/iwlwififw/iwlwifi-ty-a0-gf-a0-83.ucode new file mode 100644 index 000000000000..3fdd6d5a0d9a Binary files /dev/null and b/sys/contrib/dev/iwlwififw/iwlwifi-ty-a0-gf-a0-83.ucode differ diff --git a/sys/contrib/dev/iwlwififw/iwlwifi-ty-a0-gf-a0.pnvm b/sys/contrib/dev/iwlwififw/iwlwifi-ty-a0-gf-a0.pnvm index 70882a9127db..68b8668df93d 100644 Binary files a/sys/contrib/dev/iwlwififw/iwlwifi-ty-a0-gf-a0.pnvm and b/sys/contrib/dev/iwlwififw/iwlwifi-ty-a0-gf-a0.pnvm differ diff --git a/sys/modules/iwlwififw/iwlwifi-Qu-b0-hr-b0-fw/Makefile b/sys/modules/iwlwififw/iwlwifi-Qu-b0-hr-b0-fw/Makefile index bc41b21969dd..e781e790a048 100644 --- a/sys/modules/iwlwififw/iwlwifi-Qu-b0-hr-b0-fw/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-Qu-b0-hr-b0-fw/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 77 NAME= Qu-b0-hr-b0 .include diff --git a/sys/modules/iwlwififw/iwlwifi-Qu-b0-jf-b0-fw/Makefile b/sys/modules/iwlwififw/iwlwifi-Qu-b0-jf-b0-fw/Makefile index 125d3e969e51..ac8b13cd1777 100644 --- a/sys/modules/iwlwififw/iwlwifi-Qu-b0-jf-b0-fw/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-Qu-b0-jf-b0-fw/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 77 NAME= Qu-b0-jf-b0 .include diff --git a/sys/modules/iwlwififw/iwlwifi-Qu-c0-hr-b0-fw/Makefile b/sys/modules/iwlwififw/iwlwifi-Qu-c0-hr-b0-fw/Makefile index c254768fcb68..15389b3c3e2f 100644 --- a/sys/modules/iwlwififw/iwlwifi-Qu-c0-hr-b0-fw/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-Qu-c0-hr-b0-fw/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 77 NAME= Qu-c0-hr-b0 .include diff --git a/sys/modules/iwlwififw/iwlwifi-Qu-c0-jf-b0-fw/Makefile b/sys/modules/iwlwififw/iwlwifi-Qu-c0-jf-b0-fw/Makefile index af8ad15e7576..bd9cd5077021 100644 --- a/sys/modules/iwlwififw/iwlwifi-Qu-c0-jf-b0-fw/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-Qu-c0-jf-b0-fw/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 77 NAME= Qu-c0-jf-b0 .include diff --git a/sys/modules/iwlwififw/iwlwifi-QuZ-a0-hr-b0-fw/Makefile b/sys/modules/iwlwififw/iwlwifi-QuZ-a0-hr-b0-fw/Makefile index d89f4c878d7b..d15ee3643679 100644 --- a/sys/modules/iwlwififw/iwlwifi-QuZ-a0-hr-b0-fw/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-QuZ-a0-hr-b0-fw/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 77 NAME= QuZ-a0-hr-b0 .include diff --git a/sys/modules/iwlwififw/iwlwifi-QuZ-a0-jf-b0-fw/Makefile b/sys/modules/iwlwififw/iwlwifi-QuZ-a0-jf-b0-fw/Makefile index e92608872e07..ac0f398a10d6 100644 --- a/sys/modules/iwlwififw/iwlwifi-QuZ-a0-jf-b0-fw/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-QuZ-a0-jf-b0-fw/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 77 NAME= QuZ-a0-jf-b0 .include diff --git a/sys/modules/iwlwififw/iwlwifi-cc-a0-fw/Makefile b/sys/modules/iwlwififw/iwlwifi-cc-a0-fw/Makefile index 0cb3830c4d57..645e3c94684a 100644 --- a/sys/modules/iwlwififw/iwlwifi-cc-a0-fw/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-cc-a0-fw/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 77 NAME= cc-a0 .include diff --git a/sys/modules/iwlwififw/iwlwifi-so-a0-gf-a0-fw/Makefile b/sys/modules/iwlwififw/iwlwifi-so-a0-gf-a0-fw/Makefile index 98e1efddd7f3..4106eedfa339 100644 --- a/sys/modules/iwlwififw/iwlwifi-so-a0-gf-a0-fw/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-so-a0-gf-a0-fw/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 83 NAME= so-a0-gf-a0 .include diff --git a/sys/modules/iwlwififw/iwlwifi-so-a0-gf-a0-pnvm/Makefile b/sys/modules/iwlwififw/iwlwifi-so-a0-gf-a0-pnvm/Makefile index 6a4085119166..56b5cbde6c26 100644 --- a/sys/modules/iwlwififw/iwlwifi-so-a0-gf-a0-pnvm/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-so-a0-gf-a0-pnvm/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 83 NAME= so-a0-gf-a0 EXT= pnvm _NAME= iwlwifi-${NAME}.${EXT} diff --git a/sys/modules/iwlwififw/iwlwifi-so-a0-gf4-a0-fw/Makefile b/sys/modules/iwlwififw/iwlwifi-so-a0-gf4-a0-fw/Makefile index 44cd873e0b8e..f89756193b89 100644 --- a/sys/modules/iwlwififw/iwlwifi-so-a0-gf4-a0-fw/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-so-a0-gf4-a0-fw/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 83 NAME= so-a0-gf4-a0 .include diff --git a/sys/modules/iwlwififw/iwlwifi-so-a0-gf4-a0-pnvm/Makefile b/sys/modules/iwlwififw/iwlwifi-so-a0-gf4-a0-pnvm/Makefile index 5a63a147c156..a13ba593b628 100644 --- a/sys/modules/iwlwififw/iwlwifi-so-a0-gf4-a0-pnvm/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-so-a0-gf4-a0-pnvm/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 83 NAME= so-a0-gf4-a0 EXT= pnvm _NAME= iwlwifi-${NAME}.${EXT} diff --git a/sys/modules/iwlwififw/iwlwifi-so-a0-hr-b0-fw/Makefile b/sys/modules/iwlwififw/iwlwifi-so-a0-hr-b0-fw/Makefile index b95aba38ed80..ae908c41376a 100644 --- a/sys/modules/iwlwififw/iwlwifi-so-a0-hr-b0-fw/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-so-a0-hr-b0-fw/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 81 NAME= so-a0-hr-b0 .include diff --git a/sys/modules/iwlwififw/iwlwifi-so-a0-jf-b0-fw/Makefile b/sys/modules/iwlwififw/iwlwifi-so-a0-jf-b0-fw/Makefile index 0211cf81d4e3..372a04314cf7 100644 --- a/sys/modules/iwlwififw/iwlwifi-so-a0-jf-b0-fw/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-so-a0-jf-b0-fw/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 77 NAME= so-a0-jf-b0 .include diff --git a/sys/modules/iwlwififw/iwlwifi-ty-a0-gf-a0-fw/Makefile b/sys/modules/iwlwififw/iwlwifi-ty-a0-gf-a0-fw/Makefile index 62c98afb76ba..3bb0931b5248 100644 --- a/sys/modules/iwlwififw/iwlwifi-ty-a0-gf-a0-fw/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-ty-a0-gf-a0-fw/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 83 NAME= ty-a0-gf-a0 .include diff --git a/sys/modules/iwlwififw/iwlwifi-ty-a0-gf-a0-pnvm/Makefile b/sys/modules/iwlwififw/iwlwifi-ty-a0-gf-a0-pnvm/Makefile index f61111576131..1dcb41414755 100644 --- a/sys/modules/iwlwififw/iwlwifi-ty-a0-gf-a0-pnvm/Makefile +++ b/sys/modules/iwlwififw/iwlwifi-ty-a0-gf-a0-pnvm/Makefile @@ -1,5 +1,5 @@ -FWVERSION= 73 +FWVERSION= 83 NAME= ty-a0-gf-a0 EXT= pnvm _NAME= iwlwifi-${NAME}.${EXT} From nobody Fri Oct 6 14:25:20 2023 X-Original-To: dev-commits-src-branches@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 4S29gh5p0pz4wgmr; Fri, 6 Oct 2023 14:25: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gh5ZYLz3RBw; Fri, 6 Oct 2023 14:25:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602320; 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=nGgSmMoynuA8i70WCuz80KgyYuQu/kU09wLYfJMOnlc=; b=RhrmNcAhC4h+5L9B6q0Q32qJxcctta01ymYh28n2akKBNhgA77xx/8XrB2GeQSRoUPyYAg APRy9t/W6SbV6g02ymCUZ1DzXNkoShvS8BP2dPJPo7uBDi34lsHNXhGMa9Gtx7XGwH8pvo e0jeQBVtgEHrLenJ+Zck9XvNEMIGz+lr9U3tF5SZa5J5YE9i4pniKX0DO6qFNUITN+0MqJ Ymby+DBrHTzhaw/tgpD1eYeNafk1VHcYDgaRFPBsjJx9YrdipbMGKopaED6Ge1BKScv9N1 eu0iVYVfKXbS2HM7Blm5GQCEoHqm7aTBmuOsRm2lZQZVeLyCAUre9lXQ7JE/7A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602320; a=rsa-sha256; cv=none; b=bxd5VQqQhZx/xgmElFd4y0IJUXmMBg+/RPjrkhWDZlJ3JkjOJzZTpxlle1NSZ4xrWMcvlw KwoCXRc5eFA+EbFrOELpkTK3yBjA91q/JYG7mDI4YpETKyN3biHx/rQtrN9N/KvezQNIjQ Y9zE7A3cqEJg4S+283hxVBN+56F+OA25m4sVPotLq7a4Sp2Qjs+eGJ3XCDlQqIWnViFlWL s3jNZ/Fba5kpzmYQeixcR5VS44zMYMbF6u7dt0Xca0BV3Ga9KGHHJ+8iA0DeAyQOppIRAj krOI1NBABoETGwxW4P/Akzuy7jWFfbuDGnphh3TKzY/j6bPCCsz9hfd4ZHfBkQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602320; 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=nGgSmMoynuA8i70WCuz80KgyYuQu/kU09wLYfJMOnlc=; b=FVDeQKW6diaQHvdgo3s+HaPh75ajvFUxODg3eyg0xHzEw6CDkUClgzvkbbT0CaraiCG5uo YYL4bPsCE9qR3nduPjcmdheETxwMaIznNzbBb6KpzEGCgmdZR7g6C1de0qMLLrqihDIxDb 2QoLUD6Vom4wcLcJq5hCJn4uAsU8qP8i0LNXes3qip5Y8redWS3uQ8rR9ryqeJtLEhkpUZ 6PiFVpyEOnXWE0QAHbdH8FF9W5CUGtB+B9kr1XqM4fuzMypWRIsXYGBCwWQrkRltfLZRKy 1hitb6aAw284+fZ/LKU0RZwxLVmDnssxLcjfm6rmpZob3BX1zbOhGC+VyA6HBw== 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 4S29gh4gS9zrtY; Fri, 6 Oct 2023 14:25:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EPK0r093727; Fri, 6 Oct 2023 14:25:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EPKwG093724; Fri, 6 Oct 2023 14:25:20 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:20 GMT Message-Id: <202310061425.396EPKwG093724@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: e96f025905d6 - stable/14 - iwlwifi: Update iwlwifi.4 and iwlwififw.4 device list List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: e96f025905d6a39f5c77b6bcb3bfecb7c5d10736 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=e96f025905d6a39f5c77b6bcb3bfecb7c5d10736 commit e96f025905d6a39f5c77b6bcb3bfecb7c5d10736 Author: Bjoern A. Zeeb AuthorDate: 2023-09-21 21:47:18 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:41 +0000 iwlwifi: Update iwlwifi.4 and iwlwififw.4 device list Update the man pages for iwlwifi.4 and iwlwififw.4 to list the current state of devices supported and which firmware they need. The list is automatically generated based on a sysctl added to the iwlwifi driver (so this is the driver's view). The reader should not be surprised by the larger number of any/any/any/any entries for PCI vendor and devices in the firmware table for which other matching logic happens. The reader should also not be confused about "TBD" (to be done) entries for chipsets which the driver already supports but have no (public) product yet. Sponsored by: The FreeBSD Foundation (cherry picked from commit 242f314842767c36eaaacca9f433c80d34def39c) --- share/man/man4/iwlwifi.4 | 6 +- share/man/man4/iwlwififw.4 | 1002 +++++++++++++++++++------------------------- 2 files changed, 445 insertions(+), 563 deletions(-) diff --git a/share/man/man4/iwlwifi.4 b/share/man/man4/iwlwifi.4 index b67f1d440bde..1cf61c0008b5 100644 --- a/share/man/man4/iwlwifi.4 +++ b/share/man/man4/iwlwifi.4 @@ -1,5 +1,5 @@ .\"- -.\" Copyright (c) 2021 The FreeBSD Foundation +.\" Copyright (c) 2021-2023 The FreeBSD Foundation .\" .\" This documentation was written by Bj\xc3\xb6rn Zeeb under sponsorship from .\" the FreeBSD Foundation. @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd June 3, 2022 +.Dd September 21, 2023 .Dt IWLWIFI 4 .Os .Sh NAME @@ -178,6 +178,8 @@ Intel(R) Wi-Fi 6E AX231 160MHz Intel(R) TBD Bz device .It Intel(R) Wi-Fi 6 AX204 160MHz +.It +Intel(R) TBD Sc device .\" --------------------------------------------------------------------- .El .Pp diff --git a/share/man/man4/iwlwififw.4 b/share/man/man4/iwlwififw.4 index 82ee376aaa72..a377f6b51f78 100644 --- a/share/man/man4/iwlwififw.4 +++ b/share/man/man4/iwlwififw.4 @@ -1,5 +1,5 @@ .\"- -.\" Copyright (c) 2021 The FreeBSD Foundation +.\" Copyright (c) 2021-2023 The FreeBSD Foundation .\" .\" This documentation was written by Bj\xc3\xb6rn Zeeb under sponsorship from .\" the FreeBSD Foundation. @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd June 3, 2022 +.Dd September 21, 2023 .Dt iwlwififw 4 .Os .Sh NAME @@ -52,1414 +52,1294 @@ driver. .% --------------------------------------------------------------------- .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4070 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4070 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4072 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4072 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4170 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4170 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4c60 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4c60 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4c70 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4c70 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4060 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4060 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x406a Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x406a Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4160 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4160 Ta iwlwifi-7260 .It "" .It Intel(R) Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4062 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4062 Ta iwlwifi-7260 .It "" .It Intel(R) Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4162 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4162 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0x4270 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0x4270 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0x4272 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0x4272 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0x4260 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0x4260 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0x426a Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0x426a Ta iwlwifi-7260 .It "" .It Intel(R) Wireless N 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0x4262 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0x4262 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4470 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4470 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4472 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4472 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4460 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4460 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x446a Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x446a Ta iwlwifi-7260 .It "" .It Intel(R) Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4462 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4462 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4870 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4870 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x486e Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x486e Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4a70 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4a70 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4a6e Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4a6e Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4a6c Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4a6c Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4570 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4570 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4560 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4560 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0x4370 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0x4370 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0x4360 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0x4360 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x5070 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x5070 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x5072 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x5072 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x5170 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x5170 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x5770 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x5770 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4020 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4020 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x402a Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x402a Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0x4220 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0x4220 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0x4420 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0x4420 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc070 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc070 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc072 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc072 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc170 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc170 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc060 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc060 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc06a Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc06a Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc160 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc160 Ta iwlwifi-7260 .It "" .It Intel(R) Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc062 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc062 Ta iwlwifi-7260 .It "" .It Intel(R) Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc162 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc162 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc770 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc770 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc760 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc760 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0xc270 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0xc270 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xcc70 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xcc70 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xcc60 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xcc60 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0xc272 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0xc272 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0xc260 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0xc260 Ta iwlwifi-7260 .It "" .It Intel(R) Wireless N 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0xc26a Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0xc26a Ta iwlwifi-7260 .It "" .It Intel(R) Wireless N 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0xc262 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0xc262 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc470 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc470 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc472 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc472 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc460 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc460 Ta iwlwifi-7260 .It "" .It Intel(R) Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc462 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc462 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc570 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc570 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc560 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc560 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0xc370 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0xc370 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc360 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc360 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc020 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc020 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc02a Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc02a Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b2 Ta any Ta 0xc220 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b2 Ta any Ta 0xc220 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless N 7260 -.It 0x8086 Ta 0x08b1 Ta any Ta 0xc420 Ta iwlwifi-7260- +.It 0x8086 Ta 0x08b1 Ta any Ta 0xc420 Ta iwlwifi-7260 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x0070 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x0070 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x0072 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x0072 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x0170 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x0170 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x0172 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x0172 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless N 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x0060 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x0060 Ta iwlwifi-3160 .It "" .It Intel(R) Wireless N 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x0062 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x0062 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b4 Ta any Ta 0x0270 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b4 Ta any Ta 0x0270 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b4 Ta any Ta 0x0272 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b4 Ta any Ta 0x0272 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x0470 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x0470 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x0472 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x0472 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b4 Ta any Ta 0x0370 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b4 Ta any Ta 0x0370 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x8070 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x8070 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x8072 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x8072 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x8170 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x8170 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x8172 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x8172 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless N 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x8060 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x8060 Ta iwlwifi-3160 .It "" .It Intel(R) Wireless N 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x8062 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x8062 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b4 Ta any Ta 0x8270 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b4 Ta any Ta 0x8270 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b4 Ta any Ta 0x8370 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b4 Ta any Ta 0x8370 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b4 Ta any Ta 0x8272 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b4 Ta any Ta 0x8272 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x8470 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x8470 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x8570 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x8570 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x1070 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x1070 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3160 -.It 0x8086 Ta 0x08b3 Ta any Ta 0x1170 Ta iwlwifi-3160- +.It 0x8086 Ta 0x08b3 Ta any Ta 0x1170 Ta iwlwifi-3160 .It "" .It Intel(R) Dual Band Wireless AC 3165 -.It 0x8086 Ta 0x3165 Ta any Ta 0x4010 Ta iwlwifi-7265D- +.It 0x8086 Ta 0x3165 Ta any Ta 0x4010 Ta iwlwifi-7265D .It "" .It Intel(R) Dual Band Wireless AC 3165 -.It 0x8086 Ta 0x3165 Ta any Ta 0x4012 Ta iwlwifi-7265D- +.It 0x8086 Ta 0x3165 Ta any Ta 0x4012 Ta iwlwifi-7265D .It "" .It Intel(R) Dual Band Wireless AC 3165 -.It 0x8086 Ta 0x3166 Ta any Ta 0x4212 Ta iwlwifi-7265D- +.It 0x8086 Ta 0x3166 Ta any Ta 0x4212 Ta iwlwifi-7265D .It "" .It Intel(R) Dual Band Wireless AC 3165 -.It 0x8086 Ta 0x3165 Ta any Ta 0x4410 Ta iwlwifi-7265D- +.It 0x8086 Ta 0x3165 Ta any Ta 0x4410 Ta iwlwifi-7265D .It "" .It Intel(R) Dual Band Wireless AC 3165 -.It 0x8086 Ta 0x3165 Ta any Ta 0x4510 Ta iwlwifi-7265D- +.It 0x8086 Ta 0x3165 Ta any Ta 0x4510 Ta iwlwifi-7265D .It "" .It Intel(R) Dual Band Wireless AC 3165 -.It 0x8086 Ta 0x3165 Ta any Ta 0x4110 Ta iwlwifi-7265D- +.It 0x8086 Ta 0x3165 Ta any Ta 0x4110 Ta iwlwifi-7265D .It "" .It Intel(R) Dual Band Wireless AC 3165 -.It 0x8086 Ta 0x3166 Ta any Ta 0x4310 Ta iwlwifi-7265D- +.It 0x8086 Ta 0x3166 Ta any Ta 0x4310 Ta iwlwifi-7265D .It "" .It Intel(R) Dual Band Wireless AC 3165 -.It 0x8086 Ta 0x3166 Ta any Ta 0x4210 Ta iwlwifi-7265D- +.It 0x8086 Ta 0x3166 Ta any Ta 0x4210 Ta iwlwifi-7265D .It "" .It Intel(R) Dual Band Wireless AC 3165 -.It 0x8086 Ta 0x3165 Ta any Ta 0x8010 Ta iwlwifi-7265D- +.It 0x8086 Ta 0x3165 Ta any Ta 0x8010 Ta iwlwifi-7265D .It "" .It Intel(R) Dual Band Wireless AC 3165 -.It 0x8086 Ta 0x3165 Ta any Ta 0x8110 Ta iwlwifi-7265D- +.It 0x8086 Ta 0x3165 Ta any Ta 0x8110 Ta iwlwifi-7265D .It "" .It Intel(R) Dual Band Wireless AC 3168 -.It 0x8086 Ta 0x24fb Ta any Ta 0x2010 Ta iwlwifi-3168- +.It 0x8086 Ta 0x24fb Ta any Ta 0x2010 Ta iwlwifi-3168 .It "" .It Intel(R) Dual Band Wireless AC 3168 -.It 0x8086 Ta 0x24fb Ta any Ta 0x2110 Ta iwlwifi-3168- +.It 0x8086 Ta 0x24fb Ta any Ta 0x2110 Ta iwlwifi-3168 .It "" .It Intel(R) Dual Band Wireless AC 3168 -.It 0x8086 Ta 0x24fb Ta any Ta 0x2050 Ta iwlwifi-3168- +.It 0x8086 Ta 0x24fb Ta any Ta 0x2050 Ta iwlwifi-3168 .It "" .It Intel(R) Dual Band Wireless AC 3168 -.It 0x8086 Ta 0x24fb Ta any Ta 0x2150 Ta iwlwifi-3168- +.It 0x8086 Ta 0x24fb Ta any Ta 0x2150 Ta iwlwifi-3168 .It "" .It Intel(R) Dual Band Wireless AC 3168 -.It 0x8086 Ta 0x24fb Ta any Ta 000000 Ta iwlwifi-3168- +.It 0x8086 Ta 0x24fb Ta any Ta 000000 Ta iwlwifi-3168 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5010 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5010 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5110 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5110 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5100 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5100 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095b Ta any Ta 0x5310 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095b Ta any Ta 0x5310 Ta iwlwifi-7265 .It "" .It Intel(R) Wireless N 7265 -.It 0x8086 Ta 0x095b Ta any Ta 0x5302 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095b Ta any Ta 0x5302 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095b Ta any Ta 0x5210 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095b Ta any Ta 0x5210 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5c10 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5c10 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5012 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5012 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5412 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5412 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5410 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5410 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5510 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5510 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5400 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5400 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x1010 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x1010 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless N 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5000 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5000 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless N 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x500a Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x500a Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless N 7265 -.It 0x8086 Ta 0x095b Ta any Ta 0x5200 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095b Ta any Ta 0x5200 Ta iwlwifi-7265 .It "" .It Intel(R) Wireless N 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5002 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5002 Ta iwlwifi-7265 .It "" .It Intel(R) Wireless N 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5102 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5102 Ta iwlwifi-7265 .It "" .It Intel(R) Wireless N 7265 -.It 0x8086 Ta 0x095b Ta any Ta 0x5202 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095b Ta any Ta 0x5202 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x9010 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x9010 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x9012 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x9012 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x900a Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x900a Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x9110 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x9110 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x9112 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x9112 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095b Ta any Ta 0x9210 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095b Ta any Ta 0x9210 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095b Ta any Ta 0x9200 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095b Ta any Ta 0x9200 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x9510 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x9510 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095b Ta any Ta 0x9310 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095b Ta any Ta 0x9310 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x9410 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x9410 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless N 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5020 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5020 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless N 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x502a Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x502a Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless N 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5420 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5420 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5090 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5090 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5190 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5190 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5590 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5590 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095b Ta any Ta 0x5290 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095b Ta any Ta 0x5290 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5490 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5490 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x5f10 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x5f10 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095b Ta any Ta 0x5212 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095b Ta any Ta 0x5212 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095b Ta any Ta 0x520a Ta iwlwifi-7265- +.It 0x8086 Ta 0x095b Ta any Ta 0x520a Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x9000 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x9000 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x9400 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x9400 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 7265 -.It 0x8086 Ta 0x095a Ta any Ta 0x9e10 Ta iwlwifi-7265- +.It 0x8086 Ta 0x095a Ta any Ta 0x9e10 Ta iwlwifi-7265 .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0010 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0010 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x1010 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x1010 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x10b0 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x10b0 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0130 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0130 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x1130 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x1130 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0132 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0132 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x1132 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x1132 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0110 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0110 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x01f0 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x01f0 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0012 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0012 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x1012 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x1012 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x1110 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x1110 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0050 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0050 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0250 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0250 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x1050 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x1050 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0150 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0150 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x1150 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x1150 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f4 Ta any Ta 0x0030 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f4 Ta any Ta 0x0030 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f4 Ta any Ta 0x1030 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f4 Ta any Ta 0x1030 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0xc010 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0xc010 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0xc110 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0xc110 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0xd010 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0xd010 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0xc050 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0xc050 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0xd050 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0xd050 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0xd0b0 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0xd0b0 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0xb0b0 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0xb0b0 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x8010 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x8010 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x8110 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x8110 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x9010 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x9010 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x9110 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x9110 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f4 Ta any Ta 0x8030 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f4 Ta any Ta 0x8030 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f4 Ta any Ta 0x9030 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f4 Ta any Ta 0x9030 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f4 Ta any Ta 0xc030 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f4 Ta any Ta 0xc030 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f4 Ta any Ta 0xd030 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f4 Ta any Ta 0xd030 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x8130 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x8130 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x9130 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x9130 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x8132 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x8132 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x9132 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x9132 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x8050 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x8050 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x8150 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x8150 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x9050 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x9050 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x9150 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x9150 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless N 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0004 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0004 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless N 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0044 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0044 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 4165 -.It 0x8086 Ta 0x24f5 Ta any Ta 0x0010 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f5 Ta any Ta 0x0010 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 4165 -.It 0x8086 Ta 0x24f6 Ta any Ta 0x0030 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f6 Ta any Ta 0x0030 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0810 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0810 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0910 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0910 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0850 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0850 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0950 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0950 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x0930 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x0930 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24f3 Ta any Ta 000000 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24f3 Ta any Ta 000000 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8260 -.It 0x8086 Ta 0x24f3 Ta any Ta 0x4010 Ta iwlwifi-8000C- +.It 0x8086 Ta 0x24f3 Ta any Ta 0x4010 Ta iwlwifi-8000C .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x0010 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x0010 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x0110 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x0110 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x1110 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x1110 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x1130 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x1130 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x0130 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x0130 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x1010 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x1010 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x10d0 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x10d0 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x0050 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x0050 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x0150 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x0150 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x9010 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x9010 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x8110 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x8110 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x8050 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x8050 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x8010 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x8010 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x0810 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x0810 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x9110 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x9110 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x8130 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x8130 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x0910 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x0910 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x0930 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x0930 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x0950 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x0950 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x0850 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x0850 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8265 -.It 0x8086 Ta 0x24fd Ta any Ta 0x1014 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x1014 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8275 -.It 0x8086 Ta 0x24fd Ta any Ta 0x3e02 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x3e02 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8275 -.It 0x8086 Ta 0x24fd Ta any Ta 0x3e01 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x3e01 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8275 -.It 0x8086 Ta 0x24fd Ta any Ta 0x1012 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x1012 Ta iwlwifi-8265 .It "" .It Intel(R) Dual Band Wireless AC 8275 -.It 0x8086 Ta 0x24fd Ta any Ta 0x0012 Ta iwlwifi-8265- +.It 0x8086 Ta 0x24fd Ta any Ta 0x0012 Ta iwlwifi-8265 .It "" *** 947 LINES SKIPPED *** From nobody Fri Oct 6 14:25:21 2023 X-Original-To: dev-commits-src-branches@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 4S29gk0R45z4wgms; Fri, 6 Oct 2023 14:25:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gj6YsVz3RTW; Fri, 6 Oct 2023 14:25:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602321; 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=HCqEiX6GyY7wEMFrkzpRbaaIIRPD7/PnhT5HkrLqO8k=; b=lCXPsQRdTMzc2zqZz6Ww/A9XR2UzI29TuwR1lnRU+JquEimcK6sY4ihhPCbcxisxg90rXw yckH8yXaF07StqUalQR0Yzt/CtybGomBBOtEHLgV/bhPfQUP2jeNknapr1ravc85yXdzf0 KYPUEarBn3wTsIDVmWMXSbsAiuHNO7UZI5e968jOagPRTnM57z9Sg5lm7ruebwxZMRYyMV RBzapYkTa4qy6P4XDHEeerakdd2pLOMVDEYCG3qNjyoLyxjXs+M21RNvXz0O5gXom+ANIw FfWQp3cBNHk6e0qj6pgfEdtoyW6phiGlC6XMp7cuuX4EtzL526nMLgxY2jJzSw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602321; a=rsa-sha256; cv=none; b=VfKFcHqwQeA1hFtDoD1PibYFv/iLPFNjr24buN8SuVw6S3Rfx1n8J/lU2pJlIe4gzcFyDv sTa5Nw3V/aWJHojVrxQyZmQK9wal7tuIp4xKiruEV7TuZKY6GPqlLgxhPNQWMjJpFCcNRo 5qPEsOLi08TmNTy9VyB5VtucEbMOsCOD232jXz0HAst2AkWiIOWY7XP475hNDJq0MNm19R +n84FRzgM9G47TWj0kYsTJDunWb69WlC6mlNenlGRjq3mx3Fr8Z+7++gKOJQgjKuz8UACw +BZtUs+B1kJ+JB6OvXPPoUPx/s2KNKT+weUQYjMhT92fIiGXvWJnFJrTAIKKuw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602321; 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=HCqEiX6GyY7wEMFrkzpRbaaIIRPD7/PnhT5HkrLqO8k=; b=G6dspLwiBZA/xT9hylI0sl+VLLJJ79uJmqeJAWQDwToc8yKdUOVB4sZoj1nNLc52sqQ4X7 HQTOwsft8wCtZI0DsXDwHOlbHTTYCR/C+ZBQbxuKWz3cOqyHi/ZbnF63KDn/xTA8TIeH9T 9C3kFvTLWsLAdQWbgANpu0sauRQl0jhaMXhcCR+sYyzUwxeTl8KF+j4GXPjK3v9qj8q6Ay qQSVJdJCodadEGeILOjFJY5nRX76I1v7LwFLjd/pCw3noJdpLG+Vlnub8hgaEjBm428oX9 1jaLf4uirmI8mNot8sKVZLXPAM/z1+BLyW3Vpfyuv+hGEXLOb1Wvt2VqJ7sebQ== 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 4S29gj5ft4zrNp; Fri, 6 Oct 2023 14:25:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EPLYn093778; Fri, 6 Oct 2023 14:25:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EPLmv093775; Fri, 6 Oct 2023 14:25:21 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:21 GMT Message-Id: <202310061425.396EPLmv093775@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 8aa738297b57 - stable/14 - iwlwifi: local namespace change for sysctl List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 8aa738297b57e43b4847b6c38ec16c51f6d37db5 Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=8aa738297b57e43b4847b6c38ec16c51f6d37db5 commit 8aa738297b57e43b4847b6c38ec16c51f6d37db5 Author: Bjoern A. Zeeb AuthorDate: 2023-09-21 22:05:02 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:41 +0000 iwlwifi: local namespace change for sysctl In order for the FreeBSD-specific sysctl (which gives us a full list of PCI device IDs/names/and firmware prefixes) to be in the proper namespace add a LINUXKPI_PARAM_PREFIX definition to the file as well. The sysctl can now be used as: sysctl -n compat.linuxkpi.iwlwifi_pci_ids_name Sponsored by: The FreeBSD Foundation (cherry picked from commit 0a22677bce28bc9ad39f219b726b5791852d84ba) --- sys/contrib/dev/iwlwifi/pcie/drv.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/contrib/dev/iwlwifi/pcie/drv.c b/sys/contrib/dev/iwlwifi/pcie/drv.c index 3bde223e3f9c..0aab7a1fdc8e 100644 --- a/sys/contrib/dev/iwlwifi/pcie/drv.c +++ b/sys/contrib/dev/iwlwifi/pcie/drv.c @@ -4,6 +4,9 @@ * Copyright (C) 2013-2015 Intel Mobile Communications GmbH * Copyright (C) 2016-2017 Intel Deutschland GmbH */ +#if defined(__FreeBSD__) +#define LINUXKPI_PARAM_PREFIX iwlwifi_ +#endif #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt #include From nobody Fri Oct 6 14:25:22 2023 X-Original-To: dev-commits-src-branches@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 4S29gl1thXz4wghx; Fri, 6 Oct 2023 14:25: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gl0sMJz3RX5; Fri, 6 Oct 2023 14:25:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602323; 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=XLm0vPiYTWyri0S/zJm/VVu0wPSxI+1yWPYYTXe5I68=; b=kVUUDaJOl9lDDI4b7StD6SpSqDQxlo1dM0IlcprFv+qA976gUKanxOhSxq5KCerBzQFNkk xYgKglPf8dqMO7plMi2xw2PYmZ+lC+4qXl71HTE5SWRLHjATlBAqdHxspV7xdVAYxUJHb5 po/fVMiJJmXD9WXeYRVrSqACtP3+WQIpT1wu8CzCq6f78nVK+dta9peR87bu9YiOfFXtHb HOODkAJPBVavL7ez2QrDNlJPUbHUEIL1qWN58mDKxaLzxHUbvxJ8ukMf0rLjiq710z4IOq h8+JQktUh8ocbIKiXVkpOpgvwmNDclFEJRuIztSO0+RGomayYq0aqNF7oGMEDA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602323; a=rsa-sha256; cv=none; b=NnX+uFBFTdcl4fIDIrXNl1msIfLLnr7GH0+BQlsQI/KfZrKDrFtOOP4pJBqdYFlrKGYMKh CEtWMO/1zfkDxYHOjXOZm3GQrylrWyVknrIxpHkI76Ty117QXlOT44KM6sM0wOIz9XahvM CeGopbg21DnzBkP7OK1PyFO+TBxiuns08x+dHq6hw7jJ0thAC80Cusn5ap2f/a3EYVSSor iUfEmSiRPtCYh+Uygn0An8uyz4GkJANf935ARpfDqG29qPE+UE7rhTW+L9duW4W1Km1tMs rGSl1Za6oit9eyhbE8Nr72Ac/SlJ/zW45h2FJdBfxbIVxHcpbMI4S7EG9G+jvQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602323; 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=XLm0vPiYTWyri0S/zJm/VVu0wPSxI+1yWPYYTXe5I68=; b=y16QZ/ZDfJZZaPFuqdYap/enVlhFmqNvIxMqIi1xJtd3UfywISaxPnYpz5kpX6PT2CptEk e04sRIUznKNyHAnOExYAcFVOp7W8u0R0XuhqAozq726qt21o8TekxaG2D8CHE6QyRYflU7 ya7yYNXixOR8LWl8+0otqaHjWBTrXroO/f6uMF29mfIeaVWZ8JnHV+aybvEKfonXFmVaf4 Z2CKJRHYUYYEcnJs1MkWMVbJc6djh2fgiIrg7bjdzk6/6yv5Cqzv6PQhNCLJY+CDG0g54G UoNrS4xf7oxKLVk0ssOpOkR6GEwnzemGpQloZAUao46BG4Z43sdQ+AsbU29NCA== 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 4S29gk6njFzrkG; Fri, 6 Oct 2023 14:25:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EPMXE093829; Fri, 6 Oct 2023 14:25:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EPMHD093826; Fri, 6 Oct 2023 14:25:22 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:22 GMT Message-Id: <202310061425.396EPMHD093826@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 8323f69b8869 - stable/14 - rtw88: update driver from upstream List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 8323f69b8869ab714e329a378f632a55888d3fab Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=8323f69b8869ab714e329a378f632a55888d3fab commit 8323f69b8869ab714e329a378f632a55888d3fab Author: Bjoern A. Zeeb AuthorDate: 2023-05-16 23:19:34 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:41 +0000 rtw88: update driver from upstream This is a combined version of updates of the rtw88 driver based on wireless-testing (wt-2023-05-11) 711dca0ca3d77414f8f346e564e9c8640147f40d (after v6.4-rc1), (wt-2023-06-09) 7bd20e011626ccc3ad53e57873452b1716fcfaaa (after v6.4-rc5), (wt-2023-07-24) 62e409149b62a285e89018e49b2e115757fb9022 (after v6.5-rc3), (wt-2023-08-06) 2a220a15be657a24868368892e3e2caba2115283 (after v6.5-rc4). This update follows other currently disconnected LinuxKPI based wireless drivers to lift them all to a same version in case someone else wants to work on this driver in parallel to predominant iwlwifi efforts. While debugging some funky register reads of 0xaeaea from RF_CFGCH resulting in "rtw880: [TXGAPK] unknown channel 234!!" more of these reads came to my attention hidden by using the register index rather than the defined value. Make this more grep-able. (cherry picked from commit 90aac0d83bc9645f51ef0c2aeae6f9c0540bb031) (cherry picked from commit 4f3b2bba240b6e0603b5cbb47155fd8215bcbcb3) --- sys/contrib/dev/rtw88/Makefile | 78 +++ sys/contrib/dev/rtw88/bf.c | 17 +- sys/contrib/dev/rtw88/coex.c | 93 ++- sys/contrib/dev/rtw88/coex.h | 14 +- sys/contrib/dev/rtw88/debug.c | 85 ++- sys/contrib/dev/rtw88/debug.h | 1 + sys/contrib/dev/rtw88/efuse.c | 4 +- sys/contrib/dev/rtw88/fw.c | 220 ++++-- sys/contrib/dev/rtw88/fw.h | 47 +- sys/contrib/dev/rtw88/hci.h | 9 +- sys/contrib/dev/rtw88/mac.c | 119 +++- sys/contrib/dev/rtw88/mac.h | 1 - sys/contrib/dev/rtw88/mac80211.c | 89 ++- sys/contrib/dev/rtw88/main.c | 451 +++++++++--- sys/contrib/dev/rtw88/main.h | 81 ++- sys/contrib/dev/rtw88/pci.c | 89 +-- sys/contrib/dev/rtw88/phy.c | 71 +- sys/contrib/dev/rtw88/phy.h | 2 +- sys/contrib/dev/rtw88/ps.c | 57 +- sys/contrib/dev/rtw88/ps.h | 2 + sys/contrib/dev/rtw88/reg.h | 15 + sys/contrib/dev/rtw88/regd.c | 2 + sys/contrib/dev/rtw88/rtw8723d.c | 43 +- sys/contrib/dev/rtw88/rtw8723d.h | 19 +- sys/contrib/dev/rtw88/rtw8723ds.c | 41 ++ sys/contrib/dev/rtw88/rtw8723du.c | 39 ++ sys/contrib/dev/rtw88/rtw8821c.c | 54 +- sys/contrib/dev/rtw88/rtw8821c.h | 27 + sys/contrib/dev/rtw88/rtw8821cs.c | 36 + sys/contrib/dev/rtw88/rtw8821cu.c | 53 ++ sys/contrib/dev/rtw88/rtw8822b.c | 32 +- sys/contrib/dev/rtw88/rtw8822b.h | 8 +- sys/contrib/dev/rtw88/rtw8822bs.c | 36 + sys/contrib/dev/rtw88/rtw8822bu.c | 93 +++ sys/contrib/dev/rtw88/rtw8822c.c | 49 +- sys/contrib/dev/rtw88/rtw8822c.h | 8 +- sys/contrib/dev/rtw88/rtw8822cs.c | 36 + sys/contrib/dev/rtw88/rtw8822cu.c | 47 ++ sys/contrib/dev/rtw88/sdio.c | 1404 +++++++++++++++++++++++++++++++++++++ sys/contrib/dev/rtw88/sdio.h | 178 +++++ sys/contrib/dev/rtw88/tx.c | 149 ++-- sys/contrib/dev/rtw88/tx.h | 138 ++-- sys/contrib/dev/rtw88/usb.c | 919 ++++++++++++++++++++++++ sys/contrib/dev/rtw88/usb.h | 100 +++ sys/contrib/dev/rtw88/util.c | 104 ++- sys/contrib/dev/rtw88/util.h | 11 +- sys/contrib/dev/rtw88/wow.c | 2 +- 47 files changed, 4622 insertions(+), 551 deletions(-) diff --git a/sys/contrib/dev/rtw88/Makefile b/sys/contrib/dev/rtw88/Makefile new file mode 100644 index 000000000000..fd212c09d88a --- /dev/null +++ b/sys/contrib/dev/rtw88/Makefile @@ -0,0 +1,78 @@ +# SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause + +obj-$(CONFIG_RTW88_CORE) += rtw88_core.o +rtw88_core-y += main.o \ + mac80211.o \ + util.o \ + debug.o \ + tx.o \ + rx.o \ + mac.o \ + phy.o \ + coex.o \ + efuse.o \ + fw.o \ + ps.o \ + sec.o \ + bf.o \ + sar.o \ + regd.o + +rtw88_core-$(CONFIG_PM) += wow.o + +obj-$(CONFIG_RTW88_8822B) += rtw88_8822b.o +rtw88_8822b-objs := rtw8822b.o rtw8822b_table.o + +obj-$(CONFIG_RTW88_8822BE) += rtw88_8822be.o +rtw88_8822be-objs := rtw8822be.o + +obj-$(CONFIG_RTW88_8822BS) += rtw88_8822bs.o +rtw88_8822bs-objs := rtw8822bs.o + +obj-$(CONFIG_RTW88_8822BU) += rtw88_8822bu.o +rtw88_8822bu-objs := rtw8822bu.o + +obj-$(CONFIG_RTW88_8822C) += rtw88_8822c.o +rtw88_8822c-objs := rtw8822c.o rtw8822c_table.o + +obj-$(CONFIG_RTW88_8822CE) += rtw88_8822ce.o +rtw88_8822ce-objs := rtw8822ce.o + +obj-$(CONFIG_RTW88_8822CS) += rtw88_8822cs.o +rtw88_8822cs-objs := rtw8822cs.o + +obj-$(CONFIG_RTW88_8822CU) += rtw88_8822cu.o +rtw88_8822cu-objs := rtw8822cu.o + +obj-$(CONFIG_RTW88_8723D) += rtw88_8723d.o +rtw88_8723d-objs := rtw8723d.o rtw8723d_table.o + +obj-$(CONFIG_RTW88_8723DE) += rtw88_8723de.o +rtw88_8723de-objs := rtw8723de.o + +obj-$(CONFIG_RTW88_8723DS) += rtw88_8723ds.o +rtw88_8723ds-objs := rtw8723ds.o + +obj-$(CONFIG_RTW88_8723DU) += rtw88_8723du.o +rtw88_8723du-objs := rtw8723du.o + +obj-$(CONFIG_RTW88_8821C) += rtw88_8821c.o +rtw88_8821c-objs := rtw8821c.o rtw8821c_table.o + +obj-$(CONFIG_RTW88_8821CE) += rtw88_8821ce.o +rtw88_8821ce-objs := rtw8821ce.o + +obj-$(CONFIG_RTW88_8821CS) += rtw88_8821cs.o +rtw88_8821cs-objs := rtw8821cs.o + +obj-$(CONFIG_RTW88_8821CU) += rtw88_8821cu.o +rtw88_8821cu-objs := rtw8821cu.o + +obj-$(CONFIG_RTW88_PCI) += rtw88_pci.o +rtw88_pci-objs := pci.o + +obj-$(CONFIG_RTW88_SDIO) += rtw88_sdio.o +rtw88_sdio-objs := sdio.o + +obj-$(CONFIG_RTW88_USB) += rtw88_usb.o +rtw88_usb-objs := usb.o diff --git a/sys/contrib/dev/rtw88/bf.c b/sys/contrib/dev/rtw88/bf.c index d207fa5c122f..16c6a1d972e5 100644 --- a/sys/contrib/dev/rtw88/bf.c +++ b/sys/contrib/dev/rtw88/bf.c @@ -30,11 +30,11 @@ void rtw_bf_disassoc(struct rtw_dev *rtwdev, struct ieee80211_vif *vif, void rtw_bf_assoc(struct rtw_dev *rtwdev, struct ieee80211_vif *vif, struct ieee80211_bss_conf *bss_conf) { + const struct rtw_chip_info *chip = rtwdev->chip; struct ieee80211_hw *hw = rtwdev->hw; struct rtw_vif *rtwvif = (struct rtw_vif *)vif->drv_priv; struct rtw_bfee *bfee = &rtwvif->bfee; struct rtw_bf_info *bfinfo = &rtwdev->bf_info; - struct rtw_chip_info *chip = rtwdev->chip; struct ieee80211_sta *sta; struct ieee80211_sta_vht_cap *vht_cap; struct ieee80211_sta_vht_cap *ic_vht_cap; @@ -49,6 +49,8 @@ void rtw_bf_assoc(struct rtw_dev *rtwdev, struct ieee80211_vif *vif, sta = ieee80211_find_sta(vif, bssid); if (!sta) { + rcu_read_unlock(); + #if defined(__linux__) rtw_warn(rtwdev, "failed to find station entry for bss %pM\n", bssid); @@ -56,23 +58,25 @@ void rtw_bf_assoc(struct rtw_dev *rtwdev, struct ieee80211_vif *vif, rtw_warn(rtwdev, "failed to find station entry for bss %6D\n", bssid, ":"); #endif - goto out_unlock; + return; } ic_vht_cap = &hw->wiphy->bands[NL80211_BAND_5GHZ]->vht_cap; vht_cap = &sta->deflink.vht_cap; + rcu_read_unlock(); + if ((ic_vht_cap->cap & IEEE80211_VHT_CAP_MU_BEAMFORMEE_CAPABLE) && (vht_cap->cap & IEEE80211_VHT_CAP_MU_BEAMFORMER_CAPABLE)) { if (bfinfo->bfer_mu_cnt >= chip->bfer_mu_max_num) { rtw_dbg(rtwdev, RTW_DBG_BF, "mu bfer number over limit\n"); - goto out_unlock; + return; } ether_addr_copy(bfee->mac_addr, bssid); bfee->role = RTW_BFEE_MU; bfee->p_aid = (bssid[5] << 1) | (bssid[4] >> 7); - bfee->aid = bss_conf->aid; + bfee->aid = vif->cfg.aid; bfinfo->bfer_mu_cnt++; rtw_chip_config_bfee(rtwdev, rtwvif, bfee, true); @@ -80,7 +84,7 @@ void rtw_bf_assoc(struct rtw_dev *rtwdev, struct ieee80211_vif *vif, (vht_cap->cap & IEEE80211_VHT_CAP_SU_BEAMFORMER_CAPABLE)) { if (bfinfo->bfer_su_cnt >= chip->bfer_su_max_num) { rtw_dbg(rtwdev, RTW_DBG_BF, "su bfer number over limit\n"); - goto out_unlock; + return; } sound_dim = vht_cap->cap & @@ -103,9 +107,6 @@ void rtw_bf_assoc(struct rtw_dev *rtwdev, struct ieee80211_vif *vif, rtw_chip_config_bfee(rtwdev, rtwvif, bfee, true); } - -out_unlock: - rcu_read_unlock(); } void rtw_bf_init_bfer_entry_mu(struct rtw_dev *rtwdev, diff --git a/sys/contrib/dev/rtw88/coex.c b/sys/contrib/dev/rtw88/coex.c index cac053f485c3..86467d2f8888 100644 --- a/sys/contrib/dev/rtw88/coex.c +++ b/sys/contrib/dev/rtw88/coex.c @@ -13,7 +13,7 @@ static u8 rtw_coex_next_rssi_state(struct rtw_dev *rtwdev, u8 pre_state, u8 rssi, u8 rssi_thresh) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; u8 tol = chip->rssi_tolerance; u8 next_state; @@ -36,7 +36,7 @@ static u8 rtw_coex_next_rssi_state(struct rtw_dev *rtwdev, u8 pre_state, static void rtw_coex_limited_tx(struct rtw_dev *rtwdev, bool tx_limit_en, bool ampdu_limit_en) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; u8 num_of_active_port = 1; @@ -365,7 +365,7 @@ static void rtw_coex_set_wl_pri_mask(struct rtw_dev *rtwdev, u8 bitmap, void rtw_coex_write_scbd(struct rtw_dev *rtwdev, u16 bitpos, bool set) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; u16 val = 0x2; @@ -400,7 +400,7 @@ EXPORT_SYMBOL(rtw_coex_write_scbd); static u16 rtw_coex_read_scbd(struct rtw_dev *rtwdev) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; if (!chip->scbd_support) return 0; @@ -410,7 +410,7 @@ static u16 rtw_coex_read_scbd(struct rtw_dev *rtwdev) static void rtw_coex_check_rfk(struct rtw_dev *rtwdev) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_coex_rfe *coex_rfe = &coex->rfe; @@ -489,7 +489,7 @@ static void rtw_coex_monitor_bt_ctr(struct rtw_dev *rtwdev) static void rtw_coex_monitor_bt_enable(struct rtw_dev *rtwdev) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_coex_dm *coex_dm = &coex->dm; @@ -524,10 +524,10 @@ static void rtw_coex_monitor_bt_enable(struct rtw_dev *rtwdev) static void rtw_coex_update_wl_link_info(struct rtw_dev *rtwdev, u8 reason) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_coex_dm *coex_dm = &coex->dm; - struct rtw_chip_info *chip = rtwdev->chip; struct rtw_traffic_stats *stats = &rtwdev->stats; bool is_5G = false; bool wl_busy = false; @@ -633,7 +633,7 @@ static struct sk_buff *rtw_coex_info_request(struct rtw_dev *rtwdev, struct rtw_coex *coex = &rtwdev->coex; struct sk_buff *skb_resp = NULL; - mutex_lock(&coex->mutex); + lockdep_assert_held(&rtwdev->mutex); rtw_fw_query_bt_mp_info(rtwdev, req); @@ -650,7 +650,6 @@ static struct sk_buff *rtw_coex_info_request(struct rtw_dev *rtwdev, } out: - mutex_unlock(&coex->mutex); return skb_resp; } @@ -706,10 +705,10 @@ static const char *rtw_coex_get_bt_status_string(u8 bt_status) static void rtw_coex_update_bt_link_info(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_coex_dm *coex_dm = &coex->dm; - struct rtw_chip_info *chip = rtwdev->chip; u8 i; u8 rssi_state; u8 rssi_step; @@ -806,7 +805,7 @@ static void rtw_coex_update_bt_link_info(struct rtw_dev *rtwdev) static void rtw_coex_update_wl_ch_info(struct rtw_dev *rtwdev, u8 type) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_efuse *efuse = &rtwdev->efuse; struct rtw_coex_dm *coex_dm = &rtwdev->coex.dm; struct rtw_coex_stat *coex_stat = &rtwdev->coex.stat; @@ -933,7 +932,7 @@ EXPORT_SYMBOL(rtw_coex_write_indirect_reg); static void rtw_coex_coex_ctrl_owner(struct rtw_dev *rtwdev, bool wifi_control) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; const struct rtw_hw_reg *btg_reg = chip->btg_reg; if (wifi_control) { @@ -981,7 +980,7 @@ static void rtw_coex_mimo_ps(struct rtw_dev *rtwdev, bool force, bool state) static void rtw_btc_wltoggle_table_a(struct rtw_dev *rtwdev, bool force, u8 table_case) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_efuse *efuse = &rtwdev->efuse; u8 h2c_para[6] = {0}; u32 table_wl = 0x5a5a5a5a; @@ -1065,9 +1064,9 @@ static void rtw_coex_set_table(struct rtw_dev *rtwdev, bool force, u32 table0, static void rtw_coex_table(struct rtw_dev *rtwdev, bool force, u8 type) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_dm *coex_dm = &coex->dm; - struct rtw_chip_info *chip = rtwdev->chip; struct rtw_efuse *efuse = &rtwdev->efuse; struct rtw_coex_stat *coex_stat = &coex->stat; @@ -1135,9 +1134,9 @@ static void rtw_coex_power_save_state(struct rtw_dev *rtwdev, u8 ps_type, static void rtw_coex_set_tdma(struct rtw_dev *rtwdev, u8 byte1, u8 byte2, u8 byte3, u8 byte4, u8 byte5) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_dm *coex_dm = &coex->dm; - struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex_stat *coex_stat = &coex->stat; u8 ps_type = COEX_PS_WIFI_NATIVE; bool ap_enable = false; @@ -1193,10 +1192,10 @@ static void rtw_coex_set_tdma(struct rtw_dev *rtwdev, u8 byte1, u8 byte2, static void rtw_coex_tdma(struct rtw_dev *rtwdev, bool force, u32 tcase) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_dm *coex_dm = &coex->dm; struct rtw_coex_stat *coex_stat = &coex->stat; - struct rtw_chip_info *chip = rtwdev->chip; struct rtw_efuse *efuse = &rtwdev->efuse; u8 n, type; bool turn_on; @@ -1526,8 +1525,8 @@ static u8 rtw_coex_algorithm(struct rtw_dev *rtwdev) static void rtw_coex_action_coex_all_off(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; rtw_dbg(rtwdev, RTW_DBG_COEX, "[BTCoex], %s()\n", __func__); @@ -1549,11 +1548,11 @@ static void rtw_coex_action_coex_all_off(struct rtw_dev *rtwdev) static void rtw_coex_action_freerun(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_coex_dm *coex_dm = &coex->dm; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 level = 0; bool bt_afh_loss = true; @@ -1594,8 +1593,8 @@ static void rtw_coex_action_freerun(struct rtw_dev *rtwdev) static void rtw_coex_action_rf4ce(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; rtw_dbg(rtwdev, RTW_DBG_COEX, "[BTCoex], %s()\n", __func__); @@ -1619,8 +1618,8 @@ static void rtw_coex_action_rf4ce(struct rtw_dev *rtwdev) static void rtw_coex_action_bt_whql_test(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; rtw_dbg(rtwdev, RTW_DBG_COEX, "[BTCoex], %s()\n", __func__); @@ -1644,10 +1643,10 @@ static void rtw_coex_action_bt_whql_test(struct rtw_dev *rtwdev) static void rtw_coex_action_bt_relink(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; u32 slot_type = 0; @@ -1684,11 +1683,11 @@ static void rtw_coex_action_bt_relink(struct rtw_dev *rtwdev) static void rtw_coex_action_bt_idle(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_coex_dm *coex_dm = &coex->dm; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex_rfe *coex_rfe = &coex->rfe; u8 table_case = 0xff, tdma_case = 0xff; @@ -1753,10 +1752,10 @@ exit: static void rtw_coex_action_bt_inquiry(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; bool wl_hi_pri = false; u8 table_case, tdma_case; u32 slot_type = 0; @@ -1853,11 +1852,11 @@ static void rtw_coex_action_bt_inquiry(struct rtw_dev *rtwdev) static void rtw_coex_action_bt_game_hid(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_efuse *efuse = &rtwdev->efuse; struct rtw_coex_dm *coex_dm = &coex->dm; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; rtw_dbg(rtwdev, RTW_DBG_COEX, "[BTCoex], %s()\n", __func__); @@ -1901,10 +1900,10 @@ static void rtw_coex_action_bt_game_hid(struct rtw_dev *rtwdev) static void rtw_coex_action_bt_hfp(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; rtw_dbg(rtwdev, RTW_DBG_COEX, "[BTCoex], %s()\n", __func__); @@ -1932,10 +1931,10 @@ static void rtw_coex_action_bt_hfp(struct rtw_dev *rtwdev) static void rtw_coex_action_bt_hid(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; u32 slot_type = 0; bool bt_multi_link_remain = false, is_toggle_table = false; @@ -2015,11 +2014,11 @@ static void rtw_coex_action_bt_hid(struct rtw_dev *rtwdev) static void rtw_coex_action_bt_a2dp(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_coex_dm *coex_dm = &coex->dm; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; u32 slot_type = 0; @@ -2057,10 +2056,10 @@ static void rtw_coex_action_bt_a2dp(struct rtw_dev *rtwdev) static void rtw_coex_action_bt_a2dpsink(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; bool ap_enable = false; @@ -2096,10 +2095,10 @@ static void rtw_coex_action_bt_a2dpsink(struct rtw_dev *rtwdev) static void rtw_coex_action_bt_pan(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; rtw_dbg(rtwdev, RTW_DBG_COEX, "[BTCoex], %s()\n", __func__); @@ -2133,11 +2132,11 @@ static void rtw_coex_action_bt_pan(struct rtw_dev *rtwdev) static void rtw_coex_action_bt_a2dp_hid(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_coex_dm *coex_dm = &coex->dm; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case, interval = 0; u32 slot_type = 0; bool is_toggle_table = false; @@ -2190,10 +2189,10 @@ static void rtw_coex_action_bt_a2dp_hid(struct rtw_dev *rtwdev) static void rtw_coex_action_bt_a2dp_pan(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; bool wl_cpt_test = false, bt_cpt_test = false; @@ -2247,10 +2246,10 @@ static void rtw_coex_action_bt_a2dp_pan(struct rtw_dev *rtwdev) static void rtw_coex_action_bt_pan_hid(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; rtw_dbg(rtwdev, RTW_DBG_COEX, "[BTCoex], %s()\n", __func__); @@ -2282,10 +2281,10 @@ static void rtw_coex_action_bt_pan_hid(struct rtw_dev *rtwdev) static void rtw_coex_action_bt_a2dp_pan_hid(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; rtw_dbg(rtwdev, RTW_DBG_COEX, "[BTCoex], %s()\n", __func__); @@ -2316,9 +2315,9 @@ static void rtw_coex_action_bt_a2dp_pan_hid(struct rtw_dev *rtwdev) static void rtw_coex_action_wl_under5g(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex_stat *coex_stat = &coex->stat; u8 table_case, tdma_case; @@ -2348,8 +2347,8 @@ static void rtw_coex_action_wl_under5g(struct rtw_dev *rtwdev) static void rtw_coex_action_wl_only(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; rtw_dbg(rtwdev, RTW_DBG_COEX, "[BTCoex], %s()\n", __func__); @@ -2372,9 +2371,9 @@ static void rtw_coex_action_wl_only(struct rtw_dev *rtwdev) static void rtw_coex_action_wl_native_lps(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex_stat *coex_stat = &coex->stat; u8 table_case, tdma_case; @@ -2411,10 +2410,10 @@ static void rtw_coex_action_wl_native_lps(struct rtw_dev *rtwdev) static void rtw_coex_action_wl_linkscan(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; u32 slot_type = 0; @@ -2451,8 +2450,8 @@ static void rtw_coex_action_wl_linkscan(struct rtw_dev *rtwdev) static void rtw_coex_action_wl_not_connected(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 table_case, tdma_case; rtw_dbg(rtwdev, RTW_DBG_COEX, "[BTCoex], %s()\n", __func__); @@ -2528,8 +2527,8 @@ static void rtw_coex_action_wl_connected(struct rtw_dev *rtwdev) static void rtw_coex_run_coex(struct rtw_dev *rtwdev, u8 reason) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; - struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex_dm *coex_dm = &coex->dm; struct rtw_coex_stat *coex_stat = &coex->stat; bool rf4ce_en = false; @@ -3002,9 +3001,9 @@ void rtw_coex_media_status_notify(struct rtw_dev *rtwdev, u8 type) void rtw_coex_bt_info_notify(struct rtw_dev *rtwdev, u8 *buf, u8 length) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; - struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex_dm *coex_dm = &coex->dm; u32 bt_relink_time; u8 i, rsp_source = 0, type; @@ -3270,8 +3269,8 @@ static const u8 coex_bt_hidinfo_xb[] = {0x58, 0x62, 0x6f}; void rtw_coex_bt_hid_info_notify(struct rtw_dev *rtwdev, u8 *buf, u8 length) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; - struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_coex_hid *hidinfo; struct rtw_coex_hid_info_a *hida; @@ -3360,8 +3359,8 @@ void rtw_coex_bt_hid_info_notify(struct rtw_dev *rtwdev, u8 *buf, u8 length) void rtw_coex_query_bt_hid_list(struct rtw_dev *rtwdev) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex *coex = &rtwdev->coex; - struct rtw_chip_info *chip = rtwdev->chip; struct rtw_coex_stat *coex_stat = &coex->stat; struct rtw_coex_hid *hidinfo; u8 i, handle; @@ -3582,7 +3581,7 @@ static const char *rtw_coex_get_reason_string(u8 reason) static u8 rtw_coex_get_table_index(struct rtw_dev *rtwdev, u32 wl_reg_6c0, u32 wl_reg_6c4) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_efuse *efuse = &rtwdev->efuse; u8 ans = 0xFF; u8 n, i; @@ -3618,8 +3617,8 @@ static u8 rtw_coex_get_table_index(struct rtw_dev *rtwdev, u32 wl_reg_6c0, static u8 rtw_coex_get_tdma_index(struct rtw_dev *rtwdev, u8 *tdma_para) { + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_efuse *efuse = &rtwdev->efuse; - struct rtw_chip_info *chip = rtwdev->chip; u8 ans = 0xFF; u8 n, i, j; u8 load_cur_tab_val; @@ -3736,7 +3735,7 @@ static int rtw_coex_val_info(struct rtw_dev *rtwdev, static void rtw_coex_set_coexinfo_hw(struct rtw_dev *rtwdev, struct seq_file *m) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; const struct rtw_reg_domain *reg; char addr_info[INFO_SIZE]; int n_addr = 0; @@ -3910,7 +3909,7 @@ static const char *rtw_coex_get_wl_coex_mode(u8 coex_wl_link_mode) void rtw_coex_display_coex_info(struct rtw_dev *rtwdev, struct seq_file *m) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; struct rtw_dm_info *dm_info = &rtwdev->dm_info; struct rtw_coex *coex = &rtwdev->coex; struct rtw_coex_stat *coex_stat = &coex->stat; @@ -4057,7 +4056,7 @@ void rtw_coex_display_coex_info(struct rtw_dev *rtwdev, struct seq_file *m) rtwdev->stats.tx_throughput, rtwdev->stats.rx_throughput); seq_printf(m, "%-40s = %u/ %u/ %u\n", "IPS/ Low Power/ PS mode", - test_bit(RTW_FLAG_INACTIVE_PS, rtwdev->flags), + !test_bit(RTW_FLAG_POWERON, rtwdev->flags), test_bit(RTW_FLAG_LEISURE_PS_DEEP, rtwdev->flags), rtwdev->lps_conf.mode); diff --git a/sys/contrib/dev/rtw88/coex.h b/sys/contrib/dev/rtw88/coex.h index 07fa7aa34d4b..57cf29da9ea4 100644 --- a/sys/contrib/dev/rtw88/coex.h +++ b/sys/contrib/dev/rtw88/coex.h @@ -327,7 +327,7 @@ struct coex_rf_para { static inline void rtw_coex_set_init(struct rtw_dev *rtwdev) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; chip->ops->coex_set_init(rtwdev); } @@ -335,7 +335,7 @@ static inline void rtw_coex_set_init(struct rtw_dev *rtwdev) static inline void rtw_coex_set_ant_switch(struct rtw_dev *rtwdev, u8 ctrl_type, u8 pos_type) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; if (!chip->ops->coex_set_ant_switch) return; @@ -345,28 +345,28 @@ void rtw_coex_set_ant_switch(struct rtw_dev *rtwdev, u8 ctrl_type, u8 pos_type) static inline void rtw_coex_set_gnt_fix(struct rtw_dev *rtwdev) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; chip->ops->coex_set_gnt_fix(rtwdev); } static inline void rtw_coex_set_gnt_debug(struct rtw_dev *rtwdev) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; chip->ops->coex_set_gnt_debug(rtwdev); } static inline void rtw_coex_set_rfe_type(struct rtw_dev *rtwdev) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; chip->ops->coex_set_rfe_type(rtwdev); } static inline void rtw_coex_set_wl_tx_power(struct rtw_dev *rtwdev, u8 wl_pwr) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; chip->ops->coex_set_wl_tx_power(rtwdev, wl_pwr); } @@ -374,7 +374,7 @@ static inline void rtw_coex_set_wl_tx_power(struct rtw_dev *rtwdev, u8 wl_pwr) static inline void rtw_coex_set_wl_rx_gain(struct rtw_dev *rtwdev, bool low_gain) { - struct rtw_chip_info *chip = rtwdev->chip; + const struct rtw_chip_info *chip = rtwdev->chip; chip->ops->coex_set_wl_rx_gain(rtwdev, low_gain); } diff --git a/sys/contrib/dev/rtw88/debug.c b/sys/contrib/dev/rtw88/debug.c index fbbd11be5eef..d745c774aa6f 100644 --- a/sys/contrib/dev/rtw88/debug.c +++ b/sys/contrib/dev/rtw88/debug.c @@ -144,7 +144,9 @@ static int rtw_debugfs_get_rf_read(struct seq_file *m, void *v) addr = debugfs_priv->rf_addr; mask = debugfs_priv->rf_mask; + mutex_lock(&rtwdev->mutex); val = rtw_read_rf(rtwdev, path, addr, mask); + mutex_unlock(&rtwdev->mutex); seq_printf(m, "rf_read path:%d addr:0x%08x mask:0x%08x val=0x%08x\n", path, addr, mask, val); @@ -181,8 +183,8 @@ static int rtw_debugfs_copy_from_user(char tmp[], int size, tmp_len = (count > size - 1 ? size - 1 : count); - if (!buffer || copy_from_user(tmp, buffer, tmp_len)) - return count; + if (copy_from_user(tmp, buffer, tmp_len)) + return -EFAULT; tmp[tmp_len] = '\0'; @@ -199,13 +201,16 @@ static ssize_t rtw_debugfs_set_read_reg(struct file *filp, char tmp[32 + 1]; u32 addr, len; int num; + int ret; - rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 2); + ret = rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 2); + if (ret) + return ret; num = sscanf(tmp, "%x %x", &addr, &len); if (num != 2) - return count; + return -EINVAL; if (len != 1 && len != 2 && len != 4) { rtw_warn(rtwdev, "read reg setting wrong len\n"); @@ -286,8 +291,11 @@ static ssize_t rtw_debugfs_set_rsvd_page(struct file *filp, char tmp[32 + 1]; u32 offset, page_num; int num; + int ret; - rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 2); + ret = rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 2); + if (ret) + return ret; num = sscanf(tmp, "%d %d", &offset, &page_num); @@ -312,8 +320,11 @@ static ssize_t rtw_debugfs_set_single_input(struct file *filp, char tmp[32 + 1]; u32 input; int num; + int ret; - rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 1); + ret = rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 1); + if (ret) + return ret; num = kstrtoint(tmp, 0, &input); @@ -336,14 +347,17 @@ static ssize_t rtw_debugfs_set_write_reg(struct file *filp, char tmp[32 + 1]; u32 addr, val, len; int num; + int ret; - rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 3); + ret = rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 3); + if (ret) + return ret; /* write BB/MAC register */ num = sscanf(tmp, "%x %x %x", &addr, &val, &len); if (num != 3) - return count; + return -EINVAL; switch (len) { case 1: @@ -379,8 +393,11 @@ static ssize_t rtw_debugfs_set_h2c(struct file *filp, char tmp[32 + 1]; u8 param[8]; int num; + int ret; - rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 3); + ret = rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 3); + if (ret) + return ret; num = sscanf(tmp, "%hhx,%hhx,%hhx,%hhx,%hhx,%hhx,%hhx,%hhx", ¶m[0], ¶m[1], ¶m[2], ¶m[3], @@ -390,7 +407,9 @@ static ssize_t rtw_debugfs_set_h2c(struct file *filp, return -EINVAL; } + mutex_lock(&rtwdev->mutex); rtw_fw_h2c_cmd_dbg(rtwdev, param); + mutex_unlock(&rtwdev->mutex); return count; } @@ -404,17 +423,22 @@ static ssize_t rtw_debugfs_set_rf_write(struct file *filp, char tmp[32 + 1]; u32 path, addr, mask, val; int num; + int ret; - rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 4); + ret = rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 4); + if (ret) + return ret; num = sscanf(tmp, "%x %x %x %x", &path, &addr, &mask, &val); if (num != 4) { rtw_warn(rtwdev, "invalid args, [path] [addr] [mask] [val]\n"); - return count; + return -EINVAL; } + mutex_lock(&rtwdev->mutex); rtw_write_rf(rtwdev, path, addr, mask, val); + mutex_unlock(&rtwdev->mutex); rtw_dbg(rtwdev, RTW_DBG_DEBUGFS, "write_rf path:%d addr:0x%08x mask:0x%08x, val:0x%08x\n", path, addr, mask, val); @@ -432,14 +456,17 @@ static ssize_t rtw_debugfs_set_rf_read(struct file *filp, char tmp[32 + 1]; u32 path, addr, mask; int num; + int ret; - rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 3); + ret = rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 3); + if (ret) + return ret; num = sscanf(tmp, "%x %x %x", &path, &addr, &mask); if (num != 3) { rtw_warn(rtwdev, "invalid args, [path] [addr] [mask] [val]\n"); - return count; + return -EINVAL; } debugfs_priv->rf_path = path; @@ -461,7 +488,9 @@ static ssize_t rtw_debugfs_set_fix_rate(struct file *filp, char tmp[32 + 1]; int ret; - rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 1); + ret = rtw_debugfs_copy_from_user(tmp, sizeof(tmp), buffer, count, 1); + if (ret) + return ret; ret = kstrtou8(tmp, 0, &fix_rate); if (ret) { @@ -519,6 +548,8 @@ static int rtw_debug_get_rf_dump(struct seq_file *m, void *v) u32 addr, offset, data; u8 path; + mutex_lock(&rtwdev->mutex); + for (path = 0; path < rtwdev->hal.rf_path_num; path++) { seq_printf(m, "RF path:%d\n", path); for (addr = 0; addr < 0x100; addr += 4) { @@ -533,6 +564,8 @@ static int rtw_debug_get_rf_dump(struct seq_file *m, void *v) seq_puts(m, "\n"); *** 7356 LINES SKIPPED *** From nobody Fri Oct 6 14:25:23 2023 X-Original-To: dev-commits-src-branches@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 4S29gm3Wk9z4wgWY; Fri, 6 Oct 2023 14:25:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S29gm1m9yz3Rbq; Fri, 6 Oct 2023 14:25:24 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602324; 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=W9XBO3JTT0ANK405NowSvLCLBY6SXT5R5Zzh24WdpR0=; b=AhL0JobQmR8tKZ3WsH3Di9XxE8YfJ/Sc5Wse0+EuQZdNUPX52GPrxPHm+LbI+oDyluie8+ 7BT0J/NLVp/4YfLScsFEi5OnF2JGEUIOCc6eY2ohIHfoHZ1utogxz2uGRjreRzb+CIwq5f fCmP74fbBXCjhtKecAzz2VrgVJ5uPx+yHb/HvDSftGCbBTDx0VhYs3DsMfKG6Bxto7VZND W/5oDauL1cP0NJ8Ino0V4kESw8v+Pptbvn0hizk7Z8w1MBJfuW8PSl82k56Z+kklQU1UK2 f62DqfAiFWN/5k+Ga555L4eJAkP18XnRI568pydyCzWAbJFHCZij5tr+sgcUqA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696602324; a=rsa-sha256; cv=none; b=b+k48RLKtHM+lFVdE3woqcZLEnacnmlJ/NwN55Te6RXQwuq0WQj6AjB37pqoAAVBNXqcS7 kWlhJsEwRmblWf1+7VbGatQcRCOmb8vmbRTw028um+Ql7QrjFOM8wj+GCExN23cUHAALks ya/AOpqFvfcwGgDS20eOyrfnYi1UngOMbzYjW45NXyUWwMrNTG4LT6YkVfqXKiRGenboiO tS49PiLETiKVCtGbxDYbToOaUv3QOCMJoh4MbwkgbGvyuSaOoP3Tr+1SQVqtEpQCi6nDXk J0EH5xhQF6HS3556RssiAtmfJAiSPkLb5RaLmkGUzamxl2UJZ2c8pUxIA4lnTg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696602324; 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=W9XBO3JTT0ANK405NowSvLCLBY6SXT5R5Zzh24WdpR0=; b=S5s7X9BzQqbcDoBEc3FSMKyTcp05AX/8pI9N+9ZOIYgntC6QhbOhc9YNKlb9d4Bf8JdTGk izrQiVyXIw0vdU3n5OwuUB+88WSFVh0QFhIhZitiUItkSHY5vPW7tfcS2fD8sg43+VlFP0 wpKUyGu6uoa0ljZvBZCh6R0zv48mB24uDP/mLsBT+b3QGp1ot6qlKfzAAlv7DfNJ7gRFjK laiK7DV41x88EHSfjYnBy+HlUjegD9yz9xK70GNneXTsKZnsqQ9fsJfjV7oBxHyknjrXp7 b52PCytGBGdb/RgUllCxWxwhClhJQoF7kHw4uIRp/klMjPaqKfSW0ltX5z8hPQ== 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 4S29gm0bckzr9V; Fri, 6 Oct 2023 14:25:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 396EPNtE093883; Fri, 6 Oct 2023 14:25:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 396EPNQi093880; Fri, 6 Oct 2023 14:25:23 GMT (envelope-from git) Date: Fri, 6 Oct 2023 14:25:23 GMT Message-Id: <202310061425.396EPNQi093880@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 7ec227367ed7 - stable/14 - iwlwifi / rtw88: re-attach to build after updates List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: 7ec227367ed748011a97540296b0935de877cc5a Auto-Submitted: auto-generated The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=7ec227367ed748011a97540296b0935de877cc5a commit 7ec227367ed748011a97540296b0935de877cc5a Author: Bjoern A. Zeeb AuthorDate: 2023-09-21 17:12:01 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-10-06 12:47:42 +0000 iwlwifi / rtw88: re-attach to build after updates While the build-breaking changes were only in a smaller window further updates restored some functionality as well. Now that we are done, add iwlwifi back to the build. Sponsored by: The FreeBSD Foundation This also adds the (updated) rtw88 driver back to the build. Functionality has not been tested (much) so might not currently work but people offered to test. (cherry picked from commit af6aaa90057d75644c41527acc903082104e4114) (cherry picked from commit 299e2d5724c2bc4929b6eac3258f04055e97992e) --- sys/modules/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/modules/Makefile b/sys/modules/Makefile index 66d7c895a460..4b98c7ed6e0d 100644 --- a/sys/modules/Makefile +++ b/sys/modules/Makefile @@ -561,12 +561,12 @@ _mlx5ib= mlx5ib ${MACHINE_CPUARCH} == "i386" _ena= ena _gve= gve -#_iwlwifi= iwlwifi +_iwlwifi= iwlwifi .if ${MK_SOURCELESS_UCODE} != "no" _iwlwififw= iwlwififw .endif _ossl= ossl -#_rtw88= rtw88 +_rtw88= rtw88 .if ${MK_SOURCELESS_UCODE} != "no" _rtw88fw= rtw88fw .endif From nobody Sat Oct 7 02:48:57 2023 X-Original-To: dev-commits-src-branches@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 4S2V9j6C9bz4wY7L; Sat, 7 Oct 2023 02:48:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S2V9j5hnnz3LKk; Sat, 7 Oct 2023 02: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=1696646937; 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=uzTXzgUPs5Q2uX1rp5rKsTKMRXZQev6yF4CBai8FN/A=; b=j+hRLa7SlXl/y7RaCA1PMN6Jbu5RsejBwJV8vuAw+aHz50tD3G1Z3e9zVzM18OryZcR37n ngsZSEuVdhz6re7EO7/lkMVieAxiVTYXzfcthFzyPkxfJiJGzJOQCwm99C08tr2GISy3Wy 65pocxJ8TUTVINBYH1DAZMYqqUVkYVvu5loyZ9C5QKYQBFzn9DLbPmW+4tG3L05z+EUdNX rP89yaQS5lxtrUBKSrK0hJpPJ2uWhk1RmGrNrTWBtsdto/yT0TNhUIqm3QWyzPCA5+kAAs GgDiLGSiuDnrm84B8l4uzlerT2sJHANRuI9p56nNe7p5xE+mfUKArE7nrfgjhA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696646937; a=rsa-sha256; cv=none; b=WeekiBoHcPgEYnyoD8CtlMFTQEoH4HgfRnHxGK76PgNgoioB+zPdcN7D0F6Tm5zAPK4c26 Ot8bq6OlF3JANjed/+SSYklthVTRd+cl0vnLPcETu9gklPbiIhzHbij/1tytlNDh9F/yTv 6DTIVHUVoQYq/EgyQEEbZewe+b+SXUIczzaN5mmZ3sh90kVfld6/E6Y2WCyt9jLpFZBIho dAZPWlayAUyjaKQGG5dPwZrmEDaSuuR670LfYwiQdf4OJ+EtJ7k1mKVUIEMlwezbWVrSWN vldnZonKAmC1Ka844U3vOssFL3D56AReB3LuFDSEIjxPM3hsaWT+wm4sz/0rEQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696646937; 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=uzTXzgUPs5Q2uX1rp5rKsTKMRXZQev6yF4CBai8FN/A=; b=fprliSh1q2A/x65jeslsxcnngBxS6xf6JHB/GYJuZpBfhuodypLmurSUUQubfJVF/BRl/K JV2ftLAYmCMiY2zLduu7Pzo9ZRT/dUsjMrYwb50PskzAUtxV7pHhTJtWkEccg9hL7ZQ1B+ WvvlAXy+itMCT14fmU6kXTP6nsK/SvothFUDGm0aYJppnw/C1Rt/IY4EVeDY+ZX/WJYv+k L+ZoNYEUZNa1Grv34hgVnVsjz3fdQ86BDXQ7tVHFj23MIn7wWJp+tinkuzTPCQrFF3cdcT plNBVsyTFMJNmpJ3c2DosPw8N382kz+rlh21SF57G9YB86TxrJdiC+sM28WYUQ== 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 4S2V9j4mKNz1Csr; Sat, 7 Oct 2023 02:48:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3972mv2L022988; Sat, 7 Oct 2023 02:48:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3972mvNQ022985; Sat, 7 Oct 2023 02:48:57 GMT (envelope-from git) Date: Sat, 7 Oct 2023 02:48:57 GMT Message-Id: <202310070248.3972mvNQ022985@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alan Somers Subject: git: d67558ef3149 - releng/14.0 - Fix padding in struct tcp_info List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: asomers X-Git-Repository: src X-Git-Refname: refs/heads/releng/14.0 X-Git-Reftype: branch X-Git-Commit: d67558ef3149c02223fd15206c8c7766f6891be2 Auto-Submitted: auto-generated The branch releng/14.0 has been updated by asomers: URL: https://cgit.FreeBSD.org/src/commit/?id=d67558ef3149c02223fd15206c8c7766f6891be2 commit d67558ef3149c02223fd15206c8c7766f6891be2 Author: Alan Somers AuthorDate: 2023-09-17 14:22:08 +0000 Commit: Alan Somers CommitDate: 2023-10-07 02:48:17 +0000 Fix padding in struct tcp_info This structure should have the same size across different FreeBSD versions to ensure backwards-compatibility. It has since stable/6. But two recent changes added fields without compensating by reducing padding: 945f9a7cc9dcc071bfcc702748fbbb11087ae773 and 22c81cc51636cfebe94e0979eb31556d87775938 . Reduce padding to compensate. Direct commit to stable/14 because we decided to break compatibility in FreeBSD 15 in order to add more fields. Of course, that decision could be reversed before 15.0-RELEASE. See the review for details. PR: 273902 Reviewed by: tuexen, glebius Differential Revision: https://reviews.freebsd.org/D41894 Approved by: gjb (re) (cherry picked from commit 2209676efe9a23d9411fa0314b9c6bb285baefc1) --- sys/netinet/tcp.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netinet/tcp.h b/sys/netinet/tcp.h index 2b898d062b0d..bfb825930c66 100644 --- a/sys/netinet/tcp.h +++ b/sys/netinet/tcp.h @@ -434,7 +434,7 @@ struct tcp_info { u_int32_t tcpi_dupacks; /* Consecutive dup ACKs recvd */ /* Padding to grow without breaking ABI. */ - u_int32_t __tcpi_pad[14]; /* Padding. */ + u_int32_t __tcpi_pad[10]; /* Padding. */ }; /* From nobody Sat Oct 7 15:36:41 2023 X-Original-To: dev-commits-src-branches@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 4S2qCY4g1yz4wkj3; Sat, 7 Oct 2023 15:36: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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4S2qCY4Fk9z4v45; Sat, 7 Oct 2023 15:36:41 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696693001; 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=w8BCtbtN7/ZJzrFOugZ91IphoZar7i45nsdAcxFINjk=; b=Z79BN01fPTlgffflKzGpuhPRlcJKUTw3DWbznOhx28dszn9NQkmnTCmBxtsx7XBbxLyqez oYoePBcRaexQcAx1gLBY17L/ARrzUwLACtoAYZHyhnqkujpW5jiv1Hlw3l0QwNqC94U1Cj uH187aIVmuOnGNeHCJV9rsp5wr9GhoxnzbzaPa20qjsre1sYgclCj1Qe76fKZA0WaJF6jG C3ld9KBLOZCjhJIuSyi8l3+kpx3Ny/lLFRe/CJYtQlckM0O3ZaNlCSWcj0A/PXndS6ainn nK6frgHdq9DSC42iRr43rIObak5I3ANo/CaNpFEuejKMrHx2RIIJiuYqk/ooBA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1696693001; a=rsa-sha256; cv=none; b=mmnIV0WwRkJ1v6YzSD+rNrWI1p19QfAOKSrM3EdcGBpDxiggbk/EjBlBzCSqKvxjdg67JL aBaHwiEQ8HFpk9nkiUsNt65abrVWft7C719kB3TwgTRm5ZEJUkZa2TwGi5p0LChSWu2HZv O+qYaTnkoLeUOOXJtLFPkFcJtTx/VUiVHOL58E6Et6/DTwiLHrn6ePgO/uefECbnSAuZqH xehxnuMrJ8j5bFyO9zfslQUlqUBU0T7yf2ZXLmrorgvOOgsrvaApNkPjzVd5k7j9iye63S d1F/zxLa7yX6XcnKlOtEIw95uxpY8dFRnHWbqp/T/TMcultGGT5maoDBxIr2JQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1696693001; 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=w8BCtbtN7/ZJzrFOugZ91IphoZar7i45nsdAcxFINjk=; b=MN6t3AYOH64Svp21Z2Hc4e5HLJmANux6XqFuvL+pLCqsiDkdgngKR68iRhZECfArYKko7P hBniS0jzpvgusIou0GlBanNq9m5mNyw98gNZmIQetT4TtpnD2tLhFkktwZjBkxhIuYS1Au TAkkuQrRO+l8f+Jzxiv+/plYsUYmmOOvUwXawyZq3FWjFbeSNNsSbV8TI2J2yoqPnOa1Yi 3DzvO7XAPtSlZ+77isCHLgEC9qLw/Ygh69fszrBKcCyjNSvALDn/YunZphnkl+BuFSN8Ls PZawY/W3ndd6NKbswdMqtfDah2VyeYLeG1vpPEiSuYEZNBdYB+78FxafRX/nDg== 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 4S2qCY3BL0zbZC; Sat, 7 Oct 2023 15:36:41 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 397FafeJ003857; Sat, 7 Oct 2023 15:36:41 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 397Fafi9003854; Sat, 7 Oct 2023 15:36:41 GMT (envelope-from git) Date: Sat, 7 Oct 2023 15:36:41 GMT Message-Id: <202310071536.397Fafi9003854@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: f69181e9de1b - stable/14 - pf: cope with missing rpool.cur List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@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/stable/14 X-Git-Reftype: branch X-Git-Commit: f69181e9de1b021f4689ce50b420f9c694268ec8 Auto-Submitted: auto-generated The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=f69181e9de1b021f4689ce50b420f9c694268ec8 commit f69181e9de1b021f4689ce50b420f9c694268ec8 Author: Kristof Provost AuthorDate: 2023-10-03 15:11:44 +0000 Commit: Kristof Provost CommitDate: 2023-10-07 07:39:04 +0000 pf: cope with missing rpool.cur If we're evaluating a pfsync'd state (and have different rules on both ends) our state may point to the default rule, which does not have rpool.cur set. As a result we can end up dereferencing a NULL pointer. Explicitly check for this when we try to re-construct the route-to interface. Also add a test case which can trigger this issue. MFC after: 3 days See also: https://redmine.pfsense.org/issues/14804 Sponsored by: Rubicon Communications, LLC ("Netgate") (cherry picked from commit 74c2461386ea5eeb41e674df6b16a44b0509a882) --- sys/netpfil/pf/pf.c | 9 ++-- tests/sys/netpfil/pf/pfsync.sh | 96 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 101 insertions(+), 4 deletions(-) diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c index 3e1c8d32add9..fae0bd2854f9 100644 --- a/sys/netpfil/pf/pf.c +++ b/sys/netpfil/pf/pf.c @@ -6978,7 +6978,7 @@ pf_route(struct mbuf **m, struct pf_krule *r, struct ifnet *oifp, } else { ifp = s->rt_kif ? s->rt_kif->pfik_ifp : NULL; /* If pfsync'd */ - if (ifp == NULL) + if (ifp == NULL && r->rpool.cur != NULL) ifp = r->rpool.cur->kif ? r->rpool.cur->kif->pfik_ifp : NULL; PF_STATE_UNLOCK(s); @@ -7035,9 +7035,10 @@ pf_route(struct mbuf **m, struct pf_krule *r, struct ifnet *oifp, s->rt_addr.v4.s_addr; ifp = s->rt_kif ? s->rt_kif->pfik_ifp : NULL; /* If pfsync'd */ - if (ifp == NULL) + if (ifp == NULL && r->rpool.cur != NULL) { ifp = r->rpool.cur->kif ? r->rpool.cur->kif->pfik_ifp : NULL; + } PF_STATE_UNLOCK(s); } @@ -7191,7 +7192,7 @@ pf_route6(struct mbuf **m, struct pf_krule *r, struct ifnet *oifp, } else { ifp = s->rt_kif ? s->rt_kif->pfik_ifp : NULL; /* If pfsync'd */ - if (ifp == NULL) + if (ifp == NULL && r->rpool.cur != NULL) ifp = r->rpool.cur->kif ? r->rpool.cur->kif->pfik_ifp : NULL; PF_STATE_UNLOCK(s); @@ -7249,7 +7250,7 @@ pf_route6(struct mbuf **m, struct pf_krule *r, struct ifnet *oifp, &s->rt_addr, AF_INET6); ifp = s->rt_kif ? s->rt_kif->pfik_ifp : NULL; /* If pfsync'd */ - if (ifp == NULL) + if (ifp == NULL && r->rpool.cur != NULL) ifp = r->rpool.cur->kif ? r->rpool.cur->kif->pfik_ifp : NULL; } diff --git a/tests/sys/netpfil/pf/pfsync.sh b/tests/sys/netpfil/pf/pfsync.sh index d62cdddd504a..91c7b8410a08 100644 --- a/tests/sys/netpfil/pf/pfsync.sh +++ b/tests/sys/netpfil/pf/pfsync.sh @@ -825,6 +825,101 @@ basic_ipv6_cleanup() pfsynct_cleanup } +atf_test_case "route_to" "cleanup" +route_to_head() +{ + atf_set descr 'Test route-to with default rule' + atf_set require.user root + atf_set require.progs scapy +} + +route_to_body() +{ + pfsynct_init + + epair_sync=$(vnet_mkepair) + epair_one=$(vnet_mkepair) + epair_two=$(vnet_mkepair) + epair_out_one=$(vnet_mkepair) + epair_out_two=$(vnet_mkepair) + + vnet_mkjail one ${epair_one}a ${epair_sync}a ${epair_out_one}a + vnet_mkjail two ${epair_two}a ${epair_sync}b ${epair_out_two}a + + # pfsync interface + jexec one ifconfig ${epair_sync}a 192.0.2.1/24 up + jexec one ifconfig ${epair_one}a 198.51.100.1/24 up + jexec one ifconfig ${epair_out_one}a 203.0.113.1/24 up + jexec one ifconfig ${epair_out_one}a name outif + jexec one sysctl net.inet.ip.forwarding=1 + jexec one arp -s 203.0.113.254 00:01:02:03:04:05 + jexec one ifconfig pfsync0 \ + syncdev ${epair_sync}a \ + maxupd 1 \ + up + + jexec two ifconfig ${epair_sync}b 192.0.2.2/24 up + jexec two ifconfig ${epair_two}a 198.51.100.2/24 up + jexec two ifconfig ${epair_out_two}a 203.0.113.2/24 up + #jexec two ifconfig ${epair_out_two}a name outif + jexec two sysctl net.inet.ip.forwarding=1 + jexec two arp -s 203.0.113.254 00:01:02:03:04:05 + jexec two ifconfig pfsync0 \ + syncdev ${epair_sync}b \ + maxupd 1 \ + up + + # Enable pf! + jexec one pfctl -e + pft_set_rules one \ + "set skip on ${epair_sync}a" \ + "pass out route-to (outif 203.0.113.254)" + jexec two pfctl -e + + # Make sure we have different rulesets so the synced state is associated with + # V_pf_default_rule + pft_set_rules two \ + "set skip on ${epair_sync}b" \ + "pass out route-to (outif 203.0.113.254)" \ + "pass out proto tcp" + + ifconfig ${epair_one}b 198.51.100.254/24 up + ifconfig ${epair_two}b 198.51.100.253/24 up + route add -net 203.0.113.0/24 198.51.100.1 + ifconfig ${epair_two}b up + ifconfig ${epair_out_one}b up + ifconfig ${epair_out_two}b up + + atf_check -s exit:0 env PYTHONPATH=${common_dir} \ + ${common_dir}/pft_ping.py \ + --sendif ${epair_one}b \ + --fromaddr 198.51.100.254 \ + --to 203.0.113.254 \ + --recvif ${epair_out_one}b + + # Allow time for sync + ifconfig ${epair_one}b inet 198.51.100.254 -alias + route del -net 203.0.113.0/24 198.51.100.1 + route add -net 203.0.113.0/24 198.51.100.2 + + sleep 2 + + # Now try to trigger the state on the other pfsync member + env PYTHONPATH=${common_dir} \ + ${common_dir}/pft_ping.py \ + --sendif ${epair_two}b \ + --fromaddr 198.51.100.254 \ + --to 203.0.113.254 \ + --recvif ${epair_out_two}b + + true +} + +route_to_cleanup() +{ + pfsynct_cleanup +} + atf_init_test_cases() { atf_add_test_case "basic" @@ -837,4 +932,5 @@ atf_init_test_cases() atf_add_test_case "timeout" atf_add_test_case "basic_ipv6_unicast" atf_add_test_case "basic_ipv6" + atf_add_test_case "route_to" }